From 00a1e18f9f6e713afc5da6c139ae310943ee754e Mon Sep 17 00:00:00 2001 From: Nicolas Schodet Date: Tue, 4 May 2010 02:25:38 +0200 Subject: digital/{io,mimot}: shift once for clamp motors --- digital/io/src/bot.h | 6 +++--- digital/io/tools/test_simu_control.py | 2 +- digital/mimot/src/dirty/counter_ext.avr.c | 4 ++-- digital/mimot/src/dirty/models.host.c | 2 +- digital/mimot/tools/mimot/init.py | 8 ++++---- 5 files changed, 11 insertions(+), 11 deletions(-) diff --git a/digital/io/src/bot.h b/digital/io/src/bot.h index e5f280bd..4e058dcc 100644 --- a/digital/io/src/bot.h +++ b/digital/io/src/bot.h @@ -78,16 +78,16 @@ #define BOT_ELEVATOR_ZERO_SPEED 0x10 /** Clamp stroke in steps. */ -#define BOT_CLAMP_STROKE_STEP 5627 +#define BOT_CLAMP_STROKE_STEP 2813 /** Clamp open position in steps. */ -#define BOT_CLAMP_OPEN_STEP 30 +#define BOT_CLAMP_OPEN_STEP 15 /** Clamp work speed. */ #define BOT_CLAMP_SPEED 0x60 /** Clamp find zero speed. */ -#define BOT_CLAMP_ZERO_SPEED 0x20 +#define BOT_CLAMP_ZERO_SPEED 0x10 /** * Definition of the colors. diff --git a/digital/io/tools/test_simu_control.py b/digital/io/tools/test_simu_control.py index 3ff87fdd..64c856aa 100644 --- a/digital/io/tools/test_simu_control.py +++ b/digital/io/tools/test_simu_control.py @@ -62,7 +62,7 @@ class TestSimuControl (TestSimu): def clamp_command (self): if self.clamp_var.get (): - pos = 3441 + pos = 1720 else: pos = 0 self.mimot.goto_pos ('a0', pos) diff --git a/digital/mimot/src/dirty/counter_ext.avr.c b/digital/mimot/src/dirty/counter_ext.avr.c index 0570ab63..19805d39 100644 --- a/digital/mimot/src/dirty/counter_ext.avr.c +++ b/digital/mimot/src/dirty/counter_ext.avr.c @@ -46,9 +46,9 @@ #define COUNTER_AUX1_REVERSE 0 /** First auxiliary counter shift. */ -#define COUNTER_AUX0_SHIFT 0 +#define COUNTER_AUX0_SHIFT 1 /** Second auxiliary counter shift. */ -#define COUNTER_AUX1_SHIFT 0 +#define COUNTER_AUX1_SHIFT 1 /** Define to 1 to use the AVR External Memory system, or 0 to use hand made * signals. */ diff --git a/digital/mimot/src/dirty/models.host.c b/digital/mimot/src/dirty/models.host.c index fe1761c3..efea35bc 100644 --- a/digital/mimot/src/dirty/models.host.c +++ b/digital/mimot/src/dirty/models.host.c @@ -58,7 +58,7 @@ static const struct robot_t marcel_robot = /** Auxiliary motors, NULL if not present. */ { &marcel_clamp_f2342_model, &marcel_clamp_f2342_model }, /** Number of steps for each auxiliary motor encoder. */ - { 512, 512 }, + { 256, 256 }, /** Sensor update function. */ simu_sensor_update_marcel, }; diff --git a/digital/mimot/tools/mimot/init.py b/digital/mimot/tools/mimot/init.py index a956ea94..5b62f913 100644 --- a/digital/mimot/tools/mimot/init.py +++ b/digital/mimot/tools/mimot/init.py @@ -1,16 +1,16 @@ """Default parameters for asserv.""" host = dict ( a0kp = 4, - a0a = 16, a0sm = 0x60, a0ss = 0x20, + a0a = 16, a0sm = 0x60, a0ss = 0x10, a1kp = 4, - a1a = 16, a1sm = 0x60, a1ss = 0x20, + a1a = 16, a1sm = 0x60, a1ss = 0x10, E = 0x3ff, D = 0x1ff, ) target = dict ( a0kp = 4, - a0a = 16, a0sm = 0x60, a0ss = 0x20, + a0a = 16, a0sm = 0x60, a0ss = 0x10, a1kp = 4, - a1a = 16, a1sm = 0x60, a1ss = 0x20, + a1a = 16, a1sm = 0x60, a1ss = 0x10, E = 0x3ff, D = 0x1ff, w = 0x03, ) -- cgit v1.2.3