Giter VIP home page Giter VIP logo

zero-motorcycles's Introduction

Zero Motorcycles Home Assistant Integration

hacs_badge

This project is an attempt to create an integration to consume services provided by Zero Motorcycles for their 3rd gen electric motorcycles that come with integrated cellular connection and cloud service.

How

All you need for this integration to work is your login. That is the username and password you use for the official Zero Motorcycles app.

Currently not available in default HACS repo because that requires me to make a brand first.

For now you either have to install it manually by dropping the custom_components folder contents into your HA installation. Or by adding this repo as a custom repo within HACS. For that, within HACS just select "add repo" then pick "integration" as type and enter a name and the url of this repo. Or read here https://hacs.xyz/docs/faq/custom_repositories/

Then you can add a new integration, search for "Zero" to find this one:

add integration

Next you'll get a quick installation wizard, enter your credentials here:

configuration wizard

Once done this integration should be visible:

shows integration

An example of all the data it fetches. Note that in later releases sensor names have been adapted to include unit numbers so that these can be created for all units in case someone owns more than 1 zero motorcycle.

fetched data example

Why?

Because we can!

Limitations

This is literally my first Home Assistant integration so there is still a lot to do and as of now there are still some limitations. Here is an attempt to describe those:

  • Coordindator is hardcoded to update every 5 minutes, if you need more you'll have to change that manually for now. For this search for the (minutes=5)line in the coordinator.py file and change it to what you prefer.

Upcoming features

  • parse numeric values (if needed that is)
  • allow user to configure update interval from UI

Version History

0.4.0

  • created device_tracker for location
  • simplified sensor names + fix for multiple units
  • get version from manifest instead of constants
  • ignored yaml setup since not supported

0.3.0

  • added binary sensors
  • added device class to most sensors

0.2.0

  • renamed sensors to be unique per unit number
  • fetch values for all unit numbers

0.1.0

initial release

About

Here is a picture of my 14.4 kWh Zero SRF premium with charge tank for 12 kW maximum charging power (if conditions are met).

motorcycle picture

Notice

I have since sold this motorcycle (went to France!) and now mostly ride a 2021 Energice SS9+ with 21.5 kWh battery and 24 kW charge speed.

Resources

A good code example for sensors and device_trackers is the Porsche Connect integration with sources available at https://github.com/CJNE/ha-porscheconnect

zero-motorcycles's People

Contributors

hanscappelle avatar dependabot[bot] avatar jr-k avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.