Elct Car Team
/
CarLab
first commit
Diff: main.cpp
- Revision:
- 24:7bf492bf50f4
- Parent:
- 23:4c743746533c
- Child:
- 25:8bd029d58251
--- a/main.cpp Wed Nov 03 21:52:00 2021 +0000 +++ b/main.cpp Thu Nov 04 17:21:18 2021 +0000 @@ -59,7 +59,7 @@ while(1) { pc.printf("\n\n"); -wait(0.1); +wait(0.5); /* bt.printf("\n\n"); bt.printf("\n\rMotor enabled ? : %d ", motor_enabled ); @@ -82,10 +82,9 @@ case LOW_VOLTAGE : bt.printf("\r\nFault: LOW VOLTAGE"); break; } bt.printf("\n\n----"); - bt.printf("\n\rLandmark triggered: %d", landmark_triggered); - bt.printf("\n\rLandmark restart: %d", restarted); - bt.printf("\n\rTimer land: %d", land.read()); - bt.printf("\n\r%f", errorArea); + bt.printf("\n\rLeft sensor %1.2f", left_distance_sensor.read()); + bt.printf("\n\rRight sensor: %1,2", right_distance_sensor.read()); + bt.printf("\n\rdifference: %1,2", abs(left_distance_sensor.read() - right_distance_sensor.read() )); //pot1Voltage = pot1 * 3.3f; //dutyCycleLeft = (pot1 * fullBatScalar);