Modules | |
Functions that Require VPRG_ENABLED | |
Functions that require VPRG_ENABLED == 1. | |
Functions | |
void | Tlc5940::init (uint16_t initialValue=0) |
Pin i/o and Timer setup. | |
void | Tlc5940::clear (void) |
Clears the grayscale data array, tlc_GSData, but does not shift in any data. | |
uint8_t | Tlc5940::update (void) |
Shifts in the data from the grayscale data array, tlc_GSData. | |
void | Tlc5940::set (TLC_CHANNEL_TYPE channel, uint16_t value) |
Sets channel to value in the grayscale data array, tlc_GSData. | |
uint16_t | Tlc5940::get (TLC_CHANNEL_TYPE channel) |
Gets the current grayscale value for a channel. | |
void | Tlc5940::setAll (uint16_t value) |
Sets all channels to value. | |
void | Tlc5940::setAllDC (uint8_t value) |
Sets the dot correction for all channels to value. | |
uint8_t | Tlc5940::readXERR (void) |
Checks for shorted/broken LEDs reported by any of the TLCs. |
void Tlc5940::clear | ( | void | ) | [inherited] |
Clears the grayscale data array, tlc_GSData, but does not shift in any data.
This call should be followed by update() if you are turning off all the outputs.
uint16_t Tlc5940::get | ( | TLC_CHANNEL_TYPE | channel | ) | [inherited] |
void Tlc5940::init | ( | uint16_t | initialValue = 0 |
) | [inherited] |
Pin i/o and Timer setup.
The grayscale register will be reset to all zeros, or whatever initialValue is set to and the Timers will start.
initialValue | = 0, optional parameter specifing the inital startup value |
uint8_t Tlc5940::readXERR | ( | void | ) | [inherited] |
Checks for shorted/broken LEDs reported by any of the TLCs.
void Tlc5940::set | ( | TLC_CHANNEL_TYPE | channel, | |
uint16_t | value | |||
) | [inherited] |
Sets channel to value in the grayscale data array, tlc_GSData.
channel | (0 to NUM_TLCS * 16 - 1). OUT0 of the first TLC is channel 0, OUT0 of the next TLC is channel 16, etc. | |
value | (0-4095). The grayscale value, 4095 is maximum. |
void Tlc5940::setAll | ( | uint16_t | value | ) | [inherited] |
Sets all channels to value.
value | grayscale value (0 - 4095) |
void Tlc5940::setAllDC | ( | uint8_t | value | ) | [inherited] |
Sets the dot correction for all channels to value.
The dot correction value correspondes to maximum output current by where
value | (0-63) |
uint8_t Tlc5940::update | ( | void | ) | [inherited] |
Shifts in the data from the grayscale data array, tlc_GSData.
If data has already been shifted in this grayscale cycle, another call to update() will immediately return 1 without shifting in the new data. To ensure that a call to update() does shift in new data, use
orwhile(tlc_needXLAT);