Page 1 of 1
Detect double tap
Posted: Thursday 27 April 2017 11:12
by gomsoo
HI
I'm using Fibaro FGS-223 to control my light.
I would like to start a scene, when I double tab the switch.
But how can I detect a double tab in domoticz?
thanks
gomsoo
Re: Detect double tap
Posted: Friday 28 April 2017 12:03
by Lebo2d9
Use switch A with a delay off 2 sec. Set this switch when you pressed your button the 1st time. Add a and function with switch A and your button. The result of thus will be high if you push your button in a time of 2 seconds
I don't know of it will work. Never tested it
Verstuurd vanaf mijn SM-G920F met Tapatalk
Re: Detect double tap
Posted: Friday 28 April 2017 12:13
by emme
double tap shoud send a notification to a specific zWave group....
check the group configuration in the 223 manual.
unfortunately groups works only within the zwave network

(d'n't know if there is the possibility to create a virtual zwave switch for that double tap config

)
Re: Detect double tap
Posted: Friday 28 April 2017 17:11
by mjdb
I use a switch for two light (main ceiling light and additional ceiling spots).
- Click-1: Light-1 On
- Click-2: Light-2 On
- Click-3: Light-2 Off and so on Toggling.
- Click-Off: Light-1 Off and Light-2 Off.
Lua code:
Code: Select all
commandArray = {}
local LastSensorName = next(devicechanged)
local LightName = 'Lamp-1'
local LightState = tostring(otherdevices[LightName])
local Light2Name = 'Lamp-2'
local Light2State = tostring(otherdevices[Light2Name])
local Switch = 'MySwitchName'
local SwitchState = tostring(otherdevices[Switch])
if (LastSensorName == Switch) then
if (SwitchState == 'On') then -- Switch on Light-1
if (LightState == 'Off') then
commandArray[LightName] = 'On'
elseif (Light2State == 'Off') then -- Add Light-2
commandArray[Light2Name] = 'On'
else -- Toggle Light-2
commandArray[Light2Name] = 'Off'
end
else -- Switch all lights off
if (LightState == 'On') then
commandArray[LightName] = 'Off'
end
if (Light2State == 'On') then
commandArray[Light2Name] = 'Off'
end
end
end -- LastSensorName ==
return commandArray