Skip to content

Commit

Permalink
Merge pull request #12 from abichinger/main
Browse files Browse the repository at this point in the history
Update README and build workflow
  • Loading branch information
nliaudat authored Feb 8, 2024
2 parents f2c4973 + d9e951d commit adcc8dd
Show file tree
Hide file tree
Showing 4 changed files with 95 additions and 11 deletions.
7 changes: 7 additions & 0 deletions .github/secrets.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
wifi_ssid_1: "ssid-1"
wifi_password_1: "12345678"
wifi_ssid_2: "ssid-2"
wifi_password_2: "12345678"
wifi_ssid_3: "ssid-3"
wifi_password_3: "12345678"
fallback_hotspot_password: "canbus-fallback"
27 changes: 27 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Build

on:
push:
branches:
- main
pull_request:
branches:
- main

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.10'
- name: Install ESPHome
run: |
python3 -m venv venv
source venv/bin/activate
pip3 install wheel esphome
- name: Setup secrets.yaml
run: cat .github/secrets.yaml > esphome/secrets.yaml
- name: Build firmware
run: venv/bin/esphome compile esphome/config.yaml
66 changes: 56 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
# An ESP32 CanBus shield - made for hoval homevent, but for all canbus applications

![alt text](https://github.com/nliaudat/esp_canbus/blob/main/pcb/3d_view.PNG "board")

<img src="https://github.com/nliaudat/esp_canbus/blob/main/pcb/hoval_wiring.jpg" width=50% height=50%>
[![Wiki badge](https://img.shields.io/badge/Wiki-up_to_date-dark_green)](https://github.com/nliaudat/esp_canbus/wiki)
[![Build badge](https://github.com/nliaudat/esp_canbus/actions/workflows/build.yml/badge.svg?branch=main)](https://github.com/nliaudat/esp_canbus/actions?query=workflow%3ABuild+branch%3Amain)

![alt text](pcb/3d_view.PNG "board")

<img src="pcb/hoval_wiring.jpg" width=50% height=50%>

## Functionalities :
* Compatible with 1000 or 900 mil width ESP devkit
Expand All @@ -18,13 +21,56 @@
* ESP32-WROOM-32D costs approx 3.8$
* Box is 3D printed or fit in a 86x86 electrical box

## Firmware :
Look at wiki to configure for your your Hoval model : 'FV', 'GLT', 'GW', 'HKW', 'HV','MWA', 'PS','SOL', 'WEZ')
* Actually runs under Esphome to link hoval homevent devices, but can be general purpose
* (to update ventilation modulation, you must be in "Constant mode")
* Webserver enabled
* Hassio recognized
<img src="https://github.com/nliaudat/esp_canbus/blob/main/esphome/webserver.PNG" width=75% height=75%>
## Firmware

<p align="center">
<img src="esphome/webserver.PNG" width=75% />
<!-- <img src="esphome/home_assistant.png" width=55% /> -->
<br />
<i>web interface at http://canbus.local/</i>
</p>

### Features

* Powered by [ESPHome](https://esphome.io/)
* Webserver enabled at [canbus.local](http://canbus.local/)
* Automatically recognized by [Home Assistant](https://www.home-assistant.io/)

### Installation

#### Requirements

Make sure you have Python and ESPHome installed. <br />
To install ESPHome you can follow the [manual installation guide](https://esphome.io/guides/installing_esphome) or use [Docker](https://esphome.io/guides/getting_started_command_line#installation).

You can validate your installation by running

```bash
> esphome version
Version: 2023.11.6
```

#### Firmware configuration

Enter your Wifi SSID and password in `secrets.yaml`.<br />
Then open `config.yaml` and make the following changes:
1. Set `can_tx_pin` and `can_rx_pin`
2. Update the device list. You can find the list of your hoval devices in your room control unit under maintenance. (e.g. `HV(8)` is written as `TT_HV_addr: "8"`)
3. Select your desired presets. All presets are located at [`esphome/src/preset`](https://github.com/nliaudat/esp_canbus/tree/main/esphome/src/preset). <br /> e.g. to select the HV preset in French:

```yaml
packages:
# ...
hv_sensors: !include src/preset/HV/sensors_fr.yaml
hv_inputs: !include src/preset/HV/inputs_fr.yaml
```
If you want to create your own preset or need other datapoints have a look at [`esphome/hoval_data_processing`](https://github.com/nliaudat/esp_canbus/tree/main/esphome/hoval_data_processing)

#### Flash the firmware

Connect your ESP32 via USB to your computer. (Only required for the first time, subsequent installations can be done over WiFi) <br />
Then run `esphome run config.yaml`

## Licence:
* Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International (CC-BY-NC-SA)
Expand Down
6 changes: 5 additions & 1 deletion esphome/config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,10 @@ substitutions:
### canbus
can_tx_pin: "GPIO22" #GPIO5
can_rx_pin: "GPIO21" #GPIO4
TT_HV_addr: "8" #hoval homevent can_id (you can find it in room control unit (toptronic) under maintenance

### Device list
### You can find it in room control unit (toptronic) under maintenance
TT_HV_addr: "8"
TT_BM_addr: "8"
TT_WEZ_addr: "1"

Expand All @@ -30,6 +33,7 @@ packages:
switch: !include src/switch.yaml
# debug: !include src/debug.yaml

### Presets
hv_sensors: !include src/preset/HV/sensors_en.yaml
hv_inputs: !include src/preset/HV/inputs_en.yaml
# wez_sensors: !include src/preset/WEZ/sensors_en.yaml
Expand Down

0 comments on commit adcc8dd

Please sign in to comment.