From e4a78a8af38b6fba6a7f38412525f569a7da7f53 Mon Sep 17 00:00:00 2001 From: Pascal Schade <165774906+pascalzauberzeug@users.noreply.github.com> Date: Thu, 23 Jan 2025 18:30:49 +0100 Subject: [PATCH] Remove Quickfix for Lizard Issue 66 (#245) With the next lizard version, 0.6.2, the issue is finally fixed. This PR just reverts https://github.com/zauberzeug/field_friend/pull/213 and https://github.com/zauberzeug/field_friend/pull/236. Reconfiguring systems running on any older version than 0.6.2 will not work anymore! - [x] Wait for Lizard 0.6.2 - [x] Wait for Rosys 0.22.0 with https://github.com/zauberzeug/rosys/pull/235 --- field_friend/hardware/status_control.py | 3 --- field_friend/hardware/tornado.py | 15 --------------- field_friend/hardware/y_axis_canopen_hardware.py | 5 ----- field_friend/hardware/y_axis_stepper_hardware.py | 7 ------- field_friend/hardware/z_axis_canopen_hardware.py | 5 ----- field_friend/hardware/z_axis_stepper_hardware.py | 5 ----- requirements.txt | 3 +-- 7 files changed, 1 insertion(+), 42 deletions(-) diff --git a/field_friend/hardware/status_control.py b/field_friend/hardware/status_control.py index 45cb23a2..057f53c2 100644 --- a/field_friend/hardware/status_control.py +++ b/field_friend/hardware/status_control.py @@ -17,9 +17,6 @@ def __init__(self, robot_brain: RobotBrain, *, lizard_code = remove_indentation(f''' rdyp_status = Input({rdyp_pin}) vdp_status = {expander.name + "."}Input({vdp_pin}) - # TODO: remove when lizard issue 66 is fixed. - vdp_status.level = 0 - vdp_status.active = false ''') core_message_fields = [ 'rdyp_status.level', diff --git a/field_friend/hardware/tornado.py b/field_friend/hardware/tornado.py index cc4916d4..25a52d5b 100644 --- a/field_friend/hardware/tornado.py +++ b/field_friend/hardware/tornado.py @@ -159,21 +159,6 @@ def __init__(self, robot_brain: rosys.hardware.RobotBrain, *, {name}_ref_knife_stop.inverted = false {name}_ref_knife_ground = {expander.name + "." if (end_stops_on_expander or ref_knife_ground_pin_expander) and expander else ""}Input({ref_knife_ground_pin}) {name}_ref_knife_ground.inverted = true - - # TODO: remove when lizard issue 66 is fixed. - {name}_end_top.level = 0 - {name}_end_top.active = false - {name}_end_bottom.level = 0 - {name}_end_bottom.active = false - {name}_ref_motor.level = 0 - {name}_ref_motor.active = false - {name}_ref_gear.level = 0 - {name}_ref_gear.active = false - {name}_ref_knife_stop.level = 0 - {name}_ref_knife_stop.active = false - {name}_ref_knife_ground.level = 0 - {name}_ref_knife_ground.active = false - {name}_z = {expander.name + "." if motors_on_expander and expander else ""}MotorAxis({name}_motor_z, {name + "_end_bottom" if is_z_reversed else name + "_end_top"}, {name + "_end_top" if is_z_reversed else name + "_end_bottom"}) bool {name}_is_referencing = false diff --git a/field_friend/hardware/y_axis_canopen_hardware.py b/field_friend/hardware/y_axis_canopen_hardware.py index 17cf3a46..ea176551 100644 --- a/field_friend/hardware/y_axis_canopen_hardware.py +++ b/field_friend/hardware/y_axis_canopen_hardware.py @@ -36,11 +36,6 @@ def __init__(self, robot_brain: rosys.hardware.RobotBrain, *, {name}_end_l.inverted = {str(end_stops_inverted).lower()} {name}_end_r = {expander.name + "." if end_stops_on_expander and expander else ""}Input({end_r_pin}) {name}_end_r.inverted = {str(end_stops_inverted).lower()} - # TODO: remove when lizard issue 66 is fixed. - {name}_end_l.level = 0 - {name}_end_l.active = false - {name}_end_r.level = 0 - {name}_end_r.active = false {name} = {expander.name + "." if motor_on_expander and expander else ""}MotorAxis({name}_motor, {name + "_end_l" if reversed_direction else name + "_end_r"}, {name + "_end_r" if reversed_direction else name + "_end_l"}) ''') core_message_fields = [ diff --git a/field_friend/hardware/y_axis_stepper_hardware.py b/field_friend/hardware/y_axis_stepper_hardware.py index 4c2a769d..4b0c6d05 100644 --- a/field_friend/hardware/y_axis_stepper_hardware.py +++ b/field_friend/hardware/y_axis_stepper_hardware.py @@ -39,13 +39,6 @@ def __init__(self, robot_brain: rosys.hardware.RobotBrain, *, {name}_end_l.inverted = {str(end_stops_inverted).lower()} {name}_end_r = {expander.name + "." if end_stops_on_expander and expander else ""}Input({end_r_pin}) {name}_end_r.inverted = {str(end_stops_inverted).lower()} - # TODO: remove when lizard issue 66 is fixed. - {name}_alarm.level = 0 - {name}_alarm.active = false - {name}_end_l.level = 0 - {name}_end_l.active = false - {name}_end_r.level = 0 - {name}_end_r.active = false {name} = {expander.name + "." if motor_on_expander and expander else ""}MotorAxis({name}_motor, {name + "_end_l" if reversed_direction else name + "_end_r"}, {name + "_end_r" if reversed_direction else name + "_end_l"}) ''') core_message_fields = [ diff --git a/field_friend/hardware/z_axis_canopen_hardware.py b/field_friend/hardware/z_axis_canopen_hardware.py index a073f725..86bbfcae 100644 --- a/field_friend/hardware/z_axis_canopen_hardware.py +++ b/field_friend/hardware/z_axis_canopen_hardware.py @@ -35,11 +35,6 @@ def __init__(self, robot_brain: rosys.hardware.RobotBrain, *, {name}_end_t.inverted = {str(end_stops_inverted).lower()} {name}_end_b = {expander.name + "." if end_stops_on_expander and expander else ""}Input({end_b_pin}) {name}_end_b.inverted = {str(end_stops_inverted).lower()} - # TODO: remove when lizard issue 66 is fixed. - {name}_end_t.level = 0 - {name}_end_t.active = false - {name}_end_b.level = 0 - {name}_end_b.active = false {name} = {expander.name + "." if motor_on_expander and expander else ""}MotorAxis({name}_motor, {name + "_end_t" if reversed_direction else name + "_end_b"}, {name + "_end_b" if reversed_direction else name + "_end_t"}) ''') core_message_fields = [ diff --git a/field_friend/hardware/z_axis_stepper_hardware.py b/field_friend/hardware/z_axis_stepper_hardware.py index f0bc5ed7..acd63d9f 100644 --- a/field_friend/hardware/z_axis_stepper_hardware.py +++ b/field_friend/hardware/z_axis_stepper_hardware.py @@ -38,11 +38,6 @@ def __init__(self, robot_brain: rosys.hardware.RobotBrain, *, {name}_end_t.inverted = {str(end_stops_inverted).lower()} {name}_end_b = {expander.name + "." if end_stops_on_expander and expander else ""}Input({end_b_pin}) {name}_end_b.inverted = {str(end_stops_inverted).lower()} - # TODO: remove when lizard issue 66 is fixed. - {name}_end_t.level = 0 - {name}_end_t.active = false - {name}_end_b.level = 0 - {name}_end_b.active = false {name} = {expander.name + "." if motor_on_expander and expander else ""}MotorAxis({name}_motor, {name + "_end_t" if reversed_direction else name + "_end_b"}, {name + "_end_b" if reversed_direction else name + "_end_t"}) ''') core_message_fields = [ diff --git a/requirements.txt b/requirements.txt index c3672169..bc56c75d 100644 --- a/requirements.txt +++ b/requirements.txt @@ -5,7 +5,6 @@ icecream pillow prompt-toolkit # for lizard monitor pynmea2 -# rosys == v0.22.0 -git+https://github.com/zauberzeug/rosys.git@3b6103b6a87ecc31d61732c9e07403e409319f95#egg=rosys +rosys == v0.22.0 shapely uvicorn == 0.28.1