In a recent thread, we were talking about the TCP dongle. These references might link there ..?
https://community.givenergy.cloud/d/4218-idiot-guide-battery-idle-stuck-at-x/8
Vestas
hoggy
Rubikcube
I'm just starting out writing some givenergy_modbus code to monitor AC generation, to try to avoid clipping. (Obviously I chose day with no sun to start.) That's all working, but I was quite interested in the odd error messages I was getting. One was
Did not receive expected response type: ReadInputRegistersResponse != WriteHoldingRegisterResponse
Now what was interesting was that I had just done an API command from another window (to modify a register). So it was as if the dongle had sent the reply for that to the wrong TCP connection.
So an an experiment, I just ran a netcat instance to connect to the dongle, listening, but without sending any commands of its own. To my surprise, it seems to be receiving the responses to the commands I'm issuing from my script.
So just for kicks, I added a second netcat instance, and sure enough, it's seeing exactly the same data.
It's as if the dongle is broadcasting replies on all open TCP connections.
Is this known behaviour ? Unavoidable feature of modbus-tcp ? (The protocol does have a transaction-id field which could have been used.


