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: mbed MODSERIAL FATFileSystem
Revision 18:85a7535af8fd, committed 2017-11-22
- Comitter:
- tnhnrl
- Date:
- Wed Nov 22 00:06:48 2017 +0000
- Parent:
- 17:7c16b5671d0e
- Child:
- 19:aaa0f4f29d50
- Commit message:
- flipped checks on neutral finding subsequence
Changed in this revision
| StateMachine/StateMachine.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/StateMachine/StateMachine.cpp Tue Nov 21 22:03:26 2017 +0000
+++ b/StateMachine/StateMachine.cpp Wed Nov 22 00:06:48 2017 +0000
@@ -471,10 +471,9 @@
isSubStateTimeoutRunning = false;
}
- //before the sub-fsm runs again, make sure the piston is in a safe position
+ //before the sub-fsm runs again, make sure the piston is in a safe position (retracted)
//NEW: need to double-check this behavior
- //need to set a max travel position ? or just hardcode? or use bceFloatPosition?
- if (bce().getPosition_mm() >= 320) {
+ if (bce().getPosition_mm() <= 0) {
output_substate = NEUTRAL_EXIT;
//the "case" NEUTRAL_EXIT is used to tell the greater FSM that this sub-FSM has completed
}
@@ -511,7 +510,7 @@
output_substate = NEUTRAL_CHECK_PITCH;
}
- //before the sub-fsm runs again, make sure the piston is in a safe position
+ //before the sub-fsm runs again, make sure the piston is in a safe position (retracted)
//NEW: need to double-check this behavior
//need to set a max travel position ? or just hardcode? or use bceFloatPosition?
if (bce().getPosition_mm() >= 320) {