Quelab now has an electronic sign-in system for members. There's a hom^H^H^H Quelab-made system with an RFID reader in the window to the left of the front door, and we'll be giving everybody RFID keys.
To sign in, put your key on the window in front of the reader, and hold it there until the green light appears (it will take about one second). A half-second later the door will unlock, so you don't need to enter the door code to get in. The light will stay lit for five seconds, and when it turns off, the door will re-lock (unless the knob inside is set to keep the door unlocked).
If you get a red light instead, it means we don't like you anymore. Remember to pay your monthly dues, and we'll like you again. Also, the yellow light flashes continuously while the reader detects any key in range. If the yellow light isn't flashing, then the reader doesn't see your key, so you'll get neither a red nor a green light. This can happen if you're wiggling your key; the reader can only detect it if you hold it still.
Until you get your key, you can still use the door code to get in. When you get your key, if you have any problems with it, then use the door code, sign in on the paper sign in sheet, and report to me so I can try to figure out what's wrong.
Besides logging electronic sign-ins, the system also logs when the door is locked and unlocked (using the door code, the knob inside, or the RFID system) and opened and closed. It also has a network connection, so we can get daily reports of sign-ins for accurate accounting of Quelab member traffic, set it to make noises or email the facilities manager if the door is left open or remains unlocked after 10pm, etc.
For Geoff, or whoever registers new members:
If you need to register multiple keys, you can hold them all in front of the reader one at a time, then authorize them all and enter all the usernames, then write all the changes at once, to save time. You can also log in to the laptop on the network with username doorctrl and edit Quelab_entrance_public.db using whatever editor you want. Do that also if you want to automate revocation of authorization for lack of payment.
The obsolete Thinkpad T43 by the door was buried under junk and had a thick layer of dust on it when I found it in the shop last week. It now serves several useful functions:
It's configured to allow public read-only access to the database. Log in to the laptop1) , and read the Sqlite3 database file /home/doorctrl/rfid_iface_arduino/Quelab_entrance_public.db using sqlitebrowser or whatever else. Editing requires logging in with username doorctrl and a password that I'm giving to Geoff. 2)
In addition to the ID that's printed on the key and transmitted to the RFID reader, each key also has a code that's transmitted to the reader but not printed on the key. Our system stores the code in Quelab_entrance_secret.db, which is readable only under username doorctrl, and verifies the code when reading a tag. This means if you try to clone a key just from the printed ID, you won't have the right code, and the system will detect that the key is counterfeit. The table Counterfeits_read records what its name says, and presumably we'll want the system to email the facilities manager if anything ever appears in it.
Source code for the Arduino firmware, the host computer's control program, and the display program are in /home/doorctrl/rfid_iface_arduino/ and are publicly readable. I'll draw a schematic for the hardware, maybe later today. I jerry-rigged a temporary contact switch last night for detecting when the door is open, but Anders is going to replace it with something less embarrassing. However, the scotch tape on the circuit board is intended to be permanent because scotch tape is awesome. Every Arduino I've ever built into anything, including my keyboard, is still held in place with scotch tape. Scotch tape is in fact far better than Arduinos, though that isn't saying much.