Before PR #2591 LA was automatically capped during cruising or
deceleration. However we now rely on reaching the current pressure state
exactly to stop. When dual/quad stepping inside the eISR we might incur
in oscillating behavior if we do not handle it correctly.
This might be the cause behind #2757
This now changes e_step_loops to be a phase-local variable, so we now
reset it each phase too (instead of per-segment).
When switching to a new trapezoid step with the right pressure, cancel
any pending eISR right away.
Similarly do not schedule another eISR if the pressure will be reached
by the end of the eISR.
This was done in the past to preserve the current LA_phase. This is not
needed anymore, since it will be reset at each trapezoid step when LA
is re-initialized.
There used to be a single stage where an extruder reversal could occur,
but since PR #2591 reversals can happen up to two times per trapezoid.
Reset LA_phase when ADV_INIT is set, since it is re-inizialized only
when needed a few lines afterward. This improves performance by avoiding
to check the phase continuosly to the end of the trapezoid.
Likewise, always set ADV_INIT during the first cruising step, also to
force a LA_phase reset.
PR #2591 made LA compression always account for retractions instead of
discarding the current compression steps. While this fixed overextrusion
in short segments followed by wipes, it uncovered another issue in how
the compression steps are spread during the trapezoid calculations
leading to gaps in segments followed by retractions (as highlighted by
/some/ prints in #2693).
LA1.5 always computes the required target compression steps for a
segment at nominal speed. Because of how the extra steps are allocated
using multiples of the accelerating frequency, if the segment is
truncated before cruising is reached, an additional cycle of steps can
be inserted before deceleration starts. Deceleration is also not
guaranteed to be symmetric where up to _two_ cycles can be skipped
depending on the stepping cycle, leading to a situation where a
symmetric acceleration/deceleration block will lead up to a cycle of
accumulated compression.
While forcing an the extra step during deceleration is possible by
tweaking the error term (eISR_Err), this doesn't guarantee balance in
all cases. The underlying issue is that the function is aiming a
compression which cannot be reached (nominal speed), and not at the
effective max speed reached in the trapezoid, thus moving the average
result higher over time.
We fix this by calculating the effective maximum speed (and compression)
reached during the trapezoid, which stops compression on the required
cycle irregardless of the error term, balancing the result.
This is the first unoptimized POC: this is not for production: a lot of
calculations are redundand and could work directly in steps/s^2.
This saves nearly all of additional FLASH usage of previous commit. It is only 70B worse than if no skipping is done in temperature compensation gcode G76.
There is no known purpose of this call.
lcd_temp_calibration_set() is switching on/off pinda temperature compensation from LCD settings menu (this is called "Temp. cal." on LCD).
st_current_init() does nothing on Einsy board, it enables and sets motor current selecting outputs on Rambo board (it used to be called digipot in history)
* Update EEPROM_FSENSOR_PCB documentation
* Update IR sensor check
* Rename IR messags and add UNKNOWN state
* Update code to use new messages
* To be continued
* Move fsensor related things from ultralcd.h to fsensor.h
* Use defined Thresholds
* IR sensor auto detection "0.3 or older" and "0.4 or newer" when trigger status changes.
Typo fixes
Doxygen documentation
* Cleanup spaces
* Revert PF-build.sh changes
* re-add space in messages
* revert doxygen snytax
* Remove double _Undef
* Fix indentation and doxygen syntax
* Fix indentation
* Better message handling
* Fix indentation
* Fix indentation
* More indentation fixwa
* Extract common code into manage_inactivity_IR_ANALOG_Check
Saves ~60B of code
* Revert indentation changes on fsensor.cpp
* Keep the selftest IR sensor part disabled
Everything shall happen at runtime
* Fix indentation fsensor_update
* Fix another misleading indentation in fsensor_update
Co-authored-by: Alex Voinea <voinea.dragos.alexandru@gmail.com>
Co-authored-by: D.R.racer <drracer@drracer.eu>
* Combine repeated calls into functions with much less parameters -> 2KB
down.
* Save some bytes by removing unnecessary 1-character strings: "x" -> 'x'
used in SERIAL_xxx printing macros.
This is also saves some CPU cycles
* Fix compilation for MK25S and MK3
* Copy surrounding indentation
* Fix compilation for a rare HW setup
* rename mesh_planXX_buffer_line back to mesh_plan_buffer_line
* Remove active_extruder from remaining plan_buffer_line_destinationXYZE
calls and one more fix of indentation
Increase the flattened response in the e-jerk conversion from the 1-4.5
region to 0.3-4.5 (same slope). This brings a 0.3 LA10 e-jerk to a 3.45
LA15 equivalent.
This will better handle the legacy Pretty PETG/CFPETG v3 profiles.