Programs: Serial Port
How to set it up:
In order to use a serial port (see fig. 1) to interface with
the counter program you're going to need the following items:
-
Length of two conductor cable (like speaker cable)
-
Serial Port Plug (see fig. 2)
-
Switching device such as a reed switch (see fig. 3)
The counter program increments when ever the ring
indicator (pin 9 of the serial port) detects a change in
signal. The signal is supplied from the DTR (data terminal
ready - pin number 4). A normally off switch is used to keep
the signal interrupted. In the case of a reed switch, as a
magnet moves past the reed, a connection between pins 4 and 9
is made, and a DTR signal is sent to the ring indicator.
Using the components listed above, connect the cable to the
serial port as shown in picture of the inside of the serial
port plug (fig. 4). On the other end of the cable connect the
switching device.
|
fig. 1 - This is a serial port! Labeled is Pin 4 and 9. |
|
fig. 2 - This is a plug... Labeled (again) is Pin 4 and 9. |
|
fig. 3 - This is my reed switch and the magnet it came with. |
|
fig. 4 - This is inside the Radio Shack plug. |