Tests forked Keypad library.
Dependencies: FPointer keypad mbed
Schematic:
No extra hardware is needed besides the wires and switches. The columns are outputs configured with open drain. The rows are inputs configured with pull up resistors. A key press pulls down its row. With scanning the column is determined thereafter.
See keypad for the forked library used in this project.
Diff: main.cpp
- Revision:
- 4:16191e501b63
- Parent:
- 3:fb173f712440
diff -r fb173f712440 -r 16191e501b63 main.cpp --- a/main.cpp Sun Nov 04 09:50:00 2012 +0000 +++ b/main.cpp Sun Nov 04 09:56:51 2012 +0000 @@ -65,7 +65,7 @@ // poll multiple mode keypad.Start(); while (1) { - key = keypad.DebouncedScanMultiple(); + int key = keypad.DebouncedScanMultiple(); if (key > 0) cbAfterMultipleInput(key); wait(0.1);