My Project
 All Classes Functions Variables Pages
Public Member Functions | List of all members
RMT Class Reference

Drive the RMT peripheral. More...

#include <RMT.h>

Public Member Functions

 RMT (gpio_num_t pin, rmt_channel_t channel=RMT_CHANNEL_0)
 Create a class instance. More...
 
virtual ~RMT ()
 Class destructor.
 
void add (bool level, uint32_t duration)
 Add a level/duration to the transaction to be written. More...
 
void clear ()
 Clear any previously written level/duration pairs that have not been sent.
 
void rxStart ()
 Start receiving.
 
void rxStop ()
 Stop receiving.
 
void txStart ()
 Start transmitting.
 
void txStop ()
 Stop transmitting.
 
void write ()
 Write the items out through the RMT. More...
 

Detailed Description

Drive the RMT peripheral.

Constructor & Destructor Documentation

RMT::RMT ( gpio_num_t  pin,
rmt_channel_t  channel = RMT_CHANNEL_0 
)

Create a class instance.

Parameters
[in]pinThe GPIO pin on which the signal is sent/received.
[in]channelThe RMT channel to work with.

Member Function Documentation

void RMT::add ( bool  level,
uint32_t  duration 
)

Add a level/duration to the transaction to be written.

Parameters
[in]levelThe level of the bit to output.
[in]durationThe duration of the bit to output.
void RMT::write ( )

Write the items out through the RMT.

The level/duration set of bits that were added to the transaction are written out through the RMT device. After transmission, the list of level/durations is cleared.


The documentation for this class was generated from the following files: