Add SPI access, internal-clock PLL setup, integrated-current-sense
current control, SpreadCycle, temperature reporting, and standard TMC
fault and status helpers. Check the PLL whenever registers are restored
and clear the phase offset when reinitializing the PLL.
Document the new configuration and include a Klippy regression case.
Derived from the GPLv3 TMC5262 driver by Rogerio Goncalves in Kalico.
Signed-off-by: Rogerio Goncalves <rogerlz@gmail.com>
Signed-off-by: Uriah Kessman <fishyfabspnw@gmail.com>
Several links pointed at heading anchors that no longer exist (renamed
or moved sections), so they did not jump to the intended section.
Update them to the current anchors, and use a relative path for the
sample-pwm-tool.cfg link so it resolves like the other config links.
Signed-off-by: Satvik Mishra <Satvikmishra.ipu146183@maims.ac.in>
Add an hd44780_delay config option so the minimum wait time after
sending a command or data byte to the hd44780 chip can be tuned.
Some displays need more than the default 40us. The value is limited
to a maximum of 60us, as the mcu busy-waits for this delay.
Signed-off-by: Florian Hofer <SirDeath81_github@outlook.com>
Read the identify dictionary's kconfig key and publish it as mcu_kconfig.
Return None when older firmware does not include the key.
Signed-off-by: Morton Jonuschat <mjonuschat@gmail.com>
By applying a non-linear fit of a piecewise function with a linear
region for the Z positions below the point of contact and a constant
"tare" region, the optimal Z position can be determined with greater
precision, even beyond the ADC sample intervals. This is particularly
helpful when using a relatively slow ADC like the HX711.
Signed-off-by: Martin Hierholzer <martin@hierholzer.info>
The 'z_thermal_adjust' config section example was named
and had a maximum deviation property missing.
Signed-off-by: Frank Roth <developer@freakydu.de>
There is no longer a need for the correction macros now that the G28
code uses the standard probing interface.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
Rework the tap_threshold to use units of hz/mm (instead of hz). This
will make it easier to implement tap calibration based on results of
PROBE_EDDY_CURRENT_CALIBRATE and previous tap attempts. It can also
make the tap_threshold more stable with different probe speeds and
sensor rates.
As a result of this change, existing user configurations will need to
be updated. It is hoped that existing configurations will have a
value that is sufficiently low that they will reliably get an error
until they can recalibrate.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
Print near the origin lead in to fast motor movements, therefore the
movement needs to be scaled down. The start of the scaling is done via
a rotation velocity limit from the config.
Signed-off-by: Nils Hensch <nils.hensch@gmx.de>
Store the 12 constants needed for the common probe_eddy_current "tap"
filter in trigger_analog.py code. This avoids requiring "tap" users
to have the scipy python package installed.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This updates the outdated CanBoot flash_can.py with the latest
version of Katapult flashtool.py, which should be fully backwards
compatible.
Signed-off-by: Robert Schiele <rschiele@gmail.com>
Keeps the width sensor state in sync with the associated runout sensor and
normalizes the output when the width sensor is disabled.
When the width sensor was disabled the associated filament sensor remained
enabled but was no longer updated so would be 'stuck' in the last state it
was in before the width sensor was disabled.
The toggle switch and readings in the web interface could also be out of sync
with the actual sensor and filament states, misleading the user.
Now, when the width sensor is disabled:
- The filament sensor is disabled
- The reported filament state is 'present'
- The reported filament diameter is the nominal diameter
When the width sensor is enabled:
- The filament sensor is enabled
- The reported filament state is the derived state
- The reported filament diameter is the measured value
Finally, `min_diameter` is now used to determine the runout state rather than
a fixed value of `0.5`.
Signed-off-by: Ben Lye ben@lye.co.nz
Adds two checks to prevent config settings which could lead to div-by-zero errors in specific circumstances:
- `raw_dia1` and `raw_dia2` must be different to prevent a possible exception in `adc2_callback`
- `max_difference` must be less than `default_nominal_filament_diameter` to prevent a possible exception in `extrude_factor_update_event`
Doc is also updated.
Signed-off-by: Ben Lye ben@lye.co.nz
Adds a toggle to enable or disable flow compensation based on the
filament width sensor readings without disabling the sensor entirely.
Useful on printers where the hall effect sensor is too inaccurate to
helpfully adjust the extrusion multiplier, but is good enough to act as
a filament runout sensor.
The new setting defaults to true to preserve the existing sensor
behavior.
Existing width sensor G-Code commands are updated to optionally enable
and disable flow compensation and to show the state of the sensor and
command outputs are normalized.
Also includes updates to the relevant doc pages.
Signed-off-by: Ben Lye ben@lye.co.nz
Add a new EddyParameterHelper to override ProbeParameterHelper.
Only use the printer.cfg lift_speed, samples, sample_retract_dist,
samples_result, samples_tolerance, and samples_tolerance_retries
settings for normal probe operations. Don't use these defaults when
using a "METHOD" set to "scan", "rapid_scan", or "tap". Each of these
probing mechanisms is distinct and it's unlikely a user could
meaningfully set a default for all of them.
Don't set sample_retract_dist when using "scan" and "rapid_scan"
modes.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
Theoretically a "tap" probe should detect the exact point that the
nozzle contacts the bed. In practice, however, there can be a
systemic bias that one may wish to account for. This bias may be due
to backlash, thermal expansion, a detection bias, or similar issues.
Add a new tap_z_offset config parameter to allow users to specify an
offset.
Also, update the Z_OFFSET_APPLY_PROBE command to support modifying
this value.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
The config option 'z_offset' name is confusing as its behavior is
notably different from how other probe hardware uses 'z_offset'.
Rename to 'descend_z' to make its behavior more clear.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
Allow the "tap_threshold" to be overriden during PROBE type commands.
This makes it easier to calibrate an initial tap_threshold.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
Describe the METHOD= parameter in the probe_eddy_current chapter.
Use similar layout for both the load_cell_probe and probe_eddy_current
sections.
Avoid duplicating the METHOD= parmeter for other commands.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
Subscribing to all sensors can cause a burden on the MCU communication
channels. Add a new '-s' command line option to data_logger.py that
allows a user to request the subscriptions that they wish to capture.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>