Nikobus v2

It takes between 20 and 45sec to update the status from “ON” to “OFF” or visa versa.

about the impactedModules parameter. which address should i type in?

If you have set all up as on your screenshots then switch-module:ac139383b4:2 should do the trick.

ac139383b4 = switch module’s id
2 = second group (module has 2 groups, 6 channels each - so channel 8 => second group)

Please see doc for details.

OK! that works instantly now!
i also understand your clarification about the :2 and i’ll re-read the doc better.

Can the lightbulb be turned on (yellow) and off? are those images that are in a library?

i’ll go ahead and add a push button with a feedback led in the same way as you instructed me.
i’ll keep you posted!

You can do all sort of stuff, the yaml I shared is just a simple (testing) widget.

Changing your yaml a bit:

- component: f7-icon
    f7: "=items.gBasement_HomeOffice_Light_Ceiling_Powered.state === 'ON' ? 'lightbulb_fill' : 'lightbulb'"

should change icon as well when turning light on/off. Icons used Framework7 Icons … and there are others too …

So far so good!
i was able to add multiple pushbuttons with the procedure you described.
Looks like this now:

performed some tests and only if i quickly click the toggle button of multiple
cards after eachother then sometimes the status is not updated. If i wait a long time it gets fixed or
when an update occures on the impacted modules address, then the status is shown correctly.
For example, these 4 lights are on the same switch module. If the status of “Keukeneiland” is out of sync and i can fix it by putting for example “Berging” on and off. I suppose this is because they are on the same impacted module?
Is the “refresh time” mandatory or can this be changed?

Interesting remark you gave me about the Framework7 Icons and that other librarys exist.
So component: f7-icon specifies which library to use. Is there a link with more information about this and how i can learn more about YAML for openHAB, library’s and so on?

Are the feedback LEDs working?

if i quickly click the toggle button of multiple
cards after eachother then sometimes the status is not updated

If impactedModules parameter is setup for push button(s) then each tap should trigger a channel read of respective switch module. Since status refresh is done on a group level, each status read returns values for 6 channels - so yes, if lights are within same group, one status refresh will update channel values for all 6 within that group.

I don’t think “quickly clicking” is a real use case, but if you see issues, please provide full logs with DEBUG level set for nikobus binding.

Is the “refresh time” mandatory or can this be changed?

Not sure what refresh time you mean?

There are a lot of good articles here in community regarding UI, i.e.

Yes, i can confirm that the feedback LED’s are working correctly, even if i “force” the system by pushing like an idiot on the available “Toggle” buttons. The feedback LED’s always keep following the real status of the lights! This is great news, your NikoBus binding rocks!

I will continue to add more lights and see how it evolves during “normal use”. I’ll let you know i the behavior comes back.

I also tested the behavior of multiple feedback LED’s. For example. i have a room with 3 doors. From each door you can control the lights in the room. And each push button has a feedback LED integrated. All my test went without any issues. The LED’s respond as fluent as when i use the physical buttons and the LED’s are updated at the same speed. This is great!

By the “refresh time” i meant the status refresh of a group on the switch module.

i’ll read through the articles you send me.
Is there a logica i need to follow? For example one page per room or floor of the building? And create cards in them corresponding to the real world. Or isn’t there a strict rule to follow?

Next thing on my list are the lights that are dimmable and are connected to my Dimmer module.
Can i re-use most of the code you send me and use the same approach or do they work differently?
I read your doc and saw you mention .things and .items files. I suppose that the Things and Items i created are stored elsewhere?

Glad to hear LEDs are also working.

You can ignore .things and .items files since you are adding items and things through UI - which I would recommend …

One question - all your push buttons have a feedback LED? Even those you use with dimmers?

yes indeed, almost all push buttons have feedback LED’s, even those i use with dimmers. Dimmers are configured with one push button. For some, the last dimmed value is used when they are switched on again. Pressing the pushbutton for a short or long time makes it dimming more or less. To reverse the process you stop pushing it and when you push it again for a short or long time it dimmes the other way. A short press switches the light of (or on).

Dimmers work pretty much the same, the only difference is its state - it’s not ON and OFF, but 0 - 100.

The preferred method for controlling module’s outputs is directly linking module’s output channel - via switch for switch modules and via dimmer for dimmer modules. That way you can both directly see current state + manipulate it. But this method communicates directly with the Nikobus modules, hence your LEDs don’t “know” what is going on. Therefore you need to simulate button presses (what you are doing now). So when you tap the Toggle button, an ON command is send to Nikobus binding and that triggers a simulated button press to be send to Nikobus PC-Link. When you tap again, a new button press is send. If you don’t release the Toggle button (keep pressing it), nothing is happening, so only the initial tap/press will trigger the command.

On the other hand, if you press a real, physical Nikobus button, it will send a “press message” every ~100ms until you release it. While this does not make any difference for a switch module (you need to tap, release and tap again a button to turn light off/on), it makes a difference for dimmer. Using current approach, my guess is that taping Toggle button will - turn your light on and off, probably keeping last set dimmer value when turning on. So no dimming capability.

There are ways around this, the easiest would be to bind directly to dimmer’s output channel, as described above - so you can directly manipulate output via i.e. slider control - but loosing the LED status … or have a combination of Toggle button + slider … or write a rule that would start a timer and send ON commands until one does not release a button … up to you which road you’ll take, if you’ll have any questions, just let me know.

Hi crnjan,
Is de “Reverse Direction” option for rollershutters only available in the Snapshot 3.1 version of OpenHAB or in te 3.1 M1 Milestone verison too?

I guess any 3.1 version will do - but you need the binding jar from link I shared, dropped in the addons folder (and uninstall the official Nikobus binding).

In that order or first uninstall the binding and then copy the jar?

Maybe better to uninstall first, but at the end I guess it does not matter that much - if you see something fishy, just restart OH.

Hi crnjan

The “Reverse Direction” option seems to work fine. I have not been able to test it extensively yet, a quick test gave the desired result.

Great! So rollershutters (icon) is animating into correct direction too? If all good, I will create a PR so this will get part of official distro …

Icon is animating into correct direction. Tested all six of them and all seem to work well.
Thank you for this solution! :clap:

Hi, i did some more tests but it seems that i’m lacking YAML programming skils.
I’ve created my Dimmer control based on your “Toggle” code for my push buttons. I had to schange the Type of my item that is linked to my Nikobus push button to Switch. Leave actioncommand: ON but change .state== ‘100’ in order to swith my dimmable light on and off using the “Toggle” button of your code. this looks like this:
when burning it shows the value 100 and the icon is “lightbulb_fill” when ik “Toggle” it turns off and the icon changes. The feedback led is reacting as expected and always working fine.
I noticed that when ik click on “Toggle” i am able to see the percentages change. 0 - 15 - 36 - 56 - 100 and back. Or slightly other values. So he seems to read them correctly.
This is because the dimmers are set to gradually start or stop.
I now want to implement a slider but because i am lacking programming skills and have been tearing my hear out after a couple of hours Googling, copy/pasting and so on i’ll decided to come back to you :wink:
I searched for F7 slider and found this Range Slider | Framework7 Documentation and this one is looking realy nice image
i also found this post Dimmer widget oh3 and UI design - Add-ons / UIs - openHAB Community and tried to re-use that YAML code without any success.
This one is looking realy nice and could be combining your “Toggle” switch with a slider.

There is nothing special, simplest case would be something like

- component: oh-slider
    item: gGF_Living_Light_Table_Brightness

where gGF_Living_Light_Table_Brightness is linked to respective dimmer module’s output channel

When you setup an item and set its type as Dimmer, OH also knows to use slider in order to control it and there is nothing you need to do (additionally) - it just works. Would recommend you build up the semantic model

Yes I know, and I also tried that and it works perfectly but then i had no feedback LEDS. And when someone uses a real push on the wall , the feedback LEDS are out of control.
i’ll look further into the sematic model you proposed and see if i can find some kind of a solution for this.