mini code pour xbee

Dependencies:   mbed ConfigFile EthernetInterface WebSocketClient mbed-rtos

Fork of app4Coordo by APP Team

Files at this revision

API Documentation at this revision

Comitter:
passelin
Date:
Sat Feb 22 19:12:17 2014 +0000
Child:
1:568707763458
Commit message:
mini code pour xbee

Changed in this revision

main.cpp Show annotated file Show diff for this revision Revisions of this file
mbed.bld Show annotated file Show diff for this revision Revisions of this file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/main.cpp	Sat Feb 22 19:12:17 2014 +0000
@@ -0,0 +1,22 @@
+#include "mbed.h"
+
+DigitalOut myled(LED1);
+DigitalOut reset(p8);
+Serial pc(USBTX, USBRX);
+Serial xbee(p13, p14);
+
+int main() 
+{
+    reset = 0;
+    while(1) 
+    {
+        if(xbee.readable())
+        {
+            pc.putc(xbee.getc()); 
+        }
+        if(pc.readable())
+        {
+            xbee.putc(pc.getc());      
+        }
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/mbed.bld	Sat Feb 22 19:12:17 2014 +0000
@@ -0,0 +1,1 @@
+http://mbed.org/users/mbed_official/code/mbed/builds/a9913a65894f
\ No newline at end of file