We have a good news for the users of the Fibaro Home center 2 control unit, at last it is possible to fully use the Vision ZM1701 lock. To correctly set the Vision ZM1701 lock it is necessary to have the Fibaro Home Center 2 control unit because of the use of the LUA scripting language to set the PIN code to unlock the lock. In the Fibaro Home Center 2 control unit it is not possible to set the PIN code using the control unit because the LUA language is not available here.
Note: We recommend to pair the device with the control unit and to set the PIN code too.
The procedure of adding devices in the Fibaro control units is known to every user. So simply follow the steps and click the Devices panel -> Add or remove devices and then it is necessary to check the Add in protected mode field if it is supported by the device -> Add.
The time interval is started, during which you can add the Z-Wave device. During this interval push C-8-8-8 on the device and if pairing does not start move the two largest parts of the lock.
At the moment, the PIN code can be set by using the following LUA code. The device supports the setting of the PIN code in the range of 4-10 digits.
The necessary changes in the LUA script:
Then you must save this LUA script and start it in the debugging window you can see the progress. After you have started the scene you must wait for 15 seconds to implement the whole script and during these 15 seconds you should hear a peep.
--[[
%% properties
%% events
%% globals
--]]
local ID = 1438 -- ID Zamku
fibaro:call(ID, "getUserCode", 1);
fibaro:sleep(5000)
--
local usersStatus = fibaro:getValue(ID, "userCodes");
print(usersStatus);
fibaro:sleep(5000)
-- 12340 je PIN - zmena
fibaro:call(ID, "setUserCode", "1", "Occupied", "12340", "");
fibaro:sleep(5000)
--
local usersStatus = fibaro:getValue(ID, "userCodes");
print(usersStatus);
Explanation of what is happening in the particular scene, see the figure below.
fibaro:call(ID, "getUserCode", 1); - This command makes accessible the 1st register for the entering of the 1st PIN Code.
local usersStatus = fibaro:getValue(ID, "userCodes"); - This command makes accessible the statutes of the registers. See the figure - it is possible to set up to 13 codes - in registers 0-12.
print(usersStatus); - Information of the status of registers - if they are available or not.
fibaro:call(ID, "setUserCode", "1", "Occupied", "12340", ""); - Entering the PIN code into the first register and setting the occupancy.
The setting of the PIN code for the wireless lock is similar to the setting of the RFID reader, see the link to the article in similar articles.
2 Comments
Pavel Hulmák 20.12.2023 Reply
Dobrý den,snažím se změnit PIN kód z LUA kódu u klávesnice Philio PSK01, ale funkce setUserCode se neprovede, resp. provede se jen částečně. Když si následně zobrazím userCodes, vrátí "update: InProgress" u příslušného PINu. Nemáte s tím nějaké zkušenosti, resp. není tam nutné ještě nějaké potvrzení?
Je také možné, že změna PIN kódu u této klávesnice není z LUA scriptu povolena. Pokud ne, můžete mi doporučit jinou klávesnici, případně zámek s klávesnicé, kde je tato změna možná?
Děkuji,
P. Hulmák
SmarterHOME Team 03.01.2024 Reply
Dobrý deň,bohužiaľ s touto klávesnicou nemáme skúsenosť.
Skúste sa pozrieť na toto video tam to riešia s HC3 - https://rb.gy/9s5a6m
Pekný deň.
SmarterHOME