Skip to content

Commit

Permalink
add possibility for arne182 events
Browse files Browse the repository at this point in the history
  • Loading branch information
arne182 authored Dec 2, 2019
1 parent d709c1a commit c808c79
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions selfdrive/controls/lib/drive_helpers.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from cereal import car
from cereal import car, arne182
from common.numpy_fast import clip, interp
from selfdrive.config import Conversions as CV

Expand Down Expand Up @@ -34,8 +34,11 @@ class EventTypes:
PERMANENT = 'permanent'


def create_event(name, types):
event = car.CarEvent.new_message()
def create_event(name, types, isarne182 = False):
if isarne182
event = arne182.CarEventArne182.new_message()
else:
event = car.CarEvent.new_message()
event.name = name
for t in types:
setattr(event, t, True)
Expand Down

0 comments on commit c808c79

Please sign in to comment.