[Solved] Dsmr binding doesn't find any channels

Hi All,

Newbee here. Installed OpenHab 3 today (latest greates). Starting to find my way around. One of the things I would like to have running on OH3 is the smart energy meter. I’m using dsmrBridge for that (yup, Dutch. Kaifa E0026 meter).
I’ve been able to add the bridge binding. It says Status: online. But in the Channels tab I get:

This thing has no channels. Either the thing type doesn’t define channels, or they may be detected and appear later.

/var/log/openhab/events.log does give any strange messages:

2021-05-21 22:23:25.004 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'dsmr:dsmrBridge:bbffaf32ad' changed from UNINITIALIZED to INITIALIZING
2021-05-21 22:23:25.037 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'dsmr:dsmrBridge:bbffaf32ad' changed from INITIALIZING to UNKNOWN
2021-05-21 22:23:27.872 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'dsmr:dsmrBridge:bbffaf32ad' changed from UNKNOWN to ONLINE

I’ve to change the tty settings. I suppose they should be 8 bits, parity N and 1 stop bit @115200.

Should I manually add Things to the bridge? How do I do that? Put it in /etc/openhab/things?
Thanks for your help!

Cheers,
Tomsky

Hi Tomsky,

I suppose you’ve added the bridge via the UI? And have you read the binding page? DSMR binding.

In the UI under things you have an inbox. If the bridge is properly configured additional things should show in the inbox: in this case at least the electricity meter and the gas meter. You can add these things directly from the inbox. These two additional things have channels (all the meter readings).

Hi Chiuaua79,

Thanks for your fast reply. Indeed, I did add the bridge via the UI and have read the page you mention. But unfortunately the inbox does not receive the things, so apparently the bridge is not properly configured then? I can’t find a place to change the meter type (v4 I think in my case).

BTW When I do cat /dev/ttyUSB0 om the command line I get propperly formatted text data like:

/KFM5KAIFA-METER

1-3:0.2.8(42)
0-0:1.0.0(210521231653S)

And so on.

openhabian@openhabian:/etc/openhab/things $ stty -F /dev/ttyUSB0
speed 115200 baud; line = 0;
min = 232; time = 10;
-brkint -icrnl -imaxbel
-opost -onlcr
-isig -icanon -iexten -echo -echoe -echok -echoctl -echoke

My settings in openhab are 8 bits, parity normal, 1 stop bit and baud rate 115200

Your settings look correct to me for this smart meter. Only thing I can think of is that your openhab installation cannot read from ttyUSB0. I notice that you have openhabian installed. I don’t know if openhabian automatically assigns the dialout group (?and tty?) to user openhab or not, but that could be something to check. Otherwise I am lost also.

1 Like

The bridge has no channels so that message is correct.
If the bridge goes online it means it does receive data.
Can you do a manual discovery from the ui and does it report something in the log? Otherwise you can set a log level in the openhab console to DEBUG (log:set DEBUG org.openhab.binding.dsmr) to get more information on why it doesn’t detect the other things.

1 Like

cat /etc/groups gives me the following info:

tty:x:5:openhab,openhabian
dialout:x:20:openhabian,openhab

So that does did not seem to be the problem.

But Hilbrand’s hints were perfect. The manual discover was wat was needed. I found the Scan button after some clicking around in the UI.

For completeness I’ll add where I found it:
Things → Add thing with the blue plus → Choose dsmr binding → Press Scan
(Openhab 3.0.2)

Thanks