User's Manual
Table Of Contents
Chapter 3
Logic
3.1 Enque version state machine
3.1.1 Queuing pallet
Setting the variable enqueue = 1 activates the insertion of the read pallet in a queue, before being
disposed of by the deviation.
The tail is 4 pallets deep.
Just read a pallet on the antenna inserts into the queue, if it is not already present. Otherwise it could
be the same pallet, moving in front of the antenna, recurs periodically.
When an ID is read, the related rfidCnt timer is preset.
3.1.2 Pallet photocell reading
The photocell of the pallet is read constantly, generating events of rising/falling edge.
Rising edge
On the rising edge following actions take place:
1. the first ID is picked up in this queue
2. Whether the rfidCnt timer is still countdown means that you have just read, then the ID is deleted
from the list to be processed. In this phase the value of rfidCnt is compared to determine if the
antenna is too close / far.
3. Whether the rfidCnt timer has finished the countdown means that it was a long time between
the antenna and the photocell. Since we are in mode enque delete the ID from the list and
however process the pallet.
4. we reset the variable Temp_coll that will serve to determine the speed of the pallet
18