New binding - Rego 6xx based heat pumps

I have the Modbus connection working now, bit tricky getting the addressing right but the most fundamental issue was that the heat meter needed a supply and my assumption at this was provided by the RS485 interface board VCC/GND connections was sadly misplaced. Temporary fix was a PP3 batter across the terminals and communications were established.

IĀ“m a fan of textual configuration. I have managed to configure it via PaperUI but when IĀ“m trying to do it via the text config I run into problem.

Any one who can show an example? Below is what IĀ“w tested

rego.things

Thing regoheatpump:ipHusdata:ivtIP [ address="10.0.1.6", tcpPort="6000" ]

rego.items

Number vpGT1 "Radiator Return (GT1) [%.1f ]" <temperature> (gVP) { channel="regoheatpump:ipHusdata:ivtIP:sensorValues#radiatorReturn" }

Hi!
I have been using this binding in Openhab 2.2 but lately it stopped working.
I updated Openhab to 2.3 today and deleted, then added binding and thing + items.

I use Husdata interface. But I only see the following errors in the openhab log. Any idea how to solve this? :

2018-11-17 18:15:48.981 [WARN ] [.regoheatpump.handler.HusdataHandler] - Processing request failed

java.io.IOException: Underlying input stream returned zero bytes

at sun.nio.cs.StreamDecoder.readBytes(StreamDecoder.java:288) ~[?:?]

at sun.nio.cs.StreamDecoder.implRead(StreamDecoder.java:326) ~[?:?]

at sun.nio.cs.StreamDecoder.read(StreamDecoder.java:178) ~[?:?]

at java.io.InputStreamReader.read(InputStreamReader.java:184) ~[?:?]

at java.io.BufferedReader.fill(BufferedReader.java:161) ~[?:?]

at java.io.BufferedReader.readLine(BufferedReader.java:324) ~[?:?]

at java.io.BufferedReader.readLine(BufferedReader.java:389) ~[?:?]

at org.openhab.binding.regoheatpump.handler.HusdataHandler.handleDataFromHusdataInterface(HusdataHandler.java:112) ~[?:?]

at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:?]

at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308) [?:?]

at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180) [?:?]

at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294) [?:?]

at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:?]

at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:?]

at java.lang.Thread.run(Thread.java:748) [?:?]

2018-11-17 18:15:50.601 [WARN ] [.regoheatpump.handler.HusdataHandler] - Processing request failed

java.io.IOException: Underlying input stream returned zero bytes

at sun.nio.cs.StreamDecoder.readBytes(StreamDecoder.java:288) ~[?:?]

at sun.nio.cs.StreamDecoder.implRead(StreamDecoder.java:326) ~[?:?]

at sun.nio.cs.StreamDecoder.read(StreamDecoder.java:178) ~[?:?]

at java.io.InputStreamReader.read(InputStreamReader.java:184) ~[?:?]

at java.io.BufferedReader.fill(BufferedReader.java:161) ~[?:?]

at java.io.BufferedReader.readLine(BufferedReader.java:324) ~[?:?]

at java.io.BufferedReader.readLine(BufferedReader.java:389) ~[?:?]

at org.openhab.binding.regoheatpump.handler.HusdataHandler.handleDataFromHusdataInterface(HusdataHandler.java:112) ~[?:?]

at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:?]

at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308) [?:?]

at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180) [?:?]

at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294) [?:?]

at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:?]

at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:?]

at java.lang.Thread.run(Thread.java:748) [?:?]

2018-11-17 18:15:52.220 [WARN ] [.regoheatpump.handler.HusdataHandler] - Processing request failed

java.io.IOException: Underlying input stream returned zero bytes

at sun.nio.cs.StreamDecoder.readBytes(StreamDecoder.java:288) ~[?:?]

at sun.nio.cs.StreamDecoder.implRead(StreamDecoder.java:326) ~[?:?]

at sun.nio.cs.StreamDecoder.read(StreamDecoder.java:178) ~[?:?]

at java.io.InputStreamReader.read(InputStreamReader.java:184) ~[?:?]

at java.io.BufferedReader.fill(BufferedReader.java:161) ~[?:?]

at java.io.BufferedReader.readLine(BufferedReader.java:324) ~[?:?]

at java.io.BufferedReader.readLine(BufferedReader.java:389) ~[?:?]

at org.openhab.binding.regoheatpump.handler.HusdataHandler.handleDataFromHusdataInterface(HusdataHandler.java:112) ~[?:?]

at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:?]

at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308) [?:?]

at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180) [?:?]

at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294) [?:?]

at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:?]

at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:?]

at java.lang.Thread.run(Thread.java:748) [?:?]

Finally found some (free) time and was able to add some improvements/features to the binding:

  • binding is now using the Units Of Measurement feature,
  • added new channels,
  • implemented write support.

While UoM was added for all supported things, new channels and write support is available only for rego 6xx thing(s).

New channels:

  • heatPumpInOperationDHW - heat pump in operation while heating DHW - number of hours,
  • heatPumpInOperationRAD - heat pump in operation while heating radiators - number of hours,
  • addHeatInOperationDHW - additional heat in operation heating DHW - number of hours,
  • addHeatInOperationRAD - additional heat in operation heating radiators - number of hours,
  • summerDisconnection - the function means the heat pump only produces hot water when the outdoor temperature rises above the set value.
  • heatCurve2 - mix valve curve,
  • heatCurve2FineAdj - mix valve fine tune.

@cgrill75 - as far as I tested, 0x048 and 0x04A both belong to heat pump operation time (without additional heating) - summed together, they give the value in section 7.1 (0x048 = time used for heating radiators, 0x04A = time used to heat DHW).

Please note mapping is done using error and trial since there is no documentation available (known to me) so there is no guarantee values are actually correctly mapped - any feedback greatly appreciated.

Write support - channels:

  • hotWaterTarget
  • heatCurve
  • heatCurveFineAdj
  • indoorTempSetting
  • curveInflByInTemp
  • adjCurveAt20
  • adjCurveAt15
  • adjCurveAt10
  • adjCurveAt5
  • adjCurveAt0
  • adjCurveAtMinus5
  • adjCurveAtMinus10
  • adjCurveAtMinus15
  • adjCurveAtMinus20
  • adjCurveAtMinus25
  • adjCurveAtMinus30
  • adjCurveAtMinus35
  • heatCurveCouplingDiff
  • heatCurve2
  • heatCurve2FineAdj
  • summerDisconnection

If somebody want to give it a spin, please download from here - looking forward to your feedback!

1 Like

Really nice job! Iā€™ll test ASAP.

Hi, great job. Many thanks.
I tested briefly on my test environment (so far I donā€™t have OH2 in operation) and I have tested these NEW functions sucessfully on my Rego637 in an IVT heatpump (using the LAN functionality):
heatPumpInOperationRAD: Works correctly and shows same value as on the display.
Write support:
summerDisconnection, indoorTempSetting

In addition to what I had previously used (various channels on deviceValues and controlValues, the front panel values powerLamp and heatPumpLamp and the status values LastErrorDate and LastErrorType) all worked like a charm.

The only thing that seems a bit odd is that in PaperUI, indoorTempSetting seems to be accepting integer values only through the up/down buttons, however, it is possible to key in e.g. 23.5 and it will accept the new value). summerDisconnection works as a decimal as it should. Both Items have Number.Temperature as type so I would assume they should both behave identically.

As mentioned before, I am not using the hot water function on my heatpump nor the additional electrical heater, so I canā€™t test that part of the new functions.

Did some more testing.
It seems that other settings, such as HeatCurveCouplingDiff, have the same integer issues.

I also looked into the AdjustHeatCurveAtxxx settings. It seems they are non-functional at all. Although all of them produce actual values, they are usually in the range between -1 to +1Ā°, showing a nice curve distribution. However, on the heatpump itself, they are expressed as actual temperatures (e.g. 24.5Ā° for 0Ā° outside temperature).
I had first assumed that the AdjustHeatCurveAtxxx are offsetting the values that are created through HeatCurve and HeatCurveFineTune. However, changing an adjustment value on the heatpump display did not change any of the values in OpenHAB and vice versa.
Quite frankly, I would not invest too much time in making the AdjustHeatCurveAtxxx settings work as usually you fine tune them over the first/second year of operation (if at all) over the span of days or weeks and then never touch them again, so few of us will expose these values through OpenHAB. However, if you want to further work on them, I am happy to help through testing.

Thanks for the feedback @cgrill75!

I havenā€™t got the indoor sensor so was not able to test. I will add step=0.1 to the indoorTempSetting channel and I guess that will enable you to use 1/10 values within the PaperUI too.

When testing, I used something like:

Setpoint item=regoheatpump_ipRego6xx_ivt_settings_summerDisconnection minValue=10 maxValue=30 step=0.1

within the .sitemap and was able to step between all values, supported by the HP.

Regarding the AdjustHeatCurveAtxxx - I added those based on the mappings available from here but never actually used/tested them - will try to check if they are mapped correctly, but again - itā€™s error and trial so feedback greatly appreciated :wink:

For the sake of completeness, I use something like below when testing:

...
Frame label="Settings" {
  Setpoint item=regoheatpump_ipRego6xx_ivt_settings_hotWaterTarget minValue=35 maxValue=54 step=0.1
  Setpoint item=regoheatpump_ipRego6xx_ivt_settings_hotWaterTargetHysteresis minValue=2 maxValue=15 step=0.1
  Setpoint item=regoheatpump_ipRego6xx_ivt_settings_heatCurve minValue=0 maxValue=10 step=0.1
  Setpoint item=regoheatpump_ipRego6xx_ivt_settings_heatCurveFineAdj minValue=-10 maxValue=10 step=0.1
  Setpoint item=regoheatpump_ipRego6xx_ivt_settings_heatCurve2 minValue=0 maxValue=10 step=0.1
  Setpoint item=regoheatpump_ipRego6xx_ivt_settings_heatCurve2FineAdj minValue=-10 maxValue=10 step=0.1
  Setpoint item=regoheatpump_ipRego6xx_ivt_settings_summerDisconnection minValue=10 maxValue=30 step=0.1
}
Frame label="Operating times" {
  Text item=regoheatpump_ipRego6xx_ivt_operatingTimes_heatPumpInOperationRAD
  Text item=regoheatpump_ipRego6xx_ivt_operatingTimes_heatPumpInOperationDHW
  Text item=regoheatpump_ipRego6xx_ivt_operatingTimes_addHeatInOperationRAD
  Text item=regoheatpump_ipRego6xx_ivt_operatingTimes_addHeatInOperationDHW
}
...

Please note I done some re-grouping of channels in latest version and will make a new binding available ASAP, but above should give you the idea.

Created a PR. Please give it a spin, download from here.

NOTE: hotWaterTarget channel was moved from controlData to the setting group so all writable channels are within the setting group.

@alillebakk - based on provided info it seems as there is something wrong with your connection and not with the binding itself, were you able to make and progress?

@crnjan - Still no progress for me. The binding do work, but it seems like it misses 2 of 4 value updates. So the OpenHAB dont always know when a valve has gone from open to closed etc. Some values just stop to do updates, and only send those errors posted above. But other values from same interface keeps updating. see graph example below where two temp sensors has stopped working. In a couple of hours they normally is back on track, but we lose data from them until then.

I found a reported issue, will try to resolve it and share the binding here so you can test if it works better ā€¦

Just as an update, the PR with write support, UoM and some other improvements got merged so you can use the official binding now in latest OH snapshots.

Still looking into issue reported above for Husdata interface.

1 Like

Just updated openHAB to latest snapshot and started testing with my Ivt greenline / Rego 600:

2019-01-15 22:42:44.360 [vent.ItemStateChangedEvent] - ivtAdjustHeatCurve20 changed from NULL to 2.5 Ā°C
2019-01-15 22:42:44.580 [vent.ItemStateChangedEvent] - ivtAdjustHeatCurve15 changed from NULL to 2.3000000000000003 Ā°C

That long row of zeros should not be there. Could this be a problem with UoM?

Hereā€™s corresponding items:

Number:Temperature ivtAdjustHeatCurveMinus15 "PaluulƤmpƶ -15C" <settings> { channel="regoheatpump:ipRego6xx:greenline:settings#adjCurveAtMinus15" }
Number:Temperature ivtAdjustHeatCurveMinus20 "PaluulƤmpƶ -20C" <settings> { channel="regoheatpump:ipRego6xx:greenline:settings#adjCurveAtMinus20" }

BasicUI and HABDroid displays everything correctly with only one decimal.
Canā€™t debug it more right now but Iā€™ll continue later. Please tell me what info you need.

Edit #1:
Hot water target shows still under control data and not settings. Hot water target hysteresis is missing.

Hi! Thanks for the feedback - regarding the zeros thing - this was there before in previous version of binding that did not have UoM support and I guess it is related to OH type conversion - so you should be fine ignoring the zeros :wink: .

I had to remove the ā€œrego thingā€ from PaperUI and re-add it in order for new channels to take affect, but not sure if this was needed because I did replace the binding quite some times during development ā€¦ maybe worth a try, but it should be under settings group, I use something like:

Setpoint item=regoheatpump_ipRego6xx_ivt_settings_hotWaterTarget minValue=35 maxValue=54 step=0.1
Setpoint item=regoheatpump_ipRego6xx_ivt_settings_hotWaterTargetHysteresis minValue=2 maxValue=15 step=0.1

Not sure what you mean by ā€œhot water target hysteresis is missing.ā€? I can read/set itā€™s value without problems ā€¦

@asken11 - just FYI - in the latest version of the binding, this values (Running timeā€ and ā€œRunning time with additional powerā€) are now available:

  • heatPumpInOperationRAD
  • heatPumpInOperationDHW
  • addHeatInOperationRAD
  • addHeatInOperationDHW

my setup:

That is super! Now I really have to finish my build (It havenā€™t been high enough on my priority list!) But now with this and Grafana workingā€¦
Tnx

Hmm. After updating to the latest version I didnā€™t see any of thoseā€¦ :thinking:
I donā€™t mind them in the logs but when I create a setpoint for an writable channel and view the sitemap with HABDroid they haunt me there also.

Sorry I wrote in a hurry. I mean the channel ā€œhotWaterTargetHysteresisā€ is not visible in my system. Iā€™ll try and re-add ā€œrego thingā€ as you suggested above. Hopefully itā€™s caching problem.

Hm, I see something like:

How do you define those items that gives you problems?

Number:Temperature ivtAdjustHeatCurve20 "PaluulƤmpƶ 20C" <settings> { channel="regoheatpump:ipRego6xx:greenline:settings#adjCurveAt20" }
Setpoint item=ivtAdjustHeatCurve20 minValue=0 maxValue=4 step=0.1

As in your screenshot when viewed with browser everything works just fine. Try with the android app.