From 503e3511b2fa42263749c62a9625e6549ac2fe2d Mon Sep 17 00:00:00 2001 From: Jérémy Dufour Date: Wed, 20 May 2009 19:22:02 +0200 Subject: * digital/io/src: - support backward parameter for the asserv_goto, - enhance to avoid static obstacle, - add center circle of the playground table. --- digital/io/src/asserv.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'digital/io/src/asserv.c') diff --git a/digital/io/src/asserv.c b/digital/io/src/asserv.c index 062ca13a..d8fc2ea0 100644 --- a/digital/io/src/asserv.c +++ b/digital/io/src/asserv.c @@ -627,7 +627,7 @@ asserv_set_position (int32_t x, int32_t y, int16_t angle) /* Go to an absolute position in (X, Y). */ void -asserv_goto (uint32_t x, uint32_t y) +asserv_goto (uint32_t x, uint32_t y, uint8_t backward) { x = fixed_mul_f824 (x, asserv_scale_inv); y = fixed_mul_f824 (y, asserv_scale_inv); @@ -640,7 +640,7 @@ asserv_goto (uint32_t x, uint32_t y) asserv_twi_buffer_param[4] = v32_to_v8 (y, 1); asserv_twi_buffer_param[5] = v32_to_v8 (y, 0); /* No backward. */ - asserv_twi_buffer_param[6] = 0; + asserv_twi_buffer_param[6] = backward; /* Send the got to an absolute position command to the asserv board */ asserv_twi_send_command ('x', 7); } -- cgit v1.2.3