Skip to main content

No project description provided

Project description

hass-inspirair

GitHub CI

python python python python

pre-commit

A python application that connects to the ventilation system InspirAir® Home from Aldes via ModBus and exposes it as a device for Home Assistant .

Schematics of dataflow
graph LR
    P(hass-inspirair) <-- MQTT --> M(MQTT Broker)
    I[InspirAir Home] <-- ModBus --> P
    HM(Home Assistant \n MQTT Integration) <--MQTT--> M
    H[Home Assistant] <----> HM

Only the ventilation mode is currently writable. However, it takes some time before the value changes after a write command. Since the register will stay at its previous value until the target state is reached.

Following features are implemented:

1. Register after starting up
sequenceDiagram
    participant H as Home Assistant(MQTT)
    participant L as hass-inspirair
    participant I as InspirAir
    
    
    L->>+I: read_holding_registers
    activate L
    L-->>L: creat config
    
    L->>-H: register <prefix>/<sensor_type>/<object_id>/<device_serial>/config
2. Continues updates
sequenceDiagram

    participant H as Home Assistant(MQTT)
    participant L as hass-inspirair
    participant I as InspirAir


    L->>I: read_holding_registers
    activate L
    L->>L: parse result
    L->>H: publish <prefix>/climate/<device_serial>/state
    L->>L: sleep for <polling interval>
    deactivate L
3. React on Home Assistant Inputs
sequenceDiagram
    participant H as Home Assistant(MQTT)
    participant L as hass-inspirair
    participant I as InspirAir

    H->>L: publish "<prefix>/select/<object_id>/<device_serial>/set"
     activate L
    L->>I: write_registers
    L->>I: read_holding_registers

    L->>L: parse result
    L->>H: publish <prefix>/climate/<device_serial>/state
    deactivate L
4. React on Home Assistant MQTT lifecycle events
sequenceDiagram

    participant H as Home Assistant(MQTT)
    participant L as hass-inspirair
    participant I as InspirAir

    H->>L: publish "<prefix>/status" payload: "online"
    activate L
    L->>+I: read_holding_registers

    L-->>L: creat config

    L->>-H: register <prefix>/<sensor_type>/<object_id>/<device_serial>/config
5. Multilanguage Support Default language is german, however, an english translation is available.

Supported Models

In theory this application should work with any InspirAir® Home Ventilation system.

Currently, only the following was actually tested:

  • InspirAIR Home SC 370

Usage

Configure a config.ini file based on your requirements (or use environment variables) . See config.ini for configuration options which can also be set via environment variables Config Values.

pip intall hass-inspirair
ha-inspirair -c ./config.ini

For are more exhaustive usage tutorial see docs/tutorial/index.md.

Simulator/Testing

The compose stack includes a simulator that exposes the relevante registers via Modbus-TCP. The presented values are a pure mock. However, this stack can be used to try out the behavior of the MQTT discovery.

  1. Run docker-compose up
  2. goto http://localhost:8123
  3. Setup a user
  4. Add the MQTT Integration (host=mqtt, no further credentials)
  5. A device should show up

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

hass_inspirair-0.4.1.tar.gz (20.5 kB view hashes)

Uploaded Source

Built Distribution

hass_inspirair-0.4.1-py3-none-any.whl (26.2 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page