accel is uint32_t, drop float in comparsion
Change in memory: Flash: -24 bytes SRAM: 0 bytes
This commit is contained in:
parent
c0e21563e7
commit
65750b9a4c
|
|
@ -1054,9 +1054,9 @@ Having the real displacement of the head, we can calculate the total movement le
|
|||
if (e_D_ratio > 3.0)
|
||||
block->use_advance_lead = false;
|
||||
else if (e_D_ratio > 0) {
|
||||
const float max_accel_per_s2 = cs.max_jerk[E_AXIS] / (extruder_advance_K * e_D_ratio) * steps_per_mm;
|
||||
if (accel > max_accel_per_s2) {
|
||||
accel = ceil(max_accel_per_s2);
|
||||
const uint32_t max_accel_steps_per_s2 = ceil(cs.max_jerk[E_AXIS] / (extruder_advance_K * e_D_ratio) * steps_per_mm);
|
||||
if (accel > max_accel_steps_per_s2) {
|
||||
accel = max_accel_steps_per_s2;
|
||||
#ifdef LA_DEBUG
|
||||
SERIAL_ECHOLNPGM("LA: Block acceleration limited due to max E-jerk");
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Reference in New Issue