Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Boiler Pump Characteristic for Bosch Condens 8300iW #1802

Merged
merged 1 commit into from
Jun 28, 2024

Conversation

SLTKA
Copy link
Contributor

@SLTKA SLTKA commented Jun 15, 2024

Hi all,

This PR to add Pump Characteristic control to the boiler I have. I need some assistance with it as I'm new to ESP development (not new to software development overall). When you can confirm that changes make sense I can build and test with my S3 board.

I have some uncertainty which I describe below and in inline comments. Thanks in advance for assistance!

From manual

Page 32 https://bosch-au-en-techdoc.boschtt-documents.com/index/td?query=7738101047&searchType=query&sales=in_sales&iframe=0&adminToken=0&art=0,all&brand=
3-d1 Pump characteristic
• 0: Pump output proportional to the heat output
• 1: constant pressure 150 mbar
• 2: constant pressure 200 mbar
• 3: constant pressure 250 mbar
• 4: constant pressure 300 mbar
• 5: constant pressure 350 mbar
• 6: constant pressure 400 mbar

3-d3 Min. output of the heating pump
• 10 ... 100 %
Pump output at minimum heat output. Only available with pump characteristic 0.

3-d4 Max. output of the heating pump • 10 ... 100 %
Pump output at maximum heat output. Only available with pump characteristic 0.

My note: Looks like comment Only available with pump characteristic 0. isn't fully correct as if I set max to 40% and characteristic to 6 pump is running on 40% only.

Logs samples

Setting 3-d1 to 0 (offset 15) (HEX logs)

2024-06-10 10:36:59.396 TRACE 6442: [telegram] Rx: 89 08 E6 0F 00 B5
2024-06-10 10:36:59.437 TRACE 6443: [telegram] Rx: 88 00 F7 00 E6 00 00 3B FF 74 87 21 F4
2024-06-10 10:36:59.608 TRACE 6444: [telegram] Rx: 88 00 E6 0F 00 E5

Setting 3-d1 to 2 (offset 15) (non-HEX logs)

2024-06-10 10:31:24.016 TRACE 5871: [emsesp] controller(0x09) -W-> boiler(0x08), UBAParametersPlus(0xE6), data: 02 (offset 15)
2024-06-10 10:31:24.230 TRACE 5873: [emsesp] boiler(0x08) -B-> All(0x00), UBAParametersPlus(0xE6), data: 02 (offset 15)

Report on reading all UBAParametersPlus

2024-06-10 10:29:02.255 TRACE 5518: [emsesp] Me(0x0B) -R-> boiler(0x08), UBAParametersPlus(0xE6), length: 0x1B
2024-06-10 10:29:02.296 TRACE 5519: [emsesp] boiler(0x08) -W-> Me(0x0B), UBAParametersPlus(0xE6), data: 01 32 00 58 50 0C 00 00 06 FC 05 01 14 4B 19 00 00 00 00 1E 01 00 00 00 01 00 00
2024-06-10 10:29:02.509 TRACE 5521: [emsesp] boiler(0x08) -B-> All(0x00), UBAMonitorWWPlus(0xE9), data: 3C 02 5C 00 00 80 00 02 5C 46 00 15 11 22 00 B0 F7 00 8C B1 00 80 00 3C 01 00
2024-06-10 10:29:02.856 TRACE 5523: [emsesp] boiler(0x08) -B-> All(0x00), UBAMonitorSlowPlus(0xE5), data: 20 (offset 25)
2024-06-10 10:29:03.059 TRACE 5524: [emsesp] boiler(0x08) -B-> All(0x00), UBAMonitorSlowPlus(0xE5), data: 21 (offset 25)
2024-06-10 10:29:03.196 TRACE 5525: [emsesp] boiler(0x08) -B-> All(0x00), UBAMonitorSlowPlus(0xE5), data: 1F (offset 25)
2024-06-10 10:29:03.582 TRACE 5527: [emsesp] boiler(0x08) -B-> All(0x00), UBAMonitorSlowPlus(0xE5), data: 20 (offset 25)
2024-06-10 10:29:03.753 TRACE 5528: [emsesp] boiler(0x08) -B-> All(0x00), UBAMonitorSlowPlus(0xE5), data: 1F (offset 25)
2024-06-10 10:29:03.980 TRACE 5529: [emsesp] Me(0x0B) -R-> boiler(0x08), UBAParametersPlus(0xE6), length: 0x1B (offset 27)
2024-06-10 10:29:03.997 TRACE 5530: [emsesp] boiler(0x08) -W-> Me(0x0B), UBAParametersPlus(0xE6), data: 00 08 0D 78 00 00 00 00 00 (offset 30)

Setting 3-d3 to 41 (offset 14) (HEX log)

2024-06-10 10:37:54.837 TRACE 6556: [telegram] Rx: 89 08 E6 0E 29 9E
2024-06-10 10:37:54.908 TRACE 6557: [telegram] Rx: 88 00 E6 0D 4B 29 64

Setting 3-d3 to 29 (offset 14) (non-HEX log)

2024-06-10 10:34:33.801 TRACE 6164: [emsesp] controller(0x09) -W-> boiler(0x08), UBAParametersPlus(0xE6), data: 1D (offset 14)
2024-06-10 10:34:33.835 TRACE 6165: [emsesp] boiler(0x08) -B-> All(0x00), UBAParametersPlus(0xE6), data: 4B 1D (offset 13)

Note and question: Boiler replies with confirmation on offset 13, would it be problem for parsing? (Works well for custom entities)

Setting 3-d4 to 29 (offset 13) (HEX log)

2024-06-10 10:38:44.551 TRACE 6602: [telegram] Rx: 89 08 E6 0D 49 F8
2024-06-10 10:38:44.585 TRACE 6603: [telegram] Rx: 88 00 E6 0D 49 29 60

Custom user defined entities

I tested the following custom entities on my S3 board, they work fine (json):

{
  "type": "entities",
  "Entities": {
    "entities": [
      {
        "id": 0,
        "ram": 0,
        "device_id": 8,
        "type_id": 230,
        "offset": 15,
        "factor": 1,
        "name": "pumpcharacter",
        "uom": 0,
        "value_type": 2,
        "writeable": true
      },
      {
        "id": 1,
        "ram": 0,
        "device_id": 8,
        "type_id": 230,
        "offset": 13,
        "factor": 1,
        "name": "pumpmaxoutput",
        "uom": 3,
        "value_type": 2,
        "writeable": true
      },
      {
        "id": 2,
        "ram": 0,
        "device_id": 8,
        "type_id": 230,
        "offset": 14,
        "factor": 1,
        "name": "pumpminoutput",
        "uom": 3,
        "value_type": 2,
        "writeable": true
      }
    ]
  }
}

System status

EMS-ESP Version

3.6.5
System Uptime

014+13:10:20.932
SDK

ESP32 Arduino v2.0.14 / ESP-IDF v4.4.6-dirty
CPU

ESP32-S3/ESP32-S3 (rev.0, dual-core) @ 240 Mhz
Heap (Free / Max Alloc)

194 KB / 175 KB
PSRAM (Size / Free)

8,189 KB / 8,161 KB
Flash Chip (Size / Speed)

16,384 KB / 80 MHz
Application (Partition: Used / Free)

app1: 2,139 KB / 5,989 KB
File System (Used / Free)

24 KB / 40 KB

@SLTKA SLTKA force-pushed the feature/pump-characteristic branch from 18a9fc9 to 46bc214 Compare June 15, 2024 12:41
@@ -197,6 +197,12 @@ MAKE_WORD_TRANSLATION(deltaP1, "deltaP-1", "deltaP-1", "deltaP-1", "", "delta P-
MAKE_WORD_TRANSLATION(deltaP2, "deltaP-2", "deltaP-2", "deltaP-2", "", "delta P-2", "deltaP-2", "", "deltaP-2", "deltaP-2", "deltaP-2") // TODO translate
MAKE_WORD_TRANSLATION(deltaP3, "deltaP-3", "deltaP-3", "deltaP-3", "", "delta P-3", "deltaP-3", "", "deltaP-3", "deltaP-3", "deltaP-3") // TODO translate
MAKE_WORD_TRANSLATION(deltaP4, "deltaP-4", "deltaP-4", "deltaP-4", "", "delta P-4", "deltaP-4", "", "deltaP-4", "deltaP-4", "deltaP-4") // TODO translate
MAKE_WORD_TRANSLATION(pressure1, "150mbar", "150mbar", "150mbar", "150mbar", "150mbar", "150mbar", "150mbar", "150mbar", "150mbar", "150mbar") // TODO translate
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Is 150mbar good or better to put something like Pressure 1?

Copy link
Contributor

Choose a reason for hiding this comment

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

I guess it depends if its a set value for all of the Bosch Condens range. Are these values also described as such in the manual?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I've included extract from manual in PR description to simplify this decision for you :) Happy to update to how you think it should be

@proddy
Copy link
Contributor

proddy commented Jun 15, 2024

wow, not bad for a first attempt! It's not easy navigating through EMS-ESP. I even sometimes forget how we built it, so hats off. I'll take a look...

@@ -288,6 +288,7 @@ MAKE_ENUM(enum_flow, FL_(off), FL_(flow), FL_(bufferedflow), FL_(buffer), FL_(la
MAKE_ENUM(enum_reset, FL_(dash), FL_(maintenance), FL_(error), FL_(history), FL_(message))
MAKE_ENUM(enum_maxHeat, FL_(0kW), FL_(2kW), FL_(3kW), FL_(4kW), FL_(6kW), FL_(9kW))
MAKE_ENUM(enum_pumpMode, FL_(proportional), FL_(deltaP1), FL_(deltaP2), FL_(deltaP3), FL_(deltaP4))
MAKE_ENUM(enum_pumpCharacter, FL_(proportional), FL_(pressure1), FL_(pressure2), FL_(pressure3), FL_(pressure4), FL_(pressure5), FL_(pressure6))
Copy link
Contributor Author

Choose a reason for hiding this comment

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

From maintainers point of view should this be as I put it (pressure1, pressure2, ...) or as per manual (pressure150, preassure200, ...)? My thoughts were that actual mbar values may be different from boiler to boiler

@SLTKA
Copy link
Contributor Author

SLTKA commented Jun 15, 2024

@proddy This part is challenging me:

You already have code to set pupm max output (offset 13 on EMS_TYPE_UBAParametersPlus)


// set max pump modulation
bool Boiler::set_max_pump(const char * value, const int8_t id) {
    int v;
    if (!Helpers::value2number(value, v)) {
        return false;
    }

    if (is_received(EMS_TYPE_UBAParametersPlus)) {
        write_command(EMS_TYPE_UBAParametersPlus, 13, v, EMS_TYPE_UBAParametersPlus);
    } else {
        write_command(EMS_TYPE_UBAParameters, 9, v, EMS_TYPE_UBAParameters);
    }

    return true;
}

but I have some doubts if it should be separate as well as pumpModMax_ on others. Should I add pumpOutMax_ and completely split the logic?

@proddy
Copy link
Contributor

proddy commented Jun 21, 2024

@proddy This part is challenging me:

You already have code to set pupm max output (offset 13 on EMS_TYPE_UBAParametersPlus)


// set max pump modulation
bool Boiler::set_max_pump(const char * value, const int8_t id) {

but I have some doubts if it should be separate as well as pumpModMax_ on others. Should I add pumpOutMax_ and completely split the logic?

Not sure. What do you suggest @MichaelDvP ?

@proddy proddy added this to the v3.7.0 milestone Jun 21, 2024
@proddy proddy added the enhancement New feature or request label Jun 21, 2024
@MichaelDvP
Copy link
Contributor

The pumpModMax_ should work in the combined version.
The pumpCharacter is an ems+ variant of pumpMode_ with 6 instead of four pressures. You can use your own set_pumpCharacter or integrate as if.. in set_pumpMode. We always receive only one set telegram for ems or ems+. So it's safe to check the received status.

@SLTKA
Copy link
Contributor Author

SLTKA commented Jun 23, 2024

The pumpModMax_ should work in the combined version. The pumpCharacter is an ems+ variant of pumpMode_ with 6 instead of four pressures. You can use your own set_pumpCharacter or integrate as if.. in set_pumpMode. We always receive only one set telegram for ems or ems+. So it's safe to check the received status.

Thanks @MichaelDvP , it looks like I can keep the code as is then and keep using the existing variables. I think it is reasonable to add pumpCharacter to avoid confusion between 4 and 6 options.

@proddy or @MichaelDvP do you think it should be safe to install dev (my) branch build to my device? Asking because I'm not aware what other changes are in 3.7.0

@MichaelDvP
Copy link
Contributor

@proddy or @MichaelDvP do you think it should be safe to install dev (my) branch build to my device? Asking because I'm not aware what other changes are in 3.7.0

Yes, i think it's safe. But there are 458 commits with 479 files changed in the dev. I can't remember all. A lot of issues in main are fixed and maybe some new issues added. Try it, report issues and if you are not happy, go back to main release.

This adds support for pump characteristic and pump output settings
for 0xE6 type
@SLTKA SLTKA force-pushed the feature/pump-characteristic branch from 46bc214 to deedd49 Compare June 27, 2024 11:50
@SLTKA
Copy link
Contributor Author

SLTKA commented Jun 27, 2024

Hi @MichaelDvP looks like it works well. Synchronized with the latest dev branch (dev-18) and installed ci_s3 build to my device.
image
Looks good in home assistant as well:
image

What would be the next step for this PR?

@proddy
Copy link
Contributor

proddy commented Jun 28, 2024

Start a review and Michael and I can take a look. It also needs some documentation to add to the Wiki

@MichaelDvP
Copy link
Contributor

It's just the ems+ variant of (ems) pumpmode with 6 defined pressures instead of 4 undefined pressure settings. I don't think an extra docmentation is needed. For me it's all ok.

@proddy
Copy link
Contributor

proddy commented Jun 28, 2024

Ok

@proddy proddy merged commit 03e5834 into emsesp:dev Jun 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants