N and V column
Column #120: You Canāt Touch That: Non-contact Access Control
The Nuts and Volts of BASIC Stamps (Volume 6) ⢠Page 65
In this program, SERIN does all the work. We construct the SERIN line to wait for the
linefeed character, then the specific characters in the valid RFID tag string. Once that shows
up the program drops to the point called Access_Granted where we activate an output that
will do what we need it to do. We could, for example, disable an electric door lock that gives
us ā and just us ā access to something special. After a brief delay the lock-control output is
enabled and we go back to the top.
The logical question is, "Where did you get the tag ID string?" From the tag, of course. I just
mentioned that the (ASCII) tag string is preceded by a linefeed and followed by a carriage
return. We can put this to use by connecting the reader to a terminal program. Note that we
need to go through an RS-232 line driver (e.g., MAX232, DS275, etc.) as the serial output is
at TTL levels. Figure 120.3 shows the connections and Figure 120.4 shows the output when
using a manually-opened terminal from the BASIC Stamp IDE (note that the baud rate is set
to 2400). In most cases we'll use a BASIC Stamp to work with the reader, but be aware that
you can also connect directly to a custom PC application using a simple interface as shown.
Figure 120.3: RFID to Serial Port Connectivity