TaChing Yu / Mbed 2 deprecated 3_7SgementLED_74HC595

Dependencies:   mbed

Revision:
2:1b8ea01637ad
Parent:
1:ce89d84cafaa
--- a/main.cpp	Sun Sep 04 07:12:40 2016 +0000
+++ b/main.cpp	Sun Sep 04 07:55:10 2016 +0000
@@ -7,7 +7,7 @@
 DigitalOut zz(D12);
 DigitalOut yy(D13);
 
-const int state[10][7]= {
+const int state[10][8]= {
   { 0, 1, 1, 1, 1, 1, 1}, // 0
   { 0, 0, 0, 0, 1, 1, 0}, // 1
   { 1, 0, 1, 1, 0, 1, 1}, // 2
@@ -71,16 +71,16 @@
     {   
         seg1(round);
         r++;
-        if (r>=10)
+        if (r>=1)
         {
             round++;
             r=0;
         }
-        wait_ms(5);
+        wait_ms(1);
         seg2(round2);
-        wait_ms(5);
+        wait_ms(1);
         seg3(round3);
-        wait_ms(5);
+        wait_ms(1);
         if(round == 10)
         {
             round=0;round2++;