From 4d933a6399ac3351057119e2203b240e5d582163 Mon Sep 17 00:00:00 2001 From: Douglas Clowes Date: Fri, 12 Jul 2013 12:39:16 +1000 Subject: [PATCH] Make motor creep "single-step" one tenth steps-per-count --- site_ansto/motor_dmc2280.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/site_ansto/motor_dmc2280.c b/site_ansto/motor_dmc2280.c index 887e9b36..26b688b2 100644 --- a/site_ansto/motor_dmc2280.c +++ b/site_ansto/motor_dmc2280.c @@ -681,7 +681,7 @@ static int motCreep(pDMC2280Driv self, double target) { * we have to "single step" otherwise we want to go half way */ if (offset <= fabs(self->stepsPerX / self->cntsPerX)) { - offset = offset / DECADIC_CREEP; + offset = fabs(self->stepsPerX / self->cntsPerX) / DECADIC_CREEP; if (offset < 1) offset = 1; } else {