|
LEDDriver_NXP_Arduino 1.0.3
LED driver device operation sample code for Arduino
|
#include <LEDDriver.h>
Public Types | |
| enum | board { NONE , ARDUINO_SHIELD } |
Public Member Functions | |
| LEDDriver (uint8_t n_ch, uint8_t PWM_r, uint8_t oe) | |
| virtual void | reg_access (uint8_t reg, uint8_t val)=0 |
| virtual void | reg_access (uint8_t reg, uint8_t *vp, int len)=0 |
| virtual uint8_t | reg_access (uint8_t reg)=0 |
| virtual void | reg_access_r (uint8_t reg, uint8_t *vp, int len)=0 |
| void | pwm (uint8_t ch, float value) |
| void | pwm (float *values) |
| void | buffer_enable (bool flag) |
| void | flush (void) |
Public Attributes | |
| const uint8_t | n_channel |
Protected Attributes | |
| const uint8_t | reg_PWM |
| const uint8_t | oe_pin |
LEDDriver class
LEDDriver class is a base class for all LED drivers All actual device class will be derived from this class
Definition at line 35 of file LEDDriver.h.
| enum LEDDriver::board |
Definition at line 38 of file LEDDriver.h.
| LEDDriver::LEDDriver | ( | uint8_t | n_ch, |
| uint8_t | PWM_r, | ||
| uint8_t | oe ) |
Definition at line 5 of file LEDDriver.cpp.
|
virtual |
Definition at line 10 of file LEDDriver.cpp.
| void LEDDriver::buffer_enable | ( | bool | flag | ) |
Buffer mode enable/Disable
| flag | 'true' for enabling |
Definition at line 47 of file LEDDriver.cpp.
| void LEDDriver::flush | ( | void | ) |
| void LEDDriver::pwm | ( | float * | values | ) |
Set PWM value for all channels
| values | pointer to PWM values in float (0.0 ~ 1.0) |
Definition at line 26 of file LEDDriver.cpp.
| void LEDDriver::pwm | ( | uint8_t | ch, |
| float | value ) |
Set PWM value for a channel
| ch | channel number |
| value | PWM value in float (0.0 ~ 1.0) |
Definition at line 16 of file LEDDriver.cpp.
| const uint8_t LEDDriver::n_channel |
Definition at line 75 of file LEDDriver.h.
|
protected |
Definition at line 79 of file LEDDriver.h.
|
protected |
Definition at line 78 of file LEDDriver.h.