Skip to content

balena-io-experimental/office-lock

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

office-lock

Resin based RFID lock system used to get into our office.

Unlock the door using any of the supported key types or by making a GET request to the API endpoint with the secret key.

Support key types:

  • NFC/RFID Type 1 thru 4 tags
  • Oyster cards
  • Contactless debit cards

Parts list

Name | Link | Qty ------------ | ------------- | ------------ | ------------- Raspberry Pi 3 | Adafruit | 1 5V 2.4A power supply | Adafruit | 1 8 GB microSD card | Amazon | 1 PN532 NFC/RFID controller | Adafruit | 1 13.56MHZ RFID/NFC tag selection | Adafruit | 1 NeoPixel ring | Adafruit | 1 Perma-proto hat | Adafruit | 1 Relay | Grove | 1 Hook-up Wire | Adafruit | 1

Assembly

Fritzing

Getting started

  • Sign up on resin.io
  • Go through the getting started guide and create a new RPI3 application called office-lock
  • Clone this repository to your local workspace
  • Add the resin remote to your local workspace using the useful shortcut in the dashboard UI remoteadd
  • git push resin master
  • See the magic happening, your device is getting updated Over-The-Air!

Configure via environment variables

Variable Name Default Description
LED_TIME 0.2 The LED ring flashing speed
UNLOCK_TIME 3 The time the door is unlocked for
SECRET_KEY "" The secret key used to open the door from the API endpoint

Add access keys via environment variables

Variable Name Default Description
CARD_0 00906fe3 Card 0 ID
CARD_1 00906fe3 Card 1 ID

Add you own keys naming them CARD_0, CARD_1, CARD_2 etc

Enable public URL

Open the door with a GET request. For example:

curl -X GET https://7082d8f659ef4d03c25bc24a18debec363d37cb4da641eb6c79658e0c5e46b.resindevice.io/api/<SECRET_KEY>

Pictures and videos

Watch the video here!

Side

Top

Bottom

Releases

No releases published

Packages

No packages published

Languages