rscada / libmbus

Meter-bus library and utility programs
http://www.rscada.se/libmbus
BSD 3-Clause "New" or "Revised" License
217 stars 137 forks source link

Composite device (multiple mbus addresses) always returns value of port #1 #140

Open Smeedy opened 5 years ago

Smeedy commented 5 years ago

Hi there,

So I'm in a bit of a pickle with a vendor who is providing a T/M converter. This device has 4 ports which can hold a PTC-resistor used to measure temperatures. Each port can be configured to a different mbus-address. So port 1..4 can - for arguments sake - be configured to primary mbus-address 1..4

When scanning using libmbus I see the device on the bus occupying 4 primary addresses. When retrieving data for every address, I always get the XML telegram of the first port. Other software (MBSheet i.e.) does report the correct values for every address/port. So this is the 'works on my end' pickle I'm in.

To make things more interesting, some of these T/M converter devices also have secondary addresses configured. When retrieving data for the secondary address, all is well. So sec-address 1 correspond to port #1, sec-address 2 to port #2, and so on.

My first reaction is this is a vendor bug as we have 9 devices on the bus and we never misfire (that is we always get the correct telegram from the correct device). Or do we have an issue within libmbus? So I need to start debugging the signals on the bus using my Saleae logic analyser? Or has someone has some other trick I can try?

Thanks, Martijn