|
FastLED 3.9.15
|
A skeletal implementation of hardware SPI support.
Fill in the necessary code for init, waiting, and writing. The rest of the method implementations should provide a starting point, even if they're not the most efficient to start with
Definition at line 19 of file fastspi_ref.h.
#include <fastspi_ref.h>
Collaboration diagram for REFHardwareSPIOutput< _DATA_PIN, _CLOCK_PIN, _SPI_CLOCK_DIVIDER >:Public Member Functions | |
| void | init () |
| initialize the SPI subssytem | |
| void | release () |
| release the CS select | |
| SAMHArdwareSPIOutput (Selectable *pSelect) | |
| Constructor with selectable. | |
| SAMHardwareSPIOutput () | |
| Default Constructor. | |
| void | select () |
| latch the CS select | |
| void | setSelect (Selectable *pSelect) |
| set the object representing the selectable | |
| template<class D> | |
| void | writeBytes (FASTLED_REGISTER fl::u8 *data, int len) |
| A full cycle of writing a value for len bytes, including select, release, and waiting. | |
| void | writeBytes (FASTLED_REGISTER fl::u8 *data, int len) |
| A full cycle of writing a value for len bytes, including select, release, and waiting. | |
| void | writeBytesValue (fl::u8 value, int len) |
| A full cycle of writing a value for len bytes, including select, release, and waiting. | |
| template<fl::u8 FLAGS, class D, EOrder RGB_ORDER> | |
| void | writePixels (PixelController< RGB_ORDER > pixels, void *context=NULL) |
| write a block of uint8_ts out in groups of three. | |
Static Public Member Functions | |
| static void | waitFully () |
| wait until all queued up data has been written | |
| template<fl::u8 BIT> | |
| static void | writeBit (fl::u8 b) |
| write a single bit out, which bit from the passed in byte is determined by template parameter | |
| static void | writeByte (fl::u8 b) |
| write a byte out via SPI (returns immediately on writing register) | |
| static void | writeBytesValueRaw (fl::u8 value, int len) |
| A raw set of writing byte values, assumes setup/init/waiting done elsewhere. | |
| static void | writeWord (uint16_t w) |
| write a word out via SPI (returns immediately on writing register) | |
Private Attributes | |
| Selectable * | m_pSelect |