Skip to content

Commit

Permalink
fix bug in canpacker for Toyotas with DSU connected (#221)
Browse files Browse the repository at this point in the history
  • Loading branch information
pd0wm authored and rbiasini committed Mar 22, 2018
1 parent 3d628a6 commit c7cd8b4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions selfdrive/car/toyota/carcontroller.py
Expand Up @@ -85,7 +85,7 @@ def ipas_state_transition(steer_angle_enabled, enabled, ipas_state, ipas_reset_c
if ipas_reset_counter > 10: # try every 0.1s
steer_angle_enabled = False
return steer_angle_enabled, ipas_reset_counter

else:
return False, 0

Expand Down Expand Up @@ -200,7 +200,7 @@ def update(self, sendcan, enabled, CS, frame, actuators,
if ECU.DSU in self.fake_ecus:
can_sends.append(create_accel_command(self.packer, apply_accel, pcm_cancel_cmd, self.standstill_req))
else:
can_sends.append(create_accel_command(0, pcm_cancel_cmd, False))
can_sends.append(create_accel_command(self.packer, 0, pcm_cancel_cmd, False))

if frame % 10 == 0 and ECU.CAM in self.fake_ecus:
for addr in TARGET_IDS:
Expand Down

0 comments on commit c7cd8b4

Please sign in to comment.