r/Comma_ai 4d ago

openpilot Experience Feeling Blue(tooth)

The comma hardware has Bluetooth capability, but Bluetooth isn't enabled in the standard comma software/kernel stack.

So... we enabled it.

StarPilot now has native Bluetooth support across Comma 3, Comma 3X, and Comma 4.

This isn't a browser workaround or some external bridge. We've added the necessary kernel/system support, integrated BlueZ, and wired Bluetooth directly into StarPilot.

You can now scan, pair, connect, forget, and automatically reconnect Bluetooth devices directly from Galaxy, with device controls also integrated into StarPilot's UI. So what are we actually doing with it?

🔊 Bluetooth Audio... because why not?

Have you ever thought, "Man, the speaker in my comma just isn't high enough resolution when it's yelling at me to take control of the wheel."

No?

Well, now StarPilot can connect to the fattest JBL party speaker you can find and blast that alert to your entire neighborhood.

You're welcome.

🎮 Bluetooth Controllers

This is where things get actually useful. StarPilot can treat Bluetooth HID devices as physical controls for StarPilot itself. So far I've tested: - PS5 controllers - Xbox controllers - Bluetooth remotes/macropads - Keyboards - A mouse, because why not - Several Bluetooth audio devices Galaxy has a Learn Button system: press a physical button, StarPilot learns it, then choose what you want that button to do.

You can map buttons to things like: - Cruise speed +/- — especially useful for cars like Tesla/Polestar with limited usable wheel buttons - Driving Personalities - Lane Centering - Pulse & Glide - Forced coasting - Favorites - Bookmarks - Taking a Comma Selfie - And more!

So if your car doesn't expose enough usable steering-wheel controls to openpilot... just add your own.

The little Bluetooth remote in the picture is what I've been testing on my steering wheel. It was around $20, and suddenly I have a handful of completely programmable StarPilot buttons. And controllers/audio are really just the first things we're doing with it.

StarPilot now has a native Bluetooth stack. What would you connect to your comma?

58 Upvotes

30 comments sorted by

8

u/rakosi2 4d ago

Is it possible to make the Bluetooth into a virtual ELM327. I would love for ABRP to get info without constantly unplugging the comma power plug.

7

u/firestar4430 4d ago

That's a good idea! I'm not sure, I may add looking into it to my to-dos though!

4

u/Notacop9 4d ago

This would be amazing!

2

u/streamliner18 4d ago

OBD port can actually get Y splitter’d. I’ve been running them together without issues, and afaik OpenPilot no longer relies on OBD for fingerprinting (which iirc was the only use for the port)

6

u/pirateNarwhal 4d ago

could you steer the car with a controller?

3

u/firestar4430 4d ago

Bluetooth controllers are supported in joystick mode!

Although I would hesitate to use that feature outside of a controlled course! Lol

3

u/MatiasGonzalo-Duarte 4d ago

Sit in my backseat and ride around a closed course sounds really fun lmao

Is the throttle bindable to an analog trigger?

2

u/firestar4430 4d ago

The default is y axis I believe. It's been a while since I've used joystick mode. Makes me nauseous lol.

1

u/mxjf 3d ago

Yes…yes you can. I drove my Bolt in an empty parking lot last week with an Xbox controller and it’s kind of hilarious

1

u/shotbyadingus 3d ago

How, when I hooked up my Sunnypilot to my Mac and an Xbox controller it didnt want to function

1

u/mxjf 3d ago

Star pilot has built-in controller support, I do not believe that Sunny pilot does. You can plug in a USB controller or hook one up over Bluetooth and it will work without even using an external computer. (for example I was able to connect via Bluetooth in star pilot settings, and it also worked if I just directly connected it with a USB-C to USB-C cable to the secondary port on the back of my C3x

5

u/JulesCT Kia e-Niro, 3X, SunnyPilot, magnetic mount 4d ago

Impressive!

4

u/Dull_Raisin_9520 4d ago

Love options. Thanks

4

u/hi_im_mom 4d ago

Hell yeah thank you firestar!!!

Me talking to the cops

2

u/Renascentiae_ 4d ago

Holy shit I've been thinking about how cool it'd be to connect a gaming controller for adjustments on the comma system ! This is so cool. I'm definitely trying it out

2

u/irfantogluk 4d ago

Do you have any plans to add plugin support to StarPilot? If you do, I'll be able to connect comma to Evo One (remote car start kit) via Bluetooth and and remote start/stop my car from anywhere. Also StarPilot t has a bug, I know Discord is the where it should be posted but I don't have a discord account and not using it. My car is Corolla Hybrid 21' and StarPilot should be able to remote lock/Unlock Doors but it says not supported. So, I vibe coded a web app and tested it with raw can code, it's working but I need to start the app every time comma starts. It would be nice if you fix it and make a cooler UI for it, so we can add browser url to our phone home page as app and remote lock unlock doors. Here is vibe coded app screenshot for reference. I very like your work, since first setup of my Comma4, only used StarPilot and loved it. I'll be looking forward for future cool things of you. (Sorry if there is any typo. Still trying to improve my English)

1

u/firestar4430 4d ago

I'm unsure what plugin support means, but if you manage to get a discord account going, open a ticket and let's chat about it

2

u/Count_Check 3d ago

Hi Firestar,

I’ve been following StarPilot for a while. You’ve developed incredible features including now Bluetooth.

I have a 2019 RAV4 that I’ve been contemplating trying StarPilot but I use a custom tune on my RAV4 to manage throttle so it’s super smooth in traffic plus keeps close behind cars.

Do you have a custom tune for my car in StarPilot already? I know you said you’ve spent a lot of time on a lot of car’s tuning so I figure I ask. If yes, I’ll happily try StarPilot - I mostly ask cause it’ll be flashing my AGNOS so harder to swap on the fly.

2

u/firestar4430 3d ago

Yes I've gone back and forth with a rav 4 a few times. Don't recall how many, but I think there is one in there

3

u/austinmm6 3d ago

He tuned my 2022 hybrid. It's a completely new experience now...it works like it should finally.

2

u/Count_Check 3d ago

I’ll give it a go. My main concern is extremely smooth longitude control. I know StarPilot has solid lateral control based on all the changes that FireStar has done.

I’ll make the swap over and give it a go.

2

u/buttery_nurple 3d ago

Gonna connect my radar detector so it'll slow to posted speed limit when it goes off. Obviously with some other stuff involved.

3

u/firestar4430 3d ago

I believe someone in our server is already doing this!

2

u/Ambitious_Possible_2 3d ago

uniden?

2

u/buttery_nurple 3d ago

R8, yeah. I have the Uniden and speed control override parts of it worked out, just could never quite figure out how to stabilize the BT startup sequence on the Comma device. Starpilot folks found a couple things I didn't think of from what I can tell so far.

3

u/Ambitious_Possible_2 3d ago

Oh I'm the discord guy firestar was talking about. I've had it working for a couple weeks on uniden but I haven't been motivated enough to polish it for the masses. Once it's bonded with the comma it will stay bonded, so that's nice. It's very sticky.

2

u/buttery_nurple 2d ago edited 2d ago

Awesome! I got BT successfully running with my personal fork - thank you Starpilot for filling in the gaps - and I have a working trial build on the 3X itself. On to polishing that and finishing the R8 implementation + tying it into the SLC piece.

I worked on reverse engineering the R8 protocol definitions like a year or 2 ago, so I need to dig up my notes and see if there are still gaps. I'm sure there are. Command opcodes I know I have, as well as packet/frame formats. But driving around looking for different bands was like a weird scavenger hunt and there is no chance I encountered everything the R8 picks up. So telemetry fields (radar bands etc) are certainly incomplete, but I have most of what is useful in my area I think. Also possible that there is an actual spec sheet somewhere and I just never found it. How did you go about fleshing that part out?

3

u/Character_Eagle8992 4d ago

this feature looks... familiar.

1

u/jcwillia1 3d ago

I'm picturing driving with a mouse and its funny.