From 953ff53ccf92e700c7c25136eabbe6699caa90f9 Mon Sep 17 00:00:00 2001 From: Nicolas Schodet Date: Thu, 13 May 2010 00:46:21 +0200 Subject: digital/io/src: make angle optional in move FSM --- digital/io/src/ai_top_cb.c | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) (limited to 'digital/io/src/ai_top_cb.c') diff --git a/digital/io/src/ai_top_cb.c b/digital/io/src/ai_top_cb.c index 745e0b6a..c057bebf 100644 --- a/digital/io/src/ai_top_cb.c +++ b/digital/io/src/ai_top_cb.c @@ -61,8 +61,7 @@ fsm_branch_t ai__WAIT_INIT_TO_FINISH__init_match_is_started (void) { asserv_set_speed (BOT_MOVE_FAST); - position_t pos = PG_POSITION_DEG (375, 1503, -29); - move_start (pos, 0); + move_start_noangle (PG_VECT (375, 1503), 0); return ai_next (WAIT_INIT_TO_FINISH, init_match_is_started); } @@ -75,8 +74,7 @@ ai__WAIT_INIT_TO_FINISH__init_match_is_started (void) fsm_branch_t ai__FIRST_GO_BEGIN_OF_LINE_FAST__move_fsm_succeed (void) { - position_t pos = PG_POSITION_DEG (2625, 253, -29); - move_start (pos, 0); + move_start_noangle (PG_VECT (2625, 253), 0); loader_down (); return ai_next (FIRST_GO_BEGIN_OF_LINE_FAST, move_fsm_succeed); } @@ -91,8 +89,7 @@ fsm_branch_t ai__FIRST_GO_BEGIN_OF_LINE_FAST__move_fsm_failed (void) { asserv_set_speed (BOT_MOVE_SLOW); - position_t pos = PG_POSITION_DEG (375, 1503, -29); - move_start (pos, 0); + move_start_noangle (PG_VECT (375, 1503), 0); return ai_next (FIRST_GO_BEGIN_OF_LINE_FAST, move_fsm_failed); } @@ -156,8 +153,7 @@ ai__FIRST_GO_END_OF_LINE_SLOW__move_fsm_succeed (void) fsm_branch_t ai__FIRST_GO_END_OF_LINE_SLOW__move_fsm_failed (void) { - position_t pos = PG_POSITION_DEG (2625, 253, -29); - move_start (pos, 0); + move_start_noangle (PG_VECT (2625, 253), 0); return ai_next (FIRST_GO_END_OF_LINE_SLOW, move_fsm_failed); } -- cgit v1.2.3