Skip to main content

OpenInverter CAN tool

Build status PyPI - Python Version PyPI - License

A tool to allow configuration and operating of OpenInverter systems for electric vehicles over a CAN connection.

Features

  • Display all available modifiable parameters and read-only values supported by a given inverter firmware version
  • Read a specified parameter/value
  • Write a new value to a specified parameter
  • Display the current value of each parameter/value on a given device
  • Log a list of parameters to a CSV file at regular intervals
  • Save and load all parameters to and from a JSON file
  • Manage parameter to custom CAN message mappings:
    • Create, remove and list parameter mappings on a device
    • Support maps with standard CAN 2.0a and extended CAN 2.0b frames
    • Export and import mappings to a local JSON file
    • Export mappings to DBC allowing easier debugging with SavvyCAN
  • Upgrade firmware or recover devices over CAN
  • Display the inverter serial number
  • Command the inverter to:
    • Start
    • Stop
    • Load parameters from flash
    • Save parameters to flash
    • Revert parameters to their default values
    • Reset
  • Display a device's error log
  • Scan a CAN bus for possible nodes
  • Runs on Linux, Windows and MacOS with python 3.9+
  • Support shell completion for commands and options for bash, zsh and fish shells
  • Works with any CAN adapter supported by python-can
  • Supports stm32-sine 5.24.R or later
  • Automatic parameter database download and caching (requires stm32-sine 5.27.R or later)
  • Works with Foccci/Clara CCS controller, Stm32-vcu (a.k.a. Zombieverter VCU) and Flying ADC BMS

Installation

To avoid any clashes with other software the tool is best is best installed using the pipx package manager. Install this following the pipx installation guide for your platform.

Initial Install

The most recent release may be installed using:

    pipx install openinverter_can_tool

Upgrading

Upgrading to the most recent release is carried out using pip:

    pipx upgrade openinverter_can_tool

Configuration

Before the tool can be used the CAN interface adapter needs to be configured. To do this create ~/.canrc on Linux and MacOS or %USERPROFILE%/can.conf on Windows. Details on interfaces supported and the configuration file format can be found in the python-can documentation.

An example configuration file for a SocketCAN compatible adapter on Linux would look like:

[default]
interface = socketcan
channel = can0
bitrate = 500000

Note: Before the tool can on Linux run the SocketCAN network interface needs to be started. Read the guide on how to do this.

An example configuration file for a SLCAN adapter such as GVRET on Windows would look like:

[default]
interface = slcan
channel = COM8
bitrate = 500000

Tested interfaces

Let me know if you have used a particular CAN interface successfully and I can expand this list.

The many CANable clone devices on eBay or AliExpress can be swapped from socketcan to slcan firmware (or vice versa) using the web firmware updater.

Incompatible interfaces

These python-can drivers are known to have problems with openinverter_can_tool:

Command Line Usage

To get the usage information for the tool run the oic command with no parameters:

    Usage: oic [OPTIONS] COMMAND [ARGS]...

    OpenInverter CAN Tool allows querying and setting configuration of inverter
    parameters over a CAN connection

    Options:
    -d, --database FILE       Override the OpenInverter JSON parameter database
                                to use
    -c, --context TEXT        Which python-can configuration context to use
    -n, --node INTEGER RANGE  The CAN SDO node ID to communicate with  [env var:
                                OIC_NODE; default: 1; 1<=x<=127]
    -t, --timeout FLOAT       Response timeout in seconds  [default: 1.0]
    --debug                   Enable detailed debugging messages
    --version                 Show the version and exit.
    --help                    Show this message and exit.

    Commands:
    cache       Parameter database cache management commands
    can         Manage parameter to CAN message mappings on a device
    cmd         Execute a command on a device
    dumpall     Dump the values of all available parameters and values
    errors      List all of the errors on a device
    listparam   List the definition of PARAM
    listparams  List all available parameters and values
    load        Load all parameters from json IN_FILE
    log         Log the value of PARAMS from the device periodically in CSV...
    read        Read the value of PARAM from the device
    save        Save all parameters in json to OUT_FILE
    scan        Scan the CAN bus for available nodes
    serialno    Read the device serial number.
    upgrade     Upgrade the device firmware.
    write       Write the value to the parameter PARAM on the device

To scan for OpenInverter devices on a CAN network:

    $ oic scan
    Scanning for devices. Please wait...

    Found possible OpenInverter node: 1
    Found possible OpenInverter node: 3

To read the current value of a parameter:

    $ oic read brakeregen
    brakeregen          : -50

Values may be changed using symbolic names:

    oic write potmode DualChannel
    oic write pinswap PWMOutput13,PWMOutput23

Firmware on devices may be easily upgraded:

    $ oic upgrade stm32_sine.bin
    Device upgrade started for 87193029
    Upgrading: 15.3% complete

Experimental GUI

An experimental GUI version of the tool exists which can be started by running the oic-gui command:

Screenshot of the OpenInverter CAN Tool showing the Parameters tab on a Linux GNOME desktop

Further details can be found in the user documentation.

Development and Contributing

If you are interested in contributing to the tool please check the contributing guidelines.

Metadata

Release files for openinverter-can-tool 0.5.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for openinverter-can-tool 0.5.1
File Size Uploaded Provenance Actions
openinverter_can_tool-0.5.1.tar.gz 384.3 kB With provenance Details for openinverter_can_tool-0.5.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for openinverter-can-tool 0.5.1
File Interpreter ABI Platform Actions
openinverter_can_tool-0.5.1-py3-none-any.whl Python 3 none any Details for openinverter_can_tool-0.5.1-py3-none-any.whl

Total release size: 750.4 kB

Release files / openinverter_can_tool-0.5.1.tar.gz

Download URL openinverter_can_tool-0.5.1.tar.gz
Size 384.3 kB
Tags Source
SHA-256 checksum
How to use checksums
4fa724f50ca4eae0896448b402b7f15e912e945bd5befc8af4da9a2ebb9041c2
BLAKE2b-256 checksum
How to use checksums
3038b7a74f28862e82660956b6d621f36550e47104478fac091bb6c1cd8e9c80
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 21, 2025.

Transparency log

Release files / openinverter_can_tool-0.5.1-py3-none-any.whl

Download URL openinverter_can_tool-0.5.1-py3-none-any.whl
Size 366.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
72302f6f3024ad293584fa0706c5e9fa863e181ed50b8d6185253c126617fdb2
BLAKE2b-256 checksum
How to use checksums
1e0a6af939b1db477080fb0a47e48b3c6733aed4eee494a95f3696aaaa4c1642
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 21, 2025.

Transparency log

Security for openinverter-can-tool 0.5.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for openinverter_can_tool-0.5.1.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 21, 2025.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page