question

offgridsolutions avatar image
offgridsolutions asked

Modbus tcp data incorrect

Can somebody check the tcp registers, I’m using VenusGX units with a energy meter connected

all was working perfectly until the kWh reached 655.35 which is the max value for register A2B (2603) which I know Is the maximum for one word unsigned decimal. So I’ve switched the register to A3E (2622) and changed to double word but the register does not give the correct value,

the Venus is now showing 667 kWh but the register returns 710410.25

im running the latest firmware 2.60

any help would be appreciated

ive tried various programs to verify the plc results and all comeback with the same value

regards

shane

Venus GX - VGX
2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.

1 Answer
Les Mulder avatar image
Les Mulder answered ·

When you changed from reading a word to a dword, have you added any code for big/ittle endian conversion?

I'm not using the same system as you (I'm interrogating a BMV-712 to get total battery discharge), but in interpreting registers, I use a byte order of bigendian and a word order of littleendian to get the correct result - I get similar results to you if I interpret both as littleendian.

2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.