Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: Multi_WS2811 mbed MMA8451Q
Fork of WS2811 by
Diff: WS2811.cpp
- Revision:
- 9:dd524af149e6
- Parent:
- 8:e3249c2b7607
- Child:
- 10:62368b801d16
diff -r e3249c2b7607 -r dd524af149e6 WS2811.cpp
--- a/WS2811.cpp Sat Nov 10 05:58:14 2012 +0000
+++ b/WS2811.cpp Wed Nov 14 05:06:29 2012 +0000
@@ -31,6 +31,7 @@
*/
void WS2811::write(uint8_t byte) {
+ __disable_irq();
for (int i=0; i<8; i++) {
if (byte & 0x80)
writebit(1);
@@ -38,6 +39,7 @@
writebit(0);
byte <<= 1;
}
+ __enable_irq();
}
inline void WS2811::celldelay(void) {

Generic WS2811/WS2812