bypass HDA2 dashcam with file (#24803)

Co-authored-by: Comma Device <device@comma.ai>
This commit is contained in:
Adeeb Shihadeh
2022-06-09 19:29:54 -07:00
committed by GitHub
parent 1b402687e4
commit 53724e8b6c
+4 -1
View File
@@ -1,4 +1,5 @@
#!/usr/bin/env python3
import os
from cereal import car
from panda import Panda
from common.conversions import Conversions as CV
@@ -37,7 +38,9 @@ class CarInterface(CarInterfaceBase):
# These cars have been put into dashcam only due to both a lack of users and test coverage.
# These cars likely still work fine. Once a user confirms each car works and a test route is
# added to selfdrive/car/tests/routes.py, we can remove it from this list.
ret.dashcamOnly = candidate in {CAR.KIA_OPTIMA_H, CAR.ELANTRA_GT_I30} or candidate in HDA2_CAR
ret.dashcamOnly = candidate in {CAR.KIA_OPTIMA_H, CAR.ELANTRA_GT_I30}
if candidate in HDA2_CAR:
ret.dashcamOnly = not os.path.exists('/data/enable-ev6')
ret.steerActuatorDelay = 0.1 # Default delay
ret.steerRateCost = 0.5