Laurent m
/
APP3
asd
main.cpp
- Committer:
- manl2003
- Date:
- 2016-02-08
- Revision:
- 0:3c2ab0fec740
File content as of revision 0:3c2ab0fec740:
#include "mbed.h" #include "CoordCommands.h" DigitalOut reset(p8); Serial pc(USBTX,USBRX); Serial xbee(p13, p14); int main() { reset = 0; wait(0.4); reset = 1; wait(1); while(xbee.readable()) { char dompe = xbee.getc(); } //Temp char panID[5]; panID[0] = 0xC0; panID[1] = 0xFF; panID[2] = 0xEE; panID[3] = 0xBA; panID[4] = 0xBE; CoordinatorCommands coord(&xbee, &pc, panID, 5); while(1) { if(pc.readable()) { xbee.putc(pc.getc()); } if(xbee.readable()) { pc.putc(xbee.getc()); } } }