mbed_example
/
RawSerial_ex_2
Additional RawSerial example
Diff: main.cpp
- Revision:
- 4:3ad999bfc3c4
- Parent:
- 2:4ab47f33a1ae
--- a/main.cpp Mon Jul 30 14:24:50 2018 -0500 +++ b/main.cpp Mon Jul 30 14:25:17 2018 -0500 @@ -3,7 +3,7 @@ DigitalOut led1(LED1); DigitalOut led2(LED2); -Serial pc(USBTX, USBRX); +RawSerial pc(USBTX, USBRX); void callback_ex() { // Note: you need to actually read from the serial to clear the RX interrupt @@ -13,7 +13,7 @@ int main() { pc.attach(&callback_ex); - + while (1) { led1 = !led1; wait(0.5);