Experiment 2 from "Hacker's workbook"

Dependencies:   mbed

Files at this revision

API Documentation at this revision

Comitter:
artemlevenkov
Date:
Wed Sep 17 10:43:29 2014 +0000
Commit message:
Experiment 2 done.

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	Wed Sep 17 10:43:29 2014 +0000
@@ -0,0 +1,20 @@
+#include "mbed.h"
+
+PwmOut led(D9);
+
+int main(void)
+{
+    while(true) {
+        led = 1./3.;
+        
+        wait(0.25);
+        
+        led = 2./3.;
+        
+        wait(0.25);
+        
+        led = 1.;
+        
+        wait(0.25);
+    }
+}
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/mbed.bld	Wed Sep 17 10:43:29 2014 +0000
@@ -0,0 +1,1 @@
+http://mbed.org/users/mbed_official/code/mbed/builds/552587b429a1
\ No newline at end of file