summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--digital/io-hub/src/guybrush/bottom_clamp.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/digital/io-hub/src/guybrush/bottom_clamp.c b/digital/io-hub/src/guybrush/bottom_clamp.c
index 1d260b3c..1e6f2d4c 100644
--- a/digital/io-hub/src/guybrush/bottom_clamp.c
+++ b/digital/io-hub/src/guybrush/bottom_clamp.c
@@ -236,10 +236,15 @@ FSM_TRANS (CLAMP_INIT_FIND_0, lower_clamp_rotation_success, CLAMP_INIT_HIDE_CLAM
return FSM_NEXT (CLAMP_INIT_FIND_0, lower_clamp_rotation_success);
}
-FSM_TRANS (CLAMP_INIT_HIDE_CLAMP, lower_clamp_rotation_success, CLAMP_INIT_READY)
+FSM_TRANS (CLAMP_INIT_HIDE_CLAMP, lower_clamp_rotation_success,
+ normal_start,CLAMP_INIT_READY,
+ demo_start,CLAMP_GOING_IDLE)
{
- /*Nothing to do,just waiting for the clamp to be hidden*/
- return FSM_NEXT (CLAMP_INIT_HIDE_CLAMP, lower_clamp_rotation_success);
+ /*Looking if we are in demo mode or normal mode*/
+ if (IO_GET(CONTACT_STRAT))
+ return FSM_NEXT (CLAMP_INIT_HIDE_CLAMP,lower_clamp_rotation_success,normal_start);
+ else
+ return FSM_NEXT (CLAMP_INIT_HIDE_CLAMP,lower_clamp_rotation_success,demo_start);
}