Hi there!
i’m controlling my entry gate with different knx group adresses…
for now i have created different switches:
OPEN
CLOSE
STATUS
to open the gate i have to send “ON” to the OPEN Switch, to close i have to send “ON” to the CLOSE switch, STATUS is ON when the gate is closed and OFF when the gate is OPEN.
rule "control gate"
when
Item GateProxy received command
then
if (receivedCommand=OPEN)
GateOpen.sendCommand(ON)
else
GateClose.sendCommand(ON)
end
rule "gate state"
when
Item GateState received command
then
if(GateState.state == OFF)
GateProxy.postUpdate(CLOSED)
else
GateProxy.postUpdate(OPEN)
end