I’m new to the OH2 configuration and do not now how to configure knx central functions as things and items.
Let’s assume I have a switch actor in my knx installation with two channels. Each channel is assigned a group address for switching this actor on and off. Now I define a third group address that is additionally assigned to both channels. Now I can switch both channels on and off with this central function. So how do I configure this central function in the new OH2 style?
only part of it. I already know how to attach more than one GA to a channel of a thing. But how to I configure the button c that will send this central GA. So let’s break it down to a configuration sample:
The knx.things would look like this:
Bridge knx:ip:bridge [
type="TUNNEL",
ipAddress="knx"
] {
Thing device myactor "Actor one" @ "myhome " {
Type switch : a "Switch a" [
ga="1/1/1+2/1/1"
]
Type switch : b "Switch b" [
ga="1/1/2+2/1/1"
]
}
}
The knx.items would look like this:
Switch c "Switch c" { channel="knx:device:bridge:myactor:?" }
Switch a "Switch a" { channel="knx:device:bridge:myactor:a" }
Switch b "Switch b" { channel="knx:device:bridge:myactor:b" }
My problem now is, to which channel I have to link the item “Switch c”. For this channel I placed a question mark ("?") into the item definition. Because there is no third channel I can link this switch to.
I don’t use KNX so I could be way off base, but I don’t think you need a Thing or Channel for this. This is what Groups are for.
Group:Switch:OR(ON, OFF) C
Switch ItemA (C) { knx channel link }
Switch ItemB (C) { knx channel link }
We have your two switches A and B linked to the proper KNX channels. Then you create a Group C and add A and B to that Group. Any command you send to C will get forwarded to all of it’s members. So if you C.sendCommand(ON) then A and B will also receive an ON command to turn ON.