Experiment 15: Intrusion Alarm Revisited
128 Chapter 3
Magnetic Sensor Switches
A typical alarm sensor switch consists of two modules: the magnetic mod-
ule and the switch module, as shown in Figures 3-85 and 3-86. The magnetic
module contains a permanent magnet, and nothing else. The switch module
contains a “reed switch,” which makes or breaks a connection (like a contact in-
side a relay) under the influence of the magnet. When you bring the magnetic
module close to the switch module, you may faintly hear the reed switch click
as it flips from one state to the other.
Like all switches, reed switches can be normally open or normally closed. For
this project, you want the kind of switch that is normally open, and closes
when the magnetic module is close to it.
Attach the magnetic module to the moving part of a door or window, and at-
tach the switch module to the window frame or door frame. When the window
or door is closed, the magnetic module is almost touching the switch module.
The magnet keeps the switch closed until the door or window is opened, at
which point the switch opens.
The only question is: how do we use this component to trigger our alarm? As
long as a small current flows through all our magnetic sensor switches, the
alarm should be off, but if the flow of current stops, the alarm should switch on.
We could use a relay that is “always on” while the alarm is armed. When the cir-
cuit is interrupted, the relay relaxes and its other pair of contacts closes, which
could power up the alarm noisemaker.
But I don’t like this idea. Relays take significant power, and they can get hot.
Most of them are not designed to be kept “always-on.” I’d prefer to handle the
task using a transistor.
S
S
S
N
N
N
Figure 3-86. This cutaway diagram shows a reed switch (bottom) and the magnet that
activates it (top), inside an alarm sensor. The switch contains two flexible magnetized
strips, the upper one with its south pole adjacent to an electrical contact, the lower one
with its north pole adjacent to an electrical contact. When the south pole of the magnet
approaches the switch, the magnetic force (shown as dashed lines) repels the south
contact and attracts the north contact, causing them to snap together. Two screws on the
outside of the casing are connected with the strips inside.
Figure 3-85. In this simple alarm sensor
switch, the lower module contains a mag-
net, which opens and closes a reed switch
sealed into the upper module.