Skip to content

A Home Assistant integration to receive live data sent from the LeafSpy app

License

Notifications You must be signed in to change notification settings

Chaoscontrol/ha-leafspy

 
 

Repository files navigation

leafspy

GitHub Release GitHub Activity License

hacs Project Maintenance

Discord Community Forum

Component to integrate with leafspy.

This component will set up the following platforms.

Platform Description
device_tracker Track a Nissan Leaf using the Leaf Spy app.
sensor All data about the vehicle sent from Leaf Spy is displayed as independent sensors. They won't appear in Home Assistant until data is received.
binary_sensor Power switch sensor.

leafspy

Installation

Open your Home Assistant instance and open a repository inside the Home Assistant Community Store.

  1. Using the tool of choice open the directory (folder) for your HA configuration (where you find configuration.yaml).
  2. If you do not have a custom_components directory (folder) there, you need to create it.
  3. In the custom_components directory (folder) create a new folder called leafspy.
  4. Download all the files from the custom_components/leafspy/ directory (folder) in this repository.
  5. Place the files you downloaded in the new directory (folder) you created.
  6. Restart Home Assistant
  7. In the HA UI go to "Configuration" -> "Integrations" click "+" and search for "Leaf Spy"

Using your HA configuration directory (folder) as a starting point you should now also have this:

custom_components/leafspy/translations/en.json
custom_components/leafspy/__init__.py
custom_components/leafspy/config_flow.py
custom_components/leafspy/const.py
custom_components/leafspy/device_tracker.py
custom_components/leafspy/sensor.py
custom_components/leafspy/binary_sensor.py
custom_components/leafspy/manifest.json
custom_components/leafspy/strings.json

Configuration is done in the UI

Android/iOS app configuration

Open the Leaf Spy app, go to Menu -> Settings and scroll down to Server. Change the following settings:

  • Enable: Yes
  • Send Interval can be whatever you prefer.
  • ID: <Car Name>
  • PW: secret generated when the integration was installed
  • Http or Https depending on the access to your Home Assistant install.
  • URL: webhook url generated when the integration was installed
    • Note: Do not add http or https to the URL.

Contributions are welcome!

If you want to contribute to this please read the Contribution guidelines


About

A Home Assistant integration to receive live data sent from the LeafSpy app

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Python 100.0%