Documente Academic
Documente Profesional
Documente Cultură
Basic Operation
The circuit diagram for the Scarecrow is
shown in Fig.3.1. The heart of the circuit is
formed by IC1c, a Schmitt trigger NAND
gate, which is configured as a squarewave
oscillator. Its frequency is determined by
COMPONENTS
IC1
TR1, TR3
Scarecrow
Resistors
See
R1
2M2
SHOP
R2
220k
TALK
R3
470k
page
R4
560k
R5
390k
All 0.25W 5% carbon film.
Capacitors
C1, C4
47 radial elect.
16V (2 off)
C2, C3
100p ceramic
disc, 5mm pitch (2off)
Semiconductors
D1
1N4148 signal
diode
TR2, TR4
Miscellaneous
WD1
9
excl batts,
hardware & horn
430
Testing
Construction
The circuit is built on the printed circuit
board using the layout shown in Fig.3.2.
This board is available from the EPE PCB
Service, code 505
Assemble in the preferred order of
ascending component size, and use a socket for IC1. Care should be taken to ensure
that diode D1, capacitor C1 and IC1 are
inserted the right way around. But do not
insert IC1 into its socket until final checking has been completed. The transistors
should also be identified carefully as two
are n-channel and two are p-channel types
and they cannot be interchanged.
Having double-checked that the circuit
is correctly assembled, insert IC1. Before
handling the i.c., and also the transistors,
discharge static electricity from your body
by touching an earthed surface. Take care
to avoid touching the i.c. pins.
In common with all of the other projects in this series, this circuit can be powered by a 9V PP3 type battery. The current
drain is very low (around 500A average). As the project is likely to be used
outdoors, it is recommended that a mains
powered d.c. supply should not be used
with it for safety reasons.
The sounder specified is a special piezo
high frequency type. An ordinary audio
speaker would not be suitable in this
application, not only because of its relatively low impedance, but also its inability to reproduce sounds above 20kHz. The
specified sounder, however, does have a
paper cone which, although relatively
CMOS HANDLING
Remember that CMOS circuits
require careful handling. The very high
input impedance of the gate circuits
allows high static voltages to build up
which can cause the very thin gate oxide
layer to break down, destroying the
device. Such voltages are frequently
encountered (e.g. simply walking across
a carpeted room can generate a voltage
in excess of 20kV). Although CMOS
circuits normally have protection diodes
and resistors internally connected from
the inputs to the supply rails to prevent
the voltage at the gate from exceeding
the supply voltage, you should always
discharge static electricity from your
body by touching something grounded
(earthed) before handling them.
431
Digital Lock
T
Basic Operation
The block diagram for the Digital Lock
presented here is shown in Fig.3.3. It is
based on a single i.c. forming the counter
and decoder blocks. Initially, with the
counter reset and decoder output 0 high,
AND gate 1 is enabled. Now pressing
switch S1 causes the Clock input to go
high, so advancing the counter and resulting in decoder output 1 going high.
Alternatively, the
output may be
made to stay open
for a relatively
short period following a valid
entry, and then
close automatically.
Circuit
Diagram
432
The complete
circuit diagram for
the digital lock is
shown in Fig.3.4.
The circuit consists
of a 4017 decade
counter,
IC1,
together with a
keyboard and a few
other components.
The OR gate of the
block diagram consists of diodes D1
to D3, and resistor
R5 (showing how
easily such functions can be incorporated into logic
designs without the
necessity of using
additional i.c.s).
All
other keys are
connected to the reset
input so that pressing any of
these will reset the counter, causing
its output Q0 to go high. Simultaneously,
capacitor C1 will charge quickly via resistor R7, and hold the counter reset for a period determined by the values of C1 and R4.
The circuit now ignores all switch presses
until C1 has discharged, thus providing a
simple keyboard lock-out feature if an
invalid key is pressed. Only pressing S1,
S2 and S3 in that order will cause output
Q3 to go high and switch on the transistor
TR1 via buffer resistor R6 thus energising
the relay.
The value chosen for C1 will depend on
the time for which the relay is to remain
energised. With R4 equal to 1M, the
delay will be about one second for each
microfarad.
Code Sequence
Although the keys are labelled S1, S2,
S3 etc. in the circuit diagram, they may of
course be numbered in any sequence on the
keyboard itself. For example, S1 could be
key number five while S2 and S3 are numbers seven and three respectively. The open
sequence in this case would be 573 and
pressing any other sequence will not open
the lock. The circuit board has been
designed to make it possible to pre-wire
any sequence into the circuit.
This simple circuit does have a number of limitations however. One is that
each valid number must be different so
that sequences such as 444 or 767 cannot
be used. Assuming a 3-digit code, this
(connected to the reset input) thus increasing the chances of pressing an incorrect
key.
More sophisticated circuits often
include an automatic reset if a valid key is
COMPONENTS
Digital Lock
Resistors
R1 to R3
R4
R5
R6
R7
Capacitors
C1
10k (3 off)
1M
See
100k
SHOP
4k7
TALK
100
page
10 radial elect.
16V (see text)
Semiconductors
D1 to D7
1N4148 signal
diode (7 off)
IC1
4017 decade
counter
TR1
2N3904 npn
transistor
Miscellaneous
RLA
min. s.p.s.t. relay,
12V, contact rating
to suit load, p.c.b.
mounting (see
text)
S1 to S10
push-to-make
switch, p.c.b.
mounting (10 off)
Printed circuit board, available
from the EPE PCB Service, code
506; case to suit (see text); 16-pin
d.i.l. socket; 9V (PP3 type) battery
and clip; connecting wire; solder etc.
Approx. Cost
Guidance Only
Fig.3.5. Component and track layout details for the Digital Lock printed circuit board
9
excl. batt &
hardware
433
Construction
Printed circuit board component and
track layouts are shown in Fig.3.5. This
board is available from the EPE PCB
Service, code 506. It has been designed to
hold all of the components, including the
relay and the keys for the keyboard.
Depending on the application, a standard keyboard or one built from individual
keys may be used, and this may be separated from the main circuit by cutting the
board along the dotted line. The two parts
may then be connected by an 11-way (ribbon) cable.
The advantage of doing this is that only
the keyboard needs to be mounted outside
the protected area, so that only its connections will be accessible if the front cover is
removed. The rest of the circuit may then
be housed within the protected area so that
the intruder cannot simply short out the
transistor and energise the relay without
using the keyboard.
Most of the wires from the keyboard
will terminate on the first row of connection holes (marked R) but three should be
Power Aspects
The circuit will operate from a range of
d.c. voltages from 5V to 15V so that a 9V
supply is ideal. The relay should be chosen
to suit the supply used, although in practice
a 12V relay with a coil resistance of 400
will work satisfactorily from a 9V supply.
The relay used in the prototype has
changeover contacts and its normally-open
contacts are brought out to the pins on the
p.c.b. The contacts of any relay chosen
should of course be rated for the intended
load.
Note that the p.c.b. design is suited
only for use with a low voltage load. It
Next Month
In Part 4 next month we present a
Doorchime and Electronic Dice.
Obtaining EPE
An initiative in the UK is designed to help you obtain your favourite magazines from newsagents.
Called Just Ask! its aim is to raise awareness that newsagents can stock, order and often home
deliver magazines.
To raise awareness we will be including the Just Ask! logo in the pages of this and future issues and
have included a newsagent order form to help you to obtain copies.
So keep a look out for the logo and next time you visit your newsagent remember to Just Ask! about
obtaining copies of your chosen magazines.
Everyday Practical Electronics is published on the second Thursday of each month and distributed S.O.R. by COMAG
Make sure of your copy of EPE each month cut out or photostat this form, fill it in and hand it to your newsagent.
434