From e554b1362f2bdd0ec49649709a18f65790c5dfdd Mon Sep 17 00:00:00 2001 From: PatXue <95881915+PatXue@users.noreply.github.com> Date: Mon, 25 Mar 2024 18:10:30 -0400 Subject: [PATCH] Change wheelbase variable based on buggy_name --- rb_ws/src/buggy/scripts/auton/controller.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/rb_ws/src/buggy/scripts/auton/controller.py b/rb_ws/src/buggy/scripts/auton/controller.py index cf7120f8..08be1013 100755 --- a/rb_ws/src/buggy/scripts/auton/controller.py +++ b/rb_ws/src/buggy/scripts/auton/controller.py @@ -19,11 +19,15 @@ class Controller(ABC): NAND_WHEELBASE = 1.3 SC_WHEELBASE = 1.104 - WHEELBASE = SC_WHEELBASE current_traj_index = 0 def __init__(self, start_index, buggy_name) -> None: self.buggy_name = buggy_name + if buggy_name.upper() == 'NAND': + Controller.WHEELBASE = self.NAND_WHEELBASE + else: + Controller.WHEELBASE = self.SC_WHEELBASE + # self.trajectory_forward_1 = rospy.Publisher( # buggy_name + "/auton/debug/forward1_navsat", NavSatFix, queue_size=1 # )