FrogPilot Setup
This commit is contained in:
@@ -34,7 +34,7 @@ class CarController:
|
||||
torque -= deadband
|
||||
return torque
|
||||
|
||||
def update(self, CC, CS, now_nanos):
|
||||
def update(self, CC, CS, now_nanos, frogpilot_variables):
|
||||
|
||||
torque_l = 0
|
||||
torque_r = 0
|
||||
|
||||
@@ -6,7 +6,7 @@ from openpilot.selfdrive.car.body.values import DBC
|
||||
STARTUP_TICKS = 100
|
||||
|
||||
class CarState(CarStateBase):
|
||||
def update(self, cp):
|
||||
def update(self, cp, frogpilot_variables):
|
||||
ret = car.CarState.new_message()
|
||||
|
||||
ret.wheelSpeeds.fl = cp.vl['MOTORS_DATA']['SPEED_L']
|
||||
|
||||
@@ -7,7 +7,7 @@ from openpilot.selfdrive.car.body.values import SPEED_FROM_RPM
|
||||
|
||||
class CarInterface(CarInterfaceBase):
|
||||
@staticmethod
|
||||
def _get_params(ret, candidate, fingerprint, car_fw, experimental_long, docs):
|
||||
def _get_params(ret, params, candidate, fingerprint, car_fw, experimental_long, docs):
|
||||
ret.notCar = True
|
||||
ret.carName = "body"
|
||||
ret.safetyConfigs = [get_safety_config(car.CarParams.SafetyModel.body)]
|
||||
@@ -29,8 +29,8 @@ class CarInterface(CarInterfaceBase):
|
||||
|
||||
return ret
|
||||
|
||||
def _update(self, c):
|
||||
ret = self.CS.update(self.cp)
|
||||
def _update(self, c, frogpilot_variables):
|
||||
ret = self.CS.update(self.cp, frogpilot_variables)
|
||||
|
||||
# wait for everything to init first
|
||||
if self.frame > int(5. / DT_CTRL):
|
||||
@@ -42,5 +42,5 @@ class CarInterface(CarInterfaceBase):
|
||||
|
||||
return ret
|
||||
|
||||
def apply(self, c, now_nanos):
|
||||
return self.CC.update(c, self.CS, now_nanos)
|
||||
def apply(self, c, now_nanos, frogpilot_variables):
|
||||
return self.CC.update(c, self.CS, now_nanos, frogpilot_variables)
|
||||
|
||||
Reference in New Issue
Block a user