From 1cba78d5353ae1a17a0433a424731b35bfb5088d Mon Sep 17 00:00:00 2001 From: Adeeb <8762862+adeebshihadeh@users.noreply.github.com> Date: Fri, 12 Jun 2020 20:55:59 -0700 Subject: [PATCH] Add hyundai legacy safety mode (#1693) old-commit-hash: 437b974505a80011352bfa636e14445cea8c87c7 --- panda | 2 +- selfdrive/car/hyundai/interface.py | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/panda b/panda index 74c607f79a..d0442fd1e4 160000 --- a/panda +++ b/panda @@ -1 +1 @@ -Subproject commit 74c607f79acd2baace27265f763480af75496dac +Subproject commit d0442fd1e45589880c12b27c8a744cd1f540f540 diff --git a/selfdrive/car/hyundai/interface.py b/selfdrive/car/hyundai/interface.py index bde37e10bf..e3bbc0f71a 100644 --- a/selfdrive/car/hyundai/interface.py +++ b/selfdrive/car/hyundai/interface.py @@ -135,6 +135,10 @@ class CarInterface(CarInterfaceBase): ret.lateralTuning.pid.kiBP, ret.lateralTuning.pid.kpBP = [[0.], [0.]] ret.lateralTuning.pid.kpV, ret.lateralTuning.pid.kiV = [[0.25], [0.05]] + # these cars require a special panda safety mode due to missing counters and checksums in the messages + if candidate in [CAR.HYUNDAI_GENESIS]: + ret.safetyModel = car.CarParams.SafetyModel.hyundaiLegacy + ret.centerToFront = ret.wheelbase * 0.4 # TODO: get actual value, for now starting with reasonable value for