summaryrefslogtreecommitdiff
path: root/Tonokip_Firmware/Tonokip_Firmware.pde
diff options
context:
space:
mode:
Diffstat (limited to 'Tonokip_Firmware/Tonokip_Firmware.pde')
-rw-r--r--Tonokip_Firmware/Tonokip_Firmware.pde3
1 files changed, 2 insertions, 1 deletions
diff --git a/Tonokip_Firmware/Tonokip_Firmware.pde b/Tonokip_Firmware/Tonokip_Firmware.pde
index 51ae3ea..3232e14 100644
--- a/Tonokip_Firmware/Tonokip_Firmware.pde
+++ b/Tonokip_Firmware/Tonokip_Firmware.pde
@@ -778,9 +778,10 @@ void linear_move(unsigned long x_steps_remaining, unsigned long y_steps_remainin
steps_to_take = delta_x;
max_interval = max_x_interval;
}
+ acceleration_enabled = true;
if(full_velocity_steps == 0) full_velocity_steps++;
long full_interval = max(interval, max_interval - ((max_interval - full_interval) * full_velocity_steps / virtual_full_velocity_steps));
- if(full_interval == interval) acceleration_enabled = false;
+ if(interval > max_interval) acceleration_enabled = false;
unsigned long steps_done = 0;
unsigned int steps_acceleration_check = 1;