New binding - Rego 6xx based heat pumps

I’m using ios client and there seems to be fine as well

maybe try setting precision with something like [%.1f]?

From the binding perspective, setting value to 3.600…01 will still set 3.6 so beside the strange output it should be safe …

Ok. Everything seems to work as it should. I learned to live with those zeros :slight_smile:

@crnjan and all other contributors!
Would you mind helping out a fellow Rego friend?
I’m not using OpenHAB, but an Arduino to communicate with my Rego and I’m looking for some info about theese registers:

heatPumpInOperationRAD", ChannelFactory.hours((short) 72));
heatPumpInOperationDHW", ChannelFactory.hours((short) 74));
addHeatInOperationRAD", ChannelFactory.hours((short) 76));
addHeatInOperationDHW", ChannelFactory.hours((short) 78));

What are the register names in HEX? Should I send 0x04A or 0x004A?
Will I find theese in 0x02 (sysreg) or 0x04 (timer reg) command?

I also wonder regarding writing to registers, must I send a “save” telegram after the telegram with the value or will it save the value with the telegram that contains the value?

And hopefully the last thing, anyone know what register 1B61, contains? command 0x06

Thanks! :slight_smile:

Hi!

I would suggest to take a look how command payload is created - here and here.

Technically there is no difference between 0x004A and 0x04A, both represent the same number :wink:

So in order to create a command to read i.e. “heatPumpInOperationRAD”, one would use something like

CommandFactory.createReadFromSystemRegisterCommand(72);

and the resulting byte array is what needs to be send to HP. Same goes for creating write command

CommandFactory.createWriteToSystemRegisterCommand(address, value)

sending the result of above function to HP will set system register with specified address to specified value.

Please note that HP’s response is different for read/write operations (also read operations might have different responses, depending of the register’s type). Details can be found here.

Not sure what the command 0x06 does, haven’t played with it :slight_smile:

Please let me know how it goes.

Thank @crnjan !
Have I understood correct that the Rego will send a response after I have sent a write command to it?
What will the response contain when I have sent a write command with new value for Heat Curve i.e?

I have managed to poll out Register, Device, Settings… I have the front panel and operation hours left aside of writing new values to the register. :slight_smile:

AFAIK a response for write command will contain a single byte with value = 0x01.

Hi @crnjan
Is there any update on the issue with Husdata interface? Did you have any time to look into it?

hi! sorry for super late reply but was (and still am) busy with other stuff … while trying to find a minute or two and fix the issue…

I checked it and seems to be related to usage of BufferedReader and its readLine which seems to fire java.io.IOException if there are no bytes to read, while I expected readLine would return null if there is nothing to read from underlaying stream (serial port for example). If some fellow developer has an idea how to address it, please let me know, otherwise I will implement a different (byte by byte) reading of stream in order to fix this.

I think I found the issue - NRSerialPort that is used by the binding will setup a read timeout

serial.enableReceiveTimeout(100);

and if there is nothing on the line to read it will cause those issues you see in the logs. I will create a test jar soon and share it here for anyone interested to confirm if it is resolved and create a PR after confirmation (I don’t own a Husdata interface :grimacing:).

Created potential fix for above issue, please see here.

@gitMiguel - with https://github.com/openhab/openhab2-addons/pull/6106 merged, the zeros should be gone now :wink:

1 Like

Nice :+1: