ex_tcp_listener.rb

Path: ex_tcp_listener.rb
Last Update: Thu Sep 11 16:16:03 -0700 2014

Alien Ruby RFID Library Examples

ex_tcp_listener.rb

This is a simple server that accepts connections on a socket and prints out data that comes in on the connection.

Messages are assumed to be null-terminated strings. On receiving a null, the server prints out the data and continues reading. When nothing is read, it is assumed the reader closed down it‘s side of the socket.

Use this example in conjunction with ex_taglist_with_notify.rb. First run this program on your local machine and then run ex_taglist_with_notify.rb on the same machine to see notification messages.

Alternatively, you can manually configure your reader to stream tag or I/O data, or send notifications, to this program.

Copyright 2014, Alien Technology Corporation. All rights reserved.

Required files

socket   alienconfig  

[Validate]