MTU COMP71004 Summer 2021 / Mbed 2 deprecated lect7_4_serial

Dependencies:   mbed

Files at this revision

API Documentation at this revision

Comitter:
kinii
Date:
Thu Jul 08 19:27:20 2021 +0000
Commit message:
simple passthru example

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	Thu Jul 08 19:27:20 2021 +0000
@@ -0,0 +1,13 @@
+#include "mbed.h"
+
+Serial pc(USBTX, USBRX);
+Serial wifi(p9, p10);
+
+int main() {
+    while(1) {
+        if(pc.readable())
+            wifi.putc(pc.getc());
+        if(wifi.readable())
+            pc.putc(wifi.getc());
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/mbed.bld	Thu Jul 08 19:27:20 2021 +0000
@@ -0,0 +1,1 @@
+https://os.mbed.com/users/mbed_official/code/mbed/builds/65be27845400
\ No newline at end of file