mcu: Remove max_stepper_error config parameter

Use a regular code constant - MAX_STEPCOMPRESS_ERROR in stepper.py.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
Kevin O'Connor
2025-09-19 13:57:34 -04:00
parent ea9c88526b
commit 07466411ac
3 changed files with 5 additions and 7 deletions

View File

@@ -16,6 +16,7 @@ class error(Exception):
MIN_BOTH_EDGE_DURATION = 0.000000500
MIN_OPTIMIZED_BOTH_EDGE_DURATION = 0.000000150
MAX_STEPCOMPRESS_ERROR = 0.000025
# Interface to low-level mcu and chelper code
class MCU_stepper:
@@ -122,8 +123,7 @@ class MCU_stepper:
self._get_position_cmd = self._mcu.lookup_query_command(
"stepper_get_position oid=%c",
"stepper_position oid=%c pos=%i", oid=self._oid)
max_error = self._mcu.get_max_stepper_error()
max_error_ticks = self._mcu.seconds_to_clock(max_error)
max_error_ticks = self._mcu.seconds_to_clock(MAX_STEPCOMPRESS_ERROR)
ffi_main, ffi_lib = chelper.get_ffi()
ffi_lib.stepcompress_fill(self._stepqueue, self._oid, max_error_ticks,
step_cmd_tag, dir_cmd_tag)