driver torque limit: make driver torque message abstract (#1377)

* abs

* uncomment

* fixy
This commit is contained in:
Shane Smiskol 2023-04-28 17:36:35 -07:00 committed by GitHub
parent 99809f7071
commit 63db708491
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 3 deletions

View File

@ -334,6 +334,10 @@ class DriverTorqueSteeringSafetyTest(TorqueSteeringSafetyTestBase, abc.ABC):
cls.safety = None
raise unittest.SkipTest
@abc.abstractmethod
def _torque_driver_msg(self, torque):
pass
def test_non_realtime_limit_up(self):
self.safety.set_torque_driver(0, 0)
super().test_non_realtime_limit_up()

View File

@ -35,9 +35,9 @@ class TestMazdaSafety(common.PandaSafetyTest, common.DriverTorqueSteeringSafetyT
values = {"STEER_TORQUE_MOTOR": torque}
return self.packer.make_can_msg_panda("STEER_TORQUE", 0, values)
# def _torque_driver_msg(self, torque):
# values = {"STEER_TORQUE_DRIVER": torque}
# return self.packer.make_can_msg_panda("STEER_TORQUE", 0, values)
def _torque_driver_msg(self, torque):
values = {"STEER_TORQUE_SENSOR": torque}
return self.packer.make_can_msg_panda("STEER_TORQUE", 0, values)
def _torque_cmd_msg(self, torque, steer_req=1):
values = {"LKAS_REQUEST": torque}