ha-pitboss
ha-pitboss copied to clipboard
Wifi Support
Checklist
- [X] I have filled out the template to the best of my ability.
- [X] This only contains 1 feature request (if you have multiple feature requests, open one feature request for each feature request).
- [X] This issue is not a duplicate feature request of previous feature requests.
Is your feature request related to a problem? Please describe.
Do you plan to add wifi support?
Describe the solution you'd like
Add wifi support. Not practical to use bluetooth for grill location
Describe alternatives you've considered
N/A
Additional context
N/A
I have a partial implementation of the WebSocket protocol, but it's been too cold to run my smoker lately so I haven't been able to finish putting it through testing.
I'm happy to test if you want share :)
Ditto. I’m in central Texas and have smoked 4 times in the last 3 weeks. And I’ve done web socket programming.
https://github.com/dknowles2/pytboss/compare/main...websocket has the library changes necessary if anyone wants to poke at it to verify correctness.
@dknowles2 I've been reading the wss implementation. I can't find where the unique grill_id is determined. I'm assuming is not the grill "model" id you get from their rest API that lists all the grills/commands. Is this something you've solved or should I break out Wireshark to figure mine out?
@burundiocibu If you open the PitBoss app and go to the "Edit Grill" screen, the Grill ID should be listed there. It's also the same name that's advertised over Bluetooth.
I'd also advise not to post your grill id anywhere, as the WebSocket protocol is totally unauthenticated unless you've set a grill password through the app. (I'm working on adding support to the pytboss library for that right now)
@dknowles2 Thanks a ton. You are doing some awesome reverse engineering of this!
I pushed a preview release (2025.1.0b4) that changes the transport to use WiFi instead of bluetooth. You can install it through HACS if you request to download a specific version
Please give it a try and let me know if it makes things better. My testing earlier in the week (before the temperature dropped again here) showed that the WiFi connection wasn't very reliable either. I suspect there's some instability in the PitBoss cloud service, because I was seeing the same unreliability through the iOS app.
Updated to 2025.1.0b4. I don't know what's happening. Integration won't start anymore. Error "Failed setup, will retry: Grill unavailable". I can't find anything in HA logs about pitboss.
@TTLucian
Updated to 2025.1.0b4. I don't know what's happening. Integration won't start anymore. Error "Failed setup, will retry: Grill unavailable". I can't find anything in HA logs about pitboss.
I got it working last night. I removed the grill since it was still on the ble integration and it prompted me for the grill id. Seems you need to remove the grill then add it back if you initially had it via ble
That's the first thing I tried. It gets discovered but the integration doesn't start. I've also tried entering the device id but it doesn't work ("already_in_progress"). I've downgraded to 2024.10.1 and it works like before, via bluetooth.
I've finally got it to connect on WiFi. Only works if the grill is actually running. If the grill is off, the integration fails to load. It doesn't log any errors. Also, connection drops and it doesn't work anymore until I restart HA. Bluetooth connection is more reliable, if not also spotty, but when it drops I can restore it by reloading the integration or rebooting the BLE proxy.
So unsure if it was my Wifi, but I will agree the BLE was more consistent. This time with Wifi I had to completely remove the device and add it again because it was stuck on initializing. If it happens again I will try and log and share. Currently it is working fine and reporting after readding the device.
@Flameancer is your grill connected and reporting on WiFi when turned off?
Only works if the grill is actually running. If the grill is off, the integration fails to load.
Yes, there's no state stored on the PitBoss servers. The "WiFi" protocol is really just a publish/subscribe service, where the grill/smoker will publish updates (sent to the PitBoss cloud servers) and then a client can subscribe to those updates. This means the grill/smoker must be turned on for it to work. I can make this more clear in the integration setup phase.
It doesn't log any errors.
That's interesting. It should at least log some sort of timeout error. I may still have it at DEBUG logging level.
Also, connection drops and it doesn't work anymore until I restart HA.
Yeah, there's a bug somewhere that's causing an old connection to get leaked which prevents integration reloads and client reconnects from working correctly. I haven't figured it out yet, and haven't had time to look at this lately.
It seems that WiFi is a bit of a downgrade in terms of functionality. I think we should stick to bluetooth (even though there are still issues). Setting up a ble proxy is pretty simple. And having temperature updates while the grill is off is very useful when resting meats 😃.
I agree with @TTLucian, the wifi functionality might be more “stable” than Bluetooth but I’ve had no issues with BLE and the various proxies I have set up. Having to depend on PitBoss cloud/internet is a downgrade in terms of functionality imo.
I think something in the integration configuration to choose BLE or WiFi would provide the best of both worlds.