Table of Contents

Class TransmitterChannel

Namespace
nanoFramework.Hardware.Esp32.Rmt
Assembly
nanoFramework.Hardware.Esp32.Rmt.dll

A class that can be used to create and transmit RMT commands on ESP32

public class TransmitterChannel : RmtChannel, IDisposable
Inheritance
TransmitterChannel
Implements
Inherited Members
Extension Methods

Remarks

For detailed explanation of ESP32 RMT Module, please check the Espressif official documentation here: https://docs.espressif.com/projects/esp-idf/en/v4.4.3/esp32/api-reference/peripherals/rmt.html

Constructors

TransmitterChannel(TransmitChannelSettings)

Initializes a new instance of the TransmitterChannel class.

public TransmitterChannel(TransmitChannelSettings settings)

Parameters

settings TransmitChannelSettings

The channel settings to use.

Exceptions

ArgumentNullException

settings cannot be null.

Properties

CarrierLevel

Gets or sets a value indicating at which level of RMT output is the carrier wave applied. true = HIGH.

public bool CarrierLevel { get; set; }

Property Value

bool

EnableLooping

Gets or sets a value indicating whether to enable or disable looping through the ring buffer when transmitting RmtCommands.

public bool EnableLooping { get; set; }

Property Value

bool

IdleLevel

Gets or sets a value indicating the RMT idle level. true = HIGH.

public bool IdleLevel { get; set; }

Property Value

bool

IsChannelIdle

Gets a value indicating whether the channel is in idle mode.

public bool IsChannelIdle { get; }

Property Value

bool

this[int]

Access a command from the array of commands that will be sent

public RmtCommand this[int index] { get; set; }

Parameters

index int

Index into RMTCommand array

Property Value

RmtCommand

RMT command from index

LoopCount

Gets or sets the maximum transmission loop count. Only applicable if EnableLooping is set to true.

public int LoopCount { get; set; }

Property Value

int

Remarks

This configuration is not available on the base ESP32 target and will be ignored. Please refer to the ESP32 IDF docs for more information on feature availability for the various ESP32 targets.

Mode

Gets the current ChannelMode for this instance.

public override ChannelMode Mode { get; }

Property Value

ChannelMode

Methods

AddCommand(RmtCommand)

Add new RMT command to the list of commands that will be sent

public void AddCommand(RmtCommand cmd)

Parameters

cmd RmtCommand

RmtCommand to Add

ClearCommands()

Clear list of commands.

public void ClearCommands()

Dispose()

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

public void Dispose()

Dispose(bool)

protected virtual void Dispose(bool disposing)

Parameters

disposing bool

Finalize()

protected override void Finalize()

Send(bool)

Send the filled RMT commands to the transmitter

public void Send(bool waitTxDone)

Parameters

waitTxDone bool

If true wait the TX process to end, false function returns without waiting, but if another command is send before the end of the previous process an error will occur.

SendData(byte[], bool)

Send a RAW data to RMT module

public void SendData(byte[] data, bool waitTxDone)

Parameters

data byte[]

byte array of data for tx module ready for native function

waitTxDone bool