pwm period is now 200us instead of the default 20ms veml6040 config is now AF_BIT | TRIG_BIT
Dependencies: mbed MMA8451Q USBDevice WakeUp vt100
Fork of afero_node_suntory_2017_06_15 by
Diff: util/BitOrder.cpp
- Revision:
- 0:20bce0dcc921
diff -r 000000000000 -r 20bce0dcc921 util/BitOrder.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/util/BitOrder.cpp Tue Dec 20 01:51:02 2016 +0000 @@ -0,0 +1,10 @@ +#include "BitOrder.h" + +static const uint8_t uint8_treverse_lookup[] = { 0, 8, 4, 12, 2, 10, 6, 14,1, 9, 5, 13,3, 11, 7, 15 }; + +uint8_t BitOrder::flip(uint8_t in) +{ + return (((uint8_treverse_lookup[(in & 0x0F)]) << 4) + uint8_treverse_lookup[((in & 0xF0) >> 4)]); +} + +