Stage-1 Students SoCEM / Mbed 2 deprecated Task131Solution

Dependencies:   mbed

Files at this revision

API Documentation at this revision

Comitter:
noutram
Date:
Thu Sep 24 12:24:26 2015 +0000
Commit message:
Initial version 24-09-2015

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
diff -r 000000000000 -r fed1ab4b2b50 main.cpp
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/main.cpp	Thu Sep 24 12:24:26 2015 +0000
@@ -0,0 +1,21 @@
+#include "mbed.h"
+
+//Create an instance of a Serial object called pc
+//Transmit and receive pins have names USBTX and USBRX
+Serial pc(USBTX, USBRX);
+
+int main() {
+
+    //Set the baud rate property (bits persecond)
+    pc.baud(9600);
+
+    //Run in an infinite loop
+    while(1) {
+        
+        //Call the printf method on pc
+        pc.printf("Hello World\n");
+        
+        //Wait for 1s
+        wait(1.0);
+    }
+}
diff -r 000000000000 -r fed1ab4b2b50 mbed.bld
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/mbed.bld	Thu Sep 24 12:24:26 2015 +0000
@@ -0,0 +1,1 @@
+http://mbed.org/users/mbed_official/code/mbed/builds/b9ad9a133dc7
\ No newline at end of file