* Ship precompiled eGPU model and camera warps
Compile f78ed37d-afad-4dbc-8050-40ea885eedde/12864 through xx/ml_tools/openpilot_compile using the pinned tinygrad version.
* Precompile the existing master driving model
Use the unchanged master ONNX (SHA-256 6fee5937923c74848df4a63f6239eb6331c6274dd4bdb7a5d6ec0388a8b543d5) instead of updating the trained model.
* Compile camera warps on device
* Remove obsolete ONNX chunking and big model build check
* Chunk model artifacts only during release packaging
* Require model and camera warps for Chestnut readiness
* Recompile precompiled CPU helpers for the runtime host
* Ship the eGPU model with an ARM submission helper
* Exempt model pickles from the build product size limit
* Use tinygrad generic ONNX compiler artifacts
* Keep compiler temporary model buffers off device tmpfs
* Keep recurrent model state updates on the GPU
* Use compiled output buffers and swap recurrent state inputs
* Note when ONNX chunk reassembly can be removed
* Bump tinygrad to rebased compilers and AMD queue fix
* Keep recurrent buffers fixed and use faster USB argument updates
* Bump tinygrad for faster model startup
* modeld: use tinygrad ONNX and warp compilers for driving and DM
* Bump tinygrad with current openpilot model compile tests
* modeld: prioritize tinygrad compiler imports in build environment
* Use compiler branch based on openpilot's pinned tinygrad
* modeld: invoke tinygrad compilers without firmware patch
* modeld: move history queues into ONNX
* Move ONNX history export into xx exporter
* Rename ONNX image input to new_img
* Combine ONNX model history state
* Revert model history README addition
* Keep float32 input packing from master
* Rename model input specs to input shapes
models: add a refresh models button to mici, gate and show progress on both panels
Adds the refresh-models tile to the mici models panel (it was missing there),
factoring the sync-key trigger + in-progress check into refresh_model_list()
and refresh_in_progress() shared with the big UI.
On both UIs the refresh button is now gated on offroad + not-downloading +
not-refreshing (the manager runs offroad-only and its per-tick manifest fetch
sits above a blocking download loop, so a refresh queued in either state would
stick), and shows progress while the manager refetches: mici shows "fetching..."
on the tile, the big UI flips its button from REFRESH to "FETCHING..." to match
its FETCHING.../SELECT/CLEAR label style (as in the OSM panel), replacing the
old fire-and-forget popup.
Claude-Session: https://claude.ai/code/session_01EGMnVnSk5inGTrd7kuDVG9
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-authored-by: James Vecellio-Grant <159560811+Discountchubbs@users.noreply.github.com>
* cabana: show persistent UI FPS
* cabana: render whole fps in monospace
* cabana: keep fps aligned beside centered progress
* cabana: move fps to top right
* Revert "cabana: move fps to top right"
This reverts commit 51a5334aec79807f8102b9a6f1f902f22814d5c7.
* cabana: add browser sign-in for remote routes
* cabana: use shared dialog styling for browser sign-in
* cabana: support spacious centered action buttons
* cabana: vertically center sign-in states
* cabana: keep sign-in layout stable between states
* cabana: center sign-in error text
* cabana: avoid hint flash when retrying sign-in
* replay: retry failed segment loads
* replay: rename test helper for spellcheck
* replay: include portable temporary directory declaration
* replay: name attempt limit and shorten test delays
* replay: drop timing-dependent retry tests
models: don't block the ui on an unset LagdToggleDelay
Params.get's second positional is `block`, not a fallback value, so
get("LagdToggleDelay", "0.2") passes block=True and does a blocking read.
When the param is unset this spins the ui thread until it appears, freezing
the models panel (the description is rebuilt every frame). Read it the same
way livedelay/lagd_toggle.py does.
Claude-Session: https://claude.ai/code/session_01EGMnVnSk5inGTrd7kuDVG9
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-authored-by: James Vecellio-Grant <159560811+Discountchubbs@users.noreply.github.com>
* modeld: set the valid flag on modelDataV2SP
modelDataV2SP was published with new_message's default valid=False, so
the message was permanently invalid. Nothing acts on that today because
selfdrived lists it under ignore_valid, but it shows up as invalid in
every commIssue dump and hides any real problem behind a false one.
Copy modelV2's flag, the same way fill_model_msg already does for
drivingModelData.
Assisted-by: Claude
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
* modeld_v2: set the valid flag on modelDataV2SP
The sunnypilot model runner publishes the same message and had the same
gap. Copy modelV2's flag here too, so both daemons agree.
Assisted-by: Claude
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
---------
Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
Co-authored-by: James Vecellio-Grant <159560811+Discountchubbs@users.noreply.github.com>
build-single-tinygrad-model and build-all-tinygrad-models gain a docs_repo
input (default sunnypilot/sunnypilot-models) so a fork can run either against
its own gh-pages catalog, next to the existing hf_repo input for the dataset.
build-all's setup job now checks out the repo and branch it was dispatched
from instead of sunnypilot/sunnypilot's default branch. That keeps the
manifest's tinygrad_ref tied to the code that compiled the models, and lets a
fork run the full rebuild against its own dataset and docs repo.
Claude-Session: https://claude.ai/code/session_01EGMnVnSk5inGTrd7kuDVG9
Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
Co-authored-by: James Vecellio-Grant <159560811+Discountchubbs@users.noreply.github.com>
Both are disabled in the Actions tab and have not run in months:
- Release Drafter (release-drafter.yml) and its config
.github/release-drafter.yml: last run 2025-12-18
- Debug Discourse Posting (test-discourse.yaml.yml): one-off debug
workflow from #1435, last run 2025-10-28
The post-to-discourse composite action is kept; the prebuilt workflow
still uses it. docs, stale and jenkins scan are also disabled here but
are inherited from commaai/openpilot and left in place to avoid
modify/delete conflicts on every upstream sync.
Claude-Session: https://claude.ai/code/session_01WAnUCRcA7Hp68qxyL11Wvm
Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
Co-authored-by: James Vecellio-Grant <159560811+Discountchubbs@users.noreply.github.com>
* cabana: align center tabs and keep signal panel docked
* cabana: prevent panels from docking into the tabless center
* cabana: use native docking for the Signals panel
* cabana: migrate dock tabs when loading the layout
models: add a clear cache button to mici, gate and show progress on both panels
Adds the clear-cache tile to the mici models panel (trash slide-to-confirm),
factoring the cache-size math into model_cache_size_mb() shared with the big UI.
On both UIs the clear button is now gated on offroad + not-downloading +
not-clearing (the manager runs offroad-only, so a clear queued onroad would
never be serviced and would stick), and shows progress while the manager works:
mici shows "clearing..." on the tile, the big UI flips its button to
"CLEARING..." to match its FETCHING.../SELECT/CLEAR label style (as in the OSM
panel).
Claude-Session: https://claude.ai/code/session_01EGMnVnSk5inGTrd7kuDVG9
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
* Cabana: standardize floating dropdown menus
* Cabana: use uniform items in menus and combo lists
* Cabana: remove dropdown test and explanatory comments
* cabana: standardize button spacing and control alignment
* cabana: center shared step controls and inset chart content
* cabana: use uniform per-chart content insets
* cabana: redraw floating panes during native resizing
* cabana: keep rendering while native resize is held
* cabana: use ImGui decorations to avoid native resize loops
* cabana: draw docking previews only on the target viewport
selfdrived: don't alert on a message that was never received
posenetInvalid, locationdTemporaryError and paramsdTemporaryError are raised
off the capnp defaults of deviceMotion and vehicleParameters before either
message has ever arrived. When modeld is down, locationd and paramsd never
publish, the defaults read as a nan posenet speed, and that NoEntryAlert can
hide the process not running alert that names modeld.
Same guard as the big model alert in #38500.
* Move LFS asset transfers to xet-core
* Limit migration to Git LFS hosting on Hugging Face
---------
Co-authored-by: Harald Schäfer <6804392+haraschax@users.noreply.github.com>
* esim: MICI profile download UI
* Show temporary feedback for non-LPA QR codes
* Scan eSIM QR codes every 250 ms
* Shrink eSIM error text and log displayed errors
* Activate downloaded eSIM through the profile tap flow
* Let the eSIM connectivity error wrap naturally
* Release add-profile button feedback immediately
* Check internet before opening the eSIM QR scanner
* Use UI network state and standard connectivity dialog for eSIM
* Drop LPA prime settings change from eSIM download UI
* Scope eSIM UI constants to their owning classes
* Remove unused ot codespell exception
* esim: simplify profile download operation and UI state
* esim: share activation code validation with QR scanner
* esim: match QR scanner video to cabin preview
* esim: show errors in a scrollable text dialog
* esim: require nonblank profile nicknames
* qrcode: add QR decoder
Decodes a QR code from a grayscale image or a module matrix: adaptive
binarization, finder pattern search by run ratios, perspective sampling
with alignment pattern refinement, format info, unmasking, block
de-interleaving, Reed-Solomon correction, and numeric, alphanumeric,
byte (with ECI), and Kanji segments.
Fixtures are packed matrices from python-qrcode 8.2 covering every
version and level, plus Segno 1.6.6 matrices for the ECI cases.
* qrcode: tune decoder for the device
Measured on a comma mici with real cabin frames downsampled to 672x380,
the size the eSIM screen scans at. Per frame: 30 ms -> 8 ms with no
code in view, 42 ms -> 13 ms with a code.
- binarize: fixed two-radius fill from one integral image instead of an
iterative outward fill (a dark cabin is almost all flat tiles), tile
stats on a contiguous layout, flat tiles decided whole so sensor noise
cannot become speckle, uint8 threshold compare
- finder search: scan every 4th row, build column runs only at
candidate columns
- alignment search starts at a 2-module radius
- Reed-Solomon syndromes through table lookups, placement order cached
* qrcode: simplify decoder
Fold the function-module mask into _data_coords and the format
coordinates into _read_format, evaluate masks directly on the data
coordinates, compact the ECI, numeric, and alphanumeric parsing, and
flatten the retry loop in decode. No behavior change.
Replace the level-L-only Reed-Solomon parameters, the single hardcoded
format word, and the bitwise GF(256) multiply with the full EC table,
the 32 format words, and log/antilog tables. Block splitting and
interleaving move into _block_lengths and _interleaved. This is the
structure a decoder needs to read any version, level, and mask; the
encoder's module matrices are unchanged and test_encoder pins them.
The closed-form step between alignment patterns rounds the wrong way
for version 32 (28 instead of 26). Use the form that is right for every
version. The encoder only emits versions 1-20, so its output is
unchanged.
* modeld: build DM warp and model JITs for all camera configs
In #38684, camera_configs on comma_arm64 was restricted to only the host device
running SCons (selecting either _os_fisheye or _ar_ox_fisheye).
However, prebuilt release and nightly bundles are built on TICI/tizi runners
in Jenkins and distributed to both Comma 3/3X (TICI) and Comma 4 (MICI) devices.
Because the build machine was TICI, dm_warp_1344x760_tinygrad.pkl was omitted
from the packaged bundle, causing dmonitoringmodeld to fail with FileNotFoundError
on Comma 4 and leaving driver-monitoring calibration stuck at 0%.
Restore CAMERA_CONFIGS so both camera resolutions (1928x1208 and 1344x760)
are built for all platforms.
Fixes#38762
* simplify
---------
Co-authored-by: ZwX1616 <zwx1616@gmail.com>
* esim: MICI eSIM profile management UI
* esim: align rename button position regardless of delete button
* esim: skip profile UI when SIM is not an eUICC
Probe is_euicc() on the first profile poll and cache it; non-eUICC SIMs
avoid list_profiles/process_notifications (which hang on a plain SIM) and
the eSIM button shows ICCID/MCC-MNC metadata instead of opening the
profile management screen.
* esim: satisfy ruff E731 in action_pressed helper
* esim: get modem info from modem.py state instead of shelling out
* esim: simplify switch lifecycle, drop active flag and settle window
* esim: only show 'switching...' on the target profile
* esim: read cell strength directly from HARDWARE
* esim: hide checkmark and dim cell icon during switch; keep rename available
* esim: disable active profile button (rename still clickable as overlay)
* esim: stop rename/delete buttons and labels from flashing during operations
* esim: show 'comma prime' on network button for comma profile
* esim: move display_name and is_comma onto Profile dataclass
* esim: anchor rename button to rightmost slot to prevent shift
* esim: include iccid prefix check in Profile.is_comma
* esim: drop process_notifications from cellular manager
* esim: disable network button when SIM isn't an eUICC
* esim: rename ESim* classes to Esim*
* esim: sort imports
* esim: default to 'loading...' instead of 'no active profile'
* esim: rename PROFILE_POLL_INTERVAL to PROFILE_POLL_INTERVAL_S
* esim: slim EsimNetworkButton
* esim: use DEFAULT_TEXT_COLOR; load delete dialog texture in __init__
* esim: revert cell-icon index trick, name each NetworkStrength explicitly
* esim: tighten delete/rename spacing so 'switch' label fits on one line
* esim: shrink delete/rename buttons by 25%
* esim: keep rename button at full size, only delete shrinks
* Revert "disable modem.py for now"
This reverts commit 1eeba86ec1.
* Revert "modem.py is disabled"
This reverts commit d238a1ccc4.
* lpa: inline comma iccid prefix
* ui/cellular_manager: clear switching state when LPA returns
* ui/cellular_manager: lock callback queue, drop poll log noise
* esim: sort NetworkStrength/NetworkType imports
* esim: drop switching_iccid concept
* esim: show 'switching...' on the clicked profile button
* esim: optimistic switch, skip post-switch list_profiles to avoid flicker
* esim: only style profile button from local op flags, not global busy
* esim: remove deleting/switching state, collapse profile button branches
* esim: show GSM settings on full prime when non-comma profile is active
* esim: expose CellularManager.active_profile, dedup callers
* esim: apply comma prime defaults on switch (roaming, metered, no APN)
* esim: restore re_sort on show_event to avoid first-frame jank
* lpa: apply comma prime defaults inside TiciLPA.switch_profile
* lpa: lazy-import Params to break circular import
* lpa: treat +CME ERROR 13 (SIM failure) as non-eUICC in is_euicc
* esim: show 'obtaining IP...' on non-eUICC path while connecting
* Revert "lpa: treat +CME ERROR 13 (SIM failure) as non-eUICC in is_euicc"
This reverts commit 475ca448ea914ff8f9892b4cbf4525d961d7618b.
* esim: poll profiles every 5s
* lpa: tighten Profile.is_comma to require both Webbing provider and comma BIN
* lpa: fall back to '<unnamed>' instead of iccid prefix in display_name
* esim: re-probe is_euicc each poll for runtime SIM swaps
* esim_ui: rename EsimUIMici to EsimUI
* esim: simplify cellular manager and profile UI
- optimistic profile switch at click time so the active button no longer bounces back
- unify LPA worker threads, refresh_profiles resets the poll timer
- deterministic profile ordering on show
- reuse wifi ForgetButton for delete, drop DeleteButton
- construct CellularManager inside NetworkLayoutMici
- drop comma prime param defaults from LPA.switch_profile (moved to a separate PR)
* esim: drop eUICC state change log
* ui: gate cellular settings on prime subscription
* ui: disable eSIM management for full prime
* ui: keep eSIM management disabled for full prime
* ui: unify eSIM profile action buttons
* ui: tighten eSIM profile action spacing
* ui: place rename before delete in eSIM actions
* esim: restrict individual profiles and process switch notifications
* esim: defer poll after operations and confirm eUICC loss before clearing profiles
* ui: allow cellular settings for unregistered and unpaired devices
* ui: disable all profile switching for full prime
* ui: simplify cellular access to not full prime
* ui: make profile poll interval a CellularManager constant
* ui: read modem state on the profile poll cadence
* ui: scope eSIM profile colors to their class
* ui: inline modem state read in cellular polling
* ui: rely on hardware modem state fallback
* cabana: connect palette theme, rounded cards, floating page switch
Move the jotpluggler port's connect palette into a shared theme module
(ui/theme.h/.cc) and apply it to all of cabana: Palette struct for dark
and light, applyTheme fills ImGui and ImPlot styles, readableCurveColor
and sectionTitle for reuse by the analysis workspace. Drop the old
DarkTheme constants and per-theme color branches in widgets.
Docked panels are borderless with content in rounded bordered cards;
custom-drawn rects use the style radii. The detail widget's bottom tab
bar is replaced by a floating Messages/Logs pill.
* cabana: scrollbar and menu contrast, page switch below the page
The scrollbar grab uses the border color on the window-colored track.
Selection colors are stronger so an open menu reads as blue in both
themes and the hovered item is visible in light mode. The Messages/Logs
pill sits in a strip below the page instead of covering its last rows.
* cabana: even spacing around the page switch, steady top menu highlight
* cabana: inner spacing before the clear button of a clearable input
* cabana: center the page switch below the page, space the signal row buttons
* cabana: logs table cells padded and bordered like the messages table
* cabana: recess the signals card in the window color
* cabana: one button vocabulary
Three button shapes, all one frame height with the style padding and
rounding: ImGui::Button for framed text, iconButton for a framed square
icon, toolButton for a flat square icon (or flat text). Adjacent buttons
are ItemInnerSpacing apart, groups ItemSpacing apart. Tool bars drop
their private padding and 1 px spacing, the signal row, chart header,
detail header, logs export and signal selector buttons all use the
shared sizes, and the page switch is built from the same style values.
* cabana: center the glyph ink in square icon buttons
* cabana: framed tool buttons and plain icon glyphs
toolButton is now iconButton with an optional text, so every button in
the app is framed. Boxed glyphs (plus-square, x-square, dash-square,
arrow-*-square, window-stack) are replaced by their plain variants
(plus-lg, trash, arrows-collapse, box-arrow-*, window-plus), the light
x/plus/dash by their -lg forms, the chart menu by three-dots-vertical
and the toolbar overflow by chevron-double-right.
* cabana: draw square button glyphs at 80% so full bleed icons keep a margin
* cabana: signal values in the mono font
* cabana: center square button icons on their atlas ink, snapped to framebuffer pixels
* cabana: draw square button glyph quads directly, AddText truncates the position
* cabana: right align the messages and signals tool bars to the table edge, full size collapse button
* cabana: detail header and tab scroll buttons flush with the right edge
* cabana: header and footer strips, gap above the panels, video splitter as a separator
The menu bar and the status bar are strips in the surface color with a
separator line towards the panels, and the dockspace sits one item
spacing below the menu bar, matching the spacing above the status bar.
The video/charts splitter draws the same 1 px separator line as the
dock splitters, centered in a gap as tall as the side padding, and a
double click snaps the video back to its natural height.
* cabana: top menus flush with the menu bar, 2 px video splitter without double click
* cabana: dropdowns continue the menu bar, splitter in the border color, row button gap
Top level menus draw no top border and square top corners, and the menu
bar leaves its separator out under the open dropdown. The video splitter
uses the border color like the dock splitters. The signal row buttons
keep one inner spacing before the scrollbar.
* cabana: dropdowns share the bar's 1 px border line, messages toolbar spacing matches the video card
* cabana: tool bar groups, framed dropdown buttons, chart content flush with the tool bar
Tool bar items are ItemSpacing apart and the items of a group (a button
pair, a separator and its neighbor) ItemInnerSpacing apart, instead of
a private 1 px spacing. The dropdown buttons are framed like the other
buttons. The video time is a plain mono readout that toggles on click.
Chart cards have no horizontal margin so their header and plot line up
with the tool bar above.
* cabana: chart list spacing: gap above the scroll area, charts clear of the scrollbar, even legend gaps
* cabana: loop and speed buttons grouped like the playback buttons
* cabana: survive narrow panels and small windows
Stress tested by dragging the column and video splitters to their
limits and shrinking the window to 640x480. Fixes: the messages tool
bar and the message detail header overflow into the >> menu instead of
clipping (the view button and the name stay); the binary view keeps a
minimum cell width and scrolls sideways; the Messages/Logs switch drops
to icons when the strip is too narrow; the camera keeps its last frame
across reconnects, so a video restored from a collapsed splitter while
paused is no longer black.
* cabana: range slider spans the charts >> menu, remove all and float as menu entries
* cabana: the charts card keeps its tool bar row or collapses, like the video at the other end
* cabana: uniform >> menus: dropdowns become submenus, the time readout an action entry
* cabana: video/charts splitter gap matches the column splitters
* cabana: drop unused lambda capture in chart type menu
Claude-Session: https://claude.ai/code/session_01XTFaJpf235LeHBmyFRgeJ1
* cabana: the menu bar and the status bar stay in full screen
* cabana: simplify theme helpers and toolbar actions
* cabana: preserve panel width for overflow edit dialog
* cabana: keep message editor usable in narrow panels
* cabana: group heatmap modes in a dropdown
* cabana: trim redundant restyle comments
* cabana: fix review findings from the restyle
- set the caret and other unset colors so the light theme has no white caret
- tolerate float error in the toolbar fit check to stop spurious overflow
- restore the full screen chrome hiding
- clear stale camera frames when the server changes, keep them across a collapse
- cache icon glyph ink bounds instead of scanning the atlas every frame
- drop dead plot_bg and ImPlot globals, add a badge palette role
- add toolbarMenu and use toolbarAction for the remove message item
- derive the signal view button size seed from the font and style
* cabana: remove remaining redundant comments
On Wayland a vsynced glfwSwapBuffers blocks until the compositor sends a
frame callback, which it stops doing while the window is on another
workspace or otherwise off-screen. The main thread never gets back to
glfwPollEvents, so Hyprland reports cabana as not responding.
Run with swap interval 0 and pace the loop to the monitor refresh rate.
git-lfs is vendored in the venv, but `git lfs install` writes filters and hooks that invoke a bare `git-lfs`, which is only on PATH inside the venv. With filter.lfs.required set, any checkout from a plain shell fails.
git runs filters and hooks from the worktree root, so a relative path into the venv resolves from anywhere.
* ui: remove raygui usage (#38708)
* ui: remove raygui usage
* match previous gui_text_box line spacing
* Revert "match previous gui_text_box line spacing"
This reverts commit ffd2fe31725c6d50bffaebc621c1e170d0926c66.
* Reapply "match previous gui_text_box line spacing"
This reverts commit d41404f09607e225f43868f7747f22dc0bb2cf16.
* log chestnut supply fault (#38711)
* log chestnut INA supply fault
* ci
* bump raylib (#38712)
* cabana: replace custom non-view Qt signals w/ plain observer (#38713)
* cabana: move RoutesDialog out of streams/ (#38716)
* cabana: string helpers in utils return std::string (#38720)
* cabana: use std::string in RoutesDialog API results (#38717)
* cabana: move stream open widgets into streamselector (#38715)
* cabana: remove Qt from livestream (#38722)
* cabana: split SettingsDialog out of settings (#38719)
cabana: split SettingsDialog out of settings.{h,cc}
* cabana: split comma API route fetching out of RoutesDialog (#38721)
* cabana: de-QT streams (#38718)
* ui: fix install update button overflow (#38696)
* cabana: split utils/util into Qt-free util and qtutil (#38723)
* ui: guard branch switcher before internet connected (#38692)
* ui: check for update on target branch switch (#38693)
* ui: sync gpu loading to offroad (#38727)
ui: sync gpu loading state
* add chestnut offroad alerts (#38706)
* system: add chestnut offroad alerts
* system: refine chestnut offroad alerts
* system: refine chestnut power alerts
* system: confirm chestnut power recovery from PCIe
* system: detect missing chestnut power from INA voltage
* common: fix OpenpilotPrefix cleanup on macOS (#38728)
The destructor built its cleanup commands as "rm %s -rf", with the flags
after the operand. GNU rm permutes arguments so this works on device and
in CI, but BSD rm on macOS stops option parsing at the first operand and
treats "-rf" as a second filename:
$ mkdir -p /tmp/rmtest/sub && rm /tmp/rmtest -rf
rm: /tmp/rmtest: is a directory
rm: -rf: No such file or directory
exit=1
So nothing is removed, and each of the four calls prints two errors plus
"system command failed (256)" from check_system. Every run of a tool that
owns an OpenpilotPrefix (replay, cabana) leaks its params dir, its
comma_home and its /tmp/msgq_ dir; 33 of each had accumulated on my
machine.
Pass the flags first.
* replay: capture downloader's stderr so download progress is reported again (#38734)
* bump panda (new health packet) (#38736)
pandad: support compact health packet
* BMRLNAP (#38681)
* ui: clarify branch switcher error message (#38732)
* ui(mici): name updater signal constants (#38731)
* mici: name updater signal constants
* drop SIGNAL_ prefix
* self contained
---------
Co-authored-by: Shane Smiskol <shane@smiskol.com>
* modem.py: accept hex chars in ICCID (#38735)
E.118 specifies decimal digits, but many real SIMs carry hex characters
in EF_ICCID (e.g. China Mobile's 898600B5... range, some MVNO/IoT SIMs).
AT+QCCID returns them verbatim, and the strict isdigit() check blanked
the ICCID, leaving the modem daemon stuck in INITIALIZING forever and
cellular dead. ModemManager parses ICCID as hex for the same reason.
Verified on a comma four with a China Mobile SIM (EG916Q-GL): previously
stuck retrying 'identity read incomplete', now dials and passes traffic.
* TGC (#38739)
* 23e6a04e-e6e5-462b-a0bb-e4088275ee43/12864 tgc
* here
* monitor chestnut USB in hardwared (#38741)
hardwared: monitor chestnut USB independently
* modeld: wait for stable chestnut (#38742)
modeld: wait for stable chestnut
* Revert "monitor chestnut USB in hardwared (#38741)" (#38744)
This reverts commit 7d5596d5c3.
* amd warp (#38684)
* modeld: fuse warp and policy TinyJit
* bump tg
* fix?
* this simple trick...
* debug 1
* bump tg
* pack all
* wips
* fix
* BIG_INTO_SMALL remove
* slower
* ui: show usb connection (#38745)
* ui: show USB status
* ui: resize USB icon
* ui: classify USB device once
* ui: debounce USB disconnect
* cereal: log big model in drivingModelData (#38747)
* ui: show one GPU status (#38748)
ui: show one GPU status icon
* AGNOS 19.7 (#38750)
---------
Co-authored-by: Trey Moen <50057480+greatgitsby@users.noreply.github.com>
Co-authored-by: Daniel Koepping <elkoled@gmail.com>
Co-authored-by: Robbe Derks <robbe.derks@gmail.com>
Co-authored-by: Harald Schäfer <harald.the.engineer@gmail.com>
Co-authored-by: Shane Smiskol <shane@smiskol.com>
Co-authored-by: XiaoXX <xiaoxx97@outlook.com>
Co-authored-by: YassineYousfi <yyousfi1@binghamton.edu>
* cabana: imgui frontend base infra (ui/)
* cabana: line-for-line imgui ports of the Qt widgets and dialogs into ui/
* cabana ui: fixes from the side by side parity test
* cabana ui: deqt.md status after the line-for-line ports
* cabana ui: fixes from the line-for-line review
* cabana ui: parity fixes from the end to end matrix, event driven frame pacing
* cabana ui: preserve F1 help formatting
* cabana ui: parity fixes from the end to end matrix, event driven frame pacing
* cabana ui: deqt.md status
* cabana: fix macOS build of imgui frontend
- link Security.framework (libusb's darwin backend needs
SecTaskCreateFromSelf/SecTaskCopyValueForEntitlement)
- drop unused loop counter in SignalView::updateChartState
- avoid -Wshadow on Sparkline::size and SignalView::highlight
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana ui: parity round 3 fixes, thread pool and one malloc arena for flat memory
* cabana ui: toolbar overflow budget, menu button carets, help overlay colors, signal editor validation
* cabana ui: deqt.md status
* cabana: let vsync pace the frame loop
The loop threw away frames with glfwWaitEventsTimeout() to hit a 30fps
(10fps idle) target while glfwSwapBuffers() was already blocking on
vsync, so two clocks beat against each other. Input events also reset
frameInterval() to 0 for a few frames, so a click swung the cadence from
~33ms to ~13ms and back -- the camera view redraws on the UI's schedule,
so that showed up as a visible hitch on every message selection.
Poll and draw every iteration and let glfwSwapInterval(1) do the pacing.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana: fix macOS build of thread pool / malloc arena changes
- malloc.h and mallopt(M_ARENA_MAX) are glibc only; guard on __GLIBC__.
macOS has a single allocator zone, so there is nothing to cap.
- capturing structured bindings in a lambda is a C++20 extension and
clang rejects it under -Werror; bind the event range to plain locals.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana ui: chart axis label precision, signal list click on empty space clears the selection
* cabana ui: codespell
* cabana ui: taller signal rows, system theme detection, full dark palette
- signal rows are 1.5x a frame tall with the sparkline sized to the row,
so the graphs are readable. The expanded sub-rows keep the Qt height.
- "Automatic" resolved to the light theme regardless of the system: Qt
gets this from QStyle::standardPalette(), which follows the macOS
appearance, so read AppleInterfaceStyle and match it. Other platforms
stay light, like standardPalette() does there.
- widgets that tested settings.theme == DARK_THEME themselves went light
under AUTO_THEME while the style went dark; they now ask isDarkTheme()
for the theme applyTheme() actually resolved.
- the dark branch only set 10 ImGuiCol_ entries, so buttons, scrollbars,
tabs, title bars, separators, tables and grips still came from imgui's
stock dark theme. Derive the whole palette from DarkTheme instead.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana ui: drop the dead y axis alignment chain and chart cache stub
ImPlot::BeginAlignedPlots aligns the chart y axes, so the hand-rolled
alignment protocol ported from Qt no longer feeds anything: align_to was
write-only. Remove the whole chain (y_label_width and its measuring loop
in draw(), axisYLabelWidthChanged, align_timer, alignCharts), which
reduces updatePlotArea(int, bool) to updatePlotArea().
resetChartCache() has been an empty stub since the port (imgui redraws
every frame); drop it and its four call sites. Also replace the empty
move_icon_rect branch in mousePressEvent with an early return.
No behavior change. updateAxisY's "|| y_label_width == 0" guard only
fired after a unit change, and y_precision/y_tick_count depend solely on
min_y/max_y/tick_count, so the recompute it triggered was a no-op.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana ui: stop the main window from scrolling
The host window that holds the dockspace uses zero WindowPadding but the
default ItemSpacing, so the dockspace and the status bar below it summed
to ItemSpacing.y (5px) more than the viewport, leaving the whole UI
scrollable by a few pixels.
Reserve the spacing along with the status bar height, and mark the host
window NoScrollbar/NoScrollWithMouse: it is pinned to the viewport work
area and should never scroll, as QMainWindow does not. Full screen is
unaffected, it draws no status bar and reserves no height.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana ui: inset the status bar so its ends are not clipped
A borderless BeginChild gets WindowPadding forced to zero, so the status
bar text sat flush against both edges and the first glyph of "For Help,
Press F1" was cut off. Inset both ends by WindowPadding.x, which lines
the text up with the content of the docked panels above it.
Right align the cached minutes / FPS label to the captured child width
rather than calling GetContentRegionAvail() again after the message
text, which only returned the full width because the text had already
wrapped the cursor to a new line.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana ui: drop the leftover imgui object census log
The block printed an imgui/implot object count to stderr every 10s,
which was instrumentation for tracking down a leak, not something the
port needs. It was the only user of implot_internal.h in mainwin.cc, so
drop that include with it.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana ui: keep the selected row highlighted while hovered
Selectable() picks its background as HeaderActive when held, else
HeaderHovered when hovered, else Header. The hovered test comes before
the selected one, so a selected row under the cursor takes the hover
color. Both tables push a transparent HeaderHovered to suppress the hover
highlight that QTreeView/QTableView do not have, which also blanked the
selection: clicking a row walked press (HeaderActive, visible), release
(HeaderHovered, transparent, looks unselected), then mouse off the row
(Header, visible), so the selection appeared to flicker until the cursor
moved away.
Only make HeaderHovered transparent for rows that are not selected.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana ui: draw the binary view hex column in bold and in the text color
The Qt delegate never sets a pen for the hex column, so it inherited the
black QPainter default and the two halves of a row did not match. Use
paletteText(is_message_active), the same color the bit columns use, so
both halves read as one row and dim together when the message goes
inactive.
JetBrains Mono ships no bold variant and imgui has no embolden option, so
give drawStaticText a bold flag that redraws the glyphs a fraction of a
pixel to the right. That keeps the monospace advance, which switching to
the proportional bold face would not.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana ui: highlight the whole row in the speed menu
MenuItem spans from the cursor to the right edge, so the Indent() that
made room for the radio bullet also pushed the highlight in by one
FontSize and left the bullet column outside it. QMenu highlights the
whole item, indicator included.
Draw each row as one full width Selectable with the bullet and the label
inside it. Every row declares the same width, so the popup is as wide as
the widest entry and the highlights reach both edges; a label-less
Selectable sized zero would declare no layout width and collapse the
auto-sizing popup. Selectable auto-closes its parent popup like MenuItem
does, so clicking still works in the dropdown and in the Speed submenu of
the toolbar overflow menu, which shares this function.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana ui: fix help menu overlay, Ctrl+F11, time label clipping, toolbar overflow and tool table parity
* cabana ui: click to edit signal cells, light theme selection, logs cell selection and filter fixes
* cabana ui: chart x label margin, zoom context menu items, video splitter collapse, signal editor close
* cabana ui: signal editor lifetime and close, logs cell hover, tool table headers
* cabana ui: branch indicator clicks, editor swallows shortcut and button clicks, selection colors
* cabana ui: float dock windows into real OS windows
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana ui: toolbar menu arrow spacing, only open the editor on editable cells
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* op: add cabana2 to run the imgui cabana
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana: cabana2 launcher script builds _cabana_ui before running it
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana ui: only float the dock panels into their own OS windows
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana ui: open the video pane at the camera's natural aspect ratio
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana: default fps to 30
* cabana ui: fusion palette, shared fusion slider, chart grid colors
* cabana ui: smaller checkbox indicator, closer to the Fusion size
* cabana ui: video toolbar height and item centering, separator extent and menu arrow like Fusion
* cabana ui: message and signal row heights match Qt
* cabana ui: timeline slider height, groove and stacking match the Qt video layout
* cabana ui: fix crash opening a live stream, the video pane default height read the missing camera widget
* cabana: drop the FPS setting, the streams update the UI at a fixed 30 fps
* cabana ui: video and charts pane run edge to edge with a uniform toolbar margin like the Qt frames
* cabana ui: binary view M/L marker size and timeline event fills match Qt
* cabana ui: signal view keeps its sparklines while filtering, number label size matches Qt
* cabana ui: no modal dim fade, QDialog does not animate in
* cabana ui: collapse all is an auto-raise tool button with the Qt icon size
* cabana ui: dialogs and tool windows open as real OS windows like QDialog
* cabana ui: hold back a focus loss while a mouse button is down so tearing a panel off does not abort the drag and create its window twice
* cabana ui: speed menu rows pad the label on the right like QMenu
* cabana ui: raise the dark theme contrast, the Darcula grays all sat on top of the background
the chart y axis guides are opaque and 2 px in dark mode, and text, outlines,
separators, table borders, scrollbar and slider grabs move away from the window
and base grays. light theme is unchanged.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana ui: simplify comments, drop the Qt references and the ones that only restate the code
* cabana ui: keep the sparkline antialiased, thin peaks sparkled as the window slid
Qt dropped antialiasing above 500 points because it rasterized into a pixmap. drawing
straight into the frame, an aliased 1 px segment between two columns rounds into one of
them and the rounding flips as the window advances, so the peaks of the dense signals
popped between columns. updateState runs at STREAM_UPDATE_FPS, which at a 30s range moves
the curve well under a pixel per update, so the flip is all that is visible.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana ui: anchor the sparkline to the time window, it jittered sideways as samples expired
x was measured from the first sample still inside the window, which changes whenever the
oldest one falls out, so every update slid the whole curve sideways by the sample spacing.
measuring from the start of the window pins the right edge and lets the samples flow left
with the clock. the density heuristic wanted the data span, which is no longer the x of the
last point, and the flat line started at x 0 instead of at its first sample.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana ui: scroll the sparkline at the frame rate, it stepped at the message rate
the window ended at the last message of the id and updateState only runs when one arrives,
so a slow message held the sparkline still for several frames and then jumped it. the window
now ends at the playback clock, and draw() slides the rendered polyline by the time that has
passed since it was built, clipped to the cell.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana ui: keep the signal value on the right of the column before there is a sparkline
it was drawn left aligned from the start of the column, so the value sat next to the name
until the first samples arrived and then jumped across the row.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana ui: read a little past the sparkline window so the oldest points slide out of it
a sample used to disappear the moment it aged out, which on a fixed rate signal is a point
popping off the left edge. the query reaches back a bit further and the clip rect hides it
instead. the lead in must not move the scale, so it is left out of the min and max.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana ui: use the macOS fullscreen space, taking over the monitor rendered at the old size
glfwSetWindowMonitor switched the display mode and returned a drawable at that mode, so the
ui was rendered at the windowed size and stretched over the screen. NSWindow toggleFullScreen
keeps the backing scale. the green button goes through the same space, so the state is read
back from the style mask rather than tracked.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana ui: let the signal value column shrink again, it held the widest value ever seen
max_value_width only ever grew, so one long value left the sparklines ending
well short of the text for the rest of the message. Track the current widest
value instead, growing on demand and giving room back once it is a couple of
characters too wide, which keeps the width from jittering per sample.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana ui: make the signal rows a quarter taller so the sparklines read better
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana ui: lift the binary view heatmap alphas in dark mode, the tints washed out
The alphas were tuned against a white background; over the dark base the same
values left the cells barely colored. The floor comes up and the ramp gets a
gamma in dark mode only, which keeps the flip counts in the same order.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana ui: saturate the sparkline color in light mode, the pastel lines vanished
Signal colors are low saturation and high value, which is aimed at dark fills;
a 1 px line of one of them on white is hard to see. Draw the sparkline with
twice the saturation and less value when the theme is light.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana ui: give the docked panels a minimum width, the dividers ran over content
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* replay: capture the downloader's stderr so the progress lines reach the handler
file_downloader.py writes PROGRESS:<cur>:<total> to stderr while it streams a
file, but runPython() only piped stdout and left stderr attached to the parent,
so the progress handler only ever fired on failure and cabana downloaded a
segment with no progress bar. Pipe stderr as well, turn the PROGRESS lines into
handler calls, and pass everything else through to the parent's stderr.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* replay: read the downloader's stderr on a thread, the two fd select was overkill
getline() handles the line splitting, partial lines and EOF, so the manual
splitter, the second drain loop and the multiplexing bookkeeping go away and
the stdout loop goes back to what it was.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana ui: one toolButton helper in imgui_util.h
* cabana ui: one toImU32/toImVec4/paletteBrightText in imgui_util.h
* cabana ui: string helpers live in utils/strings.h
* cabana ui: share the fusion slider handle from imgui_util.h
* cabana ui: style.cc declarations move to imgui_util.h
* cabana ui: validatedInput and the qt validators move to imgui_util.h
* cabana ui: viewSelectable helper for the item view rows
* cabana ui: drop the comboBox pass-through
* cabana ui: tabbar moves to its own file, ready for the charts port
* cabana ui: find signal searches on the main thread again, deferred one frame like QTimer::singleShot(0)
* cabana ui: find signal computes its button and label state from the model instead of caching it
* cabana ui: share the queued popup owner protocol between the message box and the file dialog
* cabana ui: one beginDialog helper for the three centered modals, with the reopen recovery
* cabana ui: tool dialogs share the title, begin/end and escape handling, and own their connections
* cabana ui: comboBox helper replaces the hand rolled zero separated item buffers
* cabana ui: drop the unused dialog isOpen accessors
* cabana ui: one validatedText helper for the ip, double and int line edits
* cabana ui: route info reads the route segments instead of caching a row copy
* cabana ui: settings drops the phantom fps label, the constant spin flags and the raw log path buffer
* cabana ui: find similar bits drops the no-op find button disable and the address round trip
* cabana ui: message box warning overload without the empty detailed text
* cabana ui: help overlay only collects rects while it is up, skips torn off panels, and the fingerprint compare is ordered
* cabana ui: drop the glfw callbacks that only forward to the imgui backend, which already installs them
* cabana ui: elided label renders with RenderTextEllipsis instead of a paint time cache
* cabana ui: one save loop, inline cached minutes label, and drop the dead help parser branches
* cabana ui: signal cell bands are built from the two corner notches instead of a region sweep
* cabana ui: binary view items go through itemAt and updateItem assigns unconditionally
* cabana ui: message bytes read the cell padding inline and colored bytes keep the qt default pen
* cabana ui: detail widget drops createToolBar, the welcome widget flag and the unused whatsThis
* cabana ui: messages widget owns its view, header and model directly, fixed size filter editors, from_chars range parsing
* cabana ui: colored hex bytes keep the row pen, the qt delegate does not reset it per cell
* cabana ui: closeEditor drops the queued commit, its item is about to be deleted
* cabana ui: rowsInserted carries the insert position so the selected row follows its message
* cabana ui: the log filter and the message name editors use the shared validators
* cabana ui: the log header sizing and painting are free functions, no HeaderView object
* cabana ui: the visible row range is the change detector, no mirrored scroll position
* cabana ui: the line editor takes the focus flag as an argument and lets InputText revert on escape
* cabana ui: signal view drops the unreachable column parameters, unused item values and repeated sparkline tests
* cabana ui: rows outside the tree viewport are measured but not painted
* cabana ui: one toolbar item table, playback state read in draw()
* cabana ui: draw the stored thumbnail scaled by AddImage, no cpu prescaled copy
* cabana ui: one radioMenuItem helper for the speed and series type menus
* cabana ui: drop dead camera members, hoist the jpeg colour space branch, decode qlog thumbnails on the thread pool
* cabana ui: stop the vipc thread when the splitter collapses the video pane
* cabana ui: the toolbar strings and enabled state are computed in drawToolBar
* cabana ui: chartswidget uses the shared tabbar widget
* cabana ui: the chart header layout is recomputed in resizeEvent, no updateTitle
* cabana ui: updateLayout has no force flag
* cabana ui: one condition hides the value tip
* cabana ui: signal selector uses the shared dialog buttons and row indexes
* cabana ui: the chart tile geometry is one Layout struct saved and restored by drawGhost
* cabana ui: drop the empty theme branch, the unused size hint and the charts container indirections
* cabana ui: the chart holds its tip label by value
* cabana ui: one toolbar item list for both toolbar groups
* cabana ui: the sparkline polyline is emitted through the draw list path
* cabana ui: the tab bar latches a programmatic selection and defers the close request past EndTabBar
* cabana ui: validatedText refuses an invalid edit inside the imgui buffer and the ip field keeps its char filter
* cabana ui: drop the ambiguous three argument warning overload
* cabana ui: combobox reports a real change, menu rows span the popup, one popup protocol for the dialogs
* cabana ui: the startup stream is owned by the window until the first frame opens it
* cabana ui: the slider toolbar index has an out of range sentinel
* cabana ui: the find signal search runs on the frame after the pending state is painted
* cabana ui: the log clears its selection when the rows are dropped and cells are identified by their message
* cabana ui: the open editor survives a scroll, collapse all commits it and escape in the size editor does not
* cabana ui: the header display order is filled with iota
* cabana ui: qlog thumbnails decode on their own threads, the hover thumbnail is mipmapped and the time tooltip appears on the first toggle
* cabana ui: a collapsed video dock stops the vipc thread
* cabana ui: one TOOLBAR_ITEM_SPACING, the signal view used the QCommonStyle 4 instead of Fusion's 1
* cabana ui: sparkline includes imgui_util.h for isDarkTheme
* cabana ui: imgui_util.h becomes util.h and util.cc
* cabana: delete deqt.md
* cabana ui: panel min width, matching video panel padding, centered tabs
The dock panels stop shrinking at the width where the signal view tool bar
squishes instead of at a hardcoded 440. The video/charts panel keeps the
standard window padding so it lines up with the other panels, and the
Msg/Logs tabs are centered in their bar. The cached minutes label is gone
from the status bar.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana ui: persist imgui state in cabana.json and migrate the Qt frontend's layout blobs
* cabana ui: 2px sparkline stroke
a 1px antialiased line is all fringe and no solid core, so the curve
faded and shimmered as the window scrolled.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana: drop the Automatic color theme
it only did anything on macOS: the Qt frontend fell through to
standardPalette() for both Automatic and Light, so the two were
identical everywhere else.
LIGHT_THEME and DARK_THEME keep their values so a persisted dark theme
still reads as dark; the old Automatic 0 falls back to light on load.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana ui: window color between the binary and signal views, fixed split
the binary view sits at its size hint and no longer resizes, and the gap
below it takes the window color instead of leaving a white seam.
also border the video and chart panels like the signal view.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana ui: bigger tab bar scroll buttons
imgui's built in scroll arrows are fixed at FontSize - 2 wide with the
glyph drawn in a FontSize box, so they are small and sit off center.
draw chevron buttons at the frame height instead, spaced and disabled at
the ends of the scroll range like the rest of the tool buttons.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* cabana ui: 1.5px sparkline stroke
* cabana ui: stable sparkline scrolling, one sample per column, aliased spikes
Scroll the polyline by whole physical pixels with each sample's subpixel
phase fixed to its timestamp, thin to one sample per pixel column, and
draw near-vertical segments aliased so spikes stay crisp while smooth
curves keep antialiasing.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
* cabana ui: fix spelling
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
* cabana ui: size the value column for the widest value a signal can produce
Sizing it to the values in the last message moved the sparklines every
time a value changed length.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
* cabana ui: center the tab bar scroll chevrons and give the buttons a frame
The icon font glyph sits off center in its padded advance, so the
chevron is drawn in the button rect. The buttons take the theme's
button background and border like the tool buttons next to them.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
* cabana ui: darker grid lines between table cells
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
* cabana ui: the gap between the video and the charts matches the side padding
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
* cabana ui: plus-square icon for the new chart button, like the remove all button
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
* cabana ui: video toolbar buttons as tall as the charts toolbar buttons
The buttons carried 10 px of vertical padding, so the hover rect was
much taller than the glyph and the row looked off center.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
* cabana ui: the time display in the mono font at the ui font size
With proportional digits the time changed width as it ticked and the
items after it moved.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
* cabana ui: closing a floated side panel docks it back, no hide tab bar button, the charts container never scrolls
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
* cabana ui: the message tabs use the TabBar widget, chevron scroll buttons for both tab bars
The chevron scroll buttons move into a scrollable tab bar widget that
both use. The wheel scrolls the tabs, both tab bars get Close Other
Tabs, and the Msg tab is labeled Messages.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
* cabana ui: deliver a focus loss right away on macOS, holding it back swallowed the first click in a popup
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
* cabana ui: draw the remote routes dialog at the modal's level, opened inside the tab's child window it never appeared
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* cabana ui: --no-cache turns off the local route file cache, same as replay
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* cabana: parse merged segments on replay's merge thread, the parse on the main thread dropped frames on every merge while downloading
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* cabana ui: Esc leaves full screen on all platforms
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* cabana ui: an app bundle on macOS so the menu bar and the dock show Cabana
A bare binary shows its file name there. The build wraps _cabana_ui in
a minimal Cabana.app with an Info.plist and the launcher runs that.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
* Revert "cabana ui: an app bundle on macOS so the menu bar and the dock show Cabana"
This reverts commit 1a45540125847ca46fcd4d7ac0522918e315057d.
* cabana ui: the app menu on macOS says Cabana
A bare binary gets an info dictionary with its file name in it, which
glfw reads for the app menu. The name is set there before glfw brings
up cocoa.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
* cabana ui: macapp moves into ui/util
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
* cabana ui: setMacAppName lives in ui/util.cc
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
* cabana ui: apply the code review
Bugs: an empty decode batch dereferenced vals.front(), the chart x comparator
took a float, reserve used capacity(), the bit text went black while resizing
a signal, byte cells under-sized non-multiple-of-8 payloads, the CAN speed
lookup read the data speed table, the export tooltip never showed while
disabled, and the thumbnail parser and the signal search joined ad-hoc
threads on the render thread. Both now run off the pool; the search fans out
over it from its own thread.
Shared helpers in ui/util: the tool bar with its overflow menu, the menu
button, modal dialog setup, Escape inside dialogButtons, drawText,
drawElidedText, color markers, alignRight, clearableInput,
disabledItemTooltip, inputTextMultiline, tableHeadersRow with the right
click, withAlpha, boldFont, the Cocoa full screen glue, the messages panel
id. utils gets hexByte, guarded and nonEmptyDBCFiles; threadpool gets
parallelFor.
The help overlay leaves mainwin.cc for its own file, the stream teardown is
one releaseStream(), the charts own their views through unique_ptr, the
find-similar-bits message list follows the source bus, the clipboard copies
every open DBC, and the Qt vestiges (event names, model API, protected
sections, restating comments, stale TODOs, mixed member naming) are gone.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
* cabana ui: collapse the model/view/delegate split
The Qt-era model, view and delegate classes were ported one to one, but
imgui draws a table in one function. MessageView, MessageViewHeader and
MessageListModel's string API fold into MessagesWidget over a plain
MessageList; HistoryLogModel folds into LogsWidget; BinaryViewModel and
BinaryItemDelegate fold into BinaryView; SignalItemDelegate folds into
SignalView, and SignalModel keeps only the item tree with three predicates
instead of the flags bitmask; FindSignalModel becomes SignalSearch. The
byte cell painter is a set of free functions shared by the two tables.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
* cabana ui: load the route behind the window
The route file listing is an HTTPS round trip to the comma API and took
the whole first second of startup before the window existed. The replay
branch of main() now hands run() a loader that a worker executes after
the first frame; the window maps in ~0.1 s instead of ~1 s. On a failed
load the app stays open in the No Stream state with the error box
instead of exiting before a window ever appeared.
* cabana ui: fix the live stream video controls layout
* cabana ui: only copy dbc to clipboard with a single file
* cabana ui: report route loading failures instead of hanging
* cabana: launch the imgui frontend by default, --legacy for Qt
---------
Co-authored-by: Trey Moen <trey@Treys-MacBook-Pro.local>
Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
E.118 specifies decimal digits, but many real SIMs carry hex characters
in EF_ICCID (e.g. China Mobile's 898600B5... range, some MVNO/IoT SIMs).
AT+QCCID returns them verbatim, and the strict isdigit() check blanked
the ICCID, leaving the modem daemon stuck in INITIALIZING forever and
cellular dead. ModemManager parses ICCID as hex for the same reason.
Verified on a comma four with a China Mobile SIM (EG916Q-GL): previously
stuck retrying 'identity read incomplete', now dials and passes traffic.
The destructor built its cleanup commands as "rm %s -rf", with the flags
after the operand. GNU rm permutes arguments so this works on device and
in CI, but BSD rm on macOS stops option parsing at the first operand and
treats "-rf" as a second filename:
$ mkdir -p /tmp/rmtest/sub && rm /tmp/rmtest -rf
rm: /tmp/rmtest: is a directory
rm: -rf: No such file or directory
exit=1
So nothing is removed, and each of the four calls prints two errors plus
"system command failed (256)" from check_system. Every run of a tool that
owns an OpenpilotPrefix (replay, cabana) leaks its params dir, its
comma_home and its /tmp/msgq_ dir; 33 of each had accumulated on my
machine.
Pass the flags first.
* system: add chestnut offroad alerts
* system: refine chestnut offroad alerts
* system: refine chestnut power alerts
* system: confirm chestnut power recovery from PCIe
* system: detect missing chestnut power from INA voltage
* uh, i did not commit anything all this time
* slideee to the left, cha cha
* lint lint
* ui: unify model source predicate and per-source bundle lookup in model_info
* [TIZI/TICI] ui: disable the other-model row onroad like the active row
* [TIZI/TICI] ui: drop docstring that restates the function name
* [TIZI/TICI] ui: keep Favorites as the first model folder in the picker
* ui: record why model names read the params slots and not modelManagerSP
* ui: show the default model's name on the picker Default entries
* models: bind a download to its ref so cancel and reselect work everywhere
* models: resume partial chunked downloads and verify silently
* models: publish a verifying status so cached checks read as verification, not a stuck download
* [TIZI/TICI] ui: move download status onto each model's own row
* [TIZI/TICI] ui: show the row status description while it has text
* [TIZI/TICI] ui: restore the Model Status bar row
* models: a cancel interrupts verification immediately and keeps on-disk chunks
* models: a selection made mid-download queues instead of cancelling the transfer
* [TIZI/TICI] ui: Model Status shows both slots idle and the queued pick while busy
* [TIZI/TICI] ui: label the Model Status slots small and big and scroll long names
* models: start a queued download in the same tick and label empty slots (Default)
* ui: scroll Model Status names at the corrected speed
* [TIZI/TICI] ui: Model Status shows the big model failing over to small
* [TIZI/TICI] ui: stable model rows and a runner-matched failover note on Model Status
* [TIZI/TICI] ui: model rows show full names and the failover note reopens with the page
* ui: name the actually driving model runner-matched and bring mici to state parity
* fix ugly
---------
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
Co-authored-by: James Vecellio-Grant <159560811+Discountchubbs@users.noreply.github.com>
* models: dual-slot backend (qcom/usbgpu) with ref-based downloads
* models: restore get_active_source and the usbgpu-to-qcom fallback
* models: fix per-slot validation and cap mismatched-source refetches
* ui/models: select models by ref and seed the usbgpu slot on migration
* models: drop defensive attribute guards on capnp bundles
* models: remove vestigial fetcher state and dead fallbacks
* models: resolve the active bundle from the active source slot only
* models: pass the usbgpu kwarg through the modeld test stubs
* models: resolve the displayed model from the active slot in ui_state
* models: correct the validation memo type hint
* models: drop docstrings that restate the function name
---------
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
* modeld_v2: spatial features
* Update fetcher.py
* dont reshape non 4 dim arrays
* realize for non compiled
* Update compile_modeld.py
* god dammit it was realize()
* it was fucking frozen tinygrad. just need to recompile
* bump
* ci: add is_big flag to metadata.json to support backward compat
* Update model_generator.py
* Update sunnypilot-build-model.yaml
* Update helpers.py
* Revert "Update helpers.py"
This reverts commit 3a955ca11a.
* Reapply "Update helpers.py"
This reverts commit ca9c6e1933.
* models: use less strict chestnut detection state
---------
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
* ci: parallelize model chunk downloads and better publish
* ci: download all model chunks in parallel with xargs -P8
* split split
* ew
* must require
* ci: fix DM model build, separate HF defaults paths, nuke build races
* more split!
* name
* ci: download driving and DM model chunks into chestnut prebuilt output
* ci: compile default big model with stock modeld
* Revert "Revert big RL model (#38627)"
This reverts commit 516ec1e682.
* ci: compile default small model with stock modeld compiler
* ci: offload small model compilation
* Reapply "Revert big RL model (#38627)"
This reverts commit d06cfabb62.
* Reapply "Revert big RL model (#38627)"
This reverts commit d06cfabb62.
* ci: compile default big model with stock modeld
* Revert "Revert big RL model (#38627)"
This reverts commit 516ec1e682.
* ci: compile default small model with stock modeld compiler
* Reapply "Revert big RL model (#38627)"
This reverts commit d06cfabb62.
* Fix UI path color and thickness based on lateral steering state (Issue #1441)
* Fix UI path color and thickness based on lateral control engagement (Issue #1441)
* Fix UI path width and color based on MADS lateral engagement (Issue #1441)
* Fix UI path width and color based on MADS lateral engagement (Issue #1441)
* move to ModelRendererSP
* match torque bar
* same behavior across the board
* simplify
---------
Co-authored-by: Brennan Browne <brennanbrowne@google.com>
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
* Revert "ui: fix text and icon overlap on button (#38628)"
This reverts commit d9c4120f89.
* simple
* can do this
* fix eliding
* Revert "fix eliding"
This reverts commit b271a350182ad87f9942d7363383ee8ec72d0e36.
* clean up
* clean up
* Name the big default model in the device UI
Build on the default big-model metadata from #1929 and resolve the displayed model from cached capability and modeld runtime state. Keep model selection behavior unchanged.
Assisted-by: GitHub Copilot
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Remove get_default_model_label
* simplify
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: nayan <nayan8teen@gmail.com>
* device
* sunnylink
* lint
* lfs?
* Revert "lfs?"
This reverts commit bcdaec6b4c.
* update path
* Scope the default big model down to the sunnylink schema
* Drop the mock-only default model test
* Move the default model resolver out to separate PR
---------
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
* ci: Dedicated Model Runner
* recurse
* not needed
* fix wrapper
* whoops
* bypass
* modeld_v2: restore chestnut link check before big model build
* modeld_v2: stage onnx to disk instead of shared memory
* ci: clear unchunked onnx temps before model build
* ci: stream the pkl hash instead of loading it into memory
---------
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
* ci: fix prebuilt file copy for null-separated release_files.py output
* ci: drop prebuilt symlinks the launch script recreates and gate the release on no submodules
* ci: use the device-local scons cache and prune dead prebuilt config
* ci: keep the scons cache in the runner workspace instead of the device's
* modeld_v2: Support eGpu
* bump tg
* egpu
* no pkls please
* god no onnx either
* fix test
* done in build model now
* lint
* rip
* egpu ready build all split
* manual seed , reuse memory buffers across runs
* dont download big when we dont have big lol
* whoops
* no i and x
* cd
* who put those there. ??
* reduce flakiness by using artifact-name from build-model to regex, speed up pub b y checking the name before trying to clone and publish again
* try hf as a trusted publisher :)
* mf its a dataaset. i knew that
* fucking validation wants raw to fetch and full to push. grr
* smh
* dude i am missing so much
* pkl name
* move build all to hf
* tests: migrate sunnypilot tests to unittest and remove pytest
* red diff mf
* im scared , this may be a bad idea lol
* fetch latest commit.
* transition to requests
* models: use requests instead of aiohttp
* tici
* fix
* gpu fixes from upstream
* lint
* bump
* needed to say
* old
* how??
* epgu flag reduce
* this made me cry
* support monolith still
* precache warp in legacy
* Move jsons to param for sunnylink
---------
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
* relc
* so picky
* clean up
* switch to distance based
* same calls
* all you brother i'm just here to red diff
---------
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
* ui: fix inverted DM head tracking on RHD
b29d0a17af switched the mici driver state renderer from computing pose
from driverStateV2 itself to consuming driverMonitoringState.visionPolicyState.pose.
That published yaw is mirrored for RHD (policy.py:269) so the asymmetric yaw
offsets/thresholds can be tuned in a single frame, so the UI's unconditional
sign flip left RHD head tracking backwards. LHD was unaffected, which is why
the refactor looked like a no-op.
Undo the mirror on the UI side.
* Apply suggestions from code review
* fold the sign into the RHD multiplier
* dmvision c703670b-6a4a-4743-8f79-69d5486cadf7 (a62f9948 with new sleep head)
* dmvision c703670b-6a4a-4743-8f79-69d5486cadf7 (a62f9948 with new sleep head and same batchnorms)
* init
* more init
* keep it alive
* fixes
* more fixes
* more fix
* new submodule for nn data
* bump submodule
* update path to submodule
* spacing???
* update submodule path
* update submodule path
* bump
* dump
* bump
* introduce params
* Add Neural Network Lateral Control toggle to developer panel
This introduces a new toggle for enabling Neural Network Lateral Control (NNLC), providing detailed descriptions of its functionality and compatibility. It includes UI integration, car compatibility checks, and feedback links for unsupported vehicles.
* decouple even more
* static
* codespell
* remove debug
* in structs
* fix import
* convert to capnp
* fixes
* debug
* only initialize if NNLC is enabled or allow to enable
* oops
* fix initialization
* only allow engage if nnlc is off
* fix toggle param
* fix tests
* lint
* fix more test
* capnp test
* try this out
* validate if it's not None
* make it 33 to match
* align
* share the same friction input calculation
* return stock values if not enabled
* unused
* split base and child
* space
* rename
* NeuralNetworkFeedForwardModel
* less
* just use file name
* try this
* more explicit
* rename
* move it
* child class for additional controllers
* rename
* time to split out custom lateral acceleration
* move around
* space
* fix
* TODO-SP
* TODO-SP
* update regardless, it's an extension now
* update name and expose toggle
* ui: sunnypilot Panel -> Steering Panel
* Update selfdrive/ui/sunnypilot/qt/offroad/settings/lateral_panel.h
* merge
* move to steering panel
* no need for this
* live params in a thread
* no live for now
* new structs
* more ui
* more flexible
* more ui
* no longer needed
* another ui
* cereal changes
* bump opendbc
* simplify checks
* all in one place
* just Enhanced Lat Accel only
* no submodule for this
* Enhanced Lateral Acceleration: fix bugs, restore NNLC, add UI/schema
Fix 4 bugs in latcontrol_torque_lat_accel.py: missing CI param, wrong
method name (torque_from_lateral_accel → torque_from_lateral_accel_in_torque_space),
self.enabled collision with NNLC, missing output torque recomputation.
Restore NNLC + ExtOverride inheritance chain with Enhanced slotted between
ExtBase and NNLC. Add mutual exclusion constraints, Python UI toggle,
sunnylink schema entries, and controller init/update tests.
* fix lint: remove unused default params list, add ty ignore, fix test fixture
* use the og name
* rename
* need gates
* TODOs
* wrong
* gate them all on init
---------
Co-authored-by: DevTekVE <devtekve@gmail.com>
* add h264 profile option and different profiles for comma3X and comma4
* update to high profile
* resize to be baseline 3.1
* fix
* gop 15 and clean
* revert gop 15
* fix white space
* simplify teleoprtc
* bump teleop
* Process eSIM notifications after profile operations
* Clarify sleep purpose after operation in execute_and_process_notifications
Added comment to clarify the purpose of the sleep.
* chestnut: production flasher with ROM bootloader recovery
* hardwared: flash chestnut firmware offroad
* comments
* single FW version
* hardwared: fix chestnut flasher path
* chestnut: update firmware to 1d368808
* hardwared: log the flasher output
* comment
* hardwared: flash in a thread
* match panda flashing style
* fix
* chestnut: defer signals and harden the flasher
* chestnut: detect bootloader mode and retry
* comments
* chestnut: name the config dir for its content
* chestnut: name the ROM bootloader consistently
* chestnut: clearer name for the device lookup
* chestnut: spell out the low level names
* chestnut: claim the interface, not the device
* [mici] ui: fix swipe-down in sunnylink and models panels
* update mici replay test
* [mici] ui: push model sub-views as separate widgets for correct back navigation
* modeld_v2: safe model validation
* fix string
* numpy
* dumb
* god use full attribute names please
* modeld_v2: refactor compile_modeld
* redundant
* CREAM AND SUGAR
* gpu stuffs
* Update fetcher.py
* Update compile_modeld.py
* Update compile_modeld.py
* Update compile_modeld.py
* Update compile_modeld.py
* summary
* Update compile_modeld.py
* Update compile_modeld.py
* Update compile_modeld.py
* i could lie say
* needed
* i could
* Update compile_modeld.py
* done done done
* bye metadata
* simplify
* deeeeep
* oopsie
* i don't know what i'm doing
* it's a supercombo
* wtf. ghostwriter
* i might be blind
* fuck. i AM blind. or dumb. or both.
* hmmmm
* read/open - what's the difference
* realize. that i don't know shit
* whatever
* fix paths
* fuckit. dynamic everything.
* simplify everything.
* fix macos cabana
* np.random.seed is deprecated, use Generator or default rng instead @nayan
* this is annoying me
* too much fluff
* no
* lint be crazy now, man i've been away a while
* back
* fix pkl loader test
* that comment was wrong, its still per model, just compiled at with the input/output shapes
* fix chunking
* dump and assign to cpu
* prev_feat in cpu to prevent corruption
* add todo-sp
* desire me?
* allow legacy
* lint
* shapey
* bye
---------
Co-authored-by: discountchubbs <alexgrant990@gmail.com>
Co-authored-by: James Vecellio-Grant <159560811+Discountchubbs@users.noreply.github.com>
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
* exp mode confirm dialog
* full
* base
* clean up
* too diff
* fix?
* rmnl
* only toggle if exp mode is confirmed
---------
Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
* Tesla: MADS Screen Button Settings
Adds a Tesla vehicle setting (vehicle bus required) to control how many
fingers activate the MADS screen button, or disable it entirely.
Rebased onto current master:
- Migrated the setting metadata from the deprecated params_metadata.json
(removed in #1862) to the yaml SDUI system: added TeslaMadsScreenButton
to settings_ui_src/pages/vehicle.yaml and recompiled settings_ui.json.
Vehicle-bus gating uses the tesla_has_vehicle_bus capability visibility.
- Bumped opendbc_repo to the latest head of sunnypilot/opendbc#459.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JiSH2KAAueUmDe29xvpuAd
* bump
* Tesla: address MADS Screen Activation review feedback
Default TeslaMadsScreenButton to Off for fresh installs and add a param
migration that seeds existing Tesla installs with 3-Finger, preserving the
previous always-on behaviour. Brand resolves from CarPlatformBundle, falling
back to CarParamsPersistent so auto-fingerprinted Teslas are covered too.
Rename the setting to "MADS Screen Activation", hyphenate the finger-count
labels, and reword the description to use <br> (descriptions render as HTML)
with a note that a higher finger count may reduce accidental activations.
Applied both on-device and in sunnylink.
Also fix test_tesla_with_vehicle_bus_uses_param, which broke once
get_mads_limited_brands started reading TeslaMadsScreenButton from the same
blanket params mock, and add coverage for the screen-button-Off path.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01X5icDp7zZ49gpyC2mpCfF1
* bump opendbc
---------
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
Two macOS-only cabana fixes:
- signalview.h: rename the SignalView::setModel parameter that shadowed
the `model` member. Newer clang (Apple clang 21) folds
"parameter shadows a field" into plain -Wshadow, so with -Werror this
breaks the macOS build. Older clang (CI's image) only flags it under
-Wshadow-all, which is why CI stays green. The rename is clean under
any -Wshadow level and gcc.
- devicestream.cc: the --zmq bridge path had a stale `openpilot/`
segment (`../../openpilot/cereal/messaging/bridge`), a monorepo-layout
leftover that resolved to a non-existent triple-`openpilot` path, so
the bridge failed to exec and live streaming was broken. Drop it to
`../../cereal/messaging/bridge`.
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
* add support for multi-track with wideRoad single track as default
* remove stale debug mode
* multi track support
* make cameras list optional
* remove multi camera support from athena, make it only local
* update to teleop master
* replace PIL in emoji
* replace PIL in test
* fix uv.lock
* fix uv lock
* revert emoji removal from this P R
* revert merge artifact
* remove more merge artifacts
* fix lock
* red diff
* red diff +
* try cffi params
* ctypes
* lil more
* rm cython
* lil more
* that was fine
* lil more
* Drop unrelated Params concurrency changes
* Clean up ctypes Params build integration
* just c
* Clarify Params exception translation
* Expand Params C wrappers
* lil more
* power draw first
* speedup encoder
* speed up hardware test suites
* refresh IRQ actions after hardware setup
* skip unused big model in device checkout
* move LFS pruning off device checkout path
* wtf is that for?
* reverts
* locality
* rm that
* ci: test op setup with empty submodules
* ci: init submodules via op setup instead of checkout
* ci: keep submodules for build release
* ci: drop explicit submodules: false
* ci: remove checkout comment
* ci: update GitHub Actions to latest versions
Bump all workflow actions to their latest releases, including major
updates for checkout (v7), upload-artifact (v7), github-script (v9),
action-download-artifact (v21), and thollander comment action (v3).
* ci: pin third-party actions to commit SHAs
Keep official GitHub actions on version tags, but pin community
actions to immutable commit hashes for supply-chain safety.
* Reapply "usbgpu: never materialize model weights in RAM" (#38271)
This reverts commit 8196b743af.
* release oob buffers as we load them
* don't leak fds
* lint
* bigger big
* don't roundtrip the features to qcom
* Revert "don't roundtrip the features to qcom"
This reverts commit 0d2ca73d7a71bd32c46beda425957339f1dbbcf8.
* tmp bump allowed lag
* faster
* Revert "tmp bump allowed lag"
This reverts commit b407702a0242074eb12abdff14e61789fc05109a.
* Reapply "usbgpu: never materialize model weights in RAM" (#38271)
This reverts commit 8196b743af.
* release oob buffers as we load them
* don't leak fds
* lint
* 10s faster loading time for big model
* bigger big
* don't load big model in ram
* patch tg to allow out of band buffers
* dump/load oob
* roundtrip pkl to disk
* streaming chunking
* to_disk
* fixup
* linter
* Revert "bigger big"
This reverts commit 7a8147dd7fab88db963d512ab4008de940714025.
* athenad and webrtcd updates
* remove feature stream services from webrtcd split
* stream encoder thread
* reduce diff
* wire webrtc to livestream camera encoder
* request livestream camera switch service
* remove camera list in favour of init camera field
* remove cors
* clean
* remove unused
* remove extra try except
* add back exception trace
* add stream road camera info to stream cameras
* fix
* clean diff
* clean diff
* add testJoystick only on body
* fix camera list
* remove reference to future service
* encode all cameras and swap in video track in webrtc
* clean
* explicitly gate bridge send
* clean leftover
* initial idea
* add a watchdog to kill the process after disconnect or onroad
* start camerad and stream encoderd as well
* add message handler even without bridge
* remove carState when offroad
* transition to onroad works for body, kill for car not working
* turn off stream processes on started car
* cereal messaging sub field allow list, carparamspersistent, ping webrtcd to see when awake
* fix imports
* fix and increase max retries
* reduce max retries, increase timeout
* timeout on wait for connection
* remove cereal sub message and update process config to run on body ignition
* debounce 5s on teardown
* update error messages
* fix tear down crash
* clean
* clean
* fix lint
* split out and refactor
* simplify
* rm extra line
* use threadpoolexecutor to handle exceptions
* simplify
* improve
---------
Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
* ui: ensure zoom accommodates full view area in AugmentedRoadView
* fix: use _content_rect
---------
Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
* add param that requests keyframe
* set keyframe request to false on cleanup
* timing and errors
* video_enabled option and ability to add video later
* remove loggerd changes from this PR
* video enabled default to on, clean identifier
* request keyframe on start regardless of video enabled or not
* move error handling additions to different PR
* add param that requests keyframe
* set keyframe request to false on cleanup
* clean
* timing and errors
* remove other changes
* clean diff
* clean diff
* clean up live adaptation params and functions
* better function names
* fix syntax
* remove unused var
* clean diff
* improve lat maneuver report
* rm torque jerk
* add jitter maneuver
* add to 30mph
* add jerk
* color
* more state
* override
* abort reason
* abort
* rm text
* pad for small text
- patch `aioice` to only get host address of active network interface (wlan0 when on wifi, ppp0 when not)
- use common webrtc session between `startStream` and `addIceCandidates`
- first time connection speed ups
- move imports to top of file to move delay to webrtcd server start up not first connection
- warm up webrtc stack by creating a webrtc connection object to import all submodule classes
op.sh: don't eval CMD, run argv directly so special chars work
Previously op_run_command joined "$@" into a single string and eval'd
it, which broke on inputs containing shell metacharacters. For example,
'op esim --download "LPA:1$[rsp.truphone.com]($url)$QRF-SPEEDTEST" name'
would fail with a syntax error on the unquoted parens. Run "$@" instead
and only use $* for the printed display string. Also quote the unquoted
$@ in the other op_run_command callers.
* Return Honda exception removed in commaai#37857
Added handling for brakePressed state with conditions for Honda models.
* Add CAR back to imports
* match
---------
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
* modeld_v2: safe model validation
* fix string
* numpy
* dumb
* god use full attribute names please
---------
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
* modeld: RL driving model with 3-file split
Split the driving model into vision + off_policy + on_policy ONNX
files and wire up the RL policy:
- 3-file model split (vision / off_policy / on_policy), replacing the
combined big_driving_policy/vision models
- compiler updates for the split models
- actually consume the policy action in modeld
- add desire state to the driving model
- model iterations (smoothness, off/on-policy weight updates)
* modeld: update driving model
* 1e72cf5a-785f-45ea-888f-28cdb14785de/100
* tinygrad hack
* fix parsing
* looser timing
* big
* Remove unnecessary modeld rebase changes
* Tighten modeld split cleanup
---------
Co-authored-by: Comma Device <device@comma.ai>
Co-authored-by: Armandpl <adpl33@gmail.com>
* bitrate controller
* ability to set the quality so a certain level, make message handler a switch case
* distinct bitrate levels and exponential backoff of raising bitrate
* add med level threshold
* fix
* fix
* simplify
* clean
* remove CarState.brake refs
Intending to deprecate this field since it's set incorrectly by
most car implementations, and (essentially) unused in openpilot.
Everything should be using CarState.brakePressed.
See https://github.com/commaai/opendbc/pull/3338.
* fix test_models.py
* hardware: read network info without NetworkManager DBus
* hardware: simplify wpa_cli SSID escape decoding
* hardware: restore cellular block in get_network_type to match master
* hardware: factor wpa_cli helper for key=value parsing
* hardware: comment SSID byte conversion for keyfile match
* hardware: comment NM metered enum values
* hardware: use check_output for ip route and wpa_cli helpers
* hardware: read default route iface from /proc/net/route
* hardware: simplify default route iface parsing
* hardware: only check for metered == 1
* hardware: also look for *.nmconnection in /data/etc/NetworkManager/system-connections
* hardware: use nmcli for runtime metered guess on wifi
* socket
* cleanup
* poor
* lil more
* mv that
---------
Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
* initial codex
* remove ISP delay from encode ms
* try something simpler
* not allowing increase bug
* decrease bitrate increase rate
* upsample only on consecutive good checks
* rearrange
* clean
* Revert frame timing processing time change
* clean
* remove bitrate option and just do it on --stream
* make set_bitrate a lot more simple
* clean default impl
* further cleaning
* struct for bitrate to pass ci
* refactor a bit
* add comment
* small clean
* add init()
* increase bitrate
* update ffmpeg message
* remove unnecessary include
* modify set_bitrate
* change to Param
* remove getInt helper; add back in diff pr
* reword unclear error message
* move webrtcd change to new branch
* Reapply "modeld: split warp" (#38085)
This reverts commit d489dd8909.
* don't time make_random_inputs
* depend on chunk targets
* also depend on compile_modeld's dependencies
* athenad and webrtcd updates
* remove feature stream services from webrtcd split
* stream encoder thread
* reduce diff
* wire webrtc to livestream camera encoder
* request livestream camera switch service
* add frame timing headers
* rfctr
* diff
* clean
* remove camera list in favour of init camera field
* remove cors
* clean
* remove unused
* remove extra try except
* remove video_tracks unused
* add back exception trace
* add stream road camera info to stream cameras
* fix
* add back assert
* clean diff
* clean diff
* add testJoystick only on body
* fix camera list
* remove reference to future service
* video_tracks list add back
* encode all cameras and swap in video track in webrtc
* clean
* explicitly gate bridge send
* clean leftover
* rearrange video.py
* fix lint
* athenad and webrtcd updates
* remove feature stream services from webrtcd split
* stream encoder thread
* reduce diff
* wire webrtc to livestream camera encoder
* request livestream camera switch service
* remove camera list in favour of init camera field
* remove cors
* clean
* remove unused
* remove extra try except
* add back exception trace
* add stream road camera info to stream cameras
* fix
* clean diff
* clean diff
* add testJoystick only on body
* fix camera list
* remove reference to future service
* encode all cameras and swap in video track in webrtc
* clean
* explicitly gate bridge send
* clean leftover
* make local bodyteleop work still
* athenad and webrtcd updates
* remove feature stream services from webrtcd split
* remove cors
* clean
* remove unused
* remove extra try except
* add back exception trace
* clean diff
* clean diff
* add testJoystick only on body
* fix camera list
* remove reference to future service
* zero ll patched big model
* probe in a subprocess so usbgpu lock gets released
* compiles
* runs
* num_jobs gets overwritten, use side effect
* poll tg devices
* make sure build crashes on missing gpu
* fine not to rely on Device.default
* seperate tg env for each model runner
* comment
* Revert "seperate tg env for each model runner"
This reverts commit f6470cc4258eaeb3e8e37907ef370871c9af5aa4.
* env is shared, gate on flag
* no fallback warp dev must be set
* build for current device only, unless pc/release
* comment
* list
* listen for plug in
* add icon to status bar, read params on every frame (?)
* log available devices
* try copy out when loading?
* Revert "log available devices"
This reverts commit e8c52a5d59456d4820ecb13b99a6c46ea1386a20.
* Revert "try copy out when loading?"
This reverts commit 518f403aa03faeda1950fe3dbce0d9e4c1584455.
* don't trigger device probe/caching on modeld prepare
* re-export with ll and road edges
* dont cache devices in manager process
* get USBGPU from params
* no usbgpu env
* missed one
* sconscript don't poll
* unconditional env
* always explicitely set devices on input tensors
* set DEV so amd uses right compiler and iface??
* fix flag
* bump tg
* rm xdg_cache_home
* tg don't bump all the way
* missing gmmu=0 at compile time
* dm set dev
* tg backend
* update gitignore
* missing import
* unused imports
* rely on Device.DEFAULT at compile time (already the case bc onnxrunner)
* comments
* dm warp needs DEV set too
* build both smol and big
* misc typos
* set dev at compile time
* don't need
* DEV=CPU when getting metadata, ensure we don't grab gpu lock
* this would also grab lock
* put bool
* warp compile always prepare only
* missed one
* poll ui
* missing here
* don't force usbgpu at build time
* tmp patch fetch_fw
* catch all, follow hardwared patterns
* simpler
* compile make input queues
* revert this
* group this more readable
* rm empty line
* make dummy frame using numpy
* revert compile make input queues
* no compiler at runtime
* cleanup
* fine to rebuild all on change to device node for now
* fix usbgpu_present
* fix sconscript
* no size in header stream decompress
* DEBUG=2
* minimal viable feedback
* egpu gray
* oops
* gotta do this actually
* modeld build only depends on modeld devices
* don't ship onnx to release? or chunk
* don't need
* can only set compiler on dev=
* none device works, will use default
* make linter happy
* chunk agnostic onnx input to compile_modeld
* chunk big onnx
* +x chunker
* fix #!
* and don't ship chunked onnx to release
* firmware now in correct location
* better err on missing onnx/chunk
* SConscript also need to accept chunked onnx
* metadata also need to load maybe chunked
* dedupe cmd
* this needs to be on cpu
* devices are set in the tgflags, we already depend on them
* rebuilding on changed order is fine
* read file chunked can already load either chunked or not
* chunk all big onnx
* less confusing
* unused import
* python device to load onnx bytes
* default device for runners, python for metadata
* why not
* chunked to shm
process_replay/migration: drop transitive dep on long_mpc/acados
migrate_longitudinalPlan only needs get_accel_from_plan + CONTROL_N_T_IDX,
both available from drive_helpers + ModelConstants directly. Importing
from longitudinal_planner instead pulled in long_mpc -> libacados.so as
an eager side-effect, which downstream log-migration consumers (e.g.
commaai/xx pipeline) shouldn't pay for.
Brand-specific capabilities (hyundai_alpha_long_available,
subaru_has_sng) only resolved from CarPlatformBundle, which requires
manual car selection. Auto-fingerprinted vehicles had no bundle,
leaving these capabilities at default false — hiding vehicle settings
on the dashboard despite working on the device UI.
Add _resolve_brand_capabilities() with bundle-first, CP-fallback
pattern matching the device UI layouts (hyundai.py, subaru.py).
Fixes https://community.sunnypilot.ai/t/5126
* serverless code sync
* rm stuff
* we have ls-files for this
* rm
* no debounce
fix
* fix
* no del
* no init
* clean up
* clean up
* smol
* fixup
* rm
* clean up
* any change
* rm arg
* rm
* rm
* speedup slowest
* less setup
* rm som reset logging
* simpliy a lil more
* lil more
* down to 36s
* sleeeeeeep
* finishing touches
* oopsie
* ty fix
---------
Co-authored-by: Comma Device <device@comma.ai>
* filter lead prob
* rename
* try correcting model bias
* Revert "try correcting model bias"
This reverts commit b5e9b7147e58f200ca2e02ccea8adf88be99e206.
* fast gain slow lose
* cmt
* deb
* rename
* rename
* end
* py py py
* sunnylink too
* refactor
* this is not needed anymore
* mici mici
* ugh
* retry CI
* ui: refactor default model name handling
Move DEFAULT_MODEL constant into sunnypilot/models/default_model.py
and remove the one-liner common/model.py. Strip the hardcoded
" (Default)" suffix from the constant value so each UI site appends
it contextually, keeping the raw model name clean for the schema
payload to sunnylink.
Replace the DefaultModel param approach with schema["default_model"]
injected at schema assembly time, eliminating a redundant param write
on every sunnylinkd start. Remove DefaultModel from params_keys.h and
params_metadata.json.
Update update_default_model_name() to do a targeted regex replacement
instead of overwriting the whole file, since the constant now lives in
a module with other code.
---------
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
* ci: simplify cereal validation to sparse-checkout + pycapnp, drop scons build
Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
* more
* fix: resolve cereal_dir to absolute path before passing to capnp.load
Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
* ci: init opendbc submodule after sparse checkout to resolve car.capnp symlink
Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
* try to break it
* Revert "try to break it"
This reverts commit 79ce135c5f.
* try to break it
* Revert "try to break it"
This reverts commit 1eaa9e79e6.
---------
Co-authored-by: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
ui: nonblocking writes for ExperimentalMode + DriverView toggles + cycle-restart
All four put calls fire from the main render thread on user interaction
and block on disk fsync, causing visible UI frame spikes.
Each consumer is safe under nonblocking:
- onboarding inactivity_callback: write-and-forget (~25 ms saved)
- home long-press exp toggle: ui_state.experimental_mode owns visual state (~10 ms)
- onroad exp_button: $held_mode + selfdriveState owns visual state
- restart_needed_callback (OnroadCycleRequested): cross-process signal,
consumer is selfdrived which polls the param
BigParamControl-driven toggles in settings (developer.py, toggles.py)
are intentionally left blocking — those widgets refresh visual state
from disk every frame to mirror external changes, which would race a
nonblocking write.
* snap logic in scroll panel
* match previous snap speed
* velocity lookahead makes scrolling on main layout super easy
* turn off
* remove velocity lookahead
* cmts
* remove handle out of bounds
* cmts
* old style
* back
* clean up
* re-use
* revert
* finish snap when settings is clicked while moving
* rm cmt
* log raylib fps
* log fps from frame time
* whitespace
* or just log frame time?
* init pubmaster in init window
* yield timings
* bump ordinal
* dont log on screen off
* UInt
* lint
* /0
* oops
* oops2
* more precise raylib frame time, can get fps with 1/ft
* don't crash on screen off
* NL
* no _
---------
Co-authored-by: Shane Smiskol <shane@smiskol.com>
* 1
* fix
* uh
* more
* for now
* v2
* update
* more subs
* readme
* vehicle
* cycle init
* options
* new
* combine
* new
* dynamic unit
* default
* move it
* syncing more
* more
* boom shakalaka
* rearrange
* partial availability
* move
* more
* more
* hide
* move
* revert
* more
* new
* set
* sync
* dynamic
* slightly more
* update
* update
* less
* in another pr
* more
* move and fix
* device type
* order
* order
* order
* fixes
* ew
* Revert "fixes"
This reverts commit 53a2adb45a.
* sunnylink: bundle-first capabilities + protocol_version
Bundle-first brand resolution, fix steer_control_type to use
CP.steerControlType (physical) not lateralTuning.which() (tuning class),
add Subaru/Hyundai opaque per-platform flags from CarPlatformBundle, and
embed PROTOCOL_VERSION in the capabilities payload.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* sunnylink: tighten settings_ui gates against Raylib parity
Brand gates on MadsMainCruiseAllowed/MadsUnifiedEngagementMode (rivian +
tesla-no-bus); convert enablement->visibility on items Raylib hides
(DisableUpdates, EnableGithubRunner, EnableCopyparty, QuickBootToggle,
HyundaiLongitudinalTuning, LaneTurnValue, LagdToggleDelay); drop spurious
offroad_only on DynamicExperimentalControl + DisengageOnAccelerator and
SpeedLimit policy/offset over-gates; replace offroad_only with not_engaged
on AlphaLongitudinalEnabled/Toyota long toggles; extend release-branch
NOTs with is_sp_release; add Test Maneuvers section with attestation,
move LongitudinalManeuverMode in alongside new LateralManeuverMode.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* sunnylink: extend settings_ui validator for new fields
Add SchemaItem fields title_param_suffix (object form), needs_onroad_cycle,
blocked, requires_attestation; add option-level enablement to SchemaOption;
add visibility/enablement/attestation_required to PanelSection; add
not_engaged Rule type; replace vehicle_settings inline shape with
VehicleBrandSettings def (title/description/items).
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* sunnylink: inject torque tune options from versions JSON
Read latcontrol_torque_versions.json at schema generation time and
override TorqueControlTune options so adding a version to the JSON
flows to the dashboard without editing settings_ui.json by hand.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* sunnylink: per-bug regression tests for settings_ui parity
Cover the audit findings end-to-end: MADS brand gates, Test Maneuvers
section + attestation, validator accepts the JSON, dynamic torque
options match the versions JSON, SP dev items gate on is_sp_release as
well as is_release, spurious offroad_only dropped from
DisengageOnAccelerator and DynamicExperimentalControl, and offroad_only
replaced with not_engaged on AlphaLongitudinalEnabled and the Toyota
long toggles. Validator test skips when jsonschema is unavailable.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* sunnylink: protocol_version sentinel + opaque-flag tests
Pin PROTOCOL_VERSION to KNOWN_PROTOCOL_VERSIONS so a bump shows up in
review, and assert subaru_has_sng / hyundai_alpha_long_available are
declared with safe False defaults.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* schema: convert ShowAdvancedControls visibility to enablement
Items previously hidden when ShowAdvancedControls is off now render
as disabled with an ADVANCED tooltip. Same treatment for dependency-
based hides (LagdToggleDelay, LaneTurnValue) so users see what's
available and why it's locked. CameraOffset gets the Advanced gate it
was missing.
Affected: DisableUpdates, EnableGithubRunner, EnableCopyparty,
QuickBootToggle, LaneTurnValue, LagdToggleDelay, CameraOffset, and the
test_maneuvers section.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* sunnylink: route resume_queued to athena direct
Backend is retiring the CloudFront proxy on stg.api.sunnypilot.ai that
currently forwards ws|settings|navigation to athena.sunnylink.ai. Once
retired, /ws/{id}/resume_queued only resolves via athena.sunnylink.ai.
SunnylinkApi.resume_queued now temporarily swaps self.api_host to
ATHENA_HOST while re-entering api_get (preserves the SunnylinkEnabled
gate and existing JWT/UA header handling). Other device calls
(device/{id}/roles, device/{id}/users, v2/pilotauth/, backups) continue
to hit the sunnylink main API host unchanged.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* legacy code
* no
* new
* tests
* lint
* fix
* too verbose
* sunnylink: per-page YAML authoring for settings_ui + named rule macros
Replace hand-edited 2200-line settings_ui.json with a per-page YAML source
tree under settings_ui_src/, plus named rule fragments (`$ref` macros) so
the same condition isn't repeated verbatim across items.
Authoring surface (settings_ui_src/):
pages/<page>.yaml one file per panel; sections/items/sub_panels inline
pages/vehicle.yaml per-brand settings (kind: vehicle -> vehicle_settings)
_macros.yaml named rule fragments referenced via {$ref: "#/macros/<name>"}
_schemas/*.json JSON Schemas for IDE autocomplete + CI validation
Pages today: steering, cruise, display, visuals, toggles, device, software,
developer, models, vehicle (10).
Tools:
compile_settings_ui.py read src tree, resolve $refs, emit settings_ui.json
(--check mode for CI to fail on hand-edits)
extract_settings_ui.py one-shot: settings_ui.json -> per-page YAML
apply_macros.py one-shot: substitute matching rule blocks with $ref
Rule-block dedup wins (top duplicates collapsed to single macros):
offroad (9x), longitudinal (4x), longitudinal_and_icbm (5x),
hide_on_mici (4x), advanced_only (3x), mads_full_platforms (4x ~30-line
nested any/all/not -> 1 macro + 4x one-line $ref).
Validator drift fixes:
- Accept not_engaged rule type (already in schema.json + used by
AlphaLongitudinalEnabled, ToyotaEnforceStockLongitudinal,
ToyotaStopAndGoHack, LateralManeuverMode, LongitudinalManeuverMode).
- Enforce {title, description, items} shape on every vehicle brand
instead of allowing bare-list variants.
Wire format unchanged: compiled settings_ui.json structurally identical to
the prior hand-edited file, so the device generator (generate_settings_schema.py),
SettingsCapabilities, and frontend renderer all keep working without changes.
Tests: 16 new compiler tests (roundtrip, $ref semantics, depth/cycle limits,
page-tree integrity, vehicle kind routing). Existing 42 regression tests in
test_settings_changes.py and test_settings_schema.py remain green.
README rewritten for the new flow:
- Decision table for offroad_only / not_engaged / param / capability
- Multi-condition composition examples (AND/OR/mixed/3-way/negation)
- Full feature walkthrough (multi-toggle + sub_panel + new macro)
- Workflows for changing rules, widget type, deprecating an item
- All How-To examples migrated from JSON to YAML
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* sunnylink: add `details` field for popover/modal help text
Adds an optional `details` field on settings items, distinct from the inline
`description`. When present, the frontend renders an info ("i") button on the
row that opens a modal with this content. Either field may be present alone,
or both together; an item with only `details` and no `description` shows just
the title + info button (no inline body).
Migrates `AutoLaneChangeTimer` as the first user: the safety caveat
("Please use caution when using this feature. Only use the blinker when
traffic and road conditions permit.") moves out of the inline description
into `details`, leaving the description focused on what the timer actually
does.
Schema changes:
- settings_ui.schema.json: SchemaItem.details (string, optional)
- settings_ui_src/_schemas/page.schema.json: Item.details (mirror)
- compile_settings_ui.py / extract_settings_ui.py: ordered after description
Frontend support lands in sunnylink-frontend on the design-overhaul branch.
Old frontends ignore the unknown key.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* ui: refactor UIStateSP init to eliminate getattr and double update_params
- Remove update_params() and reset_onroad_sleep_timer() from UIStateSP.__init__;
__init__ is now pure attr initialization with no I/O or side effects
- Add _sp_initialized flag to UIStateSP.update_params() to fire
reset_onroad_sleep_timer() exactly once after first real param load,
keeping the call in SP territory and out of stock _initialize()
- Replace getattr(self, 'has_longitudinal_control') / getattr(self, 'CP')
in _enforce_constraints with direct attr access; safe because
_enforce_constraints is only called from update_params(), which only
runs after UIState._initialize() has set both attrs
- Rename _enforce_sp_constraints → _enforce_constraints
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
* fix
* exec
* more exec
* humanize
* sync
---------
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
modem.py: retry identity read until valid; stay in INIT on partial reads
Under rapid SIM hot-swap stress, AT identity reads (CGSN/QCCID/CIMI/GMR) can return
empty values or echo the command itself. Validate each field before accepting it,
retry the whole sequence in a loop, and stay in INITIALIZING (rather than progressing
to SEARCHING) until imei and iccid are populated. Prevents stale/empty identity from
being published to /dev/shm/modem after a glitchy reinit.
* ui: speed up `mici/AugmentedRoadView` by optimizing _calc_frame_matrix caching (#36669)
speed up AugmentedRoadView by optimizing _calc_frame_matrix caching
* ui: apply rect.x/y as a 2D screen offset post-projection
Removes the parent rect's screen position from the cached
video_transform passed to ModelRenderer. Instead, ModelRenderer
applies (rect.x, rect.y) as a 2D offset to projected_points at draw
time.
Why this works: the rect.x/y term in video_transform gets multiplied
by P_calib[2] before the perspective divide, then divided by the same
value, which cancels out to a simple additive shift on the final
screen coordinate. So adding x to video_transform[0,2] is equivalent
to adding x to screen_x post-projection.
Net effect: the cache key in _calc_frame_matrix no longer needs to
include rect.x/y. Cache stays hot under translation (e.g. swiping
between layouts), and the model overlay tracks the camera at 60Hz
because the offset is updated cheaply each frame.
This addresses the original revert reason for #36669 (model overlay
visually desyncs from camera during a home<->onroad swipe).
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* ui: update model screen offset every frame, not just on cache miss
set_screen_offset() was called inside the cache-miss path of
_calc_frame_matrix, so the offset only updated at ~20Hz (calib publish
rate). The model overlay visibly lagged the camera during a swipe.
Move it out of the cached path so it updates each frame.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* fully clean up
* shorter cmts
* make non
* clean up
* fix ty
---------
Co-authored-by: Dean Lee <deanlee3@gmail.com>
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* ui: keep arc_bar_pts cache hot when bar is translated
The LRU cache key included (cx, cy), which change every frame when
the parent widget's rect translates (e.g. during a scroll animation
in MainLayout). That made every cache lookup miss, recomputing the
arc geometry twice per frame and dropping fps.
Compute the shape at origin (so the cache key only depends on the
geometry: radius, thickness, angles), then translate to (cx, cy)
after. Cache stays hot under translation.
Measured on comma four (engaged, scrolling): ~5fps recovered while
moving between layouts.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* fully clean up
* fully clean up
---------
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* fix frame under text
* claude always taking the hard path
* cmt
* it still shows on start
* revert
* fix
* wait to show
* already a bug, don't fix here
* cmt
* cmt
remove ws_queue thread and associated api endpoint
- Simplified thread management by removing unused `ws_queue`.
- Eliminated `resume_queued` API call for better maintainability.
* update blob
* fixed
* didnt catch this
* add back
* needs BLC built in
* for real
* attempt2
* clean up override
* this should keep ox as was
* disable for OX
* update descs
---------
Co-authored-by: Comma Device <device@comma.ai>
* spellings
* unused
* no roll
* lil more
* lil more
* one more
* policy enum
* better trans
* set_timer -> set_policy
* set_timer -> set_policy
* no yaonet
* del redundant code
---------
Co-authored-by: ZwX1616 <zwx1616@gmail.com>
* c4 body ui
* clean up diff
* clean up
* default bodyview debug with True
* remove battery indicator and fix close settings bug
* organize debug file
* clean
* clean up frame index
* remove unneccessary is body check
* update bodyview
* remove joystick_debug_mode based events
* remove debug script
* apply suggestions
* clean diff
* clean diff
* move ignition message
* save a line
* remove visibility set and fix tici body face when sidebar open
* remove explicit textColor offroad message
* remove unused imports
* revert pairing dialog
* apply suggestions
* add body specific icon
* add body icon for homescreen
* set mode for state on tici after on body changed
* tiny
* tweak
* v
* tweaks
* icon ratio was wrong!
* same order
* rm
* apply suggestions
* remove commented lines in animation
* onroad click callback was on home bug and fix setup widget settings call back hack
* fix body changed
* one liner
* clean up
* formatting
* if false
* revert to master + reimplement
* close sidebar on body home tici
* make ignition message bigger on c3
* flip eye direction when turning
---------
Co-authored-by: Nick <nickorie@gmail.com>
Co-authored-by: Shane Smiskol <shane@smiskol.com>
* compile_modeld.py
* update estimates
* missing image=2?
* Revert "missing image=2?"
This reverts commit 2f5952eb63ba1e3f24cbf5769e6b5e9170d7f0a6.
* Revert "update estimates"
This reverts commit 1f72feef2ffdec6126e3c941e899b46ace7b4b65.
* Revert "compile_modeld.py"
This reverts commit f10541502efca02725f368deda2a21d1f786f57d.
* load warp in ModelState init
* dead code
* prep
* compile modeld
* update SConscript
* tmp save plot locally
* Revert "tmp save plot locally"
This reverts commit ec22f15161ad3b0241a097546b35860f989219f5.
* openpilot hacks?
* no float16
* tmp more chunks
* Revert "tmp more chunks"
This reverts commit 9e1d9b4d0dc36ff530d2a70b565fbfabd7afb00d.
* Revert "no float16"
This reverts commit 6204956e98e3c0818ed1985ede8eeccb810f63e3.
* realize boundaries
* Revert "realize boundaries"
This reverts commit ffaa19259eba70944e7793e8f51a0f87089531b3.
* prune=False?
* Reapply "tmp more chunks"
This reverts commit 2599c41cea93b4a6b4e946cdffc6a617663a7d23.
* tg bug?
* load first?
* Revert "load first?"
This reverts commit f643d082d76a424b23295e254179eb111e936e61.
* revert
* Reapply "tmp save plot locally"
This reverts commit 1b95b82ee58654bd908b1cb04ab0ddbcd1a5955d.
* 0 tol pc
* warp -> modeld
* rename
* bypass chunking?
* dont chunk
* Revert "dont chunk"
This reverts commit cc97fc67b3203456e123f02babe5c83b87c7e264.
* dont chunk
* debug
* Revert "debug"
This reverts commit b3c2f2e7a095fd32f8d8562a68fd1cca42357eac.
* Revert "dont chunk"
This reverts commit 42bd9b6f6ad0722c50348ba11ba7e2a64fdf997d.
* Revert "bypass chunking?"
This reverts commit ad5422a93483ffd8a59ba62e5fb72ced3b5d04d0.
* corrupt model outputs
* Revert "corrupt model outputs"
This reverts commit 245feb94480e02f83a20b65a9488652bcbfc88b0.
* image=0 for warp, match master
* dedupe enqueue
* pass traffic convention
* tg buffer for desire
* dedupe buffer creation
* compile_modeld: nuke stale cached pkl before compiling
The UNSAFE CI checkout keeps gitignored files (.pkl, .sconsign.dblite),
so stale pkl files from previous commits can persist and be reused
instead of being recompiled. Delete them explicitly before compiling.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* test vs compile
* all outputs need to be different on different inputs
* randomize numpy inputs
* randomize on every step
* SConscript: nuke stale pkl+chunks before compile_modeld
Move the stale artifact cleanup from compile_modeld.py into the
SConscript build command. This ensures stale gitignored pkl and chunk
files are deleted even if scons decides to skip the compile step
(due to a stale .sconsign.dblite from UNSAFE CI checkout).
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* compile_modeld: restore Context(IMAGE=0) for warp
The warp operations must run under IMAGE=0 to avoid QCOM image texture
optimizations that corrupt the output buffer after ~33 frames.
This was accidentally commented out in a855173.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* modeld: create SubMaster before model loading
Move PubMaster/SubMaster creation before the model loading step.
During model loading (3.5s+), process_replay may send liveCalibration.
If SubMaster doesn't exist yet, the message is dropped and the warp
transform stays as zeros, producing garbage warped images.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* Revert "modeld: create SubMaster before model loading"
This reverts commit 968c987c2fbb3fce141c4e345d10ddea559b6c50.
* stale metadata?
* claude debug
* Revert "claude debug"
This reverts commit 49e754c6affa45a8ea8834588a00227b8090b17a.
* Revert "stale metadata?"
This reverts commit 870388513c0d4a67dcf970cd277b6db56cb2b478.
* modeld: realize jit outputs before parsing
* Update modeld.py
* modeld: fix NameError by removing redundant MODELS_DIR definition
* test buffers in test vs. compile
* 2x inputs before running
* fixup 2x inputs test
* realize onnx weights?
* Revert "realize onnx weights?"
This reverts commit 49c8b9a505db38ff22f342db011a3a6b6526d398.
* move openpilot_hacks flag to sconscript
* stricter test vs compile
* correct timings
* more run more fail?
* Revert "more run more fail?"
This reverts commit 9e94bb63940751ec29e81b634c42449113e1f2e5.
* numpy shenanigans
* correct shapes
* dont assert timings for now
* Revert "correct shapes"
This reverts commit 5b9ff6c84c0022327d21801d179e9e51c39e8f78.
* Revert "numpy shenanigans"
This reverts commit b4f6fb3078d7e9b09698895b88728fd8eea8c8a8.
* no need to nuke
* comment unused
* don't use NPY device
* copy instead of from_blob
* to device before jit
* Revert "to device before jit"
This reverts commit 7a59ed9b1ac88657b5a3917986b6ff92e59a2ee3.
* Revert "copy instead of from_blob"
This reverts commit 196c4892a06ffba89ef631876372cecf137cc1b4.
* Revert "don't use NPY device"
This reverts commit 18abf43bbac46ad47a60c03dd8d1ef40b3f59227.
* 3 runs is enough
* no_memory_planner=1
* lint
* restore model_replay.py
* on policy -> policy
* unused
* prepare only enqueues full images
* warp with image=2?
* unused args
* test vs compile, check different inputs different outputs
* avoid uop cache collision
* dont need realize here
* misc
* input queues diverged
* strict zip
* monkey patch for now
* memory planner
* prev desire correct order
* dedupe pkl paths / compile targets
* don't change behavior, warp and enqueue frames when skipping model eval
* actually prepare only
* warm up warp jit
* correct path
* oops
* explicit warmup
* need continuous + can't have dupplicate jit inputs
* whitespace
* bufs -> input_queues
* master tg
* /N_RUNS
* bump tg, remove uop cache patch
* more readable
* Revert "bump tg, remove uop cache patch"
This reverts commit 499acca2591becd389de4025943f9e776a5b337c.
* missing dep
---------
Co-authored-by: Bruce Wayne <harald.the.engineer@gmail.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* always offroad ui
* remove
* lint
* better
* fix sync issues
* fix sync issues
* update for upstream sync
* move it all to top settings panel
* not red
* no home screen, just buttons
---------
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
* turn off ir leds on notCar
* reduce startup time on notCar
* fix: check notCar once after onroad is true
* save a disk read by using existing is_onroad
* [TIZI/TICI] ui: remove per-frame param sync
* fix: prevent params.put skip in OptionControlSP by deferring mutation to set_value
The idempotent guard added in the previous commit was being bypassed because
_handle_mouse_release mutated self.current_value before calling set_value(),
making the check always return early. Now we calculate the new value and pass
it to set_value, allowing the guard to work correctly and params to persist.
* fix: enable touch validation for visible items in TreeOptionDialog during scrolling
* rebuild scroller and call add_widget instead
---------
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
* model panel - give it some love
* fix sync issues
* update for upstream sync
* fix label
* not red
* fav models
* uhh, yeah
* handling for downloading state
---------
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
* NNLC: restore pre-v1 PID gains in torque extension
When the torque lateral controller was refactored for v1 (VERSION=1),
the NNLC extension's PID gains were inadvertently changed from the
per-vehicle defaults (kp=1.0, ki=0.3, kf=1.0) to the new base
controller values (kp=0.8, ki=0.15, no kf with speed interpolation).
The NNLC extension operates in torque space with its own PID loop
that is independent of the base controller's lateral acceleration PID.
Coupling these gains to the base controller's values results in
noticeably weaker steering response and ping-pong oscillation for
NNLC users, with no workaround since Enforce Torque Lateral Control
and NNLC are mutually exclusive.
This restores the original PID gains that were used before the v1
refactor, matching the behavior from v2025.003.000 and earlier.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* Remove k_f from PIDController init
k_f was removed from PIDController in the v1 refactor. The old
k_f=1.0 was a no-op (feedforward scale of 1.0), and the current
PIDController applies feedforward unscaled via update(), so
behavior is unchanged.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
* Revert "OP model 7 (#37760)"
This reverts commit 052692b25d.
* Revert "OP model (#37740)"
This reverts commit cb32793300.
* dead
* parse_model_outputs: drop extra space
The plural `git/refs/heads/{bucket}` endpoint does prefix matching
and returns a list when multiple refs share the prefix, which makes
`r.json()['object']` raise TypeError. Switch to the singular
`git/ref/heads/{bucket}` endpoint so we only match the exact bucket
and get a clean 404 otherwise.
* services: increase logMessage queue size
logMessage and errorLogMessage defaulted to SMALL (250KB) after
bcdeec3133, but logmessaged allows messages up to 2MB. The msgq
assert requires 3 messages to fit in the queue, so any log message
over ~83KB crashes logmessaged. This happens on dirty devices when
updated logs the full git diff output.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* use BIG queue size to fully cover 2MB cap
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* Update Python packages
* need this
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
* bump tg
* bump tg
* assign
* bump
* cpu llvm
* frame buffer updated in place, no need to return
* don't bake in stale pointers
* fix update image output indices
* lint
* bump
* replay: add dragging gesture support
* update dragging to support distance and duration; update mici script to go through settings
* refactor
* fix and add network
* add more
* interact device
* fix
* match statements
* more
* improve
* simplify script
* add keyboard test
* format
* simplify
* improve
* comment
* improve
* clarify
* clean
* simplify
* simplify
* move
* improve
* more delay
* simplify keyboard test
* simplify
* comment
* add onroad alert tests to mici
* scroll less
* test offroad alerts
* remove space
* scroll faster
* more toggle tests
* back to home
* test settings onroad
* fix pairing qr code
* add replay progress bar
* add replay progress bar
* simplify
* correct comment
* remove _
* we don't need this
* change click
* add return types
* fast typing
* use frames instead
* use frames instead
* update
* disable in CI
* +1
* fix script
* refactor how mici replay script cases are built
* refactor
* refactor: rename helper function for exploring settings in build_mici_script
* remove onroad settings check
* refactor
* simplify
* refactor: use explore_setting in more places to reduce duplication
* add type
* refactor: simplify explore_cases function by removing swipe_wait parameter
* add case to open wifi selection
* refactor: enhance run_actions to support after_each callback for interaction tests; rename explore_cases to scroll_through_cases
* add review training guide
* update comment
* comments
* comment
* fix swipe back
* scroll: use iOS-style weighted velocity averaging for fling
Weight older velocity samples more heavily on finger release to produce
more consistent fling velocities. The last touch samples before lift are
noisy (finger decelerating, rotating, jittering), so we trust the earlier
steadier samples more: 60% oldest, 35% middle, 5% newest.
Reverse-engineered from iOS UIScrollView by the Flutter team.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* Update system/ui/lib/application.py
* Apply suggestions from code review
---------
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
* modeld: quiet do_chunk output during scons build
SCons default-prints Python function actions with all their args.
The do_chunk function has 1259 tinygrad source files as deps, causing
a wall of text during builds. Wrap in SAction with a short strfunction.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* split compile and chunk into separate Commands
cleaner fix: do_chunk only depends on the pkl, not tinygrad files
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
* actually epic
* use child
* inside label
* revert other stuff
* no reset_shimmer: bool
* try 2 char
* not worth dynamic chunking
* bring back
* rm
* no emoji support on shimmer
* pandad: filter out external panda
* fix
* internal panda
* move it even higher
* this
* should be this still
* anoter
* more
* 1 more time
* bruh
* try this out
* revert
* gotta do this after
* filter
* fix pairing qr code
* test pair device
* merge and pick from explore-more
* key
* fast click
* again
* add branch selection test
* click uninstall
* test prime states
* view regulatory
* test expand calibration desc
* override interactive timeout
* reorder
* remove todo
* update
* clarify
* test reset calibration
* update
* add calibration params test
* comments
* reorganize
* clarify
* add click through training guide
* this wasn't atomic!
* start mici
* always require internet to download installer
* this made it never use cached fetch!
* this skipped installer when it wrote it raced trying to run
* entirely remove
* clean up mici
* fix tici setup
* inline
* works
* more explicit pass texture like everything else, esp since sizes are not all same
* fix some confirmation dialog images
* fix image sizes
* do bigbutton
* fix
* static
* try this
* clean up and use it
* clean up
* simpler
* do this later
* do onboarding & reset
* do setup
* temp
* Revert "temp"
This reverts commit 22fbbf5c813b4915e784b9ee235ed3bde2229048.
* simpler again
* missing size
* fix
* Revert "fix"
This reverts commit 53c4e29e614181029dc8e9a2baea7694957dc8fb.
* nl
* Smooth
* Min lat accel range
* Make the moving average masked
* Bring back the range
* Update test
* Smooth desired signal too
* Diff
* Gaussian
* Fix fmt
* Remove newline
_shake_start defaults to None, but `None or 0.0` treated it as
time zero, so any button rendered within 0.5s of window creation
would play the shake animation.
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
* try this
* try this
* fix
* delay hide on wifi/internet
* 0.5
* fix flash on forgetting
* also reset
* fix
* todo
* dupl
* wifi after
* bring back cmts
* fix spotty internet check while downloading!
* cmt
* cmt
* todo
* resort
* more delay
* redundtant
* nl
* scroll over for wifi (waiting) OR internet (continue)
* fix scroll
* fix scroll
* show_event fully manages its scroll over, not some weiird delay mixed with other triggers via fake rising edge
* instant if not popping
* cmt
* better update flow
* clean up
* clean up
* cmt
* clean up
* todo
* failed scroller
* fix for setup
* show wrong url
* setup failed is red not orange
* clean up and fix all flashing in setup
* new updater zipapp
* fix deadlock from agnos.py throwing timeout errors, never hitting failed screen! + try catch the whole process for errors while starting process
* add todo
* set core affinity like setup in updater
* fix import
* rezip
The Python file downloader was making a separate HTTP Range request per
1MB chunk via URLFile.read(), causing massive latency overhead. Use a
single streaming GET request instead, matching the old C++ behavior.
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
* pressed state for larger sliders
* wifibutton
* fix
* clean up
* some work
* don't nee this now
* stash
* more
* new pressed bigcircle
* black
* interp
* just check position
* clean up and fix slider reset
* fix custom
* no speed
* stash
* even chatter couldn't figure this one out
* makes sense to combine together, less split mentality
* clean that up
* fix lag
* match ui.py prio to eliminate lag on wifiui show event. separately, why is this slow?
* night mode
* delay scroll over
* fix auto scrolling
* stash
* waiting looks disabled
* clean up and don't reset sliders until user goes back
* rm
* fix
* add termsheader back
* fix callbacks
* ctrl alt l
* fix text spacing
* clean up
* stash
* fix style
* i want to go back
* guard on exit
* kinda useless stuff
* Revert "kinda useless stuff"
This reverts commit a4acbac31523408f358c5f68262cb630aa13ad8e.
* Revert "guard on exit"
This reverts commit 63ccfbf64edfbe1a144a441681f5ec78d8021ff7.
* wide
* setup pressed!
* grow animation
* 10s after initial
* slow fast
* start onboarding (terms)
* rm duplicate page
* add qr code
* final grey
* fix visual lag on first start
* clean up dead code
* dont exit from cancel
* revert grey
* clean up, REVIEW ME
* Revert "clean up, REVIEW ME"
This reverts commit c66fa60947c5f922520e7cf58c630b4bbe2d0177.
* reboot slider
* kb fix
* Revert "kb fix"
This reverts commit 883039448e6c37ae1d25d4f75ada6e96b6736358.
* ./ goes to letters
* Revert "./ goes to letters"
This reverts commit 0d97442427edb1a000638863a3f2181204ddc160.
* clean up
* some more clean up
* more
* clean up
* rename block
* reset pending scroll so it can't use stale data in rare sequence
* remove unused assets
* clean up imports
* fix updater
* clean up
* fix double reboot
* demo time - reset to setup on reboot
* let manager restart
* Revert "demo time - reset to setup on reboot"
This reverts commit 9468657e8438a1ce8fcb5266403b7bb3539f131f.
* url... and no grow animation on start button
* one next button
* grow instead of shake wifi button
* 36 pt font size in setup
* touch up onboarding a lil
* Revert "rm cpp bz2 (#37332)"
This reverts commit f4a36f7f74.
* more onboarding and clean up
* clean up
* wow what an amazing future clean up
* back to software select
* fix
* copy
* fix dm confirmation dialog not disabling widget underneath, all fixed with real nav stack in here
* uploading
* lint
* add review terms to device w/ close button
* todo
* remove old Terms vertical scrolling classes
* use new Scroller!
* installer
* tweak to match figma exactly
* revert
* fixup updater
* demo day
* demo day v2
* ... for percent while finishing setup
* demo day v3
* demo day v4
* remove ...
* demo day v6 -- "why does it do that!!"
* demo day v7 -- no flash
* hmm
* demo day v7
* prebuilt
* revert demo day
* scroll after pop animation
* back -> retry
* stash fixes
* damn, need back_callback
* scroll over immediately if already in network setup
* tweaks
* going down is confusing
* more
* Revert "more"
This reverts commit 29ce75b1f81eb40e7527a71d27842d9a66802206.
* Revert "going down is confusing"
This reverts commit 0cd2ae30d4135db1ccba6478429b45e886714e9c.
* dupl
* nl
* sort functions
* more clean up from merge
* move
* more
* dismiss to download (hack)
* Revert "dismiss to download (hack)"
This reverts commit 53c45ed1f63db1f0cebbce0dfab1777c8658f505.
* onboarding work
* set brightness and timeout in root onboarding only
* clean up
* type
* keep 5m for settings preview
* switch back to letters on . or /
* reset first step scroller
* custom software warning goes down network comes up and back cb fix
* clean up
* smaller qr
* ReviewTermsPage just for device as NavWidget
* clean up
* installer: stay on 100%
* reset has internet while in wifiui
* try this
* try this
* see what error we get exactly
see what error we get exactly
* not final solution but see how good
* rm
* copy changes
* reset on disconnect
* for separate pr
* Revert "reset on disconnect"
This reverts commit 552372fa4d497ba7d9de7f2edb730ee63798ffa4.
* revert this, too buggy
* fix for updater
* sort
* fix test
* minor cleanup
* more leaks than this rn
* onboarding clean up
* clean up application
* click delay to small button
* clean up
* reset more state
* fix training guide not cleaning up driverview
* Revert "fix training guide not cleaning up driverview"
This reverts commit cac7c5f436056cc9e747f80905d390790fb83c22.
* simpler fix :(
* nice catch, if you go back to terms it will reset 300s timeout and brightness
* duplicate show
* unused
* vendor libyuv from dependencies
* relock libyuv to latest vendor branch
* install cmake in macOS setup when missing
* lock
* unused?
* rm that
* no yuv for the larch
* pressable
* slow
* fast and looks great
* 0.075
* clean up
* fix missing
* clean up
* mici setup use nav stack!
* remove flat state!
* todo
* clean up
* clean up ordering
* clean up
* reset progress on show, dont mutate nav stack from thread
* reset text on show too
* rename
* clean up
i18n(fr): Add French translations for sunnypilot UI
Update 36 existing French translations with corrections and add
369 new sunnypilot-specific translation entries.
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
Handle exceptions in `getParamsAllKeysV1` to prevent crashes
- Added `try-except` block to improve error handling during key parsing.
- Ensures robustness by logging exceptions and re-raising them.
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
* jenkins: move panda tests before camera tests
* force this time
* Revert "force this time"
This reverts commit 53508225d39d63b97ff7ecc3a0181a27b5948d1b.
* mici init
* obv
* hybrid
* adapt
* less
* consolidate
* oops
Refactor speed limit alert function to use car state directly.
* no event border for tizi/tici
* abstract it
* less
* nah
* mici init
* obv
* hybrid
* adapt
* less
* consolidate
* oops
Refactor speed limit alert function to use car state directly.
* no event border for tizi/tici
* abstract it
* too soon junior
* refactor
* i like this better
* clean up
* debug
* fix able to click navwidgets that are closing (tested at rc 10)
* add dismiss guards
* fix keyboard so it unselects
* pairing: use dismiss
* main todo
* rm pop_widgets_to!
* reset dismiss state on show event
* debug pop animation bugs
* Revert "debug pop animation bugs"
This reverts commit 9239f2e12cf79b1f75d15d39262fdd15ff5a5200.
* revert
* cmt
* type
* clean up
* now do the todo
* treat using widgets, not idxs, as a separate clean up for later
* actually if not navwidget this is buggy
* fix
* short
* simpler
* clean up
* more
* great clean ups
* better name
* remove useless _can_swipe_away
* reorder
* rename
* state machine is nice but might be too much
* Revert "state machine is nice but might be too much"
This reverts commit f8952969243a2eac3ed5f84793ba7b0c0cdf24bf.
* got a better name out of it though
* clean up
* clean up
* rm!
* rm
* and this
* and
* clean up
* stash
* widgets animate out
* Revert "stash"
This reverts commit eac3493509cff6f2c64111d803c7fef21a1aa2dd.
* abstract
* works also
* works also
* support pop_widget
* only animate top
* callback in request pop
* tune it
* fix
* fix
* try this
* Revert "try this"
This reverts commit 191373a1b35917ee3a361afe73b16eeb60d0a20e.
* debug
* debug
* clean up
* simple test
* clean up
* clean up
* clean up
* clean up
* clean up
* clean up
* clkean up
* re sort
* fine
* yes
* ui sync conflicts with upstream
* md
* ref
* ci
* lint
* more
* more ci
* new new
* tools: block `manage_sunnylinkd` in sim startup script
* try this out
* unbump
* chore: sync tinygrad
Runs great in sim. now we need to rebuild some models
* oops forgot to unblock this after testing
* helpers
* oh yeah
* latest tg
* this wont do anything empriically
* reduce complexity
* okay lint
* Update tinygrad_runner.py
* Update modeld.py
* Update build-all-tinygrad-models.yaml
* tinygrad bump
* Update modeld.py
* Update tinygrad_runner.py
* bump
* Update SConscript
* Update SConscript
* com
* Update fetcher.py
* Update helpers.py
* life is froughtless, when you're thoughtless
* lint
* ozdust ballroom
* shiz
* Update tinygrad_runner.py
* Update tinygrad_runner.py
* slough it off as i do
* try old support one last time
* support mixed input dtypes
* use internal
* dont need that shiz
* Update fill_model_msg.py
* Update onnx_runner.py
* Update onnx_runner.py
* Update model_runner.py
* see if this speeds up execution
if not, revert me
* no
* Update helpers.py
* rebase
* more
* planplus
---------
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
* add back bz2 support with vendored bzip2
Reverts f4a36f7f7 ("rm cpp bz2") to restore bzip2 decompression
support in replay/cabana tools, and replaces the system libbz2-dev
with a vendored bzip2 package from commaai/dependencies.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* relock bzip2 from releases branch
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
* test wifi state machine
* clean up and another few tests
* no unittest :((
* clean up
* clean up
* try to repro on device
* try to repro on device
* nice, the flicker is covered by test_user_initiated_skips_dbus_lookup!
* add todo soon to be all fixed
* documentaiton
* test the thread races too
* _fire -> fire
* duplication
* new state
* fix some tests
* format
* combine similar tests
* use process_callbacks
* clean up
* collapse two tests
* rm nl
* previous messy test
* delete old
* asked another to ask questions
* flasher for Rivian long upgrade
* self-contained no dependency on Panda.F4_DEVICES
* standalone flasher
* move to sp module
* use brand field directly
* use brand field directly
* use brand field directly
* bump
* add some logging
---------
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
* soundd: trigger timeout warning during MADS lateral-only
The selfdrive timeout alert (warningImmediate) only fires when
selfdriveState.enabled is True. During MADS lateral-only mode,
enabled is False even though the system is actively steering.
If selfdrived stops publishing while MADS lateral is active, the
driver gets no audible warning that steering has become unresponsive.
Add selfdriveStateSP to the SubMaster and check mads.active alongside
selfdriveState.enabled so the timeout alert fires whenever the system
is actuating steering.
* test_soundd: add MADS lateral-only timeout test
Test that the selfdrive timeout warning fires when selfdriveState.enabled
is False but selfdriveStateSP.mads.active is True.
---------
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
The `steer_limited_by_safety` update in `publish()` is gated by
`selfdriveState.active`, which is False during MADS lateral-only
control. This causes the flag to never update once cruise deactivates
— it stays stuck at whatever value it had during the last ramp-up
(typically True), permanently suppressing the saturation timer in
`_check_saturation` and preventing the "Turn Exceeds Steering Limit"
alert from firing.
Use `CC.latActive` instead, which already accounts for MADS via
`get_lat_active()` in ControlsExt.
Bug was introduced in #446 (MADS), which updated `CC.latActive` to
use `mads.active` but missed updating the `steer_limited_by_safety`
gate in `publish()`.
* should fail
* this works but i think i know a better way
* something like this
* hmm
* this works
* rm useless test
* good stash
* Revert "good stash"
This reverts commit c2dddf0810286cb56e2418dd6f7085c2239e5109.
* replace python3-dev apt install with vendored package
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* keep for agnos
* cleaner
---------
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
* Reapply "feat(lpa): `at` client + list profiles (#37271)" (#37322)
This reverts commit ddf8abc14a.
* lpa: fall back to ModemManager D-Bus when serial port unavailable
On older devices, ModemManager still claims /dev/ttyUSB2, so the
direct serial open fails. Try serial first; if it can't be acquired,
transparently route AT commands through MM's D-Bus Command() interface.
Co-authored-by: Cursor <cursoragent@cursor.com>
* lpa: add serial/dbus transport labels to debug logs
Co-authored-by: Cursor <cursoragent@cursor.com>
* no
* lint
* here
* const
---------
Co-authored-by: Cursor <cursoragent@cursor.com>
* disable forget for tethering
* nets
* put in wifiman
* batch
* Revert "batch"
This reverts commit 9af20c1c7513c22bf9283b2f02514373fa981f50.
* clean up
* more
* more
* use vendored eigen from dependencies repo
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* lock
---------
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
* use vendored zeromq from dependencies repo
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* lock
* rm more crap
* use vendored git-lfs from dependencies repo
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* from releases
---------
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
* rm extra LLVM install on macOS
* update that
* rm brew cache
* no cache
* Revert "no cache"
This reverts commit a3f8eff234935d4bb27d4bd785ad8a710496a159.
* use vendored zeromq from dependencies repo
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* lock
* rm more crap
---------
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
* start
* start
* lil more
* add forget
* fix forget button scrolling
* push right a bit
* fix forget press
* add divider
* fix scroll panel
* better forget and overriding
* revert this
* check icon
* cursor merge conflict fix
* fix rounding and forget btn placement
* scroll indicator
* 65%
* calibrate
* try loading animation
* push to device
* top right
* bottom right
* no red
* top left
* bottom left
* down 2px
* WHY DOES NETWORK MANAGER KEEP CRASHING AHHH
* reduce round trip calls in update_networks
* clean up and combine getallaccesspoint and activeaccesspoint
* cmt
* animate big button over smoothly. super hacky, need to clean up
* animate
* remove old widgets and images
* remove status label, tune loading animation opac back
* connecting is a little buggy still
* add back missing network and don't pop
* some fixes
* "clean up"
* fix lag in animation
* fix adding saved connection to start
* remove saved network to start, divider
* animate up, over, and down
* revert for now
* remove fancy complex animation for now, sorry nick
* remove divider + clean up
* more clean up
* more clean up
* fix forget button press
* cmt
* tweak loading animation behavior
* new lock fix wifi
* rm old lock
* great catch by opus
* clean up
* debug
* fix touch events that are down -> up in one frame (why it only bugged on mici)
* clean up
* eager forgetting
* this SHOULD be full eager forget, more than i thought
* fix wifi slash positioning
* move forgotten networks after saved networks
* temp keep
* test on device
* fix
* see 65
* 5 best
* fix double render double brightness
* can click bottom right now
* disable touch while animating
* fix animation
* can scroll while animating, not tap
* not great yet
* clean up
* didn't work
* always update networks after activation
* stash
* move to update_state
* debug
* debug
* temp
* fix ip and metered flickering when updating at high freq (or rare race condition)
* fix
* if you give it less than 8 chars it never clears connecting
* lock no int
* better wrong password handling
* shake when wrong password
* nm set connecting when it connects on its own
* loading bottom right
* sort connecting first
* sort by unquantized to put strongest first
* clean up
* clean up nm
* clean up nm
* shorter
* fix crash
* 0.5s
* debug
* revert and try something else
* stash
* no
* rev
* use signals
* more
* not wrong password if ever connected after wrong
* similar to gnome shell, don't save connection that never successfully activated.
we do this by creating temporary memory connection with persist: volatile that deletes itself if failed, and then only write to disk when activated
* clean up
* cover all states
* clear if connecting too
* remove pritn
* might need this for CoxWifi
* whoops
* save last pass
* Revert "whoops"
This reverts commit 83a133955246ce32dcf119ededd8b01b3162a866.
* Revert "might need this for CoxWifi"
This reverts commit cddb8b35be152ed154462b188283f9d5a844583d.
* this may be less noisy for low strength networks, but less accurate as previous was reflecting nm state better
* Revert "this may be less noisy for low strength networks, but less accurate as previous was reflecting nm state better"
This reverts commit 740286c846556f32125a96bfe6ecf128300af0d8.
* race condition with volotile not removing conn fast enough/update networks not firing fast enough
* Revert "save last pass"
This reverts commit 7249a58a18b11487fd0370cee36e40a17f7ac521.
* revert some wifiman stuff to master
* not needed
* rm active ap
* remove old dead code
* do after
* always send forgotten callback so we can't be stuck in forgetting state forever
* reproduce race condition where connection removed signal takes a while to remove, then update networks keep is_saved true
* fix from merge
* nice, we can remove some eager code now for treating is_saved as not saved after forgot since it's live
* more
* rm
* simplify passed in callbacks
* clean up
* need this one check back for wrong password to hide forget for a split second
* opus says this is simpler 🤔
* Revert "opus says this is simpler 🤔"
This reverts commit 71472e5b383d7f2083d95ba1188070f41ae14775.
* another attempt
* Revert "another attempt"
This reverts commit 31f30babe656f9cad24399bc2196bb6e7ab79bbd.
* fix from merge
* some lcean up
* fix
* fixes to make work with new animation
* clean up
* this works too
* simplify loading animation behavior for now, revert wifi scan time
* clean up
* temporary fix
* stash
* Revert "stash"
This reverts commit 7471dbdc452807b33b4868a98dd8565681b2e44d.
* stash
* Revert "stash"
This reverts commit e0e5e6e861734320ce5dea5626086784577cb334.
* this check was because is_connected could have been stale from Network as the source
* nm can show connected/connecting to network with 0 aps for a while if strength is low, move out of range under those states
* stash
* Revert "stash"
This reverts commit 5ec3b454d54392523947f6477f551657d3863a6d.
* todo
* todo
* order
* don't need temporary fix anymore
* cmt
* order
* unused i
* stash
* test seemed to work
* simplify
* clean up
* move under
* Revert "move under"
This reverts commit ce940cffb32378cbe5a69edaf6fc9d9cec202e54.
* back
* fix
* already 90% of the way there and not 144 lines
* nice
* lift properly
* lift, wait, move, wait, drop!
* some clean up
* epic, he ran a simulation to turn opacity filter into pixels
* scroll independant move animation without layout!
* move into function
* clean up
* rm
* overlay behind moving item
* Revert "overlay behind moving item"
This reverts commit 598e22363eb66af6496fe5f1eea8e643d4c2adbb.
* simpler overlay under lifted item
* support multiple animations at once
* Revert "support multiple animations at once"
This reverts commit 3ce6c8281053ee4831ceb88cacf66c343fc7d7ff.
* clean up
* cmt
* clean up
* kinda works
* Revert "kinda works"
This reverts commit ff050c6afc058788b3189a0acc202ada17353504.
* clean up
clean up
* clear overlay
* diff report
* don't break more
* split nav widget out
* clean up
* clean up
* fix
* work
* small enough to not be function
* nah we want intflag
* clean up
* always runs
* more clean up
* prep for scroller
* opacity for settings
* clean up layout
* set enabled
* rm
* initial
* start to support nav stack in settings panels + fix some navwidget bugs
* add deprecation warning and move more to new nav stack
* fix overriding NavWidget enabled and do developer panel
* fix interactive timeout and do main
* more device, not done yet
* minor network fixes
* dcam dialog
* start onboarding
* fix onboarding
* do mici setup
* remove now useless CUSTOM_SOFTWARE
* support big ui with old modal overlay
* reset can be old modal overlay, but updater needs new since it uses wifiui
* flip name truthiness to inspire excitement
* all *should* work, but will do pass later
* clean up main
* clean up settiings
* clean up dialog and developer
* cleanup mici setup some
* rm one more
* fix keyboard
* revert
* might as well but clarify
* fix networkinfopage buttons
* lint
* nice clean up from cursor
* animate background fade with position
* fix device overlays
* cursor fix pt1
cursor fix pt2
* rm print
* capital
* temp fix from cursor for onboarding not freeing space after reviewing training guide
* fix home screen scroller snap not resetting
* stash
* nice gradient on top
* 40
* 20
* no gradient
* return unused returns and always show regulatory btn
* nice!
* clean up
* new_modal is always true!
* more clean up
* clean up
* big only renders top 1
* fixup setup and updater
* stash
* Revert "stash"
This reverts commit 3cfb226ccb51869ed1f7d630b5fdd6725ad094d5.
* fix mici keys coming in from top
* clean up
* fix mici dialogs like tici, pop first incase call back pushes
* clever way but not not
* Revert "clever way but not not"
This reverts commit f69d106df61262f049df20cc1a9064ca1e6feeb7.
* more setup
* mici keyboard: fix not disabling below
* cmt
* fix wifi callbacks not running in rare case
* clean up network
* clean up network
* clean up dialog
* pairing
* rm
* todo
* fix replay
* they push themselkves!
* clean up ui_state
* clean up application
* clean up
* stash
* Revert "stash"
This reverts commit 07d3f5f26c99ef891086b6fe03095d53a62b8631.
* typing
* lint
* Chunk tinygrad pkl below GitHub max size
* pull that out
* rm glob
* make work
* Single name def
* unused comment
* more cleanups
* revert that
* 10MB overhead
---------
Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
* feat(lpa): implement list_profiles in TiciLPA
Add AT command serial interface, TLV parsing, and ES10x transport
to support listing eSIM profiles (SGP.22 v2.3). TiciLPA is a
singleton that maintains a persistent connection to the modem.
* feat(lpa): close TiciLPA serial connection on exit
Register atexit cleanup so the logical channel and serial port are
released when the process exits, even on crashes or early exits.
* feat(lpa): close stale logical channels on init to prevent timeouts
* trying to brick it
* Revert "trying to brick it"
This reverts commit 46a0467314479c92d2cf331280521a1263f6cc43.
* feat(lpa): remove ensure_capabilities check on init
Target devices are known to support the required AT commands,
so skip the capability probes and stale channel cleanup to
speed up initialization.
* feat(lpa): enable debug logging via DEBUG=1 env variable
* muuuch better
* revert
* cleanup
* constant
* initial
* start to support nav stack in settings panels + fix some navwidget bugs
* add deprecation warning and move more to new nav stack
* fix overriding NavWidget enabled and do developer panel
* fix interactive timeout and do main
* more device, not done yet
* minor network fixes
* dcam dialog
* start onboarding
* fix onboarding
* do mici setup
* remove now useless CUSTOM_SOFTWARE
* support big ui with old modal overlay
* reset can be old modal overlay, but updater needs new since it uses wifiui
* flip name truthiness to inspire excitement
* all *should* work, but will do pass later
* clean up main
* clean up settiings
* clean up dialog and developer
* cleanup mici setup some
* rm one more
* fix keyboard
* revert
* might as well but clarify
* fix networkinfopage buttons
* lint
* nice clean up from cursor
* animate background fade with position
* fix device overlays
* cursor fix pt1
cursor fix pt2
* rm print
* capital
* temp fix from cursor for onboarding not freeing space after reviewing training guide
* fix home screen scroller snap not resetting
* stash
* nice gradient on top
* 40
* 20
* no gradient
* return unused returns and always show regulatory btn
* nice!
* revert selfdrive/ui
* let's do tici first
* bring back ui
* not sure why __del__, SetupWidget was never deleted?
* device "done"
* network "done!!"
* toggles "done"
* software "done"
* developer "done"
* fix onboarding
* use new modal for debug windows
* and aug
* setup "done"
* clean up
* updater "done"
* reset "done"
* pop first before callbacks in case callbacks push
* fix cmt
* not needed
* remove two commented functions for mici
* clean up application
* typing
* static
* not sure what this means
* fix big
* more static
* actually great catch
* fix cmt
* fix
* meh
* unclaud test is best
* yess
* try
* works!
* remove dict handling
* clean up
* more clean up
* remove trash
* fixup
* fix up onboarding again
* fix drivercameradialog
* don't show test window
* more widgets
* fix all
* Revert "fix all"
This reverts commit 42d3537c9314af382961a16443a63faed202b157.
* move and whitelist
* clean up
* more test + ignore
* to fix
* temp
* Revert "temp"
This reverts commit 215ecbb8a8fc0e6826d45b2c0d57999c7a19a400.
* temp
* rev
* reproduce race condition where connection removed signal takes a while to remove, then update networks keep is_saved true
* fix
* Revert "reproduce race condition where connection removed signal takes a while to remove, then update networks keep is_saved true"
This reverts commit cf7044ee955777db16434ab81c520bbe798c9164.
* not anymore
* more clear
* safe guards
nl
* signal driven wifi state
* copy exactly
* copy signal handler
* remove is_connected
* Revert "remove is_connected"
This reverts commit f2246a70f4a29e9f3405947ca43d9404578c9d2d.
* do 3 network
* missing reason
* do wifiui
* clean up mici updater
* rest
* or not connecting
* clean up is_connected
* clean up wifiui
* match wifiui state more exactly in network panel for wifi button
* update active connection info after activation (used to do in _update_networks)
* clean up prints
* more
* rm
* not needed
* clean up state machine a bit
* more
* more
* indent
* final clean up
* debug
* debug
* wait for ip?
* more
* revert
* just to see
* ensure we emit activated even if we fail to get conn path from dbus
* hmm
* fine
* back
* back
* Revert "back"
This reverts commit 6464abe243c2a3bbf62b8f9a109b72ec3ddb3817.
* debug flickering on forget then connect to another. commit before this is good
* fix rare flicker when forgetting network and immediately connecting to
another
* clean up
* clean up router stuff now
* ugh wtf
* stash -- wtf
* Revert "stash -- wtf"
This reverts commit 756a92a9c0530a16917303424e26447f258f17e4.
* Revert "fix rare flicker when forgetting network and immediately connecting to"
This reverts commit 90c5fc14551726765ab2524e7866ee8b3c5dee7c.
* remove debug
* fix
* add issues
* add flow
* match previous behavior
* it doesn't fix the flikcer
* more atomic
* Revert "more atomic"
This reverts commit ead87c5a7a4030719b64138c12b9154ec82e73d9.
* last test!
last test!
* really the race is here?
* atomic wifi_state replace
* not slow
* clean up
* WifiManager: fix all networks showing as connected when no active connection
When there's no active WiFi connection, _get_active_wifi_connection()
returns None. This caused `self._connections.get(ssid) == None` to be
True for all unsaved networks, marking them all as connected.
Co-authored-by: Cursor <cursoragent@cursor.com>
* ltl
---------
Co-authored-by: Cursor <cursoragent@cursor.com>
* ui: add edge shadow effect to horizontal scrollers in settings
Adds a black gradient falloff shadow (20x240, 100%→0% opacity) on the
left and right edges of horizontal Scroller panels. Enabled via an
opt-in `edge_shadows` parameter on Scroller for easy per-screen control.
Enabled on: settings menu, toggles, network, device, developer.
Not enabled on: home screen carousel, vertical scrollers, setup screens.
Co-authored-by: Cursor <cursoragent@cursor.com>
* ui: reduce edge shadow opacity to 80%
Co-authored-by: Cursor <cursoragent@cursor.com>
* what on earth is this
* some lines are ok
---------
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Shane Smiskol <shane@smiskol.com>
* init
* no
* more
* tree it
* final
* comment
* only with enforce torque
* only with enforce torque
* missed
* no
* lint
* Apply suggestion from @sunnyhaibin
* sunnylink metadata sync
* Apply suggestion from @sunnyhaibin
---------
Co-authored-by: nayan <nayan8teen@gmail.com>
* refactor: improve video synchronization logic in HTML report generation
* feat: include description of which video is longer in report; refactor stuff and add types
* refactor: simplify HTML report generation and remove extra formatting
* reduce diff
* fix video name
* reduce diff
* reduce diff
* fix
* parentheses
* fix I guess
* Remove gcc@13 installation from mac_setup.sh
Removed installation of gcc@13 from mac_setup.sh.
* no cache
* Revert "no cache"
This reverts commit fc27f7dc9e6dab4b61703433130531f12dbe334b.
Widen the hint label rect so it doesn't reserve right-side space for the
hidden backspace button, preventing unnecessary text eliding. Also show
the blinking cursor over the hint and add trailing ellipsis to hint
strings for consistency.
Co-authored-by: Cursor <cursoragent@cursor.com>
* debug why so slow
* forget after
* i'm not sure why this is a thing
* better forget connecting reset
* ????
* has lag
* fix
* clean up
* should be fine
* Delay lateral reengagement
* UI elements
* Add tests
* Update title and description
* Update params_metadata
* Didn't mean to pass this to int()
* Keep sentry happy
* Title and description update
* always 100 hz
---------
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
* add networks to end, remove bad scroller restore logic that sometimes starts in the middle
* works
* almost
* wifi slash
* clean up
* clean up
* opactiy
* more clean up
* more clean up
* set enabled and network missing on regain network
* cmt
* Revert "Revert tgwarp again (#37161)"
This reverts commit 45099e7fcd.
* Weird uv sizes
* Fix interleaving
* Fix on CPU
* make CPU safe
* Prevent corruption without clone
* Claude knows speeed
* fix interleaving
* less kernels
* blob caching
* This is still slightly faster
* Comment for blob cache
* like c++ wifiman
* rename to scan
* can do this
can do this
* Revert "can do this"
This reverts commit 295f7f49d448c6aacdde2ef810904df86357840b.
* kinda useless now
* clean up
* fix recent connect regression from connection not being known yet
* always update connections in background, keep track via signals only. no getallconnections each time one is added/deleted. matches c++
* works
* clean up
* clean up
* clean up
* clips: allow mici UI (now default) (#37070)
fix: make big false by default and remove assertion
* comma four: new keyboard enter button (#37072)
* works
* enter dis
* clean up
* clean up
* no debug
* useless
* poadding
* tools: fix Python version comparison using normalized semantic version format (#37075)
* Back to tethering BigButton (#37082)
Back to tethering big button
* Stock LKAS: remove permanent alert (#37083)
rm perm
* BigButton: remove unused scrolling (#37085)
* BigButton: remove unused scrolling
* clean up
* BigButton: use UnifiedLabel (#37086)
* BigButton: remove unused scrolling
* start
* debug
* stash
* actually removing the hardcoded size for multioption fixes it
* back
* cursor does sub label
* clean up
* more
* more
* try this for now
* nick suggest
* clean up
* more
* more
* Network menu improvements (#37077)
* try this
* that's handy
* todo, not sure what happens here
* set_text
* normalize
* scroll wifi
* clean up
* more
* better check
* UI: only show `onroad_fade.png` when engaged (#37051)
* only show when engaged
* retrigger CI
* fade animation 0.1
* nl
---------
Co-authored-by: Shane Smiskol <shane@smiskol.com>
* NavBar: fix no show animation (#37090)
* 1.5 not enough time on small screen
* ohhhh
* clean up
* translations: remove arabic (#37087)
* remove arabic
* more
* bump opendbc (#37091)
* long_mpc: use log.capnp source enum instead of list (#37093)
* Revert "long_mpc: use log.capnp source enum instead of list" (#37095)
Revert "long_mpc: use log.capnp source enum instead of list (#37093)"
This reverts commit 7e959c5a3e.
* mici setup: remove unused functions
* fix mici setup int enum
* clips: improve overlays for mici (#37088)
* adjust overlay sizes and wrap metadata text for mici
* comment
* adjust overlay rendering to dynamically calculate line height for wrapped metadata text
* render time first so we can use width in margin calculation
* update comment (to retry failed CI actually)
* increase metadata size on mici
* longitudinal mpc tuning: behind if main (#37099)
* longitudinal mpc tuning report: add sinusoidal oscillation scenario (#37100)
* long_mpc: use log.capnp source enum (#37096)
* Calibrate in tg (#36621)
* squash
* bump tg
* fix linmt
* Ready to merge
* cleaner
* match modeld
* more dead stuff
* long mpc: state name before subscript (#37101)
* clip: clean up imports (#37104)
* wtf is this
* don't break import timing
* they are the same
* clean up
* good catch
* rm common/mat.h
* Remove all the OpenCL (#37105)
* Remove all the OpenCL
* lil more
* bump msgq
* clip: use wrap_text helper (#37102)
* they are same
* no duplication!
* rm rstrip
* bump opendbc (#37108)
bump
* Delete less dialogs (#37111)
* try
* revert
* this is fine
* revert tg calib and opencl cleanup (#37113)
* Revert "Remove all the OpenCL (#37105)"
This reverts commit d5cbb89d84.
* Revert "rm common/mat.h"
This reverts commit 4ce701150a.
* Revert "Calibrate in tg (#36621)"
This reverts commit 593c3a0c8e.
* fix: route fetch metadata when first log isnt uploaded (#37114)
* fix: route fetch metadata when first log isnt uploaded
* default
* simple
---------
Co-authored-by: Trey Moen <treymoen@amazon.com>
* gitignore .context/
* ui diff replay: remove unused frame_data list for individual frame display (#37117)
Remove unused base64 encoding and simplify frame data handling in diff video report
* bridge: move ZMQ handling over (#37118)
* replace tabulate with simple helper (#37122)
* Better memory usage debugging (#37120)
* Revert "revert tg calib and opencl cleanup (#37113)" (#37115)
* Revert "revert tg calib and opencl cleanup (#37113)"
This reverts commit 51312afd3d.
* power draw is a lil higher
* just don't miss a cycle
* fix warp targets
* fix tinygrad dep
* CI: garbage collect tmp jenkins branches (#37125)
* Build vendored artifacts in CI (#37127)
* Build vendored artifacts in CI
* parallel
* deterministic
* fix up
* fix gitignores
* lil more
* lil more consistency
* remove get_mcu_type from pandad.py (#37132)
* Chunk big model files (#37134)
* file chunking
* try this
* more cleanup
* cleaner
* ui: delay nav bar animation (#37137)
* from da bounce
* try this
* you can get it to clean up wow
* modeld: simplify model run processing (#37138)
Hi! The point of this pr is to make the model run easier to read. On the latest tinygrad numpy().flatten() empirically does the same thing as the internal contiguous().realize().uop.base.buffer.numpy(). numpy() is also documented (docstrings), which can assist new contributors in learning what each potential execution does. Torq_boi or yassine, I know you want proof in the code base, so here it is. As of tinygrad commit 2f55005:
in tinygrad_repo/tinygrad/tensor.py
Lines 316-318 (def _buffer): ensure the tenso is contiguous() and realized() before accessing the raw buffer.
Line 378 (def numpy): Wraps the buffer access and adds a reshape to match the tensor shape.
self._buffer() is what executes contiguous().realize() and returns the buffer object.
Calling numpy() on that buffer object returns a 1D array (defined in tinygrad/device.py:193 via np.frombuffer).
The reshape(self.shape) at the end of Tensor.numpy() then adds dimensions to that 1D array. The added .flatten() removes those dimensions, flattening it back to a 1D array. Effectively the same as what is currently done, but less complex.
* Revert "Chunk big model files (#37134)" (#37139)
This reverts commit a941e8f78f.
* Process replay: move refs to ci-artifacts (#37049)
* rm upload
* use ci-artifacts
* sanitize
* rm ref_commit
* add ci
* handle exept
* bootstrap
* always
* fix
* replay
* keep ref_commit fork compatibility
* remove upload-only
* apply comments
* safe diffs in master
* Revert "safe diffs in master"
This reverts commit 369fccac786a67799193e9152488813c6df20414.
* continue on master diff
* Update .github/workflows/tests.yaml
Co-authored-by: Shane Smiskol <shane@smiskol.com>
---------
Co-authored-by: Shane Smiskol <shane@smiskol.com>
* fix first-interaction action inputs for v3 (#37144)
v3 renamed inputs from kebab-case to snake_case (repo-token -> repo_token,
pr-message -> pr_message). The old names were silently ignored, causing
"Input required and not supplied: issue_message" errors.
* bump create-pull-request action to v8.1.0 (#37143)
The pinned SHA was v6.0.4, which is incompatible with actions/checkout@v6
and causes a "Duplicate header: Authorization" 400 error during git
remote operations. See peter-evans/create-pull-request#4272.
* bump numpy to 2.4.2 (#37145)
* show dependency tree in weekly uv lock job (#37146)
* Revert "DM: Ford GT model" (#37148)
Revert "DM: Ford GT model (#37013)"
This reverts commit 1459d3519d.
* remove dead multilang for mici (#37150)
* ui: remove dead side button (#37151)
* rm side button
* fix
* fix
* BigButton: fix alignment and style (#37153)
* correct from bottom alignment
* temp
* fix scale animation w/ btn_y
* home settings are always 64
* cleanup
* some clean up
* make 23 const
* rev
* more
* remove azure deps (#37084)
* remove azure deps
* fix lint
* restore scripts
* [bot] Update Python packages (#37147)
* Update Python packages
* fix
* bump panda
* revert tinygrad
---------
Co-authored-by: Vehicle Researcher <user@comma.ai>
Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
* remove pytest-repeat (#37156)
* BigButton: push up all content when pressed (#37157)
clean implementation
* ui.py: fix stride (#37159)
fix uii.py
* BigButton: don't round drawn content (#37158)
* unround icons
* unround rest
* Revert tgwarp again (#37161)
* Reapply "revert tg calib and opencl cleanup (#37113)" (#37115)
This reverts commit 667f3bb32f.
* revert msgq too
* msgq on master
* newline in updater error
* Remove vertical scroll bar
* Simple scroll indicator (#37162)
* scroll indicator
* 65%
* calibrate
* margin
* cleaner?
* manual clean up
* clean up
* full scroll bar
* look
* looks
* unlook
* no fade, looks good but "too much"
* clean up
* cmt
* Scroll panel: adapt to content size shrinking (#37163)
fix
* WifiManager: sort by known networks (#37164)
sort by known
* mpc tuning report: minor improvements (#37167)
---------
Co-authored-by: David <49467229+TheSecurityDev@users.noreply.github.com>
Co-authored-by: Shane Smiskol <shane@smiskol.com>
Co-authored-by: ugtthis <142481257+ugtthis@users.noreply.github.com>
Co-authored-by: royjr <royjr96@gmail.com>
Co-authored-by: Jason Young <46612682+jyoung8607@users.noreply.github.com>
Co-authored-by: felsager <76905857+felsager@users.noreply.github.com>
Co-authored-by: Harald Schäfer <harald.the.engineer@gmail.com>
Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
Co-authored-by: Trey Moen <50057480+greatgitsby@users.noreply.github.com>
Co-authored-by: Trey Moen <treymoen@amazon.com>
Co-authored-by: Andi Radulescu <andi.radulescu@gmail.com>
Co-authored-by: James Vecellio-Grant <159560811+Discountchubbs@users.noreply.github.com>
Co-authored-by: Daniel Koepping <elkoled@gmail.com>
Co-authored-by: ZwX1616 <zwx1616@gmail.com>
Co-authored-by: commaci-public <60409688+commaci-public@users.noreply.github.com>
Co-authored-by: Vehicle Researcher <user@comma.ai>
* new/removed conns signal
* clean up
* only get connections when adding/removing not every refresh
* add debug
* block
* Revert "block"
This reverts commit 30bbffca8d2db21c53d7a3601ae46bf05e2a7cd5.
* rm debug
* block on any new message, faster conn rem/add reaction
* better names
* correct from bottom alignment
* temp
* fix scale animation w/ btn_y
* home settings are always 64
* cleanup
* some clean up
* make 23 const
* rev
* more
The pinned SHA was v6.0.4, which is incompatible with actions/checkout@v6
and causes a "Duplicate header: Authorization" 400 error during git
remote operations. See peter-evans/create-pull-request#4272.
v3 renamed inputs from kebab-case to snake_case (repo-token -> repo_token,
pr-message -> pr_message). The old names were silently ignored, causing
"Input required and not supplied: issue_message" errors.
Hi! The point of this pr is to make the model run easier to read. On the latest tinygrad numpy().flatten() empirically does the same thing as the internal contiguous().realize().uop.base.buffer.numpy(). numpy() is also documented (docstrings), which can assist new contributors in learning what each potential execution does. Torq_boi or yassine, I know you want proof in the code base, so here it is. As of tinygrad commit 2f55005:
in tinygrad_repo/tinygrad/tensor.py
Lines 316-318 (def _buffer): ensure the tenso is contiguous() and realized() before accessing the raw buffer.
Line 378 (def numpy): Wraps the buffer access and adds a reshape to match the tensor shape.
self._buffer() is what executes contiguous().realize() and returns the buffer object.
Calling numpy() on that buffer object returns a 1D array (defined in tinygrad/device.py:193 via np.frombuffer).
The reshape(self.shape) at the end of Tensor.numpy() then adds dimensions to that 1D array. The added .flatten() removes those dimensions, flattening it back to a 1D array. Effectively the same as what is currently done, but less complex.
* init
* more
* change
* exist
* better title
* adjust
* more
* seems better
* slightly more
* slightly more
* center it
* final
* move
* no bc ew
* more less
* commaai/openpilot:d05cb31e2e916fba41ba8167030945f427fd811b
* bump opendbc
* bump opendbc
* bump opendbc
* bump opendbc
* bump opendbc
* sunnypilot: remove Qt
* cabana: revert to stock Qt
* commaai/openpilot:5198b1b079c37742c1050f02ce0aa6dd42b038b9
* commaai/openpilot:954b567b9ba0f3d1ae57d6aa7797fa86dd92ec6e
* commaai/openpilot:7534b2a160faa683412c04c1254440e338931c5e
* sum more
* bump opendbc
* not yet
* should've been symlink'ed
* raylib says wut
* quiet mode back
* more fixes
* no more
* too extra red diff on the side
* need to bring this back
* too extra
* let's update docs here
* Revert "let's update docs here"
This reverts commit 51fe03cd51.
* param to control stock vs sp ui
* init styles
* SP Toggles
* Lint
* optimizations
* multi-button
* Lint
* param to control stock vs sp ui
* init styles
* SP Toggles
* Lint
* optimizations
* Panels. With Icons. And Scroller.
* patience, grasshopper
* more patience, grasshopper
* sp raylib preview
* fix callback
* fix ui preview
* add ui previews
* introducing ui_state_sp for py
* param to control stock vs sp ui
* better
* add ui_update callback
* better padding
* init
* revert padding to 20
* new line, who dis
* this
* support for next line multi-button
* use inline=false
* uhh
* disabled colors
* hide em all
* lambdas
* NOT inline
* final touches
* hide HIDE
* ruff.. RUFF.. WHY RUFF
* listitem -> listitemsp
* Revert "add ui_update callback"
This reverts commit 4da32cc009.
* add show_description method
* remove padding from line separator.
like, WHY? 😩😩
* scroller -> scroller_tici
* scroller -> scroller_tici
* remove line separator padding
* ui: `GuiApplicationExt`
* add to readme
* use gui_app.sunnypilot_ui()
* use gui_app.sunnypilot_ui()
* use gui_app.sunnypilot_ui()
* uhhh. nope
* optimizations
* I THINK this is not needed, i don't see it used on the visuals panel...
* unhide for now... Why hidden tho?
* refresh controls
* missing
* blindspot
* standstill timer
* road name toggle
* more descriptions
* more descriptions
* update desc
* param turn signals
* sort
* fix
* always show desc if not available
* should be bool
* rocket fuel
* steering arc
* lint
---------
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
Co-authored-by: DevTekVE <devtekve@gmail.com>
* init
* lint
* add toggle
* Update params_keys.h
* Update params_metadata.json
* Update params_keys.h
* bool
* decouple
* no
* make it perfect
* fade it
* only with torque bar
* dynamic
* in another PR
---------
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
* Revert "revert tg calib and opencl cleanup (#37113)"
This reverts commit 51312afd3d.
* power draw is a lil higher
* just don't miss a cycle
* fix warp targets
* fix tinygrad dep
* Revert "Remove all the OpenCL (#37105)"
This reverts commit d5cbb89d84.
* Revert "rm common/mat.h"
This reverts commit 4ce701150a.
* Revert "Calibrate in tg (#36621)"
This reverts commit 593c3a0c8e.
* adjust overlay sizes and wrap metadata text for mici
* comment
* adjust overlay rendering to dynamically calculate line height for wrapped metadata text
* render time first so we can use width in margin calculation
* update comment (to retry failed CI actually)
* increase metadata size on mici
* BigButton: remove unused scrolling
* start
* debug
* stash
* actually removing the hardcoded size for multioption fixes it
* back
* cursor does sub label
* clean up
* more
* more
* try this for now
* nick suggest
* clean up
* more
* more
* always check, no flickering from has inter -> waiting -> has inter from the reset
* 1s interval. i see read timeouts at 0.5s sometimes
* clean up
* cursor
* Revert "cursor"
This reverts commit 13ec6312aa7f71b58771f8789456e97c4481856a.
* clean up
* fix non-determinism in selfservice model build
also trim down model compile dependencies to the minimum required
* Apply suggestions from code review
---------
Co-authored-by: Shane Smiskol <shane@smiskol.com>
* sla ui
remove dub
debug ahead
postition
maybe
posttion
think
* sunny will be mad
Reapply "test"
This reverts commit 7a35fd3053425b06c1e4cebf68b6c9676eb6e279.
Revert "test"
This reverts commit 1a79155d3cfc8e6e09a6fc38d13747883745ef6a.
test
* road name
* Revert "road name"
This reverts commit 02e69b008603c357f14b4793e8fc893e00b3d3a0.
* decouple
* dial it in
* match cur
* no magic numbers
* cleanup
* more cleanup
* match
* always draw ahead
* Revert "always draw ahead"
This reverts commit f695e00078.
* new
* type
* Revert "type"
This reverts commit 2dafa02407.
* default
---------
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
* mici turn signal for c3x
* sp dir
* decouple
* more
* ty
* refactor and slim down
* bigger
---------
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
DM_SIZE=$(python3 -c "from openpilot.common.transformations.model import DM_INPUT_SIZE as s; print(f'{s[0]}x{s[1]}')")
for res in $(python3 -c "from openpilot.common.transformations.camera import _ar_ox_fisheye as a, _os_fisheye as o; print(f'{a.width}x{a.height} {o.width}x{o.height}')"); do
CAM_W=$(echo $res | cut -d x -f1)
CAM_H=$(echo $res | cut -d x -f2)
STRIDE_INFO=$(python3 -c "
import sys
from openpilot.system.camerad.cameras.nv12_info import get_nv12_info
<td>{% if jobs[key]["failures"]|length > 0 %}<details>{% for failure in jobs[key]["failures"] %}<a href="{{ failure['link'] }}">Log for run #{{ failure['run_number'] }}</a><br>{% endfor %}</details>{% else %}{% endif %}</td>
MODEL_SIZE=$(python3 -c "from openpilot.common.transformations.model import MEDMODEL_INPUT_SIZE as s; print(f'{s[0]}x{s[1]}')")
CAMERA_RES=$(python3 -c "from openpilot.common.transformations.camera import _ar_ox_fisheye as a, _os_fisheye as o; print(f'{a.width}x{a.height} {o.width}x{o.height}')")
MODEL_SIZE=$(python3 -c "from openpilot.common.transformations.model import MEDMODEL_INPUT_SIZE as s; print(f'{s[0]}x{s[1]}')")
CAMERA_RES=$(python3 -c "from openpilot.common.transformations.camera import _ar_ox_fisheye as a, _os_fisheye as o; print(f'{a.width}x{a.height} {o.width}x{o.height}')")
for f in "${{ env.MODELS_DIR }}/driving_vision.onnx" "${{ env.MODELS_DIR }}/big_driving_vision.onnx"; do
[ -f "$f" ] && VISION_ONNX="$f" && break
done
POLICY_ONNX=""
for f in "${{ env.MODELS_DIR }}/driving_policy.onnx" "${{ env.MODELS_DIR }}/big_driving_policy.onnx"; do
[ -f "$f" ] && POLICY_ONNX="$f" && break
done
OFF_POLICY_ONNX=""
for f in "${{ env.MODELS_DIR }}/driving_off_policy.onnx" "${{ env.MODELS_DIR }}/big_driving_off_policy.onnx"; do
[ -f "$f" ] && OFF_POLICY_ONNX="$f" && break
done
ON_POLICY_ONNX=""
for f in "${{ env.MODELS_DIR }}/driving_on_policy.onnx" "${{ env.MODELS_DIR }}/big_driving_on_policy.onnx"; do
[ -f "$f" ] && ON_POLICY_ONNX="$f" && break
done
SUPERCOMBO_ONNX=""
for f in "${{ env.MODELS_DIR }}/supercombo.onnx" "${{ env.MODELS_DIR }}/driving_supercombo.onnx" "${{ env.MODELS_DIR }}/big_supercombo.onnx" "${{ env.MODELS_DIR }}/big_driving_supercombo.onnx"; do
[ -f "$f" ] && SUPERCOMBO_ONNX="$f" && break
done
MODEL_TYPE="" ONNX_ARGS="" OUTPUT_NAME=""
if [ -f "$VISION_ONNX" ]; then
ONNX_ARGS="--vision-onnx $VISION_ONNX"
if [ -f "$ON_POLICY_ONNX" ] && [ -f "$OFF_POLICY_ONNX" ]; then
echo "::error::Build succeeded but DM model not found on HF"
exit 1
else
echo "::error::Build run failed with conclusion=$CONCLUSION"
exit 1
fi
fi
done
echo "::error::DM model build did not complete within 30 minutes"
exit 1
env:
GITHUB_TOKEN:${{ secrets.GITHUB_TOKEN }}
- name:Cancel run on failure
if:failure()
run:gh run cancel ${{ github.run_id }}
env:
GITHUB_TOKEN:${{ secrets.GITHUB_TOKEN }}
publish:
concurrency:
# We do a bit of a hack here to avoid canceling the publishing job if a new commit comes in while we're publishing by adding the sha to the group name.
# This means that if multiple commits come in while we're publishing, they will be queued up and publish one after the other.
# Otherwise, if a job is waiting to be published due to environment wait time, it would be canceled by a new commit and restart the wait time.
We use AI tools ourselves, so this isn't an anti-AI stance. The problem is people submitting code, issues, or comments they don't actually understand. AI makes that very easy to do, and it creates real work for reviewers who have to figure out what you meant when you can't explain it yourself.
If you're not going to put effort into understanding and verifying your submission, we're not going to put effort into reviewing it.
## The rule
You are responsible for everything you submit: code, PR descriptions, issues, bug reports, comments.
1. Understand what you submit. If a reviewer asks why you did something, you answer from your own understanding, not by re-prompting. If you can't do that, don't submit it.
2. Test your change. AI gets things wrong all the time. Run it, break it, confirm it actually works.
3. Driving fixes need real evidence. Attach a dongle ID, upload logs, and include segments that show the fix working. A route hash by itself proves nothing.
4. No AI-generated media (images, diagrams, videos) in issues or PRs.
## Disclosure
If AI tools helped you write something, say so. Add an `Assisted-by:` line in your commit message:
```
Assisted-by: GitHub Copilot
Assisted-by: Claude
```
Disclosing won't count against your PR. It helps reviewers know where to look. Hiding it and getting caught will.
## How we review
Reviewers are looking at whether you understand your own change. Can you explain it? Can you respond to feedback without re-prompting? Does your PR description say why you made the change, not just list what changed?
Good code from someone who used AI and understands what they wrote is fine. How you got there doesn't matter as long as you can stand behind it.
## What happens
Submissions that don't meet this bar get closed. If it keeps happening, you get blocked.
## Maintainers
Maintainers use AI at their discretion. They've earned that through sustained contribution and they know the codebase.
<!--- AUTOGENERATED FROM selfdrive/car/CARS_template.md, DO NOT EDIT. --->
<!--- AUTOGENERATED FROM openpilot/selfdrive/car/CARS_template.md, DO NOT EDIT. --->
# Supported Cars
A supported vehicle is one that just works when you install a comma device. All supported cars provide a better experience than any stock system. Supported vehicles reference the US market unless otherwise specified.
@@ -137,19 +138,17 @@ A supported vehicle is one that just works when you install a comma device. All
|Hyundai|Kona 2022-23|Smart Cruise Control (SCC)|openpilot available[<sup>1</sup>](#footnotes)|0 mph|0 mph|[](##)|[](##)|<details><summary>Parts</summary><sub>- 1 Hyundai O connector<br>- 1 OBD-C cable (2 ft)<br>- 1 comma four<br>- 1 comma power v3<br>- 1 harness box<br>- 1 mount<br><a href="https://comma.ai/shop/comma-3x?harness=Hyundai Kona 2022-23">Buy Here</a></sub></details>|||
|Hyundai|Kona Electric 2018-21|Smart Cruise Control (SCC)|openpilot available[<sup>1</sup>](#footnotes)|0 mph|0 mph|[](##)|[](##)|<details><summary>Parts</summary><sub>- 1 Hyundai G connector<br>- 1 OBD-C cable (2 ft)<br>- 1 comma four<br>- 1 comma power v3<br>- 1 harness box<br>- 1 mount<br><a href="https://comma.ai/shop/comma-3x?harness=Hyundai Kona Electric 2018-21">Buy Here</a></sub></details>|||
|Hyundai|Kona Electric 2022-23|Smart Cruise Control (SCC)|openpilot available[<sup>1</sup>](#footnotes)|0 mph|0 mph|[](##)|[](##)|<details><summary>Parts</summary><sub>- 1 Hyundai O connector<br>- 1 OBD-C cable (2 ft)<br>- 1 comma four<br>- 1 comma power v3<br>- 1 harness box<br>- 1 mount<br><a href="https://comma.ai/shop/comma-3x?harness=Hyundai Kona Electric 2022-23">Buy Here</a></sub></details>|||
|Hyundai|Kona Electric (with HDA II, Korea only) 2023|Smart Cruise Control (SCC)|Stock|0 mph|0 mph|[](##)|[](##)|<details><summary>Parts</summary><sub>- 1 Hyundai R connector<br>- 1 OBD-C cable (2 ft)<br>- 1 comma four<br>- 1 comma power v3<br>- 1 harness box<br>- 1 mount<br><a href="https://comma.ai/shop/comma-3x?harness=Hyundai Kona Electric (with HDA II, Korea only) 2023">Buy Here</a></sub></details>|<a href="https://www.youtube.com/watch?v=U2fOCmcQ8hw" target="_blank"><img height="18px" src="assets/icon-youtube.svg"></img></a>||
|Hyundai|Kona Electric Non-SCC 2019|No Smart Cruise Control (Non-SCC)|Stock|0 mph|0 mph|[](##)|[](##)|<details><summary>Parts</summary><sub>- 1 Hyundai G connector<br>- 1 OBD-C cable (2 ft)<br>- 1 comma four<br>- 1 comma power v3<br>- 1 harness box<br>- 1 mount<br><a href="https://comma.ai/shop/comma-3x?harness=Hyundai Kona Electric Non-SCC 2019">Buy Here</a></sub></details>|||
|Hyundai|Kona Electric (with HDA II, Korea only) 2023|Smart Cruise Control (SCC)|Stock|0 mph|0 mph|[](##)|[](##)|<details><summary>Parts</summary><sub>- 1 Hyundai R connector<br>- 1 OBD-C cable (2 ft)<br>- 1 comma four<br>- 1 comma power v3<br>- 1 harness box<br>- 1 mount<br><a href="https://comma.ai/shop/comma-3x?harness=Hyundai Kona Electric (with HDA II, Korea only) 2023">Buy Here</a></sub></details>|<a href="https://www.youtube.com/watch?v=U2fOCmcQ8hw" target="_blank"><img height="18px" src="assets/icon-youtube.svg" /></a>||
|Hyundai|Kona Hybrid 2020|Smart Cruise Control (SCC)|openpilot available[<sup>1</sup>](#footnotes)|0 mph|0 mph|[](##)|[](##)|<details><summary>Parts</summary><sub>- 1 Hyundai I connector<br>- 1 OBD-C cable (2 ft)<br>- 1 comma four<br>- 1 comma power v3<br>- 1 harness box<br>- 1 mount<br><a href="https://comma.ai/shop/comma-3x?harness=Hyundai Kona Hybrid 2020">Buy Here</a></sub></details>|||
|Hyundai|Kona Non-SCC 2019|No Smart Cruise Control (Non-SCC)|Stock|0 mph|0 mph|[](##)|[](##)|<details><summary>Parts</summary><sub>- 1 Hyundai B connector<br>- 1 OBD-C cable (2 ft)<br>- 1 comma four<br>- 1 comma power v3<br>- 1 harness box<br>- 1 mount<br><a href="https://comma.ai/shop/comma-3x?harness=Hyundai Kona Non-SCC 2019">Buy Here</a></sub></details>|||
|Toyota|Mirai 2021|All|openpilot|0 mph|0 mph|[](##)|[](##)|<details><summary>Parts</summary><sub>- 1 OBD-C cable (2 ft)<br>- 1 Toyota A connector<br>- 1 comma four<br>- 1 comma power v3<br>- 1 harness box<br>- 1 mount<br><a href="https://comma.ai/shop/comma-3x?harness=Toyota Mirai 2021">Buy Here</a></sub></details>|||
|Toyota|Prius 2016|Toyota Safety Sense P|Stock|0 mph|0 mph|[](##)|[](##)|<details><summary>Parts</summary><sub>- 1 OBD-C cable (2 ft)<br>- 1 Toyota A connector<br>- 1 comma four<br>- 1 comma power v3<br>- 1 harness box<br>- 1 mount<br><a href="https://comma.ai/shop/comma-3x?harness=Toyota Prius 2016">Buy Here</a></sub></details>|<a href="https://www.youtube.com/watch?v=8zopPJI8XQ0" target="_blank"><img height="18px" src="assets/icon-youtube.svg"></img></a>||
|Toyota|Prius 2017-20|All|Stock|0 mph|0 mph|[](##)|[](##)|<details><summary>Parts</summary><sub>- 1 OBD-C cable (2 ft)<br>- 1 Toyota A connector<br>- 1 comma four<br>- 1 comma power v3<br>- 1 harness box<br>- 1 mount<br><a href="https://comma.ai/shop/comma-3x?harness=Toyota Prius 2017-20">Buy Here</a></sub></details>|<a href="https://www.youtube.com/watch?v=8zopPJI8XQ0" target="_blank"><img height="18px" src="assets/icon-youtube.svg"></img></a>||
|Toyota|Prius 2021-22|All|openpilot|0 mph|0 mph|[](##)|[](##)|<details><summary>Parts</summary><sub>- 1 OBD-C cable (2 ft)<br>- 1 Toyota A connector<br>- 1 comma four<br>- 1 comma power v3<br>- 1 harness box<br>- 1 mount<br><a href="https://comma.ai/shop/comma-3x?harness=Toyota Prius 2021-22">Buy Here</a></sub></details>|<a href="https://www.youtube.com/watch?v=J58TvCpUd4U" target="_blank"><img height="18px" src="assets/icon-youtube.svg"></img></a>||
|Toyota|Prius Prime 2017-20|All|Stock|0 mph|0 mph|[](##)|[](##)|<details><summary>Parts</summary><sub>- 1 OBD-C cable (2 ft)<br>- 1 Toyota A connector<br>- 1 comma four<br>- 1 comma power v3<br>- 1 harness box<br>- 1 mount<br><a href="https://comma.ai/shop/comma-3x?harness=Toyota Prius Prime 2017-20">Buy Here</a></sub></details>|<a href="https://www.youtube.com/watch?v=8zopPJI8XQ0" target="_blank"><img height="18px" src="assets/icon-youtube.svg"></img></a>||
|Toyota|Prius Prime 2021-22|All|openpilot|0 mph|0 mph|[](##)|[](##)|<details><summary>Parts</summary><sub>- 1 OBD-C cable (2 ft)<br>- 1 Toyota A connector<br>- 1 comma four<br>- 1 comma power v3<br>- 1 harness box<br>- 1 mount<br><a href="https://comma.ai/shop/comma-3x?harness=Toyota Prius Prime 2021-22">Buy Here</a></sub></details>|<a href="https://www.youtube.com/watch?v=J58TvCpUd4U" target="_blank"><img height="18px" src="assets/icon-youtube.svg"></img></a>||
|Toyota|Prius 2016|Toyota Safety Sense P|Stock|0 mph|0 mph|[](##)|[](##)|<details><summary>Parts</summary><sub>- 1 OBD-C cable (2 ft)<br>- 1 Toyota A connector<br>- 1 comma four<br>- 1 comma power v3<br>- 1 harness box<br>- 1 mount<br><a href="https://comma.ai/shop/comma-3x?harness=Toyota Prius 2016">Buy Here</a></sub></details>|<a href="https://www.youtube.com/watch?v=8zopPJI8XQ0" target="_blank"><img height="18px" src="assets/icon-youtube.svg" /></a>||
|Toyota|Prius 2017-20|All|Stock|0 mph|0 mph|[](##)|[](##)|<details><summary>Parts</summary><sub>- 1 OBD-C cable (2 ft)<br>- 1 Toyota A connector<br>- 1 comma four<br>- 1 comma power v3<br>- 1 harness box<br>- 1 mount<br><a href="https://comma.ai/shop/comma-3x?harness=Toyota Prius 2017-20">Buy Here</a></sub></details>|<a href="https://www.youtube.com/watch?v=8zopPJI8XQ0" target="_blank"><img height="18px" src="assets/icon-youtube.svg" /></a>||
|Toyota|Prius 2021-22|All|openpilot|0 mph|0 mph|[](##)|[](##)|<details><summary>Parts</summary><sub>- 1 OBD-C cable (2 ft)<br>- 1 Toyota A connector<br>- 1 comma four<br>- 1 comma power v3<br>- 1 harness box<br>- 1 mount<br><a href="https://comma.ai/shop/comma-3x?harness=Toyota Prius 2021-22">Buy Here</a></sub></details>|<a href="https://www.youtube.com/watch?v=J58TvCpUd4U" target="_blank"><img height="18px" src="assets/icon-youtube.svg" /></a>||
|Toyota|Prius Prime 2017-20|All|Stock|0 mph|0 mph|[](##)|[](##)|<details><summary>Parts</summary><sub>- 1 OBD-C cable (2 ft)<br>- 1 Toyota A connector<br>- 1 comma four<br>- 1 comma power v3<br>- 1 harness box<br>- 1 mount<br><a href="https://comma.ai/shop/comma-3x?harness=Toyota Prius Prime 2017-20">Buy Here</a></sub></details>|<a href="https://www.youtube.com/watch?v=8zopPJI8XQ0" target="_blank"><img height="18px" src="assets/icon-youtube.svg" /></a>||
|Toyota|Prius Prime 2021-22|All|openpilot|0 mph|0 mph|[](##)|[](##)|<details><summary>Parts</summary><sub>- 1 OBD-C cable (2 ft)<br>- 1 Toyota A connector<br>- 1 comma four<br>- 1 comma power v3<br>- 1 harness box<br>- 1 mount<br><a href="https://comma.ai/shop/comma-3x?harness=Toyota Prius Prime 2021-22">Buy Here</a></sub></details>|<a href="https://www.youtube.com/watch?v=J58TvCpUd4U" target="_blank"><img height="18px" src="assets/icon-youtube.svg" /></a>||
|Toyota|Prius v 2017|Toyota Safety Sense P|Stock|19 mph|0 mph|[](##)|[](##)|<details><summary>Parts</summary><sub>- 1 OBD-C cable (2 ft)<br>- 1 Toyota A connector<br>- 1 comma four<br>- 1 comma power v3<br>- 1 harness box<br>- 1 mount<br><a href="https://comma.ai/shop/comma-3x?harness=Toyota Prius v 2017">Buy Here</a></sub></details>|||
|Toyota|RAV4 2016|Toyota Safety Sense P|Stock|19 mph|0 mph|[](##)|[](##)|<details><summary>Parts</summary><sub>- 1 OBD-C cable (2 ft)<br>- 1 Toyota A connector<br>- 1 comma four<br>- 1 comma power v3<br>- 1 harness box<br>- 1 mount<br><a href="https://comma.ai/shop/comma-3x?harness=Toyota RAV4 2016">Buy Here</a></sub></details>|||
|Toyota|RAV4 2017-18|All|Stock|19 mph|0 mph|[](##)|[](##)|<details><summary>Parts</summary><sub>- 1 OBD-C cable (2 ft)<br>- 1 Toyota A connector<br>- 1 comma four<br>- 1 comma power v3<br>- 1 harness box<br>- 1 mount<br><a href="https://comma.ai/shop/comma-3x?harness=Toyota RAV4 2017-18">Buy Here</a></sub></details>|||
<sup>1</sup>openpilot Longitudinal Control (Alpha) is available behind a toggle; the toggle is only available in non-release branches such as `devel` or `nightly-dev`. <br />
<sup>1</sup>openpilot Longitudinal Control (Alpha) is available behind a toggle; the toggle is only available in non-release branches such as `nightly-dev`. <br />
<sup>2</sup>Refers only to the Focus Mk4 (C519) available in Europe/China/Taiwan/Australasia, not the Focus Mk3 (C346) in North and South America/Southeast Asia. <br />
<sup>3</sup>See more setup details for <a href="https://github.com/commaai/openpilot/wiki/gm" target="_blank">GM</a>. <br />
<sup>4</sup>2019 Honda Civic 1.6L Diesel Sedan does not have ALC below 12mph. <br />
<sup>5</sup>See more setup details for <a href="https://github.com/commaai/openpilot/wiki/nissan" target="_blank">Nissan</a>. <br />
<sup>6</sup>In the non-US market, openpilot requires the car to come equipped with EyeSight with Lane Keep Assistance. <br />
<sup>7</sup>Enabling longitudinal control (alpha) will disable all EyeSight functionality, including AEB, LDW, and RAB. <br />
<sup>8</sup>Some 2023 model years have HW4. To check which hardware type your vehicle has, look for <b>Autopilot computer</b> under <b>Software -> Additional Vehicle Information</b> on your vehicle's touchscreen. See <a href="https://www.notateslaapp.com/news/2173/how-to-check-if-your-tesla-has-hardware-4-ai4-or-hardware-3">this page</a> for more information. <br />
<sup>9</sup>See more setup details for <a href="https://github.com/commaai/openpilot/wiki/tesla" target="_blank">Tesla</a>. <br />
<sup>10</sup>openpilot operates above 28mph for Camry 4CYL L, 4CYL LE and 4CYL SE which don't have Full-Speed Range Dynamic Radar Cruise Control. <br />
<sup>11</sup>Not including the China market Kamiq, which is based on the (currently) unsupported PQ34 platform. <br />
<sup>12</sup>Refers only to the MQB-based European B8 Passat, not the NMS Passat in the USA/China/Mideast markets. <br />
<sup>13</sup>Some Škoda vehicles are equipped with heated windshields, which are known to block GPS signal needed for some comma four functionality. <br />
<sup>14</sup>Only available for vehicles using a gateway (J533) harness. At this time, vehicles using a camera harness are limited to using stock ACC. <br />
<sup>15</sup>Model-years 2022 and beyond may have a combined CAN gateway and BCM, which is supported by openpilot in software, but doesn't yet have a harness available from the comma store. <br />
<sup>5</sup>Enabling longitudinal control (alpha) will disable all CMBS functionality, including AEB and FCW. <br />
<sup>6</sup>See more setup details for <a href="https://github.com/commaai/openpilot/wiki/nissan" target="_blank">Nissan</a>. <br />
<sup>7</sup>In the non-US market, openpilot requires the car to come equipped with EyeSight with Lane Keep Assistance. <br />
<sup>8</sup>Enabling longitudinal control (alpha) will disable all EyeSight functionality, including AEB, LDW, and RAB. <br />
<sup>9</sup>Model years 2023 and 2024 can have either hardware type, depending on build date and factory. To check which hardware type your vehicle has, look for <b>Autopilot computer</b> under <b>Software -> Additional Vehicle Information</b> on your vehicle's touchscreen. See <a href="https://www.notateslaapp.com/news/2173/how-to-check-if-your-tesla-has-hardware-4-ai4-or-hardware-3">this page</a> for more information. <br />
<sup>10</sup>See more setup details for <a href="https://github.com/commaai/openpilot/wiki/tesla" target="_blank">Tesla</a>. <br />
<sup>11</sup>openpilot operates above 28mph for Camry 4CYL L, 4CYL LE and 4CYL SE which don't have Full-Speed Range Dynamic Radar Cruise Control. <br />
<sup>12</sup>The J533 harness plugs in at the CAN gateway under the dashboard, just above the steering column. More information can be found at <a href="https://docs.howtocomma.com/docs/j533-harness-install" target="_blank">this guide</a>. <br />
<sup>13</sup>Not including the China market Kamiq, which is based on the (currently) unsupported PQ34 platform. <br />
<sup>14</sup>Refers only to the MQB-based European B8 Passat, not the NMS Passat in the USA/China/Mideast markets. <br />
<sup>15</sup>Some Škoda vehicles are equipped with heated windshields, which are known to block GPS signal needed for some comma four functionality. <br />
<sup>16</sup>Only available for vehicles using a gateway (J533) harness. At this time, vehicles using a camera harness are limited to using stock ACC. <br />
<sup>17</sup>Model-years 2022 and beyond may have a combined CAN gateway and BCM, which is supported by openpilot in software, but doesn't yet have a harness available from the comma store. <br />
## Community Maintained Cars
Although they're not upstream, the community has openpilot running on other makes and models. See the 'Community Supported Models' section of each make [on our wiki](https://wiki.comma.ai/).
> sunnypilot follows [commaai/openpilot](https://github.com/commaai/openpilot)'s contributing guidelines. The following applies to all contributions here.
# How to contribute
Our software is open source so you can solve your own problems without needing help from others. And if you solve a problem and are so kind, you can upstream it for the rest of the world to use. Check out our [post about externalization](https://blog.comma.ai/a-2020-theme-externalization/).
@@ -13,13 +15,13 @@ Development is coordinated through [Discord](https://discord.comma.ai) and GitHu
## What contributions are we looking for?
**openpilot's priorities are [safety](SAFETY.md), stability, quality, and features, in that order.**
openpilot is part of comma's mission to *solve self-driving cars while delivering shippable intermediaries*, and all development is towards that goal.
openpilot is part of comma's mission to *solve self-driving cars while delivering shippable intermediaries*, and all development is towards that goal.
### What gets merged?
The probability of a pull request being merged is a function of its value to the project and the effort it will take us to get it merged.
If a PR offers *some* value but will take lots of time to get merged, it will be closed.
Simple, well-tested bug fixes are the easiest to merge, and new features are the hardest to get merged.
Simple, well-tested bug fixes are the easiest to merge, and new features are the hardest to get merged.
@@ -29,17 +31,18 @@ All of these are examples of good PRs:
### What doesn't get merged?
* **style changes**: code is art, and it's up to the author to make it beautiful
* **style changes**: code is art, and it's up to the author to make it beautiful
* **500+ line PRs**: clean it up, break it up into smaller PRs, or both
* **PRs without a clear goal**: every PR must have a singular and clear goal
* **UI design**: we do not have a good review process for this yet
* **New features**: We believe openpilot is mostly feature-complete, and the rest is a matter of refinement and fixing bugs. As a result of this, most feature PRs will be immediately closed, however the beauty of open source is that forks can and do offer features that upstream openpilot doesn't.
* **Negative expected value**: This a class of PRs that makes an improvement, but the risk or validation costs more than the improvement. The risk can be mitigated by first getting a failing test merged.
* **Negative expected value**: This is a class of PRs that makes an improvement, but the risk or validation costs more than the improvement. The risk can be mitigated by first getting a failing test merged.
* **AI-generated contributions**: see our [AI policy](AI_POLICY.md)
### First contribution
[Projects / openpilot bounties](https://github.com/orgs/commaai/projects/26/views/1?pane=info) is the best place to get started and goes in-depth on what's expected when working on a bounty.
There's lot of bounties that don't require a comma 3X or a car.
There are a lot of bounties that don't require a comma four or a car.
## Pull Requests
@@ -58,7 +61,7 @@ A good pull request has all of the following:
* Report bugs in GitHub issues.
* Report driving issues in the `#driving-feedback` Discord channel.
* Consider opting into driver camera uploads to improve the driver monitoring model.
* Consider opting into cabin camera uploads to improve the driver monitoring model.
* Connect your device to Wi-Fi regularly, so that we can pull data for training better driving models.
* Run the `nightly` branch and report issues. This branch is like `master` but it's built just like a release.
* Annotate images in the [comma10k dataset](https://github.com/commaai/comma10k).
@@ -68,6 +71,6 @@ A good pull request has all of the following:
### A guide for forks
In order for your fork's data to be eligible for the training set:
* **Your cereal messaging structs must be [compatible](../cereal#custom-forks)**
* **Your cereal messaging structs must be [compatible](../openpilot/cereal#custom-forks)**
* **The definitions of all the stock messaging structs must not change**: Do not change how any of the fields are set, including everything from `selfdriveState.enabled` to `carState.steeringAngleDeg`. Instead, create your own structs and set them however you'd like.
* **Do not include cars that are not supported in upstream platforms**: Instead, create new opendbc platforms for cars that you'd like to support outside of upstream, even if it's just a trim-level difference.
@@ -52,7 +52,7 @@ Many factors can impact the performance of openpilot DM, causing it to be unable
* Low light conditions, such as driving at night or in dark tunnels.
* Bright light (due to oncoming headlights, direct sunlight, etc.).
* The driver's face is partially or completely outside field of view of the driver facing camera.
* The driver facing camera is obstructed, covered, or damaged.
* The driver's face is partially or completely outside field of view of the cabin camera.
* The cabin camera is obstructed, covered, or damaged.
The list above does not represent an exhaustive list of situations that may interfere with proper operation of openpilot components. A driver should not rely on openpilot DM to assess their level of attention.
@@ -4,8 +4,8 @@ openpilot is an Adaptive Cruise Control (ACC) and Automated Lane Centering (ALC)
Like other ACC and ALC systems, openpilot is a failsafe passive system and it requires the
driver to be alert and to pay attention at all times.
In order to enforce driver alertness, openpilot includes a driver monitoring feature
that alerts the driver when distracted.
To assist the driver in maintaining alertness, openpilot includes a driver monitoring feature
that alerts when it detects driver distraction.
However, even with an attentive driver, we must make further efforts for the system to be
safe. We repeat, **driver alertness is necessary, but not sufficient, for openpilot to be
@@ -35,8 +35,8 @@ For additional safety implementation details, refer to [panda safety model](http
### Forks of openpilot
* Do not disable or nerf [driver monitoring](https://github.com/commaai/openpilot/tree/master/selfdrive/monitoring)
* Do not disable or nerf [excessive actuation checks](https://github.com/commaai/openpilot/tree/master/selfdrive/selfdrived/helpers.py)
* Do not disable or nerf [driver monitoring](https://github.com/commaai/openpilot/tree/master/openpilot/selfdrive/monitoring)
* Do not disable or nerf [excessive actuation checks](https://github.com/commaai/openpilot/tree/master/openpilot/selfdrive/selfdrived/helpers.py)
* If your fork modifies any of the code in `opendbc/safety/`:
* your fork cannot use the openpilot trademark
* your fork must preserve the full [safety test suite](https://github.com/commaai/opendbc/tree/master/opendbc/safety/tests) and all tests must pass, including any new coverage required by the fork's changes
A model port is a port of openpilot to a new car model within an already supported brand. Model ports are easier than brand ports because the car's existing APIs are already known.
Here's an example of one: https://github.com/commaai/openpilot/pull/30672/.
* **onroad**: openpilot's system state while ignition is on
* **offroad**: openpilot's system state while ignition is off
* **route**: a route is a recording of an onroad session
* **segment**: routes are split into one minute chunks called segments.
* **comma connect**: the web viewer for all your routes; check it out at [connect.comma.ai](https://connect.comma.ai).
* **panda**: this is the secondary processor on the device that implements the functional safety and directly talks to the car over CAN. See the [panda repo](https://github.com/commaai/panda).
* **comma 3X**: the latest hardware by comma.ai for running openpilot. more info at [comma.ai/shop](https://comma.ai/shop).
openpilot records routes in one minute chunks called segments. A route starts on the rising edge of ignition and ends on the falling edge.
Check out our [Python library](https://github.com/commaai/openpilot/blob/master/tools/lib/logreader.py) for reading openpilot logs. Also checkout our [tools](https://github.com/commaai/openpilot/tree/master/tools) to replay and view your data. These are the same tools we use to debug and develop openpilot.
Check out our [Python library](https://github.com/commaai/openpilot/blob/master/openpilot/tools/lib/logreader.py) for reading openpilot logs. Also checkout our [tools](https://github.com/commaai/openpilot/tree/master/openpilot/tools) to replay and view your data. These are the same tools we use to debug and develop openpilot.
For each segment, openpilot records the following log types:
## rlog.bz2
## rlog.zst
rlogs contain all the messages passed amongst openpilot's processes. See [cereal/services.py](https://github.com/commaai/cereal/blob/master/services.py) for a list of all the logged services. They're a bzip2 archive of the serialized capnproto messages.
rlogs contain all the messages passed amongst openpilot's processes. See [openpilot/cereal/services.py](https://github.com/commaai/openpilot/blob/master/openpilot/cereal/services.py) for a list of all the logged services. They're a zstd archive of the serialized [Cap’n Proto](https://capnproto.org/) messages.
## {f,e,d}camera.hevc
## camera video files
Each camera stream is H.265 encoded and written to its respective file.
* `fcamera.hevc` is the road camera
* `fcamera.hevc` is the narrow road camera (the main forward camera)
* `ecamera.hevc` is the wide road camera
* `dcamera.hevc` is the driver camera
* `dcamera.hevc` is the cabin camera
## qlog.bz2 & qcamera.ts
qlogs are a decimated subset of the rlogs. Check out [cereal/services.py](https://github.com/commaai/cereal/blob/master/services.py) for the decimation.
## qlog.zst & qcamera.ts
qlogs are a decimated subset of the rlogs. Check out [openpilot/cereal/services.py](https://github.com/commaai/openpilot/blob/master/openpilot/cereal/services.py) for the decimation.
qcameras are H.264 encoded, lower res versions of the fcamera.hevc. The video shown in [comma connect](https://connect.comma.ai/) is from the qcameras.
qlogs and qcameras are designed to be small enough to upload instantly on slow internet and store forever, yet useful enough for most analysis and debugging.
qlogs and qcameras are designed to be small enough to upload instantly on slow internet, yet useful enough for most analysis and debugging.
[openpilot](http://github.com/commaai/openpilot) is an open source driver assistance system. Currently, openpilot performs the functions of Adaptive Cruise Control (ACC), Automated Lane Centering (ALC), Forward Collision Warning (FCW), and Lane Departure Warning (LDW) for a growing variety of [supported car makes, models, and model years](https://github.com/commaai/openpilot/blob/master/docs/CARS.md). In addition, while openpilot is engaged, a camera-based Driver Monitoring (DM) feature alerts distracted and asleep drivers. See more about [the vehicle integration](https://github.com/commaai/openpilot/blob/master/docs/INTEGRATION.md) and [limitations](https://github.com/commaai/openpilot/blob/master/docs/LIMITATIONS.md).
## How do I use it?
openpilot is designed to be used on the comma 3X.
## How does it work?
In short, openpilot uses the car's existing APIs for the built-in [ADAS](https://en.wikipedia.org/wiki/Advanced_driver-assistance_system) system and simply provides better acceleration, braking, and steering inputs than the stock system.
@@ -8,7 +8,7 @@ A car port enables openpilot support on a particular car. Each car model openpil
# Structure of a car port
Virtually all car-specific code is contained in two other repositories: [opendbc](https://github.com/commaai/opendbc) and [panda](https://github.com/commaai/panda).
All car-specific code is contained in the [opendbc](https://github.com/commaai/opendbc) project.
## opendbc
@@ -21,19 +21,31 @@ Each car brand is supported by a standard interface structure in `opendbc/car/[b
* `values.py`: Limits for actuation, general constants for cars, and supported car documentation
* `radar_interface.py`: Interface for parsing radar points from the car, if applicable
* `opendbc/safety/tests/test_[brand].py`: Brand-specific safety CI tests
## openpilot
For historical reasons, openpilot still contains a small amount of car-specific logic. This will eventually be migrated to opendbc or otherwise removed.
[Jason Young](https://github.com/jyoung8607) gave a talk at COMMA_CON with an overview of the car porting process. The talk is available on YouTube:
https://www.youtube.com/watch?v=XxPS5TpTUnI
## Brand Port
A brand port is a port of openpilot to a substantially new car brand or platform within a brand.
Here's an example of one: https://github.com/commaai/openpilot/pull/23331.
## Model Port
A model port is a port of openpilot to a new car model within an already supported brand. Model ports are easier than brand ports because the car's existing APIs are already known.
Here's an example of one: https://github.com/commaai/openpilot/pull/30672/.
A comma 3X is a normal [Linux](https://github.com/commaai/agnos-builder) computer that exposes [SSH](https://wiki.archlinux.org/title/Secure_Shell) and a [serial console](https://wiki.archlinux.org/title/Working_with_the_serial_console).
A comma device is a normal [Linux](https://github.com/commaai/agnos-builder) computer that exposes [SSH](https://wiki.archlinux.org/title/Secure_Shell) and a [serial console](https://wiki.archlinux.org/title/Working_with_the_serial_console).
## Serial Console
On both the comma three and 3X, the serial console is accessible from the main OBD-C port.
Connect the comma 3X to your computer with a normal USB C cable, or use a [comma serial](https://comma.ai/shop/comma-serial) for steady 12V power.
On the comma 3X, the serial console is accessible from the main OBD-C port, forwarded through the panda.
Access it using `panda/scripts/som_debug.sh`.
On the comma three, the serial console is exposed through a UART-to-USB chip, and `tools/scripts/serial.sh` can be used to connect.
comma four also exposes a serial console, albeit through an internal debug connector. Dedicated debug hardware coming soon to the comma shop.
On the comma 3X, the serial console is accessible through the [panda](https://github.com/commaai/panda) using the `panda/tests/som_debug.sh` script.
Login to the default user with:
* Username: `comma`
* Password: `comma`
@@ -25,7 +25,7 @@ In order to SSH into your device, you'll need a GitHub account with SSH keys. Se
* Port: `22`
Here's an example command for connecting to your device using its tethered connection:<br />
`ssh comma@192.168.43.1`
`ssh comma@192.168.43.1 -i ~/.ssh/my_github_key`
For doing development work on device, it's recommended to use [SSH agent forwarding](https://docs.github.com/en/developers/overview/using-ssh-agent-forwarding).
@@ -45,7 +45,7 @@ In order to use ADB on your device, you'll need to perform the following steps u
* Here's an example command for connecting to your device using its tethered connection: `adb connect 192.168.43.1:5555`
> [!NOTE]
> The default port for ADB is 5555 on the comma 3X.
> The default port for ADB is 5555.
For more info on ADB, see the [Android Debug Bridge (ADB) documentation](https://developer.android.com/tools/adb).
@@ -55,7 +55,7 @@ The public keys are only fetched from your GitHub account once. In order to upda
The `id_rsa` key in this directory only works while your device is in the setup state with no software installed. After installation, that default key will be removed.
#### ssh.comma.ai proxy
## ssh.comma.ai proxy
With a [comma prime subscription](https://comma.ai/connect), you can SSH into your comma device from anywhere.
@@ -72,7 +72,7 @@ Change `COLORS.white` to make it **blue** instead of white. A nice soft blue is
After making changes, re-run the UI to see your new UI:
```bash
./selfdrive/ui/ui.py
./openpilot/selfdrive/ui/ui.py
```

Some files were not shown because too many files have changed in this diff
Show More
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.