Add "Use Konik instead of comma connect" toggle#136
Open
dirkpetersen wants to merge 1 commit into
Open
Conversation
New optional toggle (BPUseKonik, default OFF) that points the device's backend at Konik (stable.konik.ai) instead of comma connect. When enabled, launch_env.sh exports API_HOST=https://api.konik.ai and ATHENA_HOST=wss://athena.konik.ai; openpilot already reads these env vars everywhere it talks to the backend (common/api/comma_connect.py, system/athena/athenad.py, registration, uploader), so no other code changes are needed. Unset/OFF keeps the stock comma defaults exactly byte-for-byte. The pairing dialog (both comma 3X / TICI and comma 4 / mici) also points its QR code and on-screen instructions at stable.konik.ai when the toggle is on, so users pair on the right site. Takes effect after a reboot; the user then re-pairs at stable.konik.ai. The toggle is added to both the TICI and mici BluePilot settings. Registration / DongleId is intentionally left untouched so the switch stays reversible.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Adds an optional BluePilot setting, Use Konik instead of comma connect (
BPUseKonik, default OFF), that points the device's backend at Konik instead of comma connect. Works on both comma 3X (TICI) and comma 4 (mici).How
openpilot already reads
API_HOSTandATHENA_HOSTfrom the environment with comma defaults, and every backend consumer (registration, uploader, athena websocket, prime/firehose) inherits from those two. When the toggle is on,launch_env.shexports:API_HOST=https://api.konik.aiATHENA_HOST=wss://athena.konik.aiThat's the same switch Konik's docs describe (editing the launch script), just driven by a toggle — no changes to the connectivity code. With the toggle off/unset, behavior is byte-for-byte stock comma.
The pairing dialog (TICI + mici) also points its QR code and on-screen instructions at
stable.konik.aiwhen the toggle is on, so users pair on the right site.Files
common/params_keys.h— declareBPUseKonik(BOOL, default0)launch_env.sh— export the Konik hosts when the toggle is onselfdrive/ui/bp/layouts/settings/bluepilot.py— toggle in the TICI settings (System section)selfdrive/ui/bp/mici/layouts/settings/bluepilot.py— toggle in the mici settingsselfdrive/ui/widgets/pairing_dialog.py— QR + instructions use stable.konik.ai when enabled (TICI)selfdrive/ui/mici/widgets/pairing_dialog.py— QR + "pair with Konik" label when enabled (mici)Behavior
rm DongleId; doing that from a settings toggle would be destructive/irreversible, so it's left to the user.)Enabling this sends routes/location/telemetry to a third-party server; the toggle description says so.
Testing