Hi,
I bought 4 energy meters ET112 for a better understanding of my cusumption and was surprised when I tried to connect them on the same RS485 bus because we cannot define the slave address of meters on Modbus RTU.
After many research, I found out the problem come from dbus-cgwacs module and exactly, in ac_sensor_mediator.cpp file.
In AcSensorMediator::AcSensorMediator constructor, there is a loop for (int i=1; i<=2; ++i) that limit to sensors having slave address 1 or 2.
A minimal and simple improvement could be to increase this number from 2 to 10.
And an even better solution but more complex could be defining slave addresses in a dbus-spy setting.
For my use, I tried to build a dbus-cgwacs executable but I stopped on way because it’s not simple to create a build environement when we are not use to it.
For the next release, could you increase the number in the loop
=> change for (int i=1; i<=2; ++i)
=> to for (int i=1; i<=10; ++i)
Thanks a lot,
David