Posted by: @iancalderbankI'm already reading most of the registers that the manual says are present on the EHS system (whether normal or "hidden", whether R or R/W) ,
I am assuming you did enable the new registers, for which the mim b19 module does not, out the box, have the commands to send.
You also need to program them in two commands/blocks, not once for each extended register #1 for the outdoor module and #2 for the wired remote?
[if you program the mim b19 module one extended register at a time, you get very strange behaviour]
Posted by: @cathoderayBasic python plus minimalmodbus can do it far more simply:
Maybe at a very basic level, once you need to join this with a whole host of additional criteria, you now either have to write an interface between your standalone code and HA, or start also collecting an processing a whole lot of data in your standalone code. At some point you start to have a mini HA.
The benefit of driving this from HA, is you can do stuff such as ("if no one is home ....", "when someone arrives home ...." etc), all with relative ease.
At some point I am expecting one of the very smart guys (those that write code 100 times faster than us mere mortals e.g. the Eliud Kipchoge equivalent in the HA/Python world) to have created a plugin that does similar stuff to Homely, taking data in regarding future weather and solar production etc.
I think it is worth preparing for the future, by navigating the Home Assistant learning curve now, rather than later [when you will invariably want this stuff]
Hi Ian,
Unfortunately I cannot see what is happening at your end, so must wait for your response. A copy of the data that you have obtained so far would probably be of use.
The fact that you can read data from the controller would indicate that Modbus communication has been established, but it may be useful to check the following:-
'Modbus interface module error status' in address 0
'Communication status' in address 50
'Unit type:' in address 51
I will do a little more investigation concerning Modbus, since it is many years since I used it in anger.
Posted by: @william1066Posted by: @iancalderbankI'm already reading most of the registers that the manual says are present on the EHS system (whether normal or "hidden", whether R or R/W) ,
I am assuming you did enable the new registers, for which the mim b19 module does not, out the box, have the commands to send.
You also need to program them in two commands/blocks, not once for each extended register #1 for the outdoor module and #2 for the wired remote?
[if you program the mim b19 module one extended register at a time, you get very strange behaviour]
Could you please expand on the above, preferably with examples.
I presume that you are aware that Modbus registers are 2 byte - 16 bit.
You could try this sniffer software using the trial period.
Posted by: @william1066I am assuming you did enable the new registers, for which the mim b19 module does not, out the box, have the commands to send.
You also need to program them in two commands/blocks, not once for each extended register #1 for the outdoor module and #2 for the wired remote?
[if you program the mim b19 module one extended register at a time, you get very strange behaviour]
Posted by: @derek-mI presume that you are aware that Modbus registers are 2 byte - 16 bit.
Could you please expand on the above, preferably with examples.
I've got the hidden registers being registered in two custom commands on boot of the ESP in my config here. I've put comments beside each register to explain what function they are registering, e.g. "0x8204, // Outdoor temperature". @iancalderbank provided you've kept this bit in your config, there's nothing else to register.
Posted by: @derek-mI presume that you are aware that Modbus registers are 2 byte - 16 bit.
In my config Ian's using, I've set "value_type: U_WORD" (where appropriate) (U_WORD = unsigned 16 bit integer from 1 register). There's one or two registers which use S_WORD to allow for negative values (e.g. outdoor temperature).
You may also find this informative.
Posted by: @stevenon boot of the ESP in my config here.
That is very impressive, I wimped out and ran a cable all the way to my HA machine 😀
I am not sure they are hidden registers, they are clearly documented in the manual that came with my module. They are "hidden" i.e. don't work at all if you don't program the module with the correct message set ids ... and in the "right way".
Posted by: @derek-mCould you please expand on the above, preferably with examples.
It seems there are commands the MIM-B19N module needs to send when it receives a modbus request. Likely because Samsung is using its own system.
The modbus translation needs to be set for two different targets. One target is the outdoor machine, and one target is the wired remote control. Programming the commands does not work if you try program the command one register at a time, I know, I spend a ton of time trying to work out why it was unreliable/not working at all. A bit of RTFM, and it finally clicked.
It is more confusing in the beginning because some registers work "out the box" and some don't. So if you are not in the habit of reading the entire manual, you may miss the fact of the "extended registers" i.e. those that don't work without the programming step below.
Below copied from the same post I made on the open energy monitor site.
Read pages 17 and 18 in the manual “Modbus Interface Module MIM-B19N/MIM-B19NT”, and then proceed with the below at your own risk.
The two commands that I used were (please double check the Message Set IDs and their order before you execute these commands)
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.
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”
Above commands run on Ubuntu, but should work on any OS for which mbpoll is available.
I've just tested writing to the Midea wired controller using minimalmodbus to see if I can do it without blowing up the whole shebang and it seems all works as it should. Here is the code to set the left hand end of the weather curve (I've left out the half dozen of so lines needed to set up the connection, and the zero argument at the end of each instruction sets the number of decimal places, ie none). The current curve before doing this was 58@-4 / 35@15:
>>> T1SetH1 = instrument.read_register(265, 0) >>> print(T1SetH1) 58 >>> instrument.write_register(265, 60, 0) >>> T1SetH1 = instrument.read_register(265, 0) >>> print(T1SetH1) 60 >>> instrument.write_register(265, 58, 0) >>> T1SetH1 = instrument.read_register(265, 0) >>> print(T1SetH1) 58 >>>
This is the basis of how I intend to implement a load adjusted weather compensation curve, along the lines of:
if desired_room_temp - actual_room_temp > 2: instrument.write_register(265, 60, 0) etc
This is concise, human readable and easy to maintain. What more could one want?
Midea 14kW (for now...) ASHP heating both building and DHW
Posted by: @william1066Posted by: @cathoderayBasic python plus minimalmodbus can do it far more simply:
Maybe at a very basic level, once you need to join this with a whole host of additional criteria, you now either have to write an interface between your standalone code and HA, or start also collecting an processing a whole lot of data in your standalone code. At some point you start to have a mini HA.
The benefit of driving this from HA, is you can do stuff such as ("if no one is home ....", "when someone arrives home ...." etc), all with relative ease.
At some point I am expecting one of the very smart guys (those that write code 100 times faster than us mere mortals e.g. the Eliud Kipchoge equivalent in the HA/Python world) to have created a plugin that does similar stuff to Homely, taking data in regarding future weather and solar production etc.
I think it is worth preparing for the future, by navigating the Home Assistant learning curve now, rather than later [when you will invariably want this stuff]
I think it rather depends on what one is trying to achieve. My two main objectives (others will have different objectives, and so different solutions) are simple heat pump monitoring, focused but not exclusively on efficiency, and simple adjustment of the weather comp curve to achieve a boost or throttle back depending on load, eg add a boost if room is colder than it should be, maybe after an overnight setback, and throttle back if room is warmer that it should be, maybe from solar gain. The idea of a smart home that knows not only how many people are in the house but also when each one will want to have a dump and so warms up the heated loo seat for them in advance fills me with horror. I have, as I am sure you know by now, an instinctive distrust of needless complexity. I was much happier with my trusty Morris Traveller (I once changed a head gasket by the roadside after it had blown miles from home, I luckily had the necessary tools in the car at the time and there was a motor factors a short distance away to get a new head gasket, widely available because almost so many Austin/Morris cars used the same block) than I am with my current VW Passat which has far far too many black boxes in it, none of which add any material benefit, and some of which are a RRPITA eg the electronic handbrake.
Homely can read the forecast but what it can't do is know the future and that is where it will struggle. I think we had this discussion a while back, but I would far rather rely on real data (as in my description of load balancing a weather comp curve above) than on the Michael Fish of today's guesstimates of what might happen. According to the Met Office forecast for where I live, it should be cloudy right now, in reality it is sunny intervals with mostly sun rather than cloud. Homely will make the wrong adjustments...
As a guiding principle, I like to make things as simple as possible, and then, when I have achieved that, make it even simpler.
Midea 14kW (for now...) ASHP heating both building and DHW
Posted by: @stevenI've got the hidden registers being registered in two custom commands on boot of the ESP in my config here. I've put comments beside each register to explain what function they are registering, e.g. "0x8204, // Outdoor temperature". @iancalderbank provided you've kept this bit in your config, there's nothing else to register.
I'm using @steven 's config from his github, copied line for line. The c++ lambda code at the start does the write to enable the "hidden / new" registers. I'm no coder but I can usually cope with following what working code that other people have written does. so my previous hypothesis about my system being entirely read-only must be wrong: my physical setup is able to write to modbus, otherwise the writing bit to enable those hidden/new registers wouldn't work.
I've also spent time reading glyn hudson's github and there's a brief note in the .py file saying "writing to register 68 doesn't work".
I've currently got all but one register commented out , debug in the ESP turned up to "very verbose" in an attempt to understand why mine can't successfully "write" to any of the R/W registers, but not getting anywhere with that yet.
the fundamental puzzler is that several people on here are able to get "W" to R/W registers working with config that is logically speaking the same as mine, and in one case completely identical (because I copied it - thanks again steven!), and mine won't work. there must be something different but I am yet to get a sniff of it.
My octopus signup link https://share.octopus.energy/ebony-deer-230
210m2 house, Samsung 16kw Gen6 ASHP Self installed: Single circulation loop , PWM modulating pump.
My public ASHP stats: https://heatpumpmonitor.org/system/view?id=45
11.9kWp of PV
41kWh of Battery storage (3x Powerwall 2)
2x BEVs
- 21 Forums
- 1,962 Topics
- 42.6 K Posts
- 75 Online
- 2,275 Members
Join Us!
Heat Pump Dramas?
Thinking about installing a heat pump but unsure where to start? Already have one but it’s not performing as expected? Or are you locked in a frustrating dispute with an installer or manufacturer? We’re here to help.
✅ Pre-Installation Planning
✅ Post-Installation Troubleshooting
✅ Performance Optimisation
✅ Complaint Support (Manufacturer & Installer)
Latest Posts
-
RE: Newbie out of her depth – Samsung AE120RXYDEG 12kW heat pump
@jamespa cannot find loss calculation. When they get i...
By BAMi , 13 minutes ago
-
RE: Towel rails. An unexpected final hurdle
We have both Normal Rad for heating the room and then a...
By IRMartini , 55 minutes ago
-
RE: Heat Pump Sizing & Installation Costs
Perhaps useful to have installed date too? To get conte...
By Tim441 , 3 hours ago
-
RE: What is the best strategy for operating a very oversized heat pump?
Something else... that works for some people... LG ha...
By Tim441 , 3 hours ago
-
RE: Setback savings - fact or fiction?
@cathoderay I see you are continuing to misquote from t...
By SUNandAIR , 4 hours ago
-
RE: Samsung Gen 7 R290 12kW is not behaving how I expected
So I turned my thermostats down last night And w...
By Joshua , 5 hours ago
-
RE: SolarPV tables / online calculator
I'd be interested what others find whilst using that we...
By Majordennisbloodnok , 5 hours ago
-
Volumisers in Heat Pump Systems: Does Placement Matter?
The debate over buffer tanks in heat pump systems has b...
By Mars , 6 hours ago
-
RE: F.788 Building circuit pump reports internal fault - Vaillant Arotherm
Guess I have to wait for engineer visit. I really hope ...
By jeegnesh , 17 hours ago
-
RE: Act now to defer the UK road tax increase on EVs
@majordennisbloodnok Damn right sir. my attempt at iron...
By Jancold , 20 hours ago
-
RE: ASHP and heating issues in new build house
That’s good gives you more capacity. It made me think, ...
By Terry1812 , 21 hours ago
-
RE: Seewet manhole cover within r290 exclusion zone
Thanks! I asked Vaillant, and they say I should be fi...
By dbrb2 , 24 hours ago
-
Looking for the Grant Aerona 3 setting to turn off completely at 20 OAT
I'm running my Aerona 3 on WC and the 'warm end of that...
By damonc , 1 day ago
-
RE: Do I just go with the lowest quote for my heat pump?
So after signing in Sept in two weeks the install may s...
By Jancold , 1 day ago
-
RE: Victorian Semi Retrofit / Extension ASHP and UFH Advice
When you are renovating is always a good time, as it ma...
By JamesPa , 1 day ago
-
RE: Just one room not reaching desired temperature
Looks like this issue is now resolved. Aira installed a...
By ChandyKris , 1 day ago
-
There have been several people on the OpenEnergyMonitor...
By RobS , 2 days ago
-
RE: Say hello and introduce yourself
Good point @jamespa But that probably strengthens @ch...
By Transparent , 2 days ago
-
RE: Visit a Heat Pump sessions.
Congratulations @toodles, that's a fantastic result. We...
By Old_Scientist , 2 days ago
Latest Topics
-
Heat Pump Sizing & Installation Costs
By Mars 5 hours ago
-
Volumisers in Heat Pump Systems: Does Placement Matter?
By Mars 6 hours ago
-
SolarPV tables / online calculator
By MichelleC 13 hours ago
-
By Toodles 2 days ago