homework

Dependencies:   mbed

Revision:
0:5193eafa81b6
Child:
1:3917701817b4
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/main.cpp	Fri Apr 11 10:50:46 2014 +0000
@@ -0,0 +1,24 @@
+#include "mbed.h"
+
+BusOut leds(P1_13, P1_14, P1_22, P0_17, P0_18, P0_19, P1_15, P0_1);
+
+void rotate();
+
+int main()
+{
+
+    while(1)
+    {
+        rotate();    
+    }
+}
+    
+void rotate()
+{
+    volatile uint8_t i;
+    for(i = 0x00; i < 8; i++)
+    {
+        leds = 1 << i;
+        wait(0.125);
+    }
+}
\ No newline at end of file