Popp Wall Controller 4 x on / off switch

For Z-Wave related questions in Domoticz

Moderator: leecollings

Post Reply
Keleos
Posts: 29
Joined: Saturday 27 May 2017 9:37
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Popp Wall Controller 4 x on / off switch

Post by Keleos »

Hello everyone,

I'm currently a bit frustrated and I hope you could help me. I've bought a Popp Wall Controller looking like this:
Image

I've paired it successfully with my z-Wave network and it shows 4 switch devices for it.
BUT they do not change their stage from on to off... they only send on.

What I want to archive:
When I press one of the 4 switches, it should switch on a wall plug - when I press the same button again, it should switch it off again. I do not want to use two different switches for on and off...

- I've tried to set the id of the wallplug in the "Groups and Network" page, but this seems not to work.
- I've tried to use a Group and also a Scheme, but (because the wall controller only sends on) this also doesn't work.
- I also tried to use a lua script, but I'm not good in LUA... my idea was:
...
when switch 1 is pressed and wallplug is on:
turn wallplug off
...

Would be great if you could help me to use this wall controller.

PS: it seems also similar to the Z-Wave.Me Popp KFOB-C Remote Control.

Greetings
Kel
Keleos
Posts: 29
Joined: Saturday 27 May 2017 9:37
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Popp Wall Controller 4 x on / off switch

Post by Keleos »

Got it:

Named the switches Schalter 1 .... Schalter 4 (I also own a KFOB - there I called them "Remote 1" .... Remote 4) and look with LUA for Schalter and Remote. If it recognizes a "Schalter", it uses a simple if to get the current state of the wallplug...

Code: Select all

-- Title: script_device_Schalter.lua
-- Date: 10-07-2017
-- Verwaltet on/off der Schalter und Fernbedienung


steckdose1="008:Steckdose (TV Lampe)"
steckdose2="008:Steckdose (TV Lampe)"
steckdose3="008:Steckdose (TV Lampe)"
steckdose4="008:Steckdose (TV Lampe)"


commandArray = {}
tc=next(devicechanged)
deviceName=tostring(tc)

-- Wurde eine "Schalter" oder "Remote" (Fernbedienung) Szene ausgeloest?
if ( string.match(deviceName, "Schalter") or string.match(deviceName, "Remote") ) then
    
    print("Schalter / Remote erkannt: "..deviceName)
    
    -- Schalter / Remote 1
    if ( string.match(deviceName, " 1") and otherdevices[steckdose1] == 'Off') then commandArray[steckdose1]='On' end
    if ( string.match(deviceName, " 1") and otherdevices[steckdose1] == 'On') then commandArray[steckdose1]='Off' end

    -- Schalter / Remote 1
    if ( string.match(deviceName, " 2") and otherdevices[steckdose2] == 'Off') then commandArray[steckdose2]='On' end
    if ( string.match(deviceName, " 2") and otherdevices[steckdose2] == 'On') then commandArray[steckdose2]='Off' end
        
    -- Schalter / Remote 1
    if ( string.match(deviceName, " 3") and otherdevices[steckdose3] == 'Off') then commandArray[steckdose3]='On' end
    if ( string.match(deviceName, " 3") and otherdevices[steckdose3] == 'On') then commandArray[steckdose3]='Off' end
        
    -- Schalter / Remote 1
    if ( string.match(deviceName, " 4") and otherdevices[steckdose4] == 'Off') then commandArray[steckdose4]='On' end
    if ( string.match(deviceName, " 4") and otherdevices[steckdose4] == 'On') then commandArray[steckdose4]='Off' end
end

return commandArray


Hope this helps someone else.

Greetings
Kel
Keleos
Posts: 29
Joined: Saturday 27 May 2017 9:37
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Popp Wall Controller 4 x on / off switch

Post by Keleos »

Hi everyone,
I've a problem with this script: when I push the button too long, it switches the devices on and off continously ... Is there any way to set a wait/sleep before the next commands are accepted?
Greetings
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest