Start of a microbit mpr121 library
Dependents: microbitmpr121-example
Diff: MicroBitMpr121.cpp
- Revision:
- 7:ac942cee2975
- Parent:
- 6:103a5a2ca571
- Child:
- 8:cda72c6b04c0
--- a/MicroBitMpr121.cpp Mon Jan 16 21:12:52 2017 +0000 +++ b/MicroBitMpr121.cpp Mon Jan 16 21:58:16 2017 +0000 @@ -103,13 +103,9 @@ void MicroBitMpr121::registerDump() const // What is the const purpose { - int reg_val = 0; - for(int i=0; i<0x80; i++) { - reg_val = MicroBitMpr121::read8(i); // TODO Test reg_val == 0 - printf("Reg 0x%02x: 0x%02x \n", i, reg_val); + printf("Reg 0x%02x: 0x%02x \n", i, MicroBitMpr121::read8(uint8_t(i)); } - return; }