Julesnaps / Mbed 2 deprecated Linefollowproject

Dependencies:   m3pi mbed

Revision:
81:a7a44a0944b5
Parent:
80:dd2134edd58b
Child:
82:f7443adac0c7
--- a/main.cpp	Tue Oct 25 09:24:01 2022 +0000
+++ b/main.cpp	Tue Oct 25 09:28:05 2022 +0000
@@ -39,16 +39,13 @@
 void PS_PitStop(void); // 
 void PS_CreateLog(void); // create a log file or resets it (WIP
 void PS_AddStopToLog(void); // Add one to the log 
-int PS_GetNumberofPS(void);  // Display the final number on screen WIP
+int PS_GetNumberofPS(void);  // Get number form file
+void PS_DisplayPS(void);
 
 void TE_CreateVoltageLog(void); //
 void TE_LogVoltage(int count); // test funktion that write the woltage each time the battry is checked
 
 
-int PitTest(void);   // Test if to robot needs to goto pit 
-void InitialMessages (void); // Prints initial message to the LCD 
-int PitTest(int gotoPit); 
-
 int main() {
     LocalFileSystem local("local"); 
     timer.start();
@@ -65,12 +62,11 @@
     float speed = MAX;
 
     /*Team 7 Variabels*/
-    
     int gotoPit = 0; // wether or not the robot is heading to pit. Initialstate false. 
     int ccount = 0; //used to count cycles
     
     /*Printing secret cat mission*/
-
+    PS_DisplayPS();
     LCD_InitialMessages();
     m3pi.sensor_auto_calibrate();
     
@@ -202,9 +198,9 @@
     
     m3pi.cls();
     m3pi.locate(0,0);
-    m3pi.printf("eliminate");
+    m3pi.printf("Destroy");
     m3pi.locate(0,1);
-    m3pi.printf("all cats");
+    m3pi.printf("cats");
     wait(200.0);
     
     m3pi.cls();
@@ -374,6 +370,4 @@
     fprintf(fptr,"%8d,%8d,%4.4f,%4.4f\n"  , timer.read()-startTime, count, m3pi.battery(),m3pi.pot_voltage()  );
     fclose(fptr);
 
-    return result;
-
 }