Skip to content

andreadegiovine/homeassistant-stellantis-vehicles

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

1,021 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

HomeAssistant - Stellantis Vehicles

Active installations
Last version

Currently only PSA vehicles are compatibile.

Peugeot CitroΓ«n DS Opel Vauxhall
MyPeugeot MyCitroen MyDS MyOpel MyVauxhall

Inspired by PSA Car Controller (OTP step its a fork). Thanks to Florian BEZANNIER for his great work

Requirements

Get status:

  • Vehicle native mobile app installed and active;
  • Use a pc for autentication;

Send remote commands:

  • Get status requirements;
  • Remote service actived (E-remote or Connect Plus);

Currently Stellantis not provide B2C api credentials, this integration use the mobile apps api credentials and login flow.

Features

Electric / Hybrid Thermic E-remote control Remote control Connect Plus
Get status βœ”οΈ βœ”οΈ βœ”οΈ βœ”οΈ
Wake up βœ”οΈ βœ”οΈ βœ”οΈ βœ”οΈ
ABRP sync βœ”οΈ βœ”οΈ βœ”οΈ βœ”οΈ
Preconditioning start/stop βœ”οΈ βœ”οΈ βœ”οΈ βœ”οΈ
Doors open/close βœ”οΈ βœ”οΈ βœ”οΈ βœ”οΈ
Flash lights βœ”οΈ βœ”οΈ βœ”οΈ βœ”οΈ
Honk the horn βœ”οΈ βœ”οΈ βœ”οΈ βœ”οΈ
Charging start/stop βœ”οΈ βœ”οΈ βœ”οΈ
Charging limit βœ”οΈ βœ”οΈ βœ”οΈ

Installation

Using HACS
  1. Go to HACS section;
  2. Search and install Stellantis Vehicles from the HACS integration list;
  3. Add this integration from the Home Assistant integrations.
Manually
  1. Download this repository;
  2. Copy the directory custom_components/stellantis_vehicles on your Home Assistant config/custom_components/stellantis_vehicles;
  3. Restart HomeAssistant;
  4. Add this integration from the Home Assistant integrations.

Screenshot

Entities

Controls Sensors

Vehicle Card

Card

Documented on Card: Stellantis Vehicles section.

OAuth2 Code

Remote service

This remote service simulates a browser login session on the official website to authenticate your account.

Your credentials are neither stored nor shared

The service is provided by Render.com on a free tier, with performance limitations.

If you want to support the project and extend these limits, become a hero and join our monthly supporters club!

Manual

Using browser console

As described on config flow, please get the right code from the mobile app redirect like this example (Chrome browser):

Oauth2

Using python tool

Thanks to @benbox69 for creating this awesome Python tool to fetch oauth code without using browser console: stellantis-oauth-helper

Using external service

Thanks to @benbox69 for creating this awesome external service to fetch oauth code without using browser console: OAuth Code Extractor

Commands

To use remote commands, the "E-remote" or "Connect Plus" service must be activated and configured in the vehicle.

How to complete the OTP step and activate remote commands:

New configuration

Enable remote commands

Existing configuration

Enable remote commands

WakeUp

For some vehicles no updates are received a few minutes after the engine is turned off. Use automations like these to schedule the vehicle wake up:

- id: "standby_wakeup"
  alias: Vehicle standby WakeUp (every 1 hour)
  description: ""
  mode: single
  triggers:
    - trigger: time_pattern
      hours: /1
  conditions:
    - condition: state
      entity_id: binary_sensor.#####VIN#####_battery_charging
      state: "off"
  actions:
    - action: button.press
      metadata: {}
      data: {}
      target:
        entity_id: button.#####VIN#####_wakeup
- id: "charging_wakeup"
  alias: Vehicle charging WakeUp (every 5 minutes)
  description: ""
  mode: single
  triggers:
    - trigger: time_pattern
      minutes: /5
  conditions:
    - condition: state
      entity_id: binary_sensor.#####VIN#####_battery_charging
      state: "on"
  actions:
    - action: button.press
      metadata: {}
      data: {}
      target:
        entity_id: button.#####VIN#####_wakeup

* the entity names above are in english, please use your language entity names.

Some users report that performing too many wakeups drains the service battery, making some features unavailable (such as keyless entry).

Air conditioning Start/Stop

As described in the Stellantis apps, the command is enabled when:

  1. The vehicle engine is off;
  2. The vehicle doors are locked;
  3. The battery level is at least 50% (20% for hybrids) 20% or in charging (#226);

Battery capacity / residual sensors

Thanks to the community (#272), it seems that for some vehicles Stellantis provides incorrect values. The switch.battery_values_correction entity (in your language) applies a correction if active.

*currently only to the battery_residual sensor

Card: Stellantis Vehicles

A new custom card is available to manage the vehicle, the card is configurable from the visual editor or via yaml:

type: custom:stellantis-vehicle-card
entity: device_tracker.#####VIN#####_vehicle
hide_features: false
features_icons_size: 20
features:
  - binary_sensor.#####VIN#####_remote_commands
  - sensor.#####VIN#####_battery
hide_content: false
content_icons_size: 14
content:
  - sensor.#####VIN#####_temperature
  - sensor.#####VIN#####_last_trip
hide_actions: false
actions:
  - button.#####VIN#####_wakeup
  - button.#####VIN#####_start_charge
hide_charging_limit: false
hide_charging_start: false
hide_map: false
hide_last_trip: false
hide_last_charge: false

* the entity names above are in english, please use your language entity names.

Some users report bugs during first use or after page refresh (#440, #441), it seems like a browser or mobile app cache issue.

To reset mobile app cache try: Settings > app settings > Problem solving > Reset frontend cache

Global preferences

These initial choices can be changed in the Reconfigure flow under Global preferences:

  • Enable persistent notifications
  • Anonymize personal data on logs

Thanks to the community (#414), it seems that for some hardware, the "Anonymize personal data on logs" feature makes the environment unstable. It is recommended to disable this feature and enable it only when you need to share logs.

Errors

Before any issue request, please check the integration log and look for solution below.

OTP error - NOK:MAXNBTOOLS

It seems that this error is due to reaching the limit of associated devices / SMS received. Restore your Stellantis account and try again: Follow this procedure from Peugeot community.

This operation removes the devices connected to your vehicle, no vehicle data will be lost.

OTP error - NOK:NOK_BLOCKED

It seems that this error is due to reaching the limit of wrong PIN used. Re-authenticate the integration.

Get oauth code error

As described in the "OAuth2 Code > Remote service" section, this free service has usage limitations.
If you've hit these limits, please wait and try again.
If the problem persists or is unrelated to usage limits, please use "OAuth2 Code > Manual" mode.

ABRP - A Better Routeplanner

Get a token from ABRP:

  1. Login to your account;
  2. Navigate to vehicle settings;
  3. Navigate to real time data;
  4. Navigate to edit connections;
  5. Generate a token using "Generic" method;

Use the generated token in abrp_token sensor and enable abrp_sync switch to send updates.

Contributors & Translations

Start from the "develop" branch and submit PRs in that branch.

Commit messages are included as release notes, please keep them short and understandable.

Before each PR please test:

  • New installation;
  • Reconfiguration;
  • Commands;
  • Sensors;
  • 1 week without errors in logs;

If the checklist is complete, the PR will be merged and will be released a BETA version, if no issues are reported the changes will included on next stable release.

Thanks to all users who contribute to this integration by updating translations and reporting issues.

Special thanks:

Thanks to everyone for the issues, especially to:

Support the project

The latest heroes who believe in this project πŸ‘‡

πŸ† 10 BEERS
Andrea Donno
Fabian

πŸ₯ˆ 5 BEERS
Dieter
SA Energy
Phil S
and other heroes

πŸ₯‰ 3 BEERS
SupaChris
DrBrochmann
Jeroen
and other heroes

⭐ 2 BEERS
Dave
Somebody
mggevaer
and other heroes

⭐ 1 BEERS
Someone
MR
Christof
and other heroes

Want to join the Club?

"Buy Me A Coffee"
ko-fi

Sponsor this project

Contributors