Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Component for Duco ventilation system#7993

Draft
kokx wants to merge 43 commits into
esphome:devfrom
kokx:duco-component
Draft

Component for Duco ventilation system#7993
kokx wants to merge 43 commits into
esphome:devfrom
kokx:duco-component

Conversation

@kokx

@kokx kokx commented Dec 21, 2024

Copy link
Copy Markdown

What does this implement/fix?

Adds a component that allows control of a Duco heat recovery ventilation system. It adds a select component to set the current ventilation mode, sensors for the serial number, CO2-sensors, remaining filter time, flow level and time remaining in the current ventilation mode.

At the time of writing this is only tested on a DucoBox Energy Comfort D325, it may not work on every Duco ventilation system.

Types of changes

  • Bugfix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Code quality improvements to existing code or addition of tests
  • Other

Related issue or feature (if applicable):

Pull request in esphome-docs with documentation (if applicable):

Test Environment

  • ESP32
  • ESP32 IDF
  • ESP8266
  • RP2040
  • BK72xx
  • RTL87xx

Example entry for config.yaml:

# Example config.yaml
duco:
  uart_id: duco_uart
  discovery: {}
  time:
    time_id: sntp_time

text_sensor:
  - platform: duco
    name: "Serial Number"

select:
  - platform: duco
    name: "Mode"

sensor:
  - platform: duco
    co2:
      - address: 3
        name: "CO2 Bedroom"
      - address: 4
        name: "CO2 Livingroom"
    temperature:
      - address: 3
        name: "Temperature Bedroom"
      - address: 4
        name: "Temperature Livingroom"
      - address: 1
        name: "Temperature Bathroom"
      - address: 58
        name: "Temperature Office"
    humidity:
      - address: 1
        name: "Humidity Bathroom"
      - address: 58
        name: "Humidity Office"
    filter_remaining:
      name: "Filter Time Remaining"
    flow_level:
      name: "Flow Level"
    time_remaining:
      name: "Mode Time Remaining"
    bypass:
      name: "Bypass"
    temperature_oda:
      name: "Temperature Outdoor Air"
    temperature_eha:
      name: "Temperature Outdoor Exhaust"
    temperature_sup:
      name: "Temperature Supply To Room"
    temperature_eta:
      name: "Temperature Indoor Exhaust"

number:
  - platform: duco
    name: "Comfort Temperature"

Checklist:

  • The code change is tested and works locally.
  • Tests have been added to verify that the new code works (under tests/ folder).

If user exposed functionality or configuration variables are added/changed:

@codecov-commenter

codecov-commenter commented Dec 21, 2024

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 73.36%. Comparing base (1560b8b) to head (7db1dfa).
⚠️ Report is 4059 commits behind head on dev.

Additional details and impacted files
@@            Coverage Diff             @@
##              dev    #7993      +/-   ##
==========================================
+ Coverage   69.17%   73.36%   +4.18%     
==========================================
  Files          52       53       +1     
  Lines       10755    11283     +528     
  Branches     1449     1532      +83     
==========================================
+ Hits         7440     8278     +838     
+ Misses       2922     2605     -317     
- Partials      393      400       +7     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@Tiellemans Tiellemans left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, also installed the component myself as I also have this box at home.
Really appreciate this PR and it immediate helped me automate this box.

Thanks for the hard work!

@Tiellemans

Tiellemans commented Apr 30, 2025

Copy link
Copy Markdown

Saw comments on the documentation: esphome/esphome.io#4528 (comment)
Any clue what the BOX, UCBAT, SWITCH and UC nodes are (I only detect BOX and UCBAT myself)?
Here it works fine, I have some additional components here.

  • The duco box
  • Controllers where only one supports CO2 readings
  • Wireless controller
  • One CO2 reader on the bedroom

My list is as follows:
[10:53:12][I][duco:200]: Discovered nodes:
[10:53:12][I][duco:203]: Node 1: type 17 (BOX)
[10:53:12][I][duco:203]: Node 2: type 8 (UCBAT)
[10:53:12][I][duco:203]: Node 3: type 12 (UCCO2)
[10:53:12][I][duco:203]: Node 4: type 12 (UCCO2)

Possibly related: I can see on the Duco display that it can measure indoor and outdoor temperatures. Can those sensors be read over UART as well?
This would be nice indeed, now I'm using another outside temp detector and indoor temp detectors.
We are now with 3 ppl using it, so if we are finding the way to do it, we can add it later and share it with a new PR.

@w1ll14m

w1ll14m commented May 5, 2025

Copy link
Copy Markdown

This is a very interesting PR, nice progress too! I'm going to follow this as I have a DucoBox energy premium and the connectivity board which is very disappointing.

I'm sniffing the uart comms with a saleae clone to see if I can get some more data.

  • type 10 is a temp/humidity sensor.
  • type 13 is a valve. (I have a two zone box and a heat exchanger bypass. Likely these valves control these functions)
  • Nodes 58, 67 and 68 are inside of the box.

14:28:34 | [I] | [duco:203] | Discovered nodes:
14:28:34 | [I] | [duco:205] | Node 1: type 17 (BOX)
14:28:34 | [I] | [duco:205] | Node 2: type 10 (UCRH)
14:28:34 | [I] | [duco:205] | Node 3: type 12 (UCCO2)
14:28:34 | [I] | [duco:205] | Node 58: type 10 (UCRH)
14:28:34 | [I] | [duco:205] | Node 67: type 13 (UNKNOWN)
14:28:34 | [I] | [duco:205] | Node 68: type 13 (UNKNOWN)

@kokx

kokx commented May 13, 2025

Copy link
Copy Markdown
Author

@w1ll14m I'm glad to hear that it's working well! Since you're also looking at it with a logic analyzer, can you see if you can figure out the protocol for the humidity sensor? I couldn't do that myself, since I don't have a humidity sensor in my own network.

If you're looking for a bit more information of the protocol, you can take a look at: https://github.com/kokx/duco-analysis/ . There I described how I reverse engineered the protocol itself using a Saleae. I am assuming that the humidity sensor works very similar to how the CO2-sensor works. Feel free to contact me if you have any troubles there, I'm happy to help you decipher it.

I would also be quite interested to see how the valve works, would be nice if this can be implemented as well.

@Tiellemans Unfortunately the temperature sensors aren't visible through the Connectivity Board, which means that I wasn't able to figure out that part of the protocol.

@w1ll14m

w1ll14m commented May 14, 2025

Copy link
Copy Markdown

@kokx

I've reinstalled the duco board and installed the installer app, registered (not verified) and was able to read some info from the box and sensors. I was able to read pressure and humid from box and humid + temp from sensors. I dumped the data from logic analyzer and made a few screenshots. Haven't had the time yet to figure out the messages, I did read your duco-analysis repo, which is very nice!

What is a good place to have a discussion and share some files? Are you active on IRC, discord or something else? It's probably best to not clutter this PR too much :)

@kokx

kokx commented May 14, 2025

Copy link
Copy Markdown
Author

@w1ll14m You can reach me on Discord, you should be able to find me in the esphome discord with the same username.

@kokx

kokx commented May 18, 2025

Copy link
Copy Markdown
Author

With some help from @w1ll14m it was possible to also add support for the humidity sensor, temperature sensors that are in the Box and the Bypass value. The documentation and example config were updated accordingly.

@Tiellemans

Tiellemans commented May 19, 2025

Copy link
Copy Markdown

Great update!
Saw the change and immediate added it to my ESPHome Duco controller.
With the temperatures available now, we are able to control the Duco box as cooler in nights.
When inside temp is higher than outside temp, the airflow can be set to 100% and during daytime when outside is hot, you set it on auto to let the box handle co2.

I've added the Delta T to the controller by calculating diffs (- means cool air flow inside, + means hotter air flow inside):
sensor:

  • platform: duco
    co2:
    • address: 4
      name: "CO2 Bedroom"
    • address: 3
      name: "CO2 Livingroom"
      temperature:
    • address: 4
      name: "Temperature Bedroom"
    • address: 3
      name: "Temperature Livingroom"
    • address: 2
      name: "Temperature Bathroom"
      filter_remaining:
      name: "Filter Time Remaining"
      flow_level:
      name: "Flow Level"
      time_remaining:
      name: "Mode Time Remaining"
      bypass:
      name: "Bypass"
      temperature_oda:
      id: aoin
      name: "Temperature Outdoor Air"
      temperature_eha:
      id: aoout
      name: "Temperature Outdoor Exhaust"
      temperature_sup:
      id: aiin
      name: "Temperature Supply To Room"
      temperature_eta:
      id: aiout
      name: "Temperature Indoor Exhaust"
  • platform: template
    name: "Delta T AirFlow Temperature Inside"
    id: Tai
    unit_of_measurement: °C
    update_interval: 10s
    lambda: |-
    return (id(aiin).state - (id(aiout).state));
  • platform: template
    name: "Delta T AirFlow Temperature Outside"
    id: Tao
    unit_of_measurement: °C
    update_interval: 10s
    lambda: |-
    return (id(aoin).state - (id(aoout).state));

@github-actions

Copy link
Copy Markdown
Contributor

There hasn't been any activity on this pull request recently. This pull request has been automatically marked as stale because of that and will be closed if no further activity occurs within 7 days.
If you are the author of this PR, please leave a comment if you want to keep it open. Also, please rebase your PR onto the latest dev branch to ensure that it's up to date with the latest changes.
Thank you for your contribution!

@github-actions github-actions Bot added the stale label Sep 26, 2025
@github-actions

Copy link
Copy Markdown
Contributor

To use the changes from this PR as an external component, add the following to your ESPHome configuration YAML file:

external_components:
  - source: github://pr#7993
    components: [duco]
    refresh: 1h

(Added by the PR bot)

esphome[bot]
esphome Bot previously requested changes Sep 26, 2025

@esphome esphome Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

📦 Pull Request Size

This PR is too large with 1607 line changes (excluding tests). Please consider breaking it down into smaller, focused PRs to make review easier and reduce the risk of conflicts.

For guidance on breaking down large PRs, see: https://developers.esphome.io/contributing/submitting-your-work/#how-to-approach-large-submissions

@esphome

esphome Bot commented Sep 26, 2025

Copy link
Copy Markdown
Contributor

Please take a look at the requested changes, and use the Ready for review button when you are done, thanks 👍

Learn more about our pull request process.

@esphome esphome Bot marked this pull request as draft September 26, 2025 16:57
@kokx

kokx commented Sep 26, 2025

Copy link
Copy Markdown
Author

I did a quick rebase, also adding this comment to prevent the PR being closed.

@kokx kokx marked this pull request as ready for review September 26, 2025 17:29
@esphome esphome Bot dismissed their stale review September 26, 2025 17:29

Stale

@github-actions github-actions Bot removed the stale label Sep 27, 2025
@github-actions

Copy link
Copy Markdown
Contributor

There hasn't been any activity on this pull request recently. This pull request has been automatically marked as stale because of that and will be closed if no further activity occurs within 7 days.
If you are the author of this PR, please leave a comment if you want to keep it open. Also, please rebase your PR onto the latest dev branch to ensure that it's up to date with the latest changes.
Thank you for your contribution!

@github-actions github-actions Bot added the stale label Dec 26, 2025

@esphome esphome Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

📦 Pull Request Size

This PR is too large with 1607 line changes (excluding tests). Please consider breaking it down into smaller, focused PRs to make review easier and reduce the risk of conflicts.

For guidance on breaking down large PRs, see: https://developers.esphome.io/contributing/submitting-your-work/#how-to-approach-large-submissions

@esphome esphome Bot marked this pull request as draft December 26, 2025 12:29
@github-actions

github-actions Bot commented Dec 26, 2025

Copy link
Copy Markdown
Contributor

Memory Impact Analysis

Components: duco
Platform: esp32-idf

Metric Target Branch This PR Change
RAM 12,028 bytes 34,392 bytes 📈 🚨 +22,364 bytes (+185.93%)
Flash 225,487 bytes 730,487 bytes 📈 🚨 +505,000 bytes (+223.96%)
📊 Component Memory Breakdown
Component Target Flash PR Flash Change
wifi_stack 0 bytes 106,705 bytes 📈 +106,705 bytes (0.00%)
network_stack 0 bytes 34,338 bytes 📈 +34,338 bytes (0.00%)
phy_radio 1,385 bytes 32,027 bytes 📈 +30,642 bytes (+2212.42%)
crypto 2,771 bytes 26,396 bytes 📈 +23,625 bytes (+852.58%)
crypto_math 1,458 bytes 24,712 bytes 📈 +23,254 bytes (+1594.92%)
mdns_lib 0 bytes 22,566 bytes 📈 +22,566 bytes (0.00%)
other 1,636 bytes 18,976 bytes 📈 +17,340 bytes (+1059.90%)
power_mgmt 225 bytes 13,055 bytes 📈 +12,830 bytes (+5702.22%)
rom_functions 4,199 bytes 14,522 bytes 📈 +10,323 bytes (+245.84%)
wifi_config 5,860 bytes 15,957 bytes 📈 +10,097 bytes (+172.30%)
[esphome]wifi 0 bytes 9,587 bytes 📈 🔸 +9,587 bytes (0.00%)
wifi_phy_pp 230 bytes 9,355 bytes 📈 +9,125 bytes (+3967.39%)
app_framework 386 bytes 7,563 bytes 📈 +7,177 bytes (+1859.33%)
libc 52,098 bytes 58,988 bytes 📈 +6,890 bytes (+13.23%)
can_driver 0 bytes 6,877 bytes 📈 +6,877 bytes (0.00%)
misc_system 3,883 bytes 10,758 bytes 📈 +6,875 bytes (+177.05%)
wifi_lmac 0 bytes 6,257 bytes 📈 +6,257 bytes (0.00%)
wifi_crypto 510 bytes 6,740 bytes 📈 +6,230 bytes (+1221.57%)
interrupt_handlers 11,457 bytes 17,260 bytes 📈 +5,803 bytes (+50.65%)
[esphome]duco 0 bytes 5,723 bytes 📈 🔸 +5,723 bytes (0.00%)
... ... ... (64 more components not shown)
🔍 Symbol-Level Changes (click to expand)

Changed Symbols

Symbol Target Size PR Size Change
setup() 206 bytes 2,018 bytes 📈 +1,812 bytes (+879.61%)
K 256 bytes 640 bytes 📈 +384 bytes (+150.00%)
esphome::App 168 bytes 300 bytes 📈 +132 bytes (+78.57%)
[global constructor for: esphome::Application::register_component_(esphome::Component*)] 142 bytes 210 bytes 📈 +68 bytes (+47.89%)
esp_mmu_map 910 bytes 966 bytes 📈 +56 bytes (+6.15%)
esp_panic_handler_feed_wdts 118 bytes 154 bytes 📈 +36 bytes (+30.51%)
rtc_init 930 bytes 966 bytes 📈 +36 bytes (+3.87%)
vTaskDelete 240 bytes 274 bytes 📈 +34 bytes (+14.17%)
xQueueGenericSend 255 bytes 279 bytes 📈 +24 bytes (+9.41%)
xTaskResumeAll 442 bytes 466 bytes 📈 +24 bytes (+5.43%)
esp_sha_lock_engine_common 135 bytes 158 bytes 📈 +23 bytes (+17.04%)
periph_module_enable 151 bytes 171 bytes 📈 +20 bytes (+13.25%)
xRingbufferSendComplete 141 bytes 161 bytes 📈 +20 bytes (+14.18%)
vTaskPrioritySet 294 bytes 314 bytes 📈 +20 bytes (+6.80%)
esp_mmu_vaddr_to_paddr 169 bytes 189 bytes 📈 +20 bytes (+11.83%)
xQueueSemaphoreTake 265 bytes 285 bytes 📈 +20 bytes (+7.55%)
esp_mmu_unmap 249 bytes 269 bytes 📈 +20 bytes (+8.03%)
esp_panic_handler_enable_rtc_wdt 66 bytes 86 bytes 📈 +20 bytes (+30.30%)
vRingbufferReturnItem 87 bytes 106 bytes 📈 +19 bytes (+21.84%)
__func__$18 25 bytes 8 bytes 📉 -17 bytes (-68.00%)
vTaskDelay 59 bytes 75 bytes 📈 +16 bytes (+27.12%)
multi_heap_get_info 86 bytes 102 bytes 📈 +16 bytes (+18.60%)
esp_vfs_register_fs 176 bytes 192 bytes 📈 +16 bytes (+9.09%)
ulTaskGenericNotifyTake 174 bytes 190 bytes 📈 +16 bytes (+9.20%)
esphome::Application::~Application() 54 bytes 70 bytes 📈 +16 bytes (+29.63%)
prvReceiveGeneric 204 bytes 220 bytes 📈 +16 bytes (+7.84%)
prvSendAcquireGeneric 208 bytes 224 bytes 📈 +16 bytes (+7.69%)
esp_panic_handler_disable_timg_wdts 59 bytes 75 bytes 📈 +16 bytes (+27.12%)
esp_sync_timekeeping_timers 77 bytes 92 bytes 📈 +15 bytes (+19.48%)
__func__$14 18 bytes 31 bytes 📈 +13 bytes (+72.22%)
... ... ... (183 more changed symbols not shown)

New Symbols (top 15)

Symbol Size
mdns_parse_packet 7,567 bytes
esp_internal_sha1_parallel_engine_process [$isra$0] 4,493 bytes
g_cnxMgr 3,880 bytes
ieee80211_sta_new_state 3,357 bytes
mbedtls_sha512_software_process 3,212 bytes
tcp_input 3,065 bytes
scan_parse_beacon 3,025 bytes
wifi_nvs_cfg_init 2,990 bytes
sta_recv_mgmt 2,679 bytes
tcp_receive 2,654 bytes
wpa_sm_rx_eapol 2,329 bytes
ieee80211_parse_rsn 2,010 bytes
scan_profile_check 1,812 bytes
sta_recv_assoc 1,717 bytes
_mdns_service_task 1,628 bytes
3764 more new symbols... Total: 425,730 bytes

Removed Symbols (top 15)

Symbol Size
_open_r 248 bytes
multi_heap_realloc 106 bytes
fsync 85 bytes
_read_r 83 bytes
esp_vfs_lseek 83 bytes
multi_heap_malloc 83 bytes
_write_r 83 bytes
_fstat_r 80 bytes
multi_heap_aligned_free 68 bytes
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >::_M_is_local() const 18 bytes
multi_heap_get_allocated_size_impl 12 bytes
malloc 12 bytes
cfree 10 bytes
std::type_info::__is_function_p() const 7 bytes

Note: This analysis measures static RAM and Flash usage only (compile-time allocation).
Dynamic memory (heap) cannot be measured automatically.
⚠️ You must test this PR on a real device to measure free heap and ensure no runtime memory issues.

This analysis runs automatically when components change. Memory usage is measured from a representative test configuration.

@github-actions github-actions Bot removed the stale label Dec 27, 2025
@rebot

rebot commented Jan 29, 2026

Copy link
Copy Markdown

Hi, I'm really looking forward to give it a shot. Can I safely use the pins that supply 5V on the Duco to power a nodeMCU with the duco component installed on? Is their somewhere some documentation that I can follow, including some pictures?

@kokx

kokx commented Jan 30, 2026

Copy link
Copy Markdown
Author

Yes, you can use the 5V pin to provide power to a NodeMCU. The documentation you can find here: https://github.com/kokx/esphome-docs/blob/duco-component/components/duco.rst

@DJayNL

DJayNL commented Feb 27, 2026

Copy link
Copy Markdown

Thanks so much for your effort @kokx. I have a Ducobox Focus and was able to connect an ESP32 using your project to it and am getting CO2 and Humidity readings from my 3 valves! Really wanted to get an insight and hopefully do some controlling with it later as well but I'm new to Coding, ESP32s and Home Assistant so diving straight into this I'm in a bit over my head. Anyways, I have some new components that maybe can be helpful to identify for other users with the Ducobox Focus: Type 14 (valve with RH sensor), Type 16 (Valve with CO2 sensor, If I remember correctly these are ones that are rated up to 30 m3/h or so instead of the standard 50 m3/h. They go up to 80+ m3/h without a problem but were cheaper to buy...)
Type 7 not sure, It might be the DucoTronic electrically controlled ventilation grill I have above my window:

[19:14:24.249][I][duco:206]: Discovered nodes:
[19:14:24.249][I][duco:208]: Node 1: type 17 (BOX)
[19:14:24.249][I][duco:208]: Node 2: type 14 (UNKNOWN)
[19:14:26.482][I][duco:208]: Node 3: type 16 (UNKNOWN)
[19:14:26.482][I][duco:208]: Node 4: type 16 (UNKNOWN)
[19:14:26.482][I][duco:208]: Node 5: type 9 (UC)
[19:14:26.496][I][duco:208]: Node 6: type 7 (UNKNOWN)
[19:14:26.496][I][duco:208]: Node 7: type 8 (UCBAT)

@DJayNL

DJayNL commented Feb 28, 2026

Copy link
Copy Markdown

Thanks so much for your effort @kokx. I have a Ducobox Focus and was able to connect an ESP32 using your project to it and am getting CO2 and Humidity readings from my 3 valves! Really wanted to get an insight and hopefully do some controlling with it later as well but I'm new to Coding, ESP32s and Home Assistant so diving straight into this I'm in a bit over my head. Anyways, I have some new components that maybe can be helpful to identify for other users with the Ducobox Focus: Type 14 (valve with RH sensor), Type 16 (Valve with CO2 sensor, If I remember correctly these are ones that are rated up to 30 m3/h or so instead of the standard 50 m3/h. They go up to 80+ m3/h without a problem but were cheaper to buy...) Type 7 not sure, It might be the DucoTronic electrically controlled ventilation grill I have above my window:

[19:14:24.249][I][duco:206]: Discovered nodes: [19:14:24.249][I][duco:208]: Node 1: type 17 (BOX) [19:14:24.249][I][duco:208]: Node 2: type 14 (UNKNOWN) [19:14:26.482][I][duco:208]: Node 3: type 16 (UNKNOWN) [19:14:26.482][I][duco:208]: Node 4: type 16 (UNKNOWN) [19:14:26.482][I][duco:208]: Node 5: type 9 (UC) [19:14:26.496][I][duco:208]: Node 6: type 7 (UNKNOWN) [19:14:26.496][I][duco:208]: Node 7: type 8 (UCBAT)

Additional information when hooked up to the (old) installer tool using a usb cable:
2026-02-28 11_08_58-Clipboard

@Duck184

Duck184 commented May 30, 2026

Copy link
Copy Markdown

Hi!

Great work on this, i'm using it succesfully on my Duco WTW DucoBox Energy for about half a year now.

My unit has an auto-bypass, which is nice but i'd like a bit more control over it.
The bypass sensor is nice, but on the unit i can change it from auto to manual on/off.
Is it possible to include the adaptive/auto/manual on/manual off as switches through the code?
I have been looking at the referenced API document, but can't find reference to that...

If there's anything i can do to help let me know,

Thank you!

@w1ll14m

w1ll14m commented Jun 1, 2026

Copy link
Copy Markdown

Hi!

Great work on this, i'm using it succesfully on my Duco WTW DucoBox Energy for about half a year now.

My unit has an auto-bypass, which is nice but i'd like a bit more control over it. The bypass sensor is nice, but on the unit i can change it from auto to manual on/off. Is it possible to include the adaptive/auto/manual on/manual off as switches through the code? I have been looking at the referenced API document, but can't find reference to that...

If there's anything i can do to help let me know,

Thank you!

I don't want to hijack this pull but I understand where you are coming from, I have a Duco Energy Premium. I made a few changes and suggested these to the Author.

You can find it here, perhaps this may help you for now:
https://github.com/w1ll14m/esphome_duco/tree/duco-component

These changes are still quite experimental but seem to be working quite well for my Duco, though no guarantees for your system. I'm not responsible if you make it eat your cat or burn down your house ;)

My config:

duco:
  uart_id: duco_uart
  discovery: {}
  enable_advanced_features: true

text_sensor:
  - platform: duco
    serial:
      - name: "Serial Nr Box"
      - name: "Serial Nr Node 1"
        address: 1
      - name: "Serial Nr Node 2"
        address: 2
      - name: "Serial Nr Node 3"
        address: 3
    version:
      - name: "Version Box"
      - name: "Version Node 2"
        address: 2
      - name: "Version Node 3"
        address: 3
    error:
      - name: "Error Box"
      - name: "Error Node 2"
        address: 2
      - name: "Error Node 3"
        address: 3

select:
  - platform: duco
    mode:
      - name: "Mode Box"
      - name: "Mode node 2"
        address: 2
      - name: "Mode node 3"
        address: 3
    bypass:
      - name: "Bypass Control"
        address: 1
    adaptive_bypass:
      - name: "Adaptive Bypass Control"
    heater:
      - name: "Frost Protection Heater"
    passive_cooling:
      - name: "Passive Cooling"


sensor:
  - platform: duco
    temperature:
      - address: 1 #boxx
        name: "Box Temperature Sensor BOX1"
      - address: 2 #badkamer
        name: "Sensor Badkamer Temperature"
      - address: 3 #slaapkamer william
        name: "Sensor William Temperature"
      - address: 58
        name: "Box Temperature Sensor BOXINT58"

    humidity:
      - address: 1 #box
        name: "Box Humidity Sensor BOX1"
      - address: 2 #badkamer
        name: "Sensor Badkamer Humidity"
      - address: 58 #internal box sensor
        name: "Box Humidity Sensor BOXINT58"

    co2:
      - address: 3 #slaapkamer william
        name: "Sensor William CO2"

    filter_remaining:
      name: "Box Filter Time Remaining"
    flow_level:
      name: "Box Flow Level"
    time_remaining:
      name: "Box Mode Time Remaining"
    temperature_eha:
      id: aoout
      name: "Box Temperature Outdoor Exhaust"
    temperature_eta:
      id: aiout
      name: "Box Temperature Indoor Exhaust"
    temperature_sup:
      id: aiin
      name: "Box Temperature Indoor Supply"
    temperature_oda:
      id: aoin
      name: "Box Temperature Outdoor Air"
    bypass:
      name: "Box Bypass"
  - platform: template
    name: "Box Delta T AirFlow Temperature Inside"
    id: Tai
    unit_of_measurement: °C
    update_interval: 30s
    lambda: |-
      return (id(aiin).state - (id(aiout).state));
  - platform: template
    name: "Box Delta T AirFlow Temperature Outside"
    id: Tao
    unit_of_measurement: °C
    update_interval: 30s
    lambda: |-
      return (id(aoin).state - (id(aoout).state));

number:
  - platform: duco
    comfort_temperature:
      - name: "Zone1 Comfort Temperature 13"
        address: 0x13 #default address is 12?
      - name: "Zone2 Comfort Temperature 14"
        address: 0x14 #default address is 12?
    passive_cooling:
      - name: "Passive Cooling Setpoint"
    nightboost_max:
      - name: "Nightboost Max Ventilation Percentage"
    box_ventilation_min:
      - name: "Box Ventilation Min"
    box_ventilation_max:
      - name: "Box Ventilation Max"



uart:
  - id: duco_uart
    baud_rate: 57600
    tx_pin: GPIO3
    rx_pin: GPIO1
    rx_buffer_size: 256

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants