marohito takami / Mbed 2 deprecated atoi_test

Dependencies:   mbed

Fork of Keyboard_Interrupt by marohito takami

main.cpp

Committer:
TakamiMa
Date:
2015-06-02
Revision:
0:14317ed79bae
Child:
1:5440b3d7f435

File content as of revision 0:14317ed79bae:

#include "mbed.h"

DigitalOut myled(LED1);
Serial pc(SERIAL_TX, SERIAL_RX);

void my_Interrupt(){
    char key;
    key = pc.getc();
    pc.printf("Interrupted %c\r\n", key);
}

int main() {
    pc.attach(my_Interrupt, Serial::RxIrq);
    while(1){}
}