mirror of https://github.com/Desuuuu/klipper.git
toolhead: Do not limit SET_VELOCITY_LIMIT to values specified in config
Allow a larger velocity, accel, and square_corner_velocity than what is specified in the config file. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
parent
5a5ecd88e2
commit
b1ea4f3bef
|
@ -6,6 +6,10 @@ All dates in this document are approximate.
|
||||||
|
|
||||||
# Changes
|
# Changes
|
||||||
|
|
||||||
|
20210430: The SET_VELOCITY_LIMIT (and M204) command may now set a
|
||||||
|
velocity, acceleration, and square_corner_velocity larger than the
|
||||||
|
specified values in the config file.
|
||||||
|
|
||||||
20210325: Support for the `pin_map` config option is deprecated. Use
|
20210325: Support for the `pin_map` config option is deprecated. Use
|
||||||
the [sample-aliases.cfg](../config/sample-aliases.cfg) file to
|
the [sample-aliases.cfg](../config/sample-aliases.cfg) file to
|
||||||
translate to the actual micro-controller pin names. The `pin_map`
|
translate to the actual micro-controller pin names. The `pin_map`
|
||||||
|
|
|
@ -217,9 +217,6 @@ class ToolHead:
|
||||||
self.max_accel_to_decel = self.requested_accel_to_decel
|
self.max_accel_to_decel = self.requested_accel_to_decel
|
||||||
self.square_corner_velocity = config.getfloat(
|
self.square_corner_velocity = config.getfloat(
|
||||||
'square_corner_velocity', 5., minval=0.)
|
'square_corner_velocity', 5., minval=0.)
|
||||||
self.config_max_velocity = self.max_velocity
|
|
||||||
self.config_max_accel = self.max_accel
|
|
||||||
self.config_square_corner_velocity = self.square_corner_velocity
|
|
||||||
self.junction_deviation = 0.
|
self.junction_deviation = 0.
|
||||||
self._calc_junction_deviation()
|
self._calc_junction_deviation()
|
||||||
# Print time tracking
|
# Print time tracking
|
||||||
|
@ -560,10 +557,9 @@ class ToolHead:
|
||||||
'SQUARE_CORNER_VELOCITY', self.square_corner_velocity, minval=0.)
|
'SQUARE_CORNER_VELOCITY', self.square_corner_velocity, minval=0.)
|
||||||
self.requested_accel_to_decel = gcmd.get_float(
|
self.requested_accel_to_decel = gcmd.get_float(
|
||||||
'ACCEL_TO_DECEL', self.requested_accel_to_decel, above=0.)
|
'ACCEL_TO_DECEL', self.requested_accel_to_decel, above=0.)
|
||||||
self.max_velocity = min(max_velocity, self.config_max_velocity)
|
self.max_velocity = max_velocity
|
||||||
self.max_accel = min(max_accel, self.config_max_accel)
|
self.max_accel = max_accel
|
||||||
self.square_corner_velocity = min(square_corner_velocity,
|
self.square_corner_velocity = square_corner_velocity
|
||||||
self.config_square_corner_velocity)
|
|
||||||
self._calc_junction_deviation()
|
self._calc_junction_deviation()
|
||||||
msg = ("max_velocity: %.6f\n"
|
msg = ("max_velocity: %.6f\n"
|
||||||
"max_accel: %.6f\n"
|
"max_accel: %.6f\n"
|
||||||
|
@ -586,7 +582,7 @@ class ToolHead:
|
||||||
% (gcmd.get_commandline(),))
|
% (gcmd.get_commandline(),))
|
||||||
return
|
return
|
||||||
accel = min(p, t)
|
accel = min(p, t)
|
||||||
self.max_accel = min(accel, self.config_max_accel)
|
self.max_accel = accel
|
||||||
self._calc_junction_deviation()
|
self._calc_junction_deviation()
|
||||||
|
|
||||||
def add_printer_objects(config):
|
def add_printer_objects(config):
|
||||||
|
|
Loading…
Reference in New Issue