Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Revision 14:aaa46855f00a, committed 2022-04-27
- Comitter:
- cdevarakonda
- Date:
- Wed Apr 27 11:17:56 2022 +0000
- Parent:
- 13:a9793222af20
- Child:
- 15:4976d145fbd9
- Commit message:
- Added a state where the current speed and set throttle speed are both zero for the brakes to be on high (i.e. the train must be stationary and will remain that way) It is left commented out for now
Changed in this revision
| main.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/main.cpp Wed Apr 27 09:04:11 2022 +0000
+++ b/main.cpp Wed Apr 27 11:17:56 2022 +0000
@@ -301,7 +301,14 @@
systemOn = false; // WILL STOP ABOVE HERE NEXT LOOP
pc.printf("Start Switch is Off\r\n");
}
-
+
+ ////Default Brakes on when speed is 0
+ //if(dashboard.getCurrentSpeed() ==0 && motor1.throttle == 0)
+ //{
+ // brakeValve32 = 0;//(PF_2)
+ // brakeValve22 = 0;//(PG_1)
+ //}
+ /////////////////////Left it commented out for now as unsure of the motor throttle check or to use the set speed variable
//Set foward
if (driveMode != 0 && remote.forward == 0) {
driveMode = 0;