Aller au contenu

Sécurités Volet Roulant


971jmd

Messages recommandés

bonjour a tous :)

 

pensez-vous qu'il est possible à  l’aide d'un code LUA, de changer la position du paramètre "  Protection de commande " du module FGRM222

 

exemple: 

 

si variable A=1 alors  Protection de commande = Non protégé

si variable B=2 alors Protection de commande = Aucune opération possible

 

post-112-0-88843100-1458127738_thumb.jpg

Modifié par Lazer
Sujet déplacé
Lien vers le commentaire
Partager sur d’autres sites

Sujet traité sur le topic du FGRM, à  partir de la page 12 et suivantes  : http://www.domotique-fibaro.fr/index.php/topic/172-fibaro-module-volet-roulant-roller-shutter-2-fgrm-221fgrm-222/page-12

--
-- Protection des commandes locales d'un module FGRM pour volets roulants
--

local mode = "on" -- Changer le mode on/off pour chaque bouton de module virtuel
local id = 86     -- ID du FGRM à  modifier

local protection = {
	["on"] = "0",
	["off"] = "2"
}
local HC2 = Net.FHttp("127.0.0.1", 11111)
payload = "/api/callAction?deviceID=" .. id .. "&name=setProtectionLocalAndRF&arg1=" .. protection[mode] .. "&arg2=0"
fibaro:debug(payload)
response, status, errorCode = HC2:GET(payload)
if tonumber(status) == 202 then
	fibaro:debug('OK')
else
	fibaro:debug('<span style="color:red;">Erreur : status='..status..', errorCode='..errorCode..', payload='..payload..', response='..response..'</span>')
end
Lien vers le commentaire
Partager sur d’autres sites

@ Laser

 

j'ai comparé les des fonction avec HC2Toolkit et je suis 4.080

 

avec protection "RFProtectionState": "1",                  et sans protection   avec protection "RFProtectionState": "0", 

 

avec protection "localProtectionState": "2",               et sans protection   "localProtectionState": "5",

Lien vers le commentaire
Partager sur d’autres sites

×
×
  • Créer...