Simple control for ST M5451 LED driver.
Sample usage
#include "mbed.h" #include "M5451.h" M5451 m5451(D8, D7); void toggleOneByOne(){ for(char i = 0; i < m5451.outputs(); i++){ m5451.toggleBit(i); m5451.update(); wait_ms(250); m5451.toggleBit(i); } } int main() { while(1) { m5451.setAllBits(0); toggleOneByOne(); m5451.setAllBits(1); toggleOneByOne(); } }
Changes
Revision | Date | Who | Commit message |
---|---|---|---|
1:db1e69c22bc6 | 2020-03-01 | jirrick | add toggleBit |
0:b21b3517a1d6 | 2020-03-01 | jirrick | initial version |