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.
Dependencies: millis
Diff: challenge.cpp
- Revision:
- 23:c25af9a7db8d
- Parent:
- 18:d28d458824d4
--- a/challenge.cpp	Tue May 17 10:51:36 2022 +0000
+++ b/challenge.cpp	Tue May 17 10:53:59 2022 +0000
@@ -107,7 +107,7 @@
         autoStopInProgress = true;                                  // Flag that auto-stop is in progress and fully autonomous
         autoStopCruiseSpeed = _dashboard.currentSpeed;              // Set the speed the loco was going at the point of triggering
         autoStopThrottle = _remote.throttle;
-        
+        whistleValve32 = 1;
         _dashboard.currentDistance = 0.00f;                         // Reset the distance-travelled counter to 0
 //        timeToReachTarget = targetDistance / (autoStopCruiseSpeed * 1000 / 3600);   // Time(s) = Distance(m) / Speed(converted to m/s)
         decelerationGradient = (autoStopCruiseSpeed - 1) / (targetDistance - 1);    // m = y / x → to get to 1kph at 24m, leaving ~ 4 seconds to get to target of 25m