summaryrefslogtreecommitdiff
path: root/Sprinter
diff options
context:
space:
mode:
authorKliment Yanev <kliment.yanev@gmail.com>2011-09-03 19:18:06 +0200
committerKliment Yanev <kliment.yanev@gmail.com>2011-09-03 19:18:06 +0200
commit6318cd2496f9f0e5ff8925d8f26ea3866b1d9a81 (patch)
tree039720bcd513c587811643b623f4485d4c7eec7e /Sprinter
parent699a41290fa8ae0e8da3c3a6d229578c849a67bc (diff)
Fix deceleration
Diffstat (limited to 'Sprinter')
-rw-r--r--Sprinter/Sprinter.pde4
1 files changed, 2 insertions, 2 deletions
diff --git a/Sprinter/Sprinter.pde b/Sprinter/Sprinter.pde
index eb354e1..44bdbb8 100644
--- a/Sprinter/Sprinter.pde
+++ b/Sprinter/Sprinter.pde
@@ -1217,8 +1217,8 @@ inline void linear_move(unsigned long axis_steps_remaining[]) // make linear mov
accelerating = true;
decelerating = true;
}
- long current_speed = (long) ((long) max_speed_steps_per_second - ((((long) steps_per_sqr_second) / 10000)
- * ((micros() - start_move_micros) / 100)));
+ long current_speed = (long) ((long) max_speed_steps_per_second - ((((long) steps_per_sqr_second) / 100)
+ * ((micros() - start_move_micros) / 100)/100));
interval = 100000000 / current_speed;
if (interval > max_interval)
interval = max_interval;