Exo

Dependencies:   mbed

Revision:
8:0bbcd33e7811
Child:
10:4c838a5a5e42
diff -r d8f260604fc4 -r 0bbcd33e7811 Nboard.cpp
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Nboard.cpp	Fri Sep 30 22:01:44 2016 +0000
@@ -0,0 +1,45 @@
+#include "IHM.h"
+
+IHM ihm;
+Serial pc(SERIAL_TX, SERIAL_RX);
+
+int main()
+{
+    unsigned char i=0,j;
+    float pi=4*atan(1.0);
+    pc.printf("debut");
+    ihm.LCD_printf("Hello World      ");
+    ihm.LCD_gotoxy(1,0);
+    ihm.LCD_printf("PI= %f",pi);  // test affichage float
+    ihm.BAR_set(0x3FF);
+    wait(2);
+    ihm.BAR_set(0x2AA);
+    wait(2);
+    ihm.BAR_set(0x155);
+    wait(2);
+    ihm.LCD_clear();
+    while(1) {
+        wait(0.1);
+        printf("cod");
+        i=ihm.COD_read();
+        
+        j=ihm.JOG_read();
+        ihm.BAR_set((UINT16)(i));
+        ihm.LCD_gotoxy(0,0);
+        ihm.LCD_printf("Jog=%02d",j);
+        ihm.LCD_gotoxy(1,0);
+        ihm.LCD_printf("Cod=%03d",i);
+  //      a=robot.bp(0);
+  //      b=robot.bp(1);
+  //      c=robot.bp(2);
+  //      d=robot.bp(3);
+  //      robot.led(i);
+   //     robot.LCD_gotoxy(1,0);
+  //      robot.LCD_printf("B0=%dB1=%dB2=%dB3=%d",a,b,c,d);
+        //pc.printf("jog %d \n",j);
+    }
+}
+
+
+
+