NAME

RFID::Matrics::Reader::Serial - Implement RFID::Matrics::Reader over a serial link

SYNOPSIS

This class takes a serial port object and implements the Matrics RFID protocol over it. The serial port object should be compatible with Win32::SerialPort; the Unix equivalent is Device::SerialPort. You are responsible for creating the serial port object.

An example:

    use Win32::Serialport;
    use RFID::Matrics::Reader::Serial;

    $com = Win32::SerialPort->new($opt{c})
	or die "Couldn't open COM port '$opt{c}': $^E\n";

    my $reader = 
      RFID::Matrics::Reader::Serial->new(comport => $com,
				         node => 4,
					 antenna => MATRICS_ANT_1);
    $reader->changeparam(antenna => MATRICS_ANT_1,
			 environment => 4,
			 power_level => 0xff,
			 combine_antenna_bits => 0);
    my $rff = $reader->readfullfield(antenna => MATRICS_ANT_1);
    foreach my $tag (@{$pp->{utags}})
    {
	print "I see tag $tag->{id}\n";
    }

DESCRIPTION

This class is built on top of RFID::Matrics::Reader, and implements the underlying setup, reading, and writing functions.

Constructor

new

This creates a new Matrics::Reader::Serial object. In addition to the parameters for the RFID::Matrics::Reader constructor, it takes the following parameters:

comport

Required parameter. A Win32::SerialPort-compatible object over which the serial communication should take place.

baudrate

Optional parameter. The baud rate at which we should communicat over the serial port. The default is 230400, which is the default speed of the RDR-001.

SEE ALSO

RFID::Matrics::Reader, RFID::Matrics::Reader::TCP, Win32::SerialPort, Device::SerialPort.

AUTHOR

Scott Gifford <gifford@umich.edu>, <sgifford@suspectclass.com>

Copyright (C) 2004 The Regents of the University of Michigan.

See the file LICENSE included with the distribution for license information.