Public Member Functions | Static Public Attributes | Private Member Functions | Static Private Member Functions | Private Attributes
com.phidgets.RFIDPhidget Class Reference
Inheritance diagram for com.phidgets.RFIDPhidget:
Inheritance graph
[legend]

List of all members.

Public Member Functions

final void addOutputChangeListener (OutputChangeListener l)
final void addTagGainListener (TagGainListener l)
final void addTagLossListener (TagLossListener l)
native boolean getAntennaOn () throws PhidgetException
native String getLastTag () throws PhidgetException
native int getLastTagProtocol () throws PhidgetException
native boolean getLEDOn () throws PhidgetException
native int getOutputCount () throws PhidgetException
native boolean getOutputState (int index) throws PhidgetException
native boolean getTagStatus () throws PhidgetException
final void removeOutputChangeListener (OutputChangeListener l)
final void removeTagGainListener (TagGainListener l)
final void removeTagLossListener (TagLossListener l)
 RFIDPhidget () throws PhidgetException
native void setAntennaOn (boolean state) throws PhidgetException
native void setLEDOn (boolean state) throws PhidgetException
native void setOutputState (int index, boolean state) throws PhidgetException
native void write (String tag, int protocol, boolean lock) throws PhidgetException

Static Public Attributes

static final int PHIDGET_RFID_PROTOCOL_EM4100 = 1
static final int PHIDGET_RFID_PROTOCOL_ISO11785_FDX_B = 2
static final int PHIDGET_RFID_PROTOCOL_PHIDGETS = 3

Private Member Functions

final void enableDeviceSpecificEvents (boolean b)
native void enableOutputChangeEvents (boolean b)
native void enableTagGainEvents (boolean b)
native void enableTagLossEvents (boolean b)
void fireOutputChange (OutputChangeEvent e)
void fireTagGain (TagGainEvent e)
void fireTagLoss (TagLossEvent e)

Static Private Member Functions

static native long create () throws PhidgetException

Private Attributes

long nativeOutputChangeHandler = 0
long nativeTagGainHandler = 0
long nativeTagLossHandler = 0
LinkedList outputChangeListeners = new LinkedList ()
LinkedList tagGainListeners = new LinkedList ()
LinkedList tagLossListeners = new LinkedList ()

Detailed Description

This class represents a Phidget RFID Reader. All methods to read tags and set outputs on the RFID reader are implemented in this class.

The Phidget RFID reader can read one tag at a time. Both tag and tagloss event handlers are provided, as well as control over the antenna so that multiple readers can exists in close proximity without interference.

Author:
Phidgets Inc.

Definition at line 19 of file RFIDPhidget.java.


Constructor & Destructor Documentation

Definition at line 21 of file RFIDPhidget.java.


Member Function Documentation

final void com.phidgets.RFIDPhidget.addOutputChangeListener ( OutputChangeListener  l) [inline]

Adds an output change listener. The output change handler is a method that will be called when an output has changed.

There is no limit on the number of output change handlers that can be registered for a particular Phidget.

Parameters:
lAn implemetation of the OutputChangeListener interface

Definition at line 205 of file RFIDPhidget.java.

final void com.phidgets.RFIDPhidget.addTagGainListener ( TagGainListener  l) [inline]

Adds a tag gained listener. The tag gaiend handler is a method that will be called when a new tag is seen by the reader. The event is only fired one time for a new tag, so the tag has to be removed and then replaced before another tag gained event will fire.

There is no limit on the number of tag gained change handlers that can be registered for a particular Phidget.

Parameters:
lAn implemetation of the TagGainListener interface

Definition at line 144 of file RFIDPhidget.java.

final void com.phidgets.RFIDPhidget.addTagLossListener ( TagLossListener  l) [inline]

Adds a tag lost listener. The tag lost handler is a method that will be called when a tag is removed from the reader.

There is no limit on the number of tag lost change handlers that can be registered for a particular Phidget.

Parameters:
lAn implemetation of the TagLossListener interface

Definition at line 175 of file RFIDPhidget.java.

static native long com.phidgets.RFIDPhidget.create ( ) throws PhidgetException [static, private]
final void com.phidgets.RFIDPhidget.enableDeviceSpecificEvents ( boolean  b) [inline, private]

Reimplemented from com.phidgets.Phidget.

Definition at line 129 of file RFIDPhidget.java.

native void com.phidgets.RFIDPhidget.enableTagGainEvents ( boolean  b) [private]
native void com.phidgets.RFIDPhidget.enableTagLossEvents ( boolean  b) [private]
void com.phidgets.RFIDPhidget.fireOutputChange ( OutputChangeEvent  e) [inline, private]

Definition at line 219 of file RFIDPhidget.java.

void com.phidgets.RFIDPhidget.fireTagGain ( TagGainEvent  e) [inline, private]

Definition at line 158 of file RFIDPhidget.java.

void com.phidgets.RFIDPhidget.fireTagLoss ( TagLossEvent  e) [inline, private]

Definition at line 189 of file RFIDPhidget.java.

Returns the state of the antenna. True indicated that the antenna is active, False indicated inactive.

Returns:
state of the antenna
Exceptions:
PhidgetExceptionIf this Phidget is not opened and attached. See open for information on determining if a device is attached.

Returns the last tag read. This method will only return a valid tag after a tag has been seen. This method can be used even after a tag has been removed from the reader

Returns:
tag
Exceptions:
PhidgetExceptionIf this Phidget is not opened and attached. See open for information on determining if a device is attached.

Returns the protocol of the last tag read. This method will only return a valid protocol after a tag has been seen. This method can be used even after a tag has been removed from the reader

Returns:
protocol
Exceptions:
PhidgetExceptionIf this Phidget is not opened and attached. See open for information on determining if a device is attached.

Returns the state of the onboard LED. This LED is by default turned off.

Returns:
state of the LED
Exceptions:
PhidgetExceptionIf this Phidget is not opened and attached. See open for information on determining if a device is attached.

Returns the number of outputs. These are the outputs provided by the terminal block. Older RFID readers do not have these outputs, and this method will return 0.

Returns:
number of outputs
Exceptions:
PhidgetExceptionIf this Phidget is not opened and attached. See open for information on determining if a device is attached.
native boolean com.phidgets.RFIDPhidget.getOutputState ( int  index) throws PhidgetException

Returns the state of an output. True indicated activated, False deactivated, which is the default.

Parameters:
indexindex of the output
Returns:
state of the output
Exceptions:
PhidgetExceptionIf this Phidget is not opened and attached, or the index is out of range. See open for information on determining if a device is attached.

Returns the state of whether or not a tag is being read by the reader. True indicated that a tag is on (or near) the reader, false indicates that one is not.

Returns:
tag read state
Exceptions:
PhidgetExceptionIf this Phidget is not opened and attached. See open for information on determining if a device is attached.
final void com.phidgets.RFIDPhidget.removeOutputChangeListener ( OutputChangeListener  l) [inline]

Definition at line 213 of file RFIDPhidget.java.

final void com.phidgets.RFIDPhidget.removeTagGainListener ( TagGainListener  l) [inline]

Definition at line 152 of file RFIDPhidget.java.

final void com.phidgets.RFIDPhidget.removeTagLossListener ( TagLossListener  l) [inline]

Definition at line 183 of file RFIDPhidget.java.

Sets the state of the antenna. True turns the antenna on, False turns it off. The antenna if by default turned off, and needs to be explicitely activated before tags can be read. Control over the antenna allows multiple readers to be used in close proximity, as multiple readers will interfere with each other if their antenna's are activated simultaneously.

Parameters:
statenew state for the antenna
Exceptions:
PhidgetExceptionIf this Phidget is not opened and attached. See open for information on determining if a device is attached.
native void com.phidgets.RFIDPhidget.setLEDOn ( boolean  state) throws PhidgetException

Sets the state of the onboard LED. True turns the LED on, False turns it off. The LED is by default turned off.

Parameters:
statenew state for the LED
Exceptions:
PhidgetExceptionIf this Phidget is not opened and attached. See open for information on determining if a device is attached.
native void com.phidgets.RFIDPhidget.setOutputState ( int  index,
boolean  state 
) throws PhidgetException

Sets the state of a digital output. True indicated activated, False deactivated, which is the default.

Parameters:
indexindex of the output
statedesired state
Exceptions:
PhidgetExceptionIf this Phidget is not opened and attached, or the index is out of range. See open for information on determining if a device is attached.
native void com.phidgets.RFIDPhidget.write ( String  tag,
int  protocol,
boolean  lock 
) throws PhidgetException

Writes a tag.

Parameters:
tagtag string
protocoltag protocol
locklock tag from futher writes
Exceptions:
PhidgetExceptionIf this Phidget is not opened and attached, if the string is too malformed, or the protocol is invalid. See open for information on determining if a device is attached.

Member Data Documentation

Definition at line 212 of file RFIDPhidget.java.

Definition at line 151 of file RFIDPhidget.java.

Definition at line 182 of file RFIDPhidget.java.

LinkedList com.phidgets.RFIDPhidget.outputChangeListeners = new LinkedList () [private]

Definition at line 211 of file RFIDPhidget.java.

EM4100 (EM4102) 40-bit. This is used with getSgetLastTagProtocolcreenSize and write

Definition at line 30 of file RFIDPhidget.java.

ISO11785 FDX-B encoding (Animal ID). This is used with getSgetLastTagProtocolcreenSize and write

Definition at line 34 of file RFIDPhidget.java.

PhidgetsTAG Protocol 24 character ASCII. This is used with getSgetLastTagProtocolcreenSize and write

Definition at line 38 of file RFIDPhidget.java.

LinkedList com.phidgets.RFIDPhidget.tagGainListeners = new LinkedList () [private]

Definition at line 150 of file RFIDPhidget.java.

LinkedList com.phidgets.RFIDPhidget.tagLossListeners = new LinkedList () [private]

Definition at line 181 of file RFIDPhidget.java.


The documentation for this class was generated from the following file:


pedal_monitor
Author(s): Pedro Mendes
autogenerated on Fri Jun 6 2014 18:37:23