Posted by: @cathoderaywhat about 120 ohm resistors?
I may review my decision about this over time. [Circulator] Pump modbus is over TCP/IP, the Heat Pump is over RS485. Screen shot is of flow rate x 2 sources, temperature x 2 sources, there are some bad reads
I finally managed to get time to install the MIM-B19N modbus interface into my Samsung 8kw HT Quiet at the weekend. I'm integrating it with Home Assistant slightly differently again, using an ESP32 rather than a Raspberry Pi.
With the ESP32, you can install ESPHome and configure it in a similar way to how @william1066 is. ESPHome is built by the same folks as Home Assistant (Nebu Casa) so it integrates seamlessly. I've put my config up here temporarily, and will put it into a repo once I've finished playing around.
I'm using an RS485 to TTL board, which is powered by the ESP32 via 3v or 5v pin depending on the board. I've tested it successfully with this one and this one.
From the outdoor unit to the RS485 board I ran some shielded Belden 8723 (equivalent, from here £22 for 25 meters). I've got a 120ohm resistor at both ends, but haven't connected the ground cable yet — I will do that at the RS485 end once I've finished setting up.
So far so good, no dropouts for the last 24 hours or so. The only thing I noticed was the target flow temperature (register 68) doesn't seem to read live when water law (weather compensation) is enabled and always returns 30ºC — that's the "low" water law target when outdoor temp is at 17ºC (it's currently ~5ºC outside).
@william1066 - all very interesting and useful, thank you. I don't think you mentioned the RS-485 to USB box you are using? The cheapo type or the more expensive 'isolating' type (where I think the 'isolating' keeps the two sides apart, neither can blow up the other one)?
The wires, of course I meant shielded not sheathed. The shielding, grounding and 120 ohm resistors are as I understand it about better a better cleaner signal. For short runs, poor signals are less of a problem, and as my run will be relatively short, about 5-10m, I will start by keeping things simple.
The trouble is, none of this is simple to a beginner! Let's say I want to rewire a table lamp. I know exactly what cable I need, and how to the job without blowing up the lamp, the house or myself. RS-485 cable? I have absolutely no idea, and as is usual with this stuff, google is your enemy. Within 10 minutes, you will have 50 tabs open and none of them make any sense. Down the bottomless rabbit hole I go again...
This is why a beginner's guide is so sorely needed. I am not stupid, and am reasonably capable with my hands, but none of that is of any use if I can find the practical details of what to do...
PS have however managed to make some progress on doing some of this wirelessly, see here.
Midea 14kW (for now...) ASHP heating both building and DHW
Hello @cathoderay,
since Midea family is pretty big (mine for example is local brand Rotenso) then some manuals are better than others, here is very good example:
https://www.clivet.com/en/edge-evo-2.0-exc
in general very nice lecture and well explained settings, what's more from page 143 of the manual you will find Modbus registers table.
Question how to get to the Modbus line, seems not clear if H1H2 are the right connectors (in manual says it's for cascade unit while on page 63: " This appliance supports the MODBUS RTU communication protocol"), then we have XYE: some Midea version of modbus...
really appreciate your work!
Posted by: @stevenSo far so good, no dropouts for the last 24 hours or so. The only thing I noticed was the target flow temperature (register 68) doesn't seem to read live when water law (weather compensation) is enabled and always returns 30ºC — that's the "low" water law target when outdoor temp is at 17ºC (it's currently ~5ºC outside).
I see the same with "Indoor Temperature" and "Target Indoor Temperature" when you are on external thermostat.
Posted by: @william1066I see the same with "Indoor Temperature" and "Target Indoor Temperature" when you are on external thermostat.
For the time being I've added a template sensor to calculate the approximate target flow temperature using y=mx+b. I added four number helpers into Home Assistant for the high/low values/targets then use the outdoor unit's outdoor temperature sensor as x. I realise water law/weather comp likely isn't strictly linear, but this should get me close enough.
You can see in the graph from this morning it reaches the calculated target temperature, then once the house is 1ºC below the thermostat (Wiser) it starts it's 3 cycles per hour before the DHW kicks in at 8am.
template:
- sensor:
- name: Target Flow Temperature
unique_id: target_flow_temperature_calculated
unit_of_measurement: "ºC"
device_class: temperature
state: >
{% set ashp = {
"low": states('input_number.wl_low') | int,
"low_target": states('input_number.wl_low_target') | int,
"high": states('input_number.wl_high') | int,
"high_target": states('input_number.wl_high_target') | int
} %}
{% set m = (ashp.low_target - ashp.high_target)/(ashp.low - ashp.high) %}
{% set b = ashp.high_target - (m * ashp.high) %}
{{ (m * states('sensor.outdoor_temperature') | float) + b }}
Posted by: @william1066I see the same with "Indoor Temperature" and "Target Indoor Temperature" when you are on external thermostat.
-- Attachment is not available --
I have the same issue (with Samsung controller in Water Outlet mode but no external thermostat). It is frustrating to have to use a separate temperature sensor for Indoor Temp when the controller clearly still has that parameter!
I think the Samsung 'water law'/WC is linear so you should get the exact target flow temp with your method.
I wanted to have some control over the the flow temp whilst still having an element of weather compensation. I therefore have the Samsung controller in Water Outlet mode (which turns the internal WC off) and have implemented the WC curve/line in HA, and also added some basic load control (flow temp turned down 1 degree for every 0.1 degree above indoor temp target). This seems to work OK, so long as the Zigbee temperature sensor is working.
- name: "ASHP WL P"
state: >
{% set indoor = states('sensor.0x00124b0029282fdb_temperature') | float %}
{% set diff = indoor - (states('input_number.ashp_ha_indoor_target') | float) %}
{% if diff > 0 %}
{{ (diff * -10) | round(1)}}
{%- else -%}
{{0}}
{%- endif -%}
- name: "ASHP WL temp"
state: >
{% set outdoor = states('sensor.ashp_outdoor_temp') | float %}
{% set point1 = {
"outdoor_temp": 15,
"WL_temp": 35
}%}
{% set point2 = {
"outdoor_temp": -10,
"WL_temp": 50
}%}
{{ (states('sensor.ashp_wl_p') | float) + (states('input_number.ashp_wl_offset') | float) + point1.WL_temp + ((1-((outdoor - point2.outdoor_temp) / (point1.outdoor_temp - point2.outdoor_temp))) * (point2.WL_temp - point1.WL_temp)) }}
It needs an extra bit of logic to deal with outdoor temps below -10 and above 15.
Posted by: @AnonymousQuestion how to get to the Modbus line, seems not clear if H1H2 are the right connectors (in manual says it's for cascade unit while on page 63: " This appliance supports the MODBUS RTU communication protocol"), then we have XYE: some Midea version of modbus...
Thanks, that's very useful, I definitely recognise parts of that manual as being the same as the Midea manuals but the Edge Evo manual is less cryptic in places.
I think H1 and H2 are Midea speak for the conventional RS-485 A/B connections, and modbus-RTU is the protocal/language in use. XYE - like you, I think it is a proprietry Midea version of modbus. The cascade looks to me like it might be dealing with the master/slave setup required by RS-485/modbus (you have a salve cascade, with the slaves (heat pumps) cascaded via the CN30 H1/H2 connections). I think essentially if you put all the diagrams together it seems H1 and H2 are where you make the RS-485 A/B connections in the wired controller. The CN30 H1/H2 connectors on the heat pump PCBs are primarily for setting up slave cascades.
Midea 14kW (for now...) ASHP heating both building and DHW
This video from Homely is also quite informative. It shows the actual physical wire connection process to the Midea wired controller. Interestingly, no apparent ground/earth, but a 120 Ohm resistor is used.
There is a similar video for Samsung units.
Midea 14kW (for now...) ASHP heating both building and DHW
@william1066 I would be very interested if you could share your Home Assistant config. My MIM-B19N will hopefully be delivered by the weekend and looking forward to trying to get it all set up.
@redzer_irl I am in the process of putting my config and the process into github, but that requires some sanitising the config.
You need to "program" the MIM-B19N in the correct way, otherwise you get garbage data out.
I am not sure what sort of damage you can do if you don't do things correctly. Proceed at your own risk. it took me a while before I realised you had to program all registers in a single command [for each block], so my module and the heat pump survived a certain level of "test and learn".
Please read pages 17 and 18 in the manual “Modbus Interface Module MIM-B19N/MIM-B19NT”.
These two commands worked for me [please double check the Message Set IDs and their order before you execute these commands and change the device, if different]
mbpoll -m rtu -0 -r 6000 -b 9600 -d 8 -t 4:hex /dev/ttyUSB0 0x8238 0x8204 mbpoll -m rtu -0 -r 7000 -b 9600 -d 8 -t 4:hex /dev/ttyUSB0 0x411E 0x42D7 0x42D6 0x4087 0x406C 0x42E9 0x42F1 0x4067
The version of mbpoll I used is is as follows running on Ubuntu.
mbpoll/jammy,now 1.4.11+dfsg-2 amd64 [installed] command line utility to communicate with ModBus slave (RTU or TCP)
I am using the “Waveshare Industrial USB to RS485 Converter with original FT232RL”
Extracts from my ha config below. I have been reading the data for some time, I have only just started using the R/W registers, the R/W registers seems to be working fine now, so I now have much more sophisticated scheduling available via home assistant than I had before.
With the flow rate, I was converting to lpm, but may change that to keep it in m3/hr and then use a template sensor in HA to change that to lpm. There is no lpm in ha.
I am pushing all my ha data into an influxdb instance, with retention forever, this as a data backup, but also because it provides a useful way of building dashboards.
I suggest you implement the sensors first. Do that for a couple days or a week, check how reliable that is for you, then start with the R/W registers. I ran a couple weeks before moving my DHW and heating schedule into HA automations by writing to the heating and hot water registers.
Extracts from config, full file on github in the next couple of days.
modbus:
- name: "samsung"
type: serial
baudrate: 9600
bytesize: 8
method: rtu
parity: E
port: /dev/ttyUSB0
stopbits: 1
switches:
- name: Heating
unique_id: samsung_gen6_16kw_heating
slave: 1
address: 52
command_on: 1
command_off: 0
verify:
input_type: holding
delay: 10
address: 52
state_on: 1
state_off: 0
sensors:
- name: "Outside Temperature"
scan_interval: 60
slave: 1
address: 5
state_class: measurement
scale: 0.1
unit_of_measurement: °C
precision: 1
data_type: int16
- 27 Forums
- 2,495 Topics
- 57.8 K Posts
- 486 Online
- 6,220 Members
Join Us!
Worth Watching
Latest Posts
-
Below is a better quality image. Does that contain all ...
By trebor12345 , 26 minutes ago
-
Sorry to bounce your thread. To put to bed some concern...
By L8Again , 28 minutes ago
-
@painter26 — they (the analogue gauges) are subtly diff...
By cathodeRay , 1 hour ago
-
RE: What determines the SOC of a battery?
The answer from Fogstar was crisp. My hypothesis, su...
By Batpred , 1 hour ago
-
RE: Electricity price predictions
I am always impressed with how you keep abreast of so m...
By Batpred , 2 hours ago
-
RE: Setback savings - fact or fiction?
I fully understand your reasoning, same steady inputs s...
By cathodeRay , 2 hours ago
-
RE: Humidity, or lack thereof... is my heat pump making rooms drier?
@majordennisbloodnok I’m glad I posted this. There see...
By AndrewJ , 2 hours ago
-
RE: Testing new controls/monitoring for Midea Clone ASHP
@tasos and @cathoderay thanks. I have some history grap...
By benson , 4 hours ago
-
Our Experience installing a heat pump into a Grade 2 Listed stone house
First want to thank everybody who has contributed to th...
By Travellingwave , 5 hours ago
-
RE: Solis inverters S6-EH1P: pros and cons and battery options
Just to wrap this up here for future readers: The S...
By Batpred , 7 hours ago
-
RE: Struggling to get CoP above 3 with 6 kw Ecodan ASHP
Welcome to the forums.I assume that you're getting the ...
By Sheriff Fatman , 8 hours ago
-
RE: Say hello and introduce yourself
@editor @kev1964-irl This discussion might be best had ...
By GC61 , 9 hours ago
-
RE: Oversized 10.5kW Grant Aerona Heat Pump on Microbore Pipes and Undersized Rads
@uknick TBH if I were taking the floor up ...
By JamesPa , 24 hours ago
-
RE: Getting ready for export with a BESS
I would have not got it if it was that tight
By Batpred , 1 day ago
-
RE: Need help maximising COP of 3.5kW Valiant Aerotherm heat pump
@judith thanks Judith. Confirmation appreciated. The ...
By DavidB , 1 day ago
-
RE: Recommended home battery inverters + regulatory matters - help requested
That makes sense. I thought better to comment in this t...
By Batpred , 1 day ago
-
Bosch CS5800i 7kW replacing Greenstar Junior 28i
My heat pump journey began a couple of years ago when I...
By Slartibartfast , 1 day ago
-
RE: How to control DHW with Honeywell EvoHome on Trianco ActiveAir 5 kW ASHP
The last photo is defrost for sure (or cooling, but pre...
By JamesPa , 1 day ago
-
RE: Plug and play solar. Thoughts?
Essentially, this just needed legislation. In Germany t...
By Batpred , 1 day ago
-
RE: A Smarter Smart Controller from Homely?
@toodles Intentional opening of any warranty “can of wo...
By Papahuhu , 1 day ago
-
RE: Safety update; RCBOs supplying inverters or storage batteries
Thanks @transparent Thankyou for your advic...
By Bash , 1 day ago
-
RE: Air source heat pump roll call – what heat pump brand and model do you have?
Forum Handle: Odd_LionManufacturer: SamsungModel: Samsu...
By Odd_Lion , 1 day ago
-
RE: Configuring third party dongle for Ecodan local control
Well, it was mentioned before in the early pos...
By F1p , 2 days ago





