Plamen Totev
/
keypad_with_beep1
beep keypad
Fork of Autus by
main.cpp
- Committer:
- umairaftab
- Date:
- 2014-03-06
- Revision:
- 2:97a458c4c997
- Parent:
- 1:9ef26efedcea
- Child:
- 4:0cd0c7fe0682
File content as of revision 2:97a458c4c997:
#include "mbed.h" #define BAUDRATE0 1200 #include "keypad.h" #include "buzz.h" Serial pc(PTE20,PTE21); Ticker timer1ms; int main(void) { timer1ms.attach(&timer1, 0.001); //interrupt attached function(timer) with interval (1 ms) pc.baud( BAUDRATE0 ); char key; // lcd.cls(); while(1) { // lcd.cls(); key = Keypad(); //if (key!=NULL) //{} pc.printf("k\n"); wait(0.2); // if(key != 100) { // pc.printf("keypad = %f\n", key); // } // lcd.printf("%c\n\r",&key); //wait(0.2); }