|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcomponent.RFIDChannel
public class RFIDChannel
An RFIDChannel represents the wireless medium between the reader and the tags. It does a number of things.
First, it delivers a frame from the reader to each of the tags. As it does that, it uses the BER to inject random bit errors, corrupted each bit independently. If the frame type contains a CRC field, it is assumed to detect all bit errors that occur. If the frame does not contain a CRC field, the corrupted packet is delivered.
Second, correct delivery of a frame causes the tag to update its state, and to generate a reply if called for by the current state of the tag and the received frame.
Third, it collects all reply frames. If there is more than one, the reply is unreadable (corrupted). If there is only one, the BER is applied, as in the reader to tag case. If there are no replies, the reply frame is null.
Finally, the RFIDChannel is in control of the simulator's clock. It increments the clock, based on the time required to send the frame from the reader, the time to send the reply frame if there is one, and the required inter-frame gaps. Additionally, when the simuator clock exceeds the time allowed to inventory the tags, an exception is thrown, causing control to exit the RFIDReader.inventory() method.
Field Summary | |
---|---|
int[] |
frameCnt
|
Constructor Summary | |
---|---|
RFIDChannel(RFIDTag[] tagArray,
double errorRate,
double bw,
int timeLimit)
Constructor. |
Method Summary | |
---|---|
java.lang.String |
dumpStats(java.lang.String prefix)
Utility method that returns a printable String summarizing what the channel has seen to this point. |
TtoRFrame |
sendFrame(RtoTFrame f)
Delivers frame f to each tag, injecting bit errors as it does so. |
void |
setDebug(boolean b)
Control whether the channel should print debugging info (currently a trace of packets sent in each direction). |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public int[] frameCnt
Constructor Detail |
---|
public RFIDChannel(RFIDTag[] tagArray, double errorRate, double bw, int timeLimit)
Method Detail |
---|
public void setDebug(boolean b)
public TtoRFrame sendFrame(RtoTFrame f) throws SimDoneException
Returns:
SimDoneException
public java.lang.String dumpStats(java.lang.String prefix)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |