Alexandre Lemay / Mbed 2 deprecated APP1_s5_A17

Dependencies:   mbed MMA8452

Revision:
6:909e7877d915
Parent:
2:3576839565ae
Child:
8:5124be43c963
--- a/Afficheur.cpp	Tue Sep 05 00:05:38 2017 +0000
+++ b/Afficheur.cpp	Tue Sep 05 05:51:17 2017 +0000
@@ -9,11 +9,18 @@
         chipSelect = 0;
     }
     
-    void Afficheur::write(char* characters,int length ) 
+    void Afficheur::write(char* characters,int length,int expo ) 
     {
+        
+Serial pc(USBTX, USBRX);
+        pc.printf("1");
         static char buf[20];
+        pc.printf("2");
         resetDisplay();
-        afficheur.write(characters,length,buf,20);      
+        pc.printf("3");
+        afficheur.write(characters,length,buf,20);
+        pc.printf("4");
+        showDot(expo);    
     }
     void Afficheur::write(char ch)
     {
@@ -25,9 +32,9 @@
         char buf[1];
         afficheur.write("v",1,buf,1);
     }
-    void Afficheur::showDot()
+    void Afficheur::showDot(int expo)
     {
-        char command[2] = {'w',2};
+        char command[2] = {'w',expo};
         char buf[2];
         afficheur.write(command,2,buf, 2);
     }