-
Notifications
You must be signed in to change notification settings - Fork 26
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Tesla vehicle command over BLE #2630
Comments
That's definitely correct. We can make use of a proxy to keep sending commands but there's a major issue : Tesla introduced a cap on the number of commands that can be sent per car each day. For those of us who'd like to optimize their solar power production by making use of commands like start/stop charging and set charge amp, this is a big limitation. |
Another good reason to why just use BLE, as it is local directly to the car, not through any of Teslas servers. Here is a project using python: https://github.com/kaedenbrinkman/PyTeslaBLE |
Someone should just make a Home Assistant custom component out of it, and just use ESPHome's |
Someone should indeed. Question is who's capable and willing to ? I'm currently reading on the topic, and found some interesting resources on the subject. The question now is how do we convert this into an esphome module/integration (not even sure how to call it) ? For now, it's beyond my knowledge. Not sure ChatGPT will know much about this either. |
Definitely would like to have this, for exactly the same reason of controlling charging amps to make use of solar power. |
This is quite fresh and new, but it's working. https://github.com/iainbullock/tesla_ble_mqtt_docker |
Wow! Nice find! I was hoping to get it work with an ESP32 (for its low power consumption) and place it around the car, but a r-Pi is fine as well, at least for now. |
Yes it's up and running. The number of commands is limited and there are minor issues for now, but I guess the hardest part is done (adding the key to the vehicule was painless, and commands are received well). I wrote a tutorial to set this up (doc is clear but I think some users will have difficulties), use your browser to translate to english: https://forum.hacf.fr/t/envoyer-des-commandes-a-sa-tesla-via-mqtt-ble/43348. Esphome support would be nice but this is out of my reach. |
Thanks! I'll give it a try later today after work. What do you actually mean by "the number of commands is limited"? |
At this stage, you can only :
There's no limit on the amount of commands you can send (poor choice of words in my previous message sorry). More commands can be added, but from what I've understood the author is on holiday for now. As for the charge current issue, it's under scrutiny. I'm confident it'll be fixed. |
Aha got it. Setting charging current is my urgent need at the moment so that's fine. |
Some WIP here as well: https://github.com/robin-thoni/tesla-ble-esphome |
So for this to work you just need an ESP 32 whatever setup in ESPhome, I mean it does make it local, so that is good, my biggest thing I want to do is know if it is charging and set the temperature to go on in the morning or when I'm leaving. Is that possible with this eventually? |
Hi there We will merge with this one as well https://github.com/iainbullock/tesla_ble_mqtt_docker Today the HA Addon is working, relatively stable, ans brings you command buttons to operate your solar charge, and all the others (AC, windows, trunk, honk, ...). It also implements a presence scanner. But not capability yet to read car values. This is fairly new so moving quickly. It can be used as is in home assistant using built in bluetooth (eg. on RPi) or can be deployed as standalone docker. It then populates MQTT entities. Please come and comment there to make thing progress. In the next steps we have: bluetooth proxy (esp)... It would make a lot of sense to empack different variants in the same place (python variants, esp standalone, ...) |
Hey guys, here's a working demo (with sound) (video has to be <10Mb, so shitty quality): tesla-ble-watchy-demo.mp4My repo is up to date if you want to test, with instructions in the README |
That's awesome! 👍 |
Super nice yes 👍
Le ven. 5 juil. 2024, 18:03, mr-p666 ***@***.***> a écrit :
… That's awesome! 👍
—
Reply to this email directly, view it on GitHub
<#2630 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AASFC4JL7VA3V75BRJNN3R3ZK27VBAVCNFSM6AAAAABD6UJBLCVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEMJRGEYTKMJSHA>
.
You are receiving this because you commented.Message ID:
***@***.***>
|
It will be nice if there some instruction how to use EspHome add-on in HA to program an ESP. |
That's out of scope. There's already the official doc for this.
I'm using HA |
@andig and @robin-thoni, ERROR 2024/07/14 17:34:09 max charge current 4A: Post "http://192.168.178.xxx:8080/api/1/vehicles/XX/command/set_charging_amps": dial tcp 192.168.178.xx:8080: connect: connection refused I stacked first with similar issue in #14616 and after many restart. ping 192.168.178.xx Pinging 192.168.178.xx with 32 bytes of data: |
I'm not sure what you're trying to do, since I've never used evcc. The only thing I can tell you is that setting the max current charge limit is currently not supported in tesla-ble-esphome, as it's not part of VCSEC, which is the only supported component at the moment |
I've added support for |
Good job! Can't wait to test this! |
Q for those using RPi with a Tesla: how well does it work for you? I am able to hang and crash a RPi with the BLE traffic, about once per day or two. It's not really usable. Happening with both RPi4 and Zero 2 W. I'm now looking into using ESP32, because that one can at least restart if it hangs... |
when it works it works really well. But I have to restart the raspberry once per week because of error 429. I don't know whether it is evcc or the ble proxy |
tes
Describe the problem you have/What new integration you would like
Support for local control of Tesla vehicle. Send commands to the car (i.e unlock/lock, start charge, set charge amps).
Teslas repo: https://github.com/teslamotors/vehicle-command (everything below "Using the HTTP proxy" is not necessary for local BLE control).
Commands over BLE: https://github.com/teslamotors/vehicle-command/tree/main/cmd/tesla-control
Please describe your use case for this integration and alternatives you've tried:
ESP in garage, connected to vehicle over BLE as well as local wifi. Sending commands to ESP over MQTT/HA to start/stop charging and set charge amp.
Was using Tesla "node" in nodered earlier, but Tesla changed their API, so it no longer works, with little hope for fixing (https://github.com/onokje/node-red-contrib-tesla).
Local control over BLE also bypasses the requirements for internet and the use of Teslas API.
Additional context
Gathering information from the car from Teslas API is not as strict as controlling the car. So getting info from the car over BLE is not necessary, or possible I think.
Teslamate still works for logging car, also this is a plus, since logging also works on trips, outside of BLE/wifi range.
Needs to control the car elsewhere than garage/BLE coverage may just as well be done through the Tesla app.
The text was updated successfully, but these errors were encountered: