RFID WebSocket

Setup

Install gem:

gem install rfid

Create logs and pids folders

rfid setup

sudo /usr/sbin/update-rc.d -f rfid defaults

Start

Run websocket:

rfid websocket start

Run webui (optional):

rfid app start

Usage

Create event

rfid checkout DEVICE_ID CARD1 CARD2 ...

rfid checkout 4ea92ba9c546617ab8000001 715=9370462=000195

Usage (development)

WebSocket

ruby runner.rb start
ruby runner.rb restart
ruby runner.rb stop

For testing

ruby runner.rb run

Sinatra

Start thin server

bundle exec thin --rackup config.ru start

bundle exec thin start -R config.ru -C config/thin.yml

Platform

Ruby 1.9.3-p0
Redis 2.4.2
Libcurl (Ubuntu: sudo apt-get install libcurl3 libcurl3-gnutls libcurl4-openssl-dev)
Browser with websockets enabled

Copyright © 2011 Aimbulance, released under the MIT license