How to use access keys with Relay Outputs

How to use access keys with Relay Outputs

In the tab "1wire" can be found the "Reader" element, it is used to control access to the system (by iButton or RFID). Normally, when the keys are not connected, the "Reader" element is in the 'not connected' state. When a valid key is connected to the reader (stored in the database access control data, read - Access control (legacy)), the element goes into a 'normal' state, until the key is turned off. When a not valid key is connected to the reader, the element goes into a 'alarm' state.

The use of "Reader" to open the electronic door lock

These events with indefinite duration (key activation) are best managed through a trigger. Create a trigger "Trigger Valid Key" that will turn on when a valid key is connected. And create a logic "Logic Valid Key" for this event.

 

Now create the main logic scheme. First, it disables the trigger only after 10 seconds, thus avoiding double triggers. Secondly, it supplies a pulse to the control output of the electronic lock. Set the desired pulse duration in the properties of the corresponding element. If you have a USB camera connected, then this is a good time to use it to record video for security purposes (see USB camera settings. How to save a video).