mirror of
https://github.com/sunnypilot/sunnypilot.git
synced 2026-06-20 09:12:05 +08:00
fix
This commit is contained in:
@@ -1037,12 +1037,20 @@ EVENTS: dict[int, dict[str, Alert | AlertCallbackType]] = {
|
||||
},
|
||||
|
||||
EventName.silentDoorOpen: {
|
||||
ET.SOFT_DISABLE: user_soft_disable_alert("Door Open"),
|
||||
ET.WARNING: Alert(
|
||||
"",
|
||||
"",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.none, 0.),
|
||||
ET.NO_ENTRY: NoEntryAlert("Door Open"),
|
||||
},
|
||||
|
||||
EventName.silentSeatbeltNotLatched: {
|
||||
ET.SOFT_DISABLE: user_soft_disable_alert("Seatbelt Unlatched"),
|
||||
ET.WARNING: Alert(
|
||||
"",
|
||||
"",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.none, 0.),
|
||||
ET.NO_ENTRY: NoEntryAlert("Seatbelt Unlatched"),
|
||||
},
|
||||
|
||||
|
||||
@@ -45,10 +45,10 @@ class ModularAssistiveDrivingSystem:
|
||||
self.events.add(EventName.silentLkasDisable)
|
||||
|
||||
if not self.selfdrive.enabled and self.enabled:
|
||||
if self.events.has(EventName.wrongGear) and not self.events.has(EventName.reverseGear):
|
||||
if self.events.has(EventName.wrongGear):
|
||||
self.events.replace(EventName.wrongGear, EventName.silentWrongGear)
|
||||
transition_paused_state()
|
||||
if self.events.has(EventName.reverseGear) and CS.vEgo < 5:
|
||||
if self.events.has(EventName.reverseGear):
|
||||
self.events.replace(EventName.reverseGear, EventName.silentReverseGear)
|
||||
transition_paused_state()
|
||||
if self.events.has(EventName.brakeHold):
|
||||
|
||||
Reference in New Issue
Block a user