Thanks Michal!
I will try this next week. Looks great!
Hi Michal,
question. I Saw that you are having an Estia 4, I have an Estia 5 heat pump. Is the addressing the same or is it different?
E.g. outside temperature register address is 40019 for me. It is the 19th register entry and you are using address 18 in your code… Would be great if you can show which “register” entry you are referring to for the Estia 4.
I just see that register entry 40018 does not excist for Estia 4, so entry 40019 is the 18th entry for an Estia 4 and the 19th for Estia 5 i assume…
Hi,
It shoud be the same, look at the documentation.
Google this for manual:
BMS-IFMB0AWR-E_OM_EEU-002_Estia_Modbus_Interface_EN.pdf
For holding registers start address = (value of modbus address for registers) - 40001.
So if you want to read register number 40001 described in the manual, you work with address 0, if you to read 40005, you work with address 4.
Read the manual for Estia interface, everything you need to know is there.
I hope it helps.
M.
Ok. Clear…
Issue i have now is that i incorporated your code in config.yaml including one sensor to try but this sensor does not appear / i cannot select it in a UI… How can I check where the integration goes wrong?
I can see that data is polled via modbus, so i assume that the data arrives in home assistant…
If you setup the sensor in HA it should show in lovelace regardless of data fetching. Show me your code from config.yaml.
Look also in the log under system and if there is an error, copy and paste it here.
Everything bad should show there.
M.
after a full restart of HA it indeed shows in lovelace… Strange, I expected that a re-run of config.yaml would do the job… Thanks!
Now I added the code to automation.yaml… and I can add the automations but I do not get a slider, only a on/off slider… Would be great if you could give me a tip here how to improve
You have to add this to config.yaml. This code is for setting two helpers - sliders. Automations are there just for syncing data between sliders and Toshiba.
input_number:
setpoint_room:
name: Teplá voda
min: 40
max: 55
step: 1
unit_of_measurement: °C
setpoint_room2:
name: Otopná/chladící voda
min: 18
max: 35
step: 1
unit_of_measurement: °C
Excellent! It works. Now i am curious if also equipement data can be retreived via modbus. Like rpm of the fans or temperature of the cooling medium. This is outside the documented registers…
Further i would like to create an estimated COP efficiency. I am afraid that i will need flow data and consumed power…
small addition to the code as from october 2023: please remove the “count” lines, the data is counted automatically.
Ahoj Michale,
if I understood it correctly, I have to purchase the Modbus interface BMS-IFMB0UEW-E. It costs 15,000 CZK (600 EUR). Has anyone found a cheaper option?
Hi Michal @enzografix I have installed the same Toshiba RS485 module, L1 is blinking but any modbus requests from HA via waveshare gateway are not responded. I have configured waveshare to ModbusTCP<->ModbusRTU mode. My question:
Do you have any additional terminator resistor added ? Toshiba unit, by default, has connected terminator resistor but other end at Waveshare has nothing.
What is your setup of RS485 bus ?
Thank you very much.
Peter
Is here somebody who owns a MB unit and willing to document the AB protocol?
Is it possible to use BMS controller pararell with casual one?
According Toshiba documentation, secondary controller is not allowed if modbus unit is connected - share the same bus. Anyways, I still could not make this 600€ piece of hardware to work with R32 unit even though everything is connected right. My local dealer plays dead bug. Maybe I just return for RMA.
Peter
Hello Peter,
I had a similar problem, and I found the solution by changing the switches in the S1 set of the BMS-IFMB0UEW-E device. In my case I changed the source configuration to the series 5 configuration of the hydro unit.
Maybe you can try with another layout from another series.
In fact I recommend you to check all the switches of the BMS-IFMB0UEW-E device.
It is also important that you verify that you have the BMS-IFMB0UEW-E device. The BMS-IFMB0AWR-E device is only valid for series 4 and 5 hydro units.
Here are some screenshots of the BMS-IFMB0UEW-E device, the Waveshare “RS232/RS485 TO ETH” device, and the settings I have in the devices and in home assistant.
I hope this helps you, because it is very frustrating to have bought such an expensive device, without having positive results.
Photo of the BMS-IFMB0UEW-E device, switches and User manual:
Image Waveshare “RS232/RS485 TO ETH” conection and configuration:
Configuration.yaml:
# Toshiba Estia 4
modbus:
- name: Toshiba
type: tcp
host: 192.168.x.x # IP address of your waveshare
port: 1
sensors:
- name: Temperatura exterior
unit_of_measurement: °C
state_class: measurement
slave: 1
address: 18
input_type: holding
data_type: int16
scan_interval: 30
scale: 1
- name: Control temperatura Suelo Radiante
unit_of_measurement: °C
state_class: measurement
slave: 1
address: 14
input_type: holding
data_type: int16
scan_interval: 30
scale: 1
- name: Control temperatura ACS
unit_of_measurement: °C
state_class: measurement
slave: 1
address: 16
input_type: holding
data_type: int16
scan_interval: 30
scale: 1
- name: Control temperatura
unit_of_measurement: °C
state_class: measurement
slave: 1
address: 17
input_type: holding
data_type: int16
scan_interval: 30
scale: 1
- name: Cilindro temp. agua
unit_of_measurement: °C
state_class: measurement
slave: 1
address: 19
input_type: holding
data_type: int16
scan_interval: 30
scale: 1
- name: Temperatura entrada agua
unit_of_measurement: °C
state_class: measurement
slave: 1
address: 21
input_type: holding
data_type: int16
scan_interval: 30
scale: 1
- name: Temperatura salida agua
unit_of_measurement: °C
state_class: measurement
slave: 1
address: 22
input_type: holding
data_type: int16
scan_interval: 30
scale: 1
- name: Temperatura salida calentador agua
unit_of_measurement: °C
state_class: measurement
slave: 1
address: 23
input_type: holding
data_type: int16
scan_interval: 30
scale: 1
- name: Temperatura entrada circuito suelo radiante
unit_of_measurement: °C
state_class: measurement
slave: 1
address: 24
input_type: holding
data_type: int16
scan_interval: 30
scale: 1
- name: Estado Alarmas
slave: 1
address: 11
input_type: holding
data_type: int16
scan_interval: 30
- name: Codigo Alarma
slave: 1
address: 12
input_type: holding
data_type: int16
scan_interval: 30
- name: Unidad Alarma
slave: 1
address: 13
input_type: holding
data_type: int16
scan_interval: 30
Helio XurxoFB,
I got it working. Thx for you examples.
The only thing what’s not working is the displays in HA.
I don’t see the sliders etc.
Will you share your current configuration.yaml and your automation.yaml also witch frontend (i asume a lovelace) you uses?
Regards,
Leo
Hello Leo,
Regarding what you ask me, I don’t have yaml automation for this application. I have no programming knowledge and was not able to do it that way.
The yaml configuration I have for this application, I have shared it in my previous post.
I tell you how I managed to make it work (it’s not elegant, but it worked for me).
For the ON/OFF selectors and for the sliders, I have used helpers, because I was not able to make it work otherwise (I am quite novice in HA).
For ON/OFF I used boolean helpers.
For the sliders I used numeric type helpers (setting as maximum and minimum the ones I considered as maximum and minimum suitable for each case).
To send “orders” to the Toshiba machine, I used node-red. Attached is the JSON flow below.
Helpers images:
Lovelace Toshiba:
Node-red flow image:
JSON node-red flow:
[{"id":"eebb5d95cd83e80a","type":"tab","label":"Compartir_Toshiba","disabled":false,"info":"","env":[]},{"id":"9dbb1826f55d1884","type":"modbus-flex-write","z":"eebb5d95cd83e80a","name":"40006: Temp. ACS","showStatusActivities":false,"showErrors":false,"showWarnings":true,"server":"7f91eb9f08442e19","emptyMsgOnFail":false,"keepMsgProperties":false,"delayOnStart":false,"startDelayTime":"","x":1050,"y":120,"wires":[[],[]]},{"id":"928e9fdc9a778c1d","type":"function","z":"eebb5d95cd83e80a","name":"Temp. ACS","func":"msg.payload = { \n value: msg.payload, \n 'fc': 6, \n 'unitid': 1, \n 'address': 5 , \n 'quantity': 1 } \nreturn msg;","outputs":1,"timeout":0,"noerr":0,"initialize":"","finalize":"","libs":[],"x":750,"y":120,"wires":[["9dbb1826f55d1884"]]},{"id":"fc7392f65b8db62c","type":"poll-state","z":"eebb5d95cd83e80a","name":"Barra temp. ACS","server":"3c1b4095.37154","version":3,"exposeAsEntityConfig":"","updateInterval":"5","updateIntervalType":"num","updateIntervalUnits":"seconds","outputInitially":false,"outputOnChanged":true,"entityId":"input_number.temperatura_acs","stateType":"num","ifState":"","ifStateType":"num","ifStateOperator":"is","outputs":1,"outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"entityState"},{"property":"data","propertyType":"msg","value":"","valueType":"entity"},{"property":"topic","propertyType":"msg","value":"","valueType":"triggerId"}],"x":120,"y":120,"wires":[["928e9fdc9a778c1d"]]},{"id":"213b38321f0aadb8","type":"modbus-flex-write","z":"eebb5d95cd83e80a","name":"40004: Temp. Calefacción","showStatusActivities":false,"showErrors":false,"showWarnings":true,"server":"7f91eb9f08442e19","emptyMsgOnFail":false,"keepMsgProperties":false,"delayOnStart":false,"startDelayTime":"","x":1070,"y":180,"wires":[[],[]]},{"id":"815a66a4f29ca1e8","type":"function","z":"eebb5d95cd83e80a","name":"Temp. Calefacción","func":"msg.payload = { \n value: msg.payload, \n 'fc': 6, \n 'unitid': 1, \n 'address': 3 , \n 'quantity': 1 } \nreturn msg;","outputs":1,"timeout":0,"noerr":0,"initialize":"","finalize":"","libs":[],"x":770,"y":180,"wires":[["213b38321f0aadb8"]]},{"id":"f6ebb2e0421a6f8d","type":"poll-state","z":"eebb5d95cd83e80a","name":"Barra temp. Calefacción","server":"3c1b4095.37154","version":3,"exposeAsEntityConfig":"","updateInterval":"5","updateIntervalType":"num","updateIntervalUnits":"seconds","outputInitially":false,"outputOnChanged":true,"entityId":"input_number.temperatura_suelo_radiante","stateType":"num","ifState":"","ifStateType":"num","ifStateOperator":"is","outputs":1,"outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"entityState"},{"property":"data","propertyType":"msg","value":"","valueType":"entity"},{"property":"topic","propertyType":"msg","value":"","valueType":"triggerId"}],"x":140,"y":180,"wires":[["815a66a4f29ca1e8"]]},{"id":"7866ef793e2b781d","type":"modbus-flex-write","z":"eebb5d95cd83e80a","name":"40002: Calef. Suelo Radiante","showStatusActivities":false,"showErrors":false,"showWarnings":true,"server":"7f91eb9f08442e19","emptyMsgOnFail":false,"keepMsgProperties":false,"delayOnStart":false,"startDelayTime":"","x":1080,"y":300,"wires":[[],[]]},{"id":"4910959e0f82e8ec","type":"function","z":"eebb5d95cd83e80a","name":"Estado Calefacción","func":"msg.payload = { \n value: msg.payload, \n 'fc': 6, \n 'unitid': 1, \n 'address': 0 , \n 'quantity': 1 } \nreturn msg;","outputs":1,"timeout":0,"noerr":0,"initialize":"","finalize":"","libs":[],"x":770,"y":300,"wires":[["7866ef793e2b781d"]]},{"id":"f3bd32eb7a7590c8","type":"poll-state","z":"eebb5d95cd83e80a","name":"Estado Calefacción Suelo Radiante","server":"3c1b4095.37154","version":3,"exposeAsEntityConfig":"","updateInterval":"5","updateIntervalType":"num","updateIntervalUnits":"hours","outputInitially":false,"outputOnChanged":true,"entityId":"input_boolean.estado_suelo_radiante","stateType":"habool","ifState":"","ifStateType":"str","ifStateOperator":"is","outputs":1,"outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"entityState"},{"property":"data","propertyType":"msg","value":"","valueType":"entity"},{"property":"topic","propertyType":"msg","value":"","valueType":"triggerId"}],"x":180,"y":300,"wires":[["ee088d2bf502ef83"]]},{"id":"ee088d2bf502ef83","type":"change","z":"eebb5d95cd83e80a","name":"","rules":[{"t":"change","p":"payload","pt":"msg","from":"true","fromt":"bool","to":"1","tot":"str"},{"t":"change","p":"payload","pt":"msg","from":"false","fromt":"bool","to":"0","tot":"num"}],"action":"","property":"","from":"","to":"","reg":false,"x":460,"y":300,"wires":[["4910959e0f82e8ec"]]},{"id":"81cf76b8d57066d6","type":"poll-state","z":"eebb5d95cd83e80a","name":"Estado ACS","server":"3c1b4095.37154","version":3,"exposeAsEntityConfig":"","updateInterval":"5","updateIntervalType":"num","updateIntervalUnits":"hours","outputInitially":false,"outputOnChanged":true,"entityId":"input_boolean.estado_acs","stateType":"habool","ifState":"","ifStateType":"str","ifStateOperator":"is","outputs":1,"outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"entityState"},{"property":"data","propertyType":"msg","value":"","valueType":"entity"},{"property":"topic","propertyType":"msg","value":"","valueType":"triggerId"}],"x":110,"y":240,"wires":[["43b0c8240c02f2fb"]]},{"id":"cca336e609a9c085","type":"modbus-flex-write","z":"eebb5d95cd83e80a","name":"40001: Estado ACS","showStatusActivities":false,"showErrors":false,"showWarnings":true,"server":"7f91eb9f08442e19","emptyMsgOnFail":false,"keepMsgProperties":false,"delayOnStart":false,"startDelayTime":"","x":1050,"y":240,"wires":[[],[]]},{"id":"9444a925a463af11","type":"function","z":"eebb5d95cd83e80a","name":"Estado ACS","func":"msg.payload = { \n value: msg.payload, \n 'fc': 6, \n 'unitid': 1, \n 'address': 1 , \n 'quantity': 1 } \nreturn msg;","outputs":1,"timeout":0,"noerr":0,"initialize":"","finalize":"","libs":[],"x":750,"y":240,"wires":[["cca336e609a9c085"]]},{"id":"43b0c8240c02f2fb","type":"change","z":"eebb5d95cd83e80a","name":"","rules":[{"t":"change","p":"payload","pt":"msg","from":"true","fromt":"bool","to":"1","tot":"str"},{"t":"change","p":"payload","pt":"msg","from":"false","fromt":"bool","to":"0","tot":"num"}],"action":"","property":"","from":"","to":"","reg":false,"x":460,"y":240,"wires":[["9444a925a463af11"]]},{"id":"7f91eb9f08442e19","type":"modbus-client","name":"BMS-TCP-RTU","clienttype":"tcp","bufferCommands":true,"stateLogEnabled":false,"queueLogEnabled":false,"failureLogEnabled":true,"tcpHost":"192.168.3.232","tcpPort":"1","tcpType":"TCP-RTU-BUFFERED","serialPort":"/dev/ttyUSB","serialType":"RTU-BUFFERD","serialBaudrate":"9600","serialDatabits":"8","serialStopbits":"1","serialParity":"none","serialConnectionDelay":"100","serialAsciiResponseStartDelimiter":"0x3A","unit_id":1,"commandDelay":1,"clientTimeout":1000,"reconnectOnTimeout":false,"reconnectTimeout":2000,"parallelUnitIdsAllowed":true,"showErrors":false,"showWarnings":true,"showLogs":true},{"id":"3c1b4095.37154","type":"server","name":"Home Assistant","addon":true}]
I hope this can help you.
Regards,
Thanks
It helps a lot.
I also uses Node Red and it’s owrking now.
Regards,
Could you also show how your connection with heat pump looks?
Hi there, I’ve been following this thread for a while now, as I’ve been very disappointed with my Toshiba Estia heat pump, and I thought I might be able to improve it by a large degree by integrating it into Home Assistant. I thought about an idea slightly different to the aforementioned Modbus idea (which seems rather limited as they expose pretty few options on the card, despite the insane price/markup they sell the card for).
My use case is:
- have the temperature (Heating 1, Heating 2, Warm water heating) be controllable within Lovelace
- writing an Automation using the Solar energy predictor and weather integration, to guess at what time it would be best to heat; and optimizing to use surplus solar energy, as reported by the inverter (e.g. have the heat pump run at a power of ~50% (~1800W) instead of 100% (~3600W) when only 2kW of excess solar power are reported by the inverter)
- controlling the % at what the heat pump runs (e.g. to run at lower power at night, so as to not be as loud and disturb the neighbors)
Use case 1) would of course already be possible with this solution using Modbus, but the two others could not easily be achieved.
Now, like all modern heat pumps, the Toshiba Estia is (in theory) an inverter-heat pump, which means that the compressor should be controllable not only like an on-off switch, but also variably - according to the product sheet it should be possible to control from 0 and 10-100%.
However, by default the pump has some internal control logic that determines at what level the inverter drives the compressor, and this logic appears to be really bad (or just dumb) to me:
- turning on at full power for 15 min after a power outage (which is quite the contrary to what makes sense to do when the Fronius inverter flips to emergency power operation (which causes a short 1 min power outage) as the battery will automatically be drained by ~1 kWh by the heat pump) - which could be disabled with a hex code, but then you have to turn it on manually, which also really isn’t what’s supposed to happen
- just appears to “ignore” the setpoint temperature of warm water (?), e.g. when the water tank reaches 40°C and the setpoint is at 55°C it does not heat? - but when the setpoint is at 45°C and the tank is at 75°C (due to extra heater rod) it sometimes starts to heat randomly?
- using the automatic program just heats at random times, which are by chance basically always outside of the times PV power would be available (0:30, 3:00, 22:00, 23:30)
- warm water is always heated at 100% power (which is totally unnecessary)
- heating 1 & 2 seems to mostly run at either 0W or 1800W for me (as in on-off switching - which is really bad for heat pump longevity)
- (few other issues that I’ll not mention now)
Now most of these issues could potentially be solved by dropping the quite shitty inbuilt control logic from the loop, and instead re-implementing it as Home Assistant automation, so having the heat pump control just be a “dumb” interface to the inverter level.
This seams to not be possible over modbus:
As it exposes very few R/W registers, all of which are using the internal setpoint temperature controlling.