
* Routeur
Diff: main.cpp
- Revision:
- 1:2abb01319ca6
- Parent:
- 0:b399a75f4990
- Child:
- 2:aebf0ae12644
--- a/main.cpp Sat Feb 11 23:45:12 2017 +0000 +++ b/main.cpp Sun Feb 12 00:01:06 2017 +0000 @@ -1,9 +1,8 @@ #include "ConfigFile.h" #include "mbed.h" -DigitalOut myled(LED1); DigitalOut reset(p8); -Serial uart(p13, p14); // tx, rx +Serial xbee(p13, p14); // tx, rx Serial pc(USBTX, USBRX); // tx, rx uint8_t calculateChecksum(uint8_t frameSize, uint8_t* buffer) { @@ -55,12 +54,12 @@ }*/ void sendFrame(uint8_t bufferSize, uint8_t* buffer) { - if (uart.writeable()) { - uart.printf("%s", buffer); + if (xbee.writeable()) { + xbee.printf("%s", buffer); } /*for (int i = 0; i < bufferSize;) { - if (uart.writeable()) { - uart.putc(buffer[i]); + if (xbee.writeable()) { + xbee.putc(buffer[i]); i++; } }*/