Final

Dependencies:   mbed

Fork of MiniProject5_LightTracker by Austin Sloop

Revision:
13:871d01d0d250
Parent:
11:7b3d64a66efd
Child:
14:69cad6d9a2e5
--- a/SegDisplay.cpp	Tue Jan 12 00:06:10 2016 +0000
+++ b/SegDisplay.cpp	Tue Jan 12 01:12:23 2016 +0000
@@ -29,12 +29,11 @@
     return SegByte;
 }
 
-void SegDisplay(int x, bool negative)
+void SegDisplay(int x)
 {
-    while(1)
+    for(int i=0;i<25;i++)
     {
-        if(negative ==1){Negative =1;}
-        
+        if(x<0){Negative=1;}
         Display1 =1;
         Display = SegConvert(x/10);
         wait(.001);
@@ -43,7 +42,7 @@
         Display10 = 1;
         Display = SegConvert(x%10);
         wait(.001);
-        Display10=0;    
-    }    
+        Display10=0;  
+    }     
 }