|
|
|
@ -1,6 +1,6 @@ |
|
|
|
|
import math |
|
|
|
|
from cereal import car |
|
|
|
|
from openpilot.selfdrive.car import DT_CTRL, get_safety_config |
|
|
|
|
from openpilot.selfdrive.car import get_safety_config |
|
|
|
|
from openpilot.selfdrive.car.interfaces import CarInterfaceBase |
|
|
|
|
from openpilot.selfdrive.car.body.values import SPEED_FROM_RPM |
|
|
|
|
|
|
|
|
@ -27,12 +27,4 @@ class CarInterface(CarInterfaceBase): |
|
|
|
|
def _update(self, c): |
|
|
|
|
ret = self.CS.update(self.cp) |
|
|
|
|
|
|
|
|
|
# wait for everything to init first |
|
|
|
|
if self.frame > int(5. / DT_CTRL): |
|
|
|
|
# body always wants to enable |
|
|
|
|
ret.init('events', 1) |
|
|
|
|
ret.events[0].name = car.CarEvent.EventName.pcmEnable |
|
|
|
|
ret.events[0].enable = True |
|
|
|
|
self.frame += 1 |
|
|
|
|
|
|
|
|
|
return ret |
|
|
|
|