I,m trying set a negative value via mqtt and Modbus TCP in CCGX. I can write positive values.
What can I do?
This site is now in read-only archive mode. Please move all discussion, and create a new account at the new Victron Community site.
I,m trying set a negative value via mqtt and Modbus TCP in CCGX. I can write positive values.
What can I do?
In case someone would like to know, I have already figured out how to write negative values via ModbusTCP in the CCGX in register 2700 of the Register List.
This specific register is int16 and admits values between -32768 and 32768, but .... to write negative values you have to send 65536 minus the absolute value to send.
Example: if I want to write -50W in the GridSetPoint, via modbustcp I would have to write 65536-50, I mean, 64486.
I hope someone will find it useful.
It wasn't that difficult .....
Por si a alguien le viene bien saberlo, Ya he averiguado como escribir valoras negativos via ModbusTCP en la CCGX en el registro 2700 del Register List.
Este registro concreto es int16 y admite valores entre -32768 y 32768, pero....para escribir valores negativos hay que enviar 65536 menos el valor a enviar absoluto.
Ejemplo: si quiero escribir -50W en el GridSetPoint, via modbustcp tendria que escribir 65536-50, osea, 64486.
Espero que a alguien le sea útil.
No era tan dificil.....
Thanks, I was scratching my head over this one never would have worked that out in a month of Sundays.
30 People are following this question.