Skip to content

Commit

Permalink
Merge pull request #85 from helmo/patch-1-docs
Browse files Browse the repository at this point in the history
Update docs
  • Loading branch information
yoziru authored Dec 7, 2024
2 parents f98305a + baa7b46 commit c20ba5d
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 12 deletions.
16 changes: 8 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ Tested with M5Stack NanoC6 and Tesla firmwares 2024.26.3.1.
- [x] Doors locked / unlocked
- [x] User present / not present
- [x] Charging flap open / closed (only when vehicle is awake)
- [x] BLE signal strength
- [x] BLE signal strength

## Usage

Expand All @@ -33,10 +33,10 @@ Tested with M5Stack NanoC6 and Tesla firmwares 2024.26.3.1.
### Finding the BLE MAC address of your vehicle

1. Copy and rename `secrets.yaml.example` to `secrets.yaml` and update it with your WiFi credentials (`wifi_ssid` and `wifi_password`) and vehicle VIN (`tesla_vin`).
1. Enable the `tesla_ble_listener` package in `packages/base.yml` and build the firmware.
1. Flash the firmware to your ESP32 device.
1. Open the ESPHome logs in Home Assistant andto wake it up. watch for the "Found Tesla vehicle" message, which will contain the BLE MAC address of your vehicle.
> Note: The vehicle must be in range and awake for the BLE MAC address to be discovered. If the vehicle is not awake, open the Tesla app and run any command
1. Enable the `tesla_ble_listener` package in `packages/base.yml` by uncommenting the `listener: !include listener.yml` line.
1. Build and flash the firmware to your ESP32 device. See the 'Building and flashing ESP32 firmware' section below.
1. Open the ESPHome logs in Home Assistant and wake it up. Watch for the "Found Tesla vehicle" message, which will contain the BLE MAC address of your vehicle.
> Note: The vehicle must be in range and awake for the BLE MAC address to be discovered. If the vehicle is not awake, open the Tesla app and run any command
```log
[00:00:00][D][tesla_ble_listener:044]: Parsing device: [CC:BB:D1:E2:34:F0]: BLE Device name 1
[00:00:00][D][tesla_ble_listener:044]: Parsing device: [19:8A:BB:C3:D2:1F]:
Expand All @@ -54,7 +54,7 @@ Tested with M5Stack NanoC6 and Tesla firmwares 2024.26.3.1.
### Building and flashing ESP32 firmware
1. Connect your ESP32 device to your computer via USB
1. Copy and rename `secrets.yaml.example` to `secrets.yaml` and update it with your WiFi credentials (`wifi_ssid` and `wifi_password`) and vehicle details (`ble_mac_address` and `tesla_vin`)
1. Build the image with [ESPHome](https://esphome.io/guides/getting_started_command_line.html)
1. Build the image with [ESPHome](https://esphome.io/guides/getting_started_command_line.html). Alternate boards are listed in the `boards/` directory.
```sh
make compile BOARD=m5stack-nanoc6
Expand All @@ -63,7 +63,7 @@ Tested with M5Stack NanoC6 and Tesla firmwares 2024.26.3.1.
1. Upload/flash the firmware to the board.
```sh
make upload
make upload BOARD=m5stack-nanoc6
```
1. After flashing, you can use the log command to monitor the logs from the device. The host suffix is the last part of the device name in the ESPHome dashboard (e.g. `5b2ac7`).
Expand All @@ -80,7 +80,7 @@ Tested with M5Stack NanoC6 and Tesla firmwares 2024.26.3.1.
### Adding the device to Home Assistant
1. In Home Assistant, go to Settings > Devices & Services. If your device is discovered automatically, you can add it by clicking the "Configure" button by the discovered device. If not, click the "+ Add integration" button and select "ESPHome" as the integration and enter the IP address of your device.
1. In Home Assistant, go to Settings > Devices & Services. If your device is discovered automatically, you can add it by clicking the "Configure" button by the discovered device. If not, click the "+ Add integration" button and select "ESPHome" as the integration and enter the IP address of your device.
2. Enter the API encryption key from the `secrets.yaml` file when prompted.
3. That's it! You should now see the device in Home Assistant and be able to control it.
Expand Down
1 change: 1 addition & 0 deletions packages/base.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ packages:
board: !include board.yml
common: !include common.yml
project: !include project.yml
# listener: !include packages/listener.yml # Uncomment this to scan find your VIN BLE MAC address

esphome:
name: ${device_name}
Expand Down
1 change: 0 additions & 1 deletion tesla-ble-esp32-generic.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ packages:
base: !include packages/base.yml
device_base: !include boards/esp32-generic.yml
client: !include packages/client.yml
# listener: !include packages/listener.yml # Uncomment this to scan find your VIN BLE MAC address

dashboard_import:
package_import_url: github://yoziru/esphome-tesla-ble/tesla-ble-esp32-generic.dashboard.yml
1 change: 0 additions & 1 deletion tesla-ble-m5stack-atoms3.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ packages:
base: !include packages/base.yml
device_base: !include boards/m5stack-atoms3.yml
client: !include packages/client.yml
# listener: !include packages/listener.yml # Uncomment this to scan find your VIN BLE MAC address
# for ESPHome Dashboard, use this instead of external_components

dashboard_import:
Expand Down
1 change: 0 additions & 1 deletion tesla-ble-m5stack-nanoc6.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ packages:
base: !include packages/base.yml
device_base: !include boards/m5stack-nanoc6.yml
client: !include packages/client.yml
# listener: !include packages/listener.yml # Uncomment this to scan find your VIN BLE MAC address

dashboard_import:
package_import_url: github://yoziru/esphome-tesla-ble/tesla-ble-m5stack-nanoc6.dashboard.yml
1 change: 0 additions & 1 deletion tesla-ble.example.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ packages:
base: !include packages/base.yml
client: !include packages/client.yml
common: !include packages/common.yml
# listener: !include packages/listener.yml # Uncomment this to scan find your VIN BLE MAC address
# for ESPHome Dashboard, use this instead of external_components

dashboard_import:
Expand Down

0 comments on commit c20ba5d

Please sign in to comment.