Auberon Tatum / Mbed 2 deprecated Accel_test_LCD1Modular

Dependencies:   mbed

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers Precision.cpp Source File

Precision.cpp

00001 #include "header.h"
00002 
00003 
00004 extern float X;
00005 extern float Y;
00006 extern float Z;
00007 extern float xout;
00008 extern float yout;
00009 extern float zout;
00010 
00011 // Precision Mode
00012 void Precise(void){
00013  lcd.cls();
00014  while(1){
00015  SigCon();
00016         lcd.locate(1,1);  lcd.printf("X=");  lcd.printf("%.2f",X); //print to screen
00017         lcd.locate(1,3);  lcd.printf("Y=");  lcd.printf("%.2f",Y);
00018         lcd.locate(1,5);  lcd.printf("Z=");  lcd.printf("%.2f",Z); //only for testing
00019         lcd.locate(1,7);  lcd.printf("%.2f" ,xout);              // help with fine tuning by showing accelerations
00020         lcd.locate(1,9);  lcd.printf("%.2f" ,yout);
00021         lcd.locate(1,11); lcd.printf("%.2f" ,zout);          //dont know why but out by factor of 10
00022         wait_ms(5);
00023         but3.fall(&menuscreen);
00024                             }
00025            }