From 5d55416cac3fa485d61fb01c95ca8067c2ca17c7 Mon Sep 17 00:00:00 2001 From: Jérémy Dufour Date: Wed, 20 May 2009 16:34:31 +0200 Subject: * digital/io/src: - implement top FSM. --- digital/io/src/top.h | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) (limited to 'digital/io/src/top.h') diff --git a/digital/io/src/top.h b/digital/io/src/top.h index 3b453dc9..1492405d 100644 --- a/digital/io/src/top.h +++ b/digital/io/src/top.h @@ -25,4 +25,44 @@ * * }}} */ +#include "asserv.h" + +/** + * Get the next position to get pucks on the ground. + * About the @p restart parameter, you need to set to 1 when for example, you + * have unload some pucks and restart the procedure to get new one. + * @param position the next position computed. + * @param restart set it to 1 when you restart a procedure. + * @return 0 if there is no more position. + */ +uint8_t +top_get_next_position_to_get_puck_on_the_ground (asserv_position_t *position, + uint8_t restart); + +/** + * Get the next position to get pucks from the distributor. + * @param clean_position the position to clean the distributor. + * @param front_position the position in front of the distributor to fuck it. + */ +void +top_get_next_position_to_get_distributor (asserv_position_t *clean_position, + asserv_position_t *front_position); + +/** + * Get the next position to get an unload position. + * @param position the next unloading position. + */ +void +top_get_next_position_to_unload_puck (asserv_position_t *position); + +/** + * Count number of pucks we have taken during a match. + */ +extern uint8_t top_total_puck_taken; + +/** + * Number of pucks inside the bot. + */ +extern uint8_t top_puck_inside_bot; + #endif /* top_h */ -- cgit v1.2.3