Show TeslaMate data to your AWTRIX 3 flashed Ulanzi TC001 Smart Pixel Clock.
Show distance from home.
In case you defined geofence, it will be shown instead.
See battery SOC of your car.
You can choose between rated and estimated battery range.
See the charge power if your car is charging.
See the car's inside temperature (red icon).
See the car's outside temperature (blue icon).
If there is a new Update for your Tesla, you'll get notified for which car (display name) and which version is installed and which new version is available.
You need a device that can be flashed with AWTRIX 3. Right now this is the Ulanzi TC001 Smart Pixel Clock. Flashing instructions can be found here.
I have it plugged to the wall with a 2 amps adapter (something like this). I also have plugged a timer (something like this) in between to charge and discharge the TC001 internal battery. So it does not keep fully charged over time.
You can also use DIY hardware. Please refer to the website of the AWTRIX 3 maintainer.
You need already set up and running:
- Teslamate (https://docs.teslamate.org/docs/installation/docker)
- AWTRIX 3 flashed device (https://blueforcer.github.io/awtrix3/)
- MQTT broker like Mosquitto (https://mosquitto.org/)
- Mode-RED (https://nodered.org/)
- If you have a standard installation of TeslaMade, Mosquitto MQTT is already running.
- You should now see TeslaMate publishing information to MQTT. You may use something like "MQTT Explorer" (https://mqtt-explorer.com/) to connect to your MQTT broker and check if you see "teslamate" topics.
- Connect the AWTRIX device to your MQTT server by going to the IP adresss of the device and choose "MQTT" in menu. Enter MQTT information and remember the "prefix". You'll need it later in the Node-RED flow.
- You should now see the AWTRIX device publishing information to MQTT. Check for the "prefix" topic.
- Download the JSON file and import it to Node-RED by clicking the burger menu and choose "import".
- Change the variable "awtrix_prefix" in the "vars" node to the MQTT topic of your AWTRIX device (remember the "prefix").
- Change variables for your home coordinates ("home_longitude", "home latitude") in "vars" node for distance calculation.
- Also change the MQTT server settings in Node-RED to your MQTT server (see right side settings icon "MQTT"). Or delete it if you already have one configured for other flows.
- Click "deploy" to save everything and see it running.
- Node-RED will now write the apps to your AWTRIX device (see "custom" folder) and the apps will show up.
Download all icons used by the flow to your AWTRIX device by going to the IP address of the device and choose "Icons" in menu. Download all icons by using the icon ID. You can find all icon IDs in the "Readme.1st" node of the already imported flow.
Now all apps will have an icon.
You can set device settings in "config" node and also deaktivate standard AWTRIX apps.
Feel free to change the imported flow to your own needs. You may want to add a 2nd car. You may also change the icons. Check the "Readme.1st" node for further information. - Enjoy it. :-)
In case I update the flow due to calculation changes or fixing bugs, you need to import the whole flow again to Node-RED. It will automatically import as a new flow, so you won't loose your mods. You need to check on your own what has been changed or transfer your mods.
Distance calculation is taken from Jörg Hofmann.
- Maybe old information will be shown before new data is pulled from the MQTT broker during startup of the AWTRIX device. This seems to be due to caching or the device or Node-RED does not recognize new data. This will need a few minutes then.
- As the MQTT broker is the service in between, everything relies on MQTT. If there is no new data pushed from other systems (in this case TeslaMate) to MQTT, the device will not show the information anymore after a few times because Node-RED will only pull new data. - This can be fixed with an "inject" node which triggers to push the app data again to MQTT for the AWTRIX device. See "batterySocCar1" for reference.
- Yet I did not find out how to cope with changed MQTT data that Node-RED misses. Please let me know if you have a solution.
- Distance calculation does give direkt distance and not distance on the road.
- Change "vars" node to "config" node
- Add more parameters to config node
- Move all AWTRIX settings to config node
- Initial version