I think I could do the following with existing hardware:
Leave the pump as it is today and only block (prohibit) Domestic Hot Water (DHW) and heating when electricity price is too high.
These should both be available with my system:
Maybe you are right…Can you fill me in on how these units work?
They simply block the mode when active:
I can do it from the pump panel (FTC5) but haven’t managed to do it over Modbus.
So is there a tank of hot water somewhere that the Heat Pump heats?
I linked the slider with Z1 Heating Prohibit.
Once again, I don’t understand how the sensor gets value = 2.
yes, there is.
I am not an expert at the 16-bit data thing…2 may be 1…not sure really?
What does the local HMI (pump panel) say atm?
I’m away from the unit at the moment. Will see it in couple of hours.
Currently only option in remote control.
I’m now at the HMI and prohibit command doesn’t work.
Are you able to operate the device from the HMI?
What does the sensor do in responce?
Have you got working sensors setup to monitor all the functions that you can control from the HMI?
Do they all report as expected?
I’m able to use HMI and commands from there work as expected.
I tried to prohibit Z1 heating in the morning from HMI, pump blocked heating, but status didn’t update in HA sensor.
I was trying to set up node red modbus flow to read registers, for some time it worked, but now I can’t get the register values through debug anymore. For the next 6-7 hours I have only remote access to the system.
I have used node-red in the past and I must advise that I abandoned it because modbus control was sketchy and as more than 80% of my devices are modbus…for this period I recommend that you stick to basics and work with HA as the modbus integration is proving itself to be solid.
Idea to use node red was to get a second opinion from independent system about what is currently written in register. To see if anything changes when I change it through HA.
As I have serial RTU setup, it was inconvenient to unplug the RS485 adapter and plug it to PC to use some Modbus polling software.
Fair enough but I found that once a modbus sensor was setup in HA it is rock solid…not so when I was using node-red.
However there are many different modbus implementations in node-red and the one you are using may be fine. For you to decide.
I think it is best for you to setup solid sensors that you trust and observe indications as you operate the HMI for a while.
Once you know what to expect you can start to try to gain control from HA or Node-Red.
For you to decide.
I put Z1 heating (40) to prohibit mode from HMI.
Node red confirms this:
Array[0]= 40(40041).
Same is confirmed by sensor:
But there was very a big time delay.
When I set slider to 0, then it don’t change the register status.
After that I de-activated prohibit from HMI, but HA sensor still hasn’t picked up new status (node red has).
As long as you are happy with what node-red feeds back then thats fine.
Can you post your HA config for that sensor please?
NOTE: I recommend you should monitor only from node-red/HA for now…make all changes that you want from the HMI until you know what is being reported by your sensors is as you expect.
in configuration.yaml I have:
modbus:
name: hub1
type: serial
method: rtu
port: /dev/ttyUSB0
baudrate: 9600
stopbits: 1
bytesize: 8
parity: N
sensor: !include sensor.yaml
sensor.yaml
## MODBUS ##
- platform: modbus
registers:
- name: MelcoBEMS MINI (A1M) Firmware Version (READ ONLY)
hub: hub1
slave: 1
register: 10
# - name: Modbus Comms Counter (READ ONLY)
# hub: hub1
# slave: 1
# register: 11
- name: Fault Code (decimal) (READ ONLY)
hub: hub1
slave: 1
register: 12
- name: Soojuspump ON/OFF [25/40026]
hub: hub1
slave: 1
register: 25
- name: Operating Mode Stop/Heating [26/40027].2
hub: hub1
slave: 1
register: 26
- name: Operating Mode (DHW)[27/40028] (Normal/Eco)
hub: hub1
slave: 1
register: 27
- name: A/C Mode Z1 Heating(room temp)/Heating(curve) [28/40029].2
hub: hub1
slave: 1
register: 28
- name: Force DHW [37/40038] Normal/Force DHW
hub: hub1
slave: 1
register: 37
- name: Holiday [38/40039] Normal/Holiday
hub: hub1
slave: 1
register: 38
- name: DHW On Prohibit # [39/40040], On/Prohibit
hub: hub1
slave: 1
register: 39
- name: Heating On Prohibit Z1 #, On/Prohibit [40/40041]
hub: hub1
slave: 1
register: 40
- name: Status of heating
hub: hub1
slave: 1
register: 72
- name: Heat Pump Frequency – Master (READ ONLY)
hub: hub1
slave: 1
register: 73
- name: Sensor1
hub: hub1
unit_of_measurement: °C
slave: 1
register: 100
reverse_order: true
scale: 0.1
- name: Tank water temperature
hub: hub1
slave: 1
register: 105
unit_of_measurement: °C
scale: 0.01
- name: Heat Pump Master ON/OFF (READ ONLY)
hub: hub1
slave: 1
register: 127
- name: Boiler ON/OFF (READ ONLY)
hub: hub1
slave: 1
register: 144
- name: Booster Heater 1 ON/OFF (READ ONLY)
hub: hub1
slave: 1
register: 145
- name: Model Profile 1 (READ ONLY)
hub: hub1
slave: 1
register: 270
- name: Last Measured Heating Energy Produced – kWh part (READ ONLY)
hub: hub1
slave: 1
register: 292
unit_of_measurement: kWh
- name: Last Measured Heating Energy Produced – Wh part (READ ONLY)
hub: hub1
slave: 1
register: 293
unit_of_measurement: Wh
scale: 0.01
- name: Last Measured DHW Energy Produced – kWh part (READ ONLY)
hub: hub1
slave: 1
register: 296
unit_of_measurement: kWh
- name: Last Measured DHW Energy Produced – Wh part (READ ONLY)
hub: hub1
slave: 1
register: 297
unit_of_measurement: Wh
scale: 0.01
some debug as well:
2019-10-01 20:09:50 DEBUG (SyncWorker_10) [pymodbus.transaction] Changing transaction state from 'PROCESSING REPLY' to 'TRANSACTION_COMPLETE'
2019-10-01 20:09:50 ERROR (SyncWorker_10) [homeassistant.components.modbus.sensor] No response from hub hub1, slave 1, register 297
2019-10-01 20:09:50 DEBUG (SyncWorker_3) [pymodbus.transaction] Current transaction state - TRANSCATION_COMPLETE
2019-10-01 20:09:50 DEBUG (SyncWorker_3) [pymodbus.transaction] Running transaction 1434
2019-10-01 20:09:50 DEBUG (SyncWorker_3) [pymodbus.transaction] SEND: 0x1 0x3 0x0 0x1c 0x0 0x1 0x45 0xcc
2019-10-01 20:09:50 DEBUG (SyncWorker_3) [pymodbus.framer.rtu_framer] Changing state to IDLE - Last Frame End - 1569949790.811062, Current Time stamp - 1569949790.840063
2019-10-01 20:09:50 DEBUG (SyncWorker_3) [pymodbus.client.sync] New Transaction state 'SENDING'
2019-10-01 20:09:50 DEBUG (SyncWorker_3) [pymodbus.transaction] Changing transaction state from 'SENDING' to 'WAITING FOR REPLY'
2019-10-01 20:09:50 DEBUG (SyncWorker_3) [pymodbus.transaction] Transaction failed. (read failed: device reports readiness to read but returned no data (device disconnected or multiple access on port?))
2019-10-01 20:09:50 DEBUG (SyncWorker_3) [pymodbus.framer.rtu_framer] Frame - [b''] not ready
2019-10-01 20:09:50 DEBUG (SyncWorker_3) [pymodbus.transaction] Getting transaction 1434
2019-10-01 20:09:50 DEBUG (SyncWorker_3) [pymodbus.transaction] Changing transaction state from 'PROCESSING REPLY' to 'TRANSACTION_COMPLETE'
2019-10-01 20:09:50 ERROR (SyncWorker_3) [homeassistant.components.modbus.switch] No response from hub hub1, slave 1, register 28
2019-10-01 20:09:52 DEBUG (SyncWorker_5) [pymodbus.transaction] Current transaction state - TRANSCATION_COMPLETE
2019-10-01 20:09:52 DEBUG (SyncWorker_5) [pymodbus.transaction] Running transaction 1435
2019-10-01 20:09:52 DEBUG (SyncWorker_5) [pymodbus.transaction] SEND: 0x1 0x3 0x0 0x26 0x0 0x1 0x65 0xc1
2019-10-01 20:09:52 DEBUG (SyncWorker_5) [pymodbus.framer.rtu_framer] Changing state to IDLE - Last Frame End - None, Current Time stamp - 1569949792.042021
2019-10-01 20:09:52 DEBUG (SyncWorker_5) [pymodbus.client.sync] New Transaction state 'SENDING'
2019-10-01 20:09:52 DEBUG (SyncWorker_5) [pymodbus.transaction] Changing transaction state from 'SENDING' to 'WAITING FOR REPLY'
2019-10-01 20:09:55 DEBUG (SyncWorker_5) [pymodbus.transaction] Incomplete message received, Expected 7 bytes Recieved 0 bytes !!!!
2019-10-01 20:09:55 DEBUG (SyncWorker_5) [pymodbus.transaction] Changing transaction state from 'WAITING FOR REPLY' to 'PROCESSING REPLY'
2019-10-01 20:09:55 DEBUG (SyncWorker_5) [pymodbus.transaction] RECV:
2019-10-01 20:09:55 DEBUG (SyncWorker_5) [pymodbus.framer.rtu_framer] Frame - [b''] not ready
2019-10-01 20:09:55 DEBUG (SyncWorker_5) [pymodbus.transaction] Getting transaction 1435
2019-10-01 20:09:55 DEBUG (SyncWorker_5) [pymodbus.transaction] Changing transaction state from 'PROCESSING REPLY' to 'TRANSACTION_COMPLETE'
2019-10-01 20:09:55 ERROR (SyncWorker_5) [homeassistant.components.modbus.switch] No response from hub hub1, slave 1, register 38
2019-10-01 20:09:55 DEBUG (SyncWorker_0) [pymodbus.transaction] Current transaction state - TRANSCATION_COMPLETE
2019-10-01 20:09:55 DEBUG (SyncWorker_0) [pymodbus.transaction] Running transaction 1436
2019-10-01 20:09:55 DEBUG (SyncWorker_0) [pymodbus.transaction] SEND: 0x1 0x3 0x0 0x1c 0x0 0x1 0x45 0xcc
2019-10-01 20:09:55 DEBUG (SyncWorker_0) [pymodbus.framer.rtu_framer] Changing state to IDLE - Last Frame End - 1569949795.068959, Current Time stamp - 1569949795.101973
2019-10-01 20:09:55 DEBUG (SyncWorker_0) [pymodbus.client.sync] New Transaction state 'SENDING'
2019-10-01 20:09:55 DEBUG (SyncWorker_0) [pymodbus.transaction] Changing transaction state from 'SENDING' to 'WAITING FOR REPLY'
Factory just conformed that there were mistakes in the manual:
These registers are read only.
Question why sensors won’t update data remains.
I believe your syntax is out…
Should be 6 spaces to - name:
Putting it under the ‘g’ in registers:
Not directly under the ‘r’ in registers:
## MODBUS ##
- platform: modbus
registers:
- name: MelcoBEMS MINI (A1M) Firmware Version (READ ONLY)
hub: hub1
slave: 1
register: 10
EDIT: although my example is setup correctly its not displaying correctly?
Not sure why?
Just set it up like this says below.
Should be 6 spaces to - name:
Putting it under the ‘g’ in registers:
Not directly under the ‘r’ in registers: