Force Stop (cem_path) was missing a tracking_lead guard, causing it to activate behind stopped leads at red lights and stop signs — stopping the car far short of the lead instead of letting ACC handle following distance. Added and not self.starpilot_planner.tracking_lead to cem_path, matching the guard already present on dash_path.
D2 — update() in starpilot_onroad.cc now only fires when at least one overlay (showBlindspot, showSignal, showSteering, showFPS) is active. ~30–60 wasted repaints/sec eliminated when all overlays are off.
E4 — Holiday theme check reordered so current_holiday_theme != "stock" (cheapest) is first. Default is stock, so the rest of the chain never evaluates on a normal non-holiday drive.
E7 — paintSteeringTorqueBorder no longer rebuilds the QLinearGradient and computes lighter(120)/setAlpha/5 setColorAt calls every frame. The gradient is now built once in resizeEvent and reused. The per-frame work is now just the two geometry calculations and fillRect.
E5/E6/E8 — Audited clean: all remaining params_memory.put calls are event-driven (button presses, random events), no hot-path logging exists in the UI code, and all QTimers are event-driven or single-shot offroad dialogs.
Wave A (pure refactors):
A2: nnff toggle moved to front of NNFF check — kills ~100 IPC reads/sec when NNFF disabled
A4: 3 filters now use update_alpha() instead of being recreated — ~60 allocs/sec eliminated
Wave B (write reduction):
B1: CEStatus only writes on state transitions (+ E3 folded in: extracted ce_write_value local at both sites). Reset path added in the manual-override branch. ~19 writes/sec saved during cruise
B2: GPS position only persists when compass is enabled AND bearing shifts >0.5° (+ E1 folded in: json.dumps inside the gate). ~95% of writes eliminated on highway
Wave C (polling throttles):
C1: Onscreen distance button reads at 10 Hz instead of 100 Hz — ~90 IPC reads/sec eliminated. Wheel button unaffected
C2: SpeedLimitAccepted IPC read throttled to 5 Hz via existing _slc_adopt_counter. Wheel accel still instant
C3: Lane width numpy calls at 5 Hz instead of 20 Hz — ~300 allocs/sec eliminated. Counter resets when speed drops below threshold so values are fresh on re-entry
CC main button now accepts the current best speed limit source, even if new speed limit source is not flashing.
It snaps cruise speed to match (+ your offset), in either direction.
It works even before engaging longitudinal, so you can pre-set speed limit.
Won't interfere with cars using CC main for Always-On Lateral.
Fix three SLC bugs:
1. Auto-accept limits when not engaged to keep previous_target current.
2. Gate Vision out of the limits dict when not a configured priority slot.
3. Replace mapdOut fallback with 0 when filler has no data to prevent stale OSM speed limits from leaking in.
Force Stop 2.0 — Smoother deceleration curve. On cars with the ADAS stop-sign signal, stops are even more confident; cars without dashboard stop sign signal will also benefit from a new deceleration curve and MPC handoff.
Toggle off = stock behavior.
UI Build
LKAS engage/disengage sound
It will now make the same sound as op engage/disengage
Wheel Control fix 2
build
Feature: Model Name on Developer Sidebar
Model Name port and correct DEVELOPER_SIDEBAR_METRICS slot numbering
Wheel Controls button fixes
Mode/Star buttons were not showing on desk
LKAS option was showing even when car was using it for AOL, not it hides it if being used for AOL
MapGears Sync Accel/Decel on UI
MapGears will sync with "Longitudinal Tuning" UI to show chosen accel/decel profile to match with chosen drive mode.
Drive mode -> accel/decel profile mapping.
Eco → Eco
Normal → Standard
Sport → Sport+/Sport
Writes on gear state change, gated on MapAcceleration/MapDeceleration toggles independently
ECU Disable and Auto long/exp check
ECU Disable and Auto long/exp check
compile
Star and Mode buttons to wheel control options
cereal/custom.capnp — Added modePressed @16 and customPressed @17 fields to StarPilotCarState
opendbc_repo/opendbc/car/hyundai/carstate.py — Added STEERING_WHEEL_MEDIA_BUTTONS (50Hz) to the CANFD CAN parser, initialized mode_button/custom_button state, and set fp_ret.modePressed/fp_ret.customPressed in update_canfd()
common/params_keys.h — Added 6 new params: ModeButtonControl, LongModeButtonControl, VeryLongModeButtonControl, StarButtonControl, LongStarButtonControl, VeryLongStarButtonControl
starpilot/common/starpilot_variables.py — Added full short/long/very-long toggle processing for both Mode and Star buttons (gated on HyundaiFlags.CANFD), with has_canfd_media_buttons flag propagated to toggles
starpilot/controls/starpilot_card.py — Added Mode and Star button press counters and short/long/very-long press event handling, mirroring the existing distance button logic
selfdrive/ui/layouts/settings/starpilot/wheel.py — Added 6 new tiles for Mode/Star buttons (short, long, very long each), visible only when cs.isHKGCanFd is true
MapGears for HKG
Add HKG "Drive Modes" button ability to map to eco/normal/sport accel profiles.
Dashboard speed limit reading for CANFD
Add FR_CMR_02_100ms to CAN parsers in get_can_parsers_canfd: on ECAN (freq=10) for LKA_STEERING cars, on CAM (freq=0, optional) for all others
calculate_canfd_speed_limit and fp_ret.dashboardSpeedLimit assignment were already present
CAM bus uses freq=0 to avoid breaking canValid on non-LKA cars that don't have this message
CANFD steering limits
Raises STEER_MAX to 409
Speed-dependent deltas (DELTA_UP=10/DOWN=8 below 15 m/s, UP=2/DOWN=3 above),
Update panda safety ceiling and tests to match.
Removes TacoTuneHacks toggle dependency.
Ioniq 6 toml values update Updated toml values closer to learned values
DBC Update HKG Signals
Added 5 new messages to hyundai_canfd.dbc and hyundai_canfd_generated.dbc:
DRIVE_MODE_EV (0x205):
EV drive mode state with Normal/Eco/Sport (button) values. Can be used to change
acceleration profiles in openpilot based on drive mode.
CAM_0x361 (0x361):
Camera sign recognition with SIGN_TYPE and SIGN_TYPE_2 signals.
Dashboard Speed Limit. Can be used as source for SLC.
ADAS_0x380 (0x380):
ADAS stop sign detection bit. Dashboard stop sign alert.
Triggers 80-90ft before stop sign typically and can be used to help stopping for stop signs.
DOOR_LOCK (0x414):
Not actual command to lock/unlock, but may be used to detect lock state changes.
STEERING_WHEEL_MEDIA_BUTTONS (0x448):
Steering wheel button inputs (voice, phone, mode, next/prev, menu, scroll, custom)
Can be used to assign custom functions to steering wheel buttons in openpilot.
Targets Ioniq 6 but may apply to other Hyundai CAN FD vehicles.