This is only a preview of the January 1989 issue of Silicon Chip. You can view 38 of the 96 pages in the full issue, including the advertisments. For full access, purchase the issue for $10.00 or subscribe for access to the latest issues. Articles in this series:
Articles in this series:
Articles in this series:
Articles in this series:
Articles in this series:
|
Simple ultrasonic
proximity detector
Do you hove trouble parking close to a
wall or getting out of tight parking
spots? This ultrasonic distance indicator
will save you from those embarrassing
dings and scrapes.
By JOHN CLARKE & GREG SWAIN
Sometimes it can be really difficult to judge parking distances,
particularly if you're trying to back
up close to a wall or loading dock. It
only takes one mistake and ...
kerunch!
To solve this problem, we set
about designing a circuit that would
warn the driver before the crunch
26
SILICON CHIP
point. The result is the ultrasonic
distance indicator featured here. It
can be easily fitted to just about any
sort of vehicle and has a range of
about 1 metre.
The idea behind the device is simple. A couple of ultrasonic transducers are mounted on the rear
bumper bar and monitor the
distance between the vehicle and
any large obstruction which could
be a wall or another vehicle. As the
vehicle reverses and gets closer,
the beep rate from a small piezo
transducer gradually increases until, at a preset distance, the
transducer gives a continuous tone
which says "this far and no
further".
To make it easy to operate, the
ultrasonic ranger is automatically
switched on whenever reverse gear
is selected. That's done simply by
deriving the power supply from the
switched line to the reversing
lights. You can set the minimum
distance trip point to whatever
figure you like by means of a
trimpot.
As an option, you can also set
100
+BV
~+.;::.::;:......----------+--------------....---+BY
+12V VIA
REVERSING
SWITCH
10
100
16VW!
16VW!
.,.
100
+
1k
470k
470k
+
16VW+
2.2k
40kHz
ADJUST
VR1
22k
14
470k
nm
22!l
IC3
555
10k
ULTRASONIC
TRANSMITTER
SCS•401T
1M
01
1N414B .
40kHz
OSCILLATOR
BURST
OSCILLATOR
- - - - - - - - - - - - - - - - - - - - - --
-~-----t1------t-----t1----+BV
1.2k
ULTRASONIC
RECEIVER
SCM-401
4
470k
.,.
R
D
14
15k
- 2
IC5 Qlt,:--~IM,--+----,
>----1-----13 CK 4013
s
6
1.2k
4.7k
7
RETURN DELAY
DETECTOR
AVERAGE
SIGNAL
4.7k
SCHMITT
1.8k
1M
.---------+-~--------------..--+Bv
10k
2
'HIT'
OUTPUT
10k
EXTRA
0ts1:~c
E_____.
VR3
47k
.,.
10k
10
+
16VW!
.,.
PIEZ0
TRANSDUCER
AUDIO TONE
RATE
AUDIO
OSCILLATOR
CAR REVERSING ALARM
Fig.1: IC2b is the burst oscillator and controls IC3 which drives the transmitter. When the reflected signal is received,
it clocks Q-bar of IC5 low. IC5's output, in turn, controls the beep indicator circuit (IC2c, IC4 and IC2d).
and select a second minimum
distance trip point. This feature
would be useful on station wagons
and vans which require sufficient
clearance for the rear door to be
opened. A switch mounted on the
dashboard will enable you to select
between the two distances.
How it worlcs
Two ultrasonic transducers and
five ICs are used in the circuit. In
operation, the ultrasonic transmitter sends out a burst of signal and
the receiver then detects the
reflected signal from the object.
The time taken for the signal to
return is used to determine the
distance.
Fig.1 shows all the circuit details.
Let's look at the transmitter circuit
first, since this is by far the easiest
to understand.
IC3 is a 555 timer and is wired as
an astable oscillator which runs at
40kHz. The output signal appears
at pin 3 and drives the ultrasonic
transducer via a 220 resistor. Trimpot VR 1 allows the frequency to be
precisely set to 40kHz.
Pin 4 of IC3 is the reset input and
this is controlled by the output of
burst oscillator stage IC2b. When
pin 4 is high, the 555 timer
oscillates; when pin 4 is low, the
555 stops.
JANUARY 1989
27
r300us--------30ms
_JlJlJLJUl___
I
I
~~y _J
I
3
~3
T_Rs~_:~_fl_T_ _ _ _ _ _ _ _ _
PIN 1
IC2a
_
I
flJUl
JUl
---------1
PIIC!52
_J
_
PIN 1
IC2a
I
SHORT RANGE
RETURN SIGNAL
_
fUlJ
I
I..._______________,
(LOW AVERAGE VOLTAGE)
I
LONG RANGE-fUUl
RETURN SIGNAL
(HIGH AVERAGE VOLTAGE)
Q
___.flfill_JUl_
I
1-----.L
..
L
nnI.._______
_Ju
I
PIN 2
IC5
Fig.2: the top waveform shows the bursts of 40lcHz signal at the
output of IC3. D-type flipflop IC5 is reset at the start of each burst
which means that its Q-bar output is set high. When the reflected
signal arrives at the ultrasonic receiver, IC5 is clocked and its Q-bar
output goes low. It remains low until reset at the start of the next burst.
ULTRASONIC
RECEIVER
I
+12V VIA
REVERSING
SWITCH
100uf
~
GNU
r
ULTRASONIC
TRANSMITTER
+PIEZO-
TRANSDUCER
Fig.3: here's how to mount the parts on the PCB. Make sure that you
don't swap the 555 and TLC555 timers because that would upset
circuit operation. Leave out VR3 and switch S1 if you only require one .
set distance (see text).
IC2b is wired as a Schmitt trigger
oscillator. A voltage divider consisting of two 470k0 resistors sets
the bias on the non-inverting input
while a third 470k0 resistor sets the
hysteresis levels to 1/3 and 2/3 of
the supply voltage.
In operation, the .039µ,F timing
capacitor charges mainly via D1
and its series lOkO resistor and
discharges via the lMO resistor.
This is because D1 is reverse biased during each discharge cycle.
This gives a train of pulses at pin 14
which are each high for about
28
SILICON CHIP
300µ,s and low for about 30ms.
What this means is that IC3 provides a 300µ,s burst of 40kHz
oscillation every 30ms. This 30ms
gap is to allow sufficient time for
each burst to be reflected back to
the receiver before the next burst is
transmitted (see Fig.2).
As well as controlling IC3, the
output of IC2b is also wired to the
reset input (pin 4) of D-type flipflop
IC5. When pin 14 of IC2b switches
high, it resets IC5 so that its Q-bar
output goes high. As we shall see, it
is IC5 that allows the circuit to
determine the delay time between
the transmitted and reflected
signals.
Receiver circuit
The reflected 300µ,s burst signal
.is picked up by the ultrasonic
receiver and fed to pin 3 of ICla.
ICla is an AC-coupled non-inverting
amplifier with a gain of 11 as set by
the 47k0 and 4.7k0 feedback
resistors. The .01µ,F capacitor in
series with the 4.7k0 resistor rolls
off the frequency response below
3.4kHz.
Following ICla is an identical op
amp stage, ICl b, which is also
wired with a gain of 11 (ie, the two
stages together provide a gain of
121). The amplified 40kHz signal
appears at pin 7 of IClb and is applied to pin 6 of Schmitt trigger
stage IC2a. DC bias for the noninverting input is derived by filtering the output of IClb via a 1.2k0
resistor and 10µ,F capacitor.
IC2a's job is to monitor the output
of ICl b for amplified 40kHz burst
signal. As soon as the signal input
on pin 6 exceeds about 400mV, the
output at pin 1 swings high and low
(ie, it squares up the signal). This
output signal then clocks flipflop
IC5.
What happens now is that Q-bar
(pin 2) of IC5 immediately switches
low on the first positive going clock
input from IC2a. If you're not too
familiar with D flipflops, just
remember that the data (D) input at
pin 5 is transferred to the Q output
by the clock input. Because the D input is connected to the positive supply, this means that Q goes high and
thus Q-bar must go low.
Fig.2 shows the waveform
details. Note that additional clock
pulses from IC2a have no further
effect on the Q-bar output after it
switches low. It remains low until
reset high again by the output of
IC2b at the start of the next
transmitted burst signal.
What this all means is that Q-bar
is set high at the start of the
transmitted signal and remains
high until that signal is reflected
back to the receiver. The further
away the object is, the longer it
takes for the signal to come back
and the longer the Q-bar output
stays high.
The output signal from IC5 is
PARTS LIST
1 PCB, code SC05102891,
105 x 60mm
1 plastic case, 130 x 67 x
43mm (or larger)
1 plastic case, 83 x 54 x
30mm
1 40kHz ultrasonic transmitter
1 40kHz ultrasonic receiver
1 piezo transducer
1 SPOT toggle switch
Semiconductors
The PCB clips neatly into the specified case but you can use a larger case if
you wish. Use shielded cable to make the connections to the ultrasonic
transducers and note how the 3-terminal regulator is oriented.
D
7808 3-terminal regulator
1 6V 1W zener diode
1 N4148, 1 N914 diodes
LM339 quad comparator
LF353, TL072 dual FET
input op amp
1 555 timer
1 TLC555CP CMOS timer
1 4013 dual D-type flipflop
Capacitors
2 1 OOµF 1 6VW PC electrolytic
4 1 OµF 16VW PC electrolytic
1 .04 7µF metallised polyester
(greencap)
2 .039µ,F metallised polyester
2 .01 µF metallised polyester
1 .0068µ,F metallised polyester
2 .001 µF metallised polyester
t~
~
~
1
1
2
1
1
~~~!!:::::~~~~~-~
Fig.4: the printed circuit board is coded SC05102891 and measures
105 x 60mm.
filtered using a 15k0 resistor and
10µ,F capacitor and fed to pin 5 of
comparator stage IC2c. This stage
compares the filtered 'average
signal' with the voltage on pin 4, as
set by either VR2 or VR3. Switch Sl
selects between these two trimpots,
which provide the distance set adjustments (ie, the distances at
which the transducer emits a continuous tone).
Actually, the way in which the
circuit works from here is really
quite devious. What goes on? Well,
comparator IC2c controls oscillator
stage IC4, which in turn controls
Schmitt trigger oscillator IC2d.
Let's look at this in greater detail.
The 'average signal' from IC5 is
also connected to the frequency
control input of IC4. This IC is a
We mounted the ultrasonic transducers CMOS version of the .more familiar
in a small plastic case. Mount the case 555 timer and oscillates at a frequency of about lHz when its pin 5
so that it can be easily removed when
the car is to be washed.
is at + 8V.
Resistors (0.25W, 5%)
2 x 1 MO, 7 x 4 70k0, 1 x 1 OOkO,
2 X 47k0, 1 X 27k0, 1 X 22k0, 1
x 15k0, 7 x 1 OkO, 3 x 4. 7k0, 1 x
2.2k0, 2 x 1.8k0, 2 x 1.2k0, 1 x
1 kO, 1 x 220, 1 x 100, .2 x 47k0
miniature vertical trimpots, 1 x
22k0 miniature vertical trimpot
Miscellaneous
Hookup wire, shielded cable,
solder etc.
But IC4's operation is a bit
trickier than that. As the voltage on
its frequency control input (pin 5)
decreases, its output frequency increases. And this is precisely what
happens as the car gets nearer to
the obstruction (ie, a wall or
another car) behind it. The closer
the car gets, the lower the 'average
signal' voltage and the higher the
output frequency from IC4. This, in
turn, increases the audio beep rate.
This situation continues until the
'average signal' voltage drops
below the voltage on pin 4 of comparator IC2c. When that happens,
pin 2 of IC2c switches low and
JANUARY 1989
29
For the prototype, the audio transducer was mounted on one end of the case
but this will not be pratical for all installations. Mount the unit towards the
back of the vehicle to keep the leads to the transducers short.
7
CAR REVERSING ALARM
_J
L
Fig.5: here is a full size reproduction of the front panel artwork.
shuts down the IC4 beep oscillator.
The pin 3 output of IC4 controls
Schmitt trigger oscillator IC2d.
When pin 3 is low, D2 is reverse
biased and IC2d oscillates at about
lkHz and drives the piezo transducer via a 4.7kO resistor. When
pin 3 of IC4 subsequently goes high,
the .0068µ.F capacitor at the inverting input of IC2d charges via D2
and the IC2d oscillator stops.
In practice, this means that we
get a series of lkHz beeps which increase in rate as the car gets closer
to the object. This beep rate continues to increase until IC2c shuts
down IC4. When that happens, pin
3 of IC4 goes low and IC2d drives
30
SILICON CHIP
the piezo transducer continuously.
Power for the circuit is derived
from the + 12V supply rail to the
reversing lights. This is fed to a
3-terminal regulator to give a + 8V
supply, thus making the circuit independent of changes in battery
voltage. Zener diode D3 ensures
that high voltage spikes on the supply line are kept out of the
regulator.
Construction
The circuit for the reversing
alarm is built on a small PCB coded
SC05102891 (105 x 60mm). Fig.3
shows the wiring details.
Start construction by installing
The completed unit can be easily
tucked away in a corner of the boot.
Power for the circuit comes from the
+ 12V rail to the reversing lights.
all the low profile components first.
These parts include the resistors,
diodes, wire links and ICs. Note that
the ICs, diodes and electrolytic
capacitors are all polarised parts
and must be correctly oriented as
shown in Fig.3.
The 3-terminal regulator must
also be installed the right way
around. It should be mounted with
its metal tab facing towards the adjacent edge of the PCB (see photo).
Push the regulator down onto the
board as far as it will comfortably
go before soldering the leads.
Attention can now be turned to
the wiring. Shielded audio cable is
used for the connections to the
40kHz transducers while all other
connections can be run using
medium-duty hookup wire. Be sure
to make the leads long enough to
reach their required destinations
when the unit is mounted in
position.
Switch Sl and its associated wiring can be deleted if you only require one minimum set distance. If
you do decide to leave Sl out, delete
VR3 also and connect a wire link
between the wiper of VR2 and pin 4
of IC2. Just wire the link between
two of the vacant pads that would
normally be used to terminate the
switch wiring.
The reversing alarm can be
bench tested by connecting it up to
a 12V power supply. Switch on and
check that there is + 8V at the
regulator output and on the IC supply pins.
Now lie the two transducers side
by side away from any obstructions
and check that the piezo transducer
beeps at about a one second rate. If
this checks out, move your hand
close to the sensors. The frequency
of the audio beeps should increase.
If the beeps don't increase in frequency, try adjusting trimpot VRl.
This trimpot sets the transmit frequency and should be adjusted for
maximum sensitivity. VR2 and VR3
should be adjusted to give the
desired minimum set distance (ie, a
continuous audio tone] for each setting of S1.
Installation
We housed the prototype PCB in
a plastic case measuring 130 x 67 x
43mm but you can use a larger case
if you wish. The ultrasonic sensors
were housed in a separate small
plastic case measuring 83 x 54 x
30mm.
The PCB is secured to the inside
of the plastic case using the integral side pillar supports. You will
have to drill holes in the case for
the screened transducer leads, the
power supply wiring and leads for
the piezo transducer.
Just how you mount the unit will
depend on the type of vehicle you
have. In any case, the unit should
be mounted towards the rear of the
vehicle (eg, in the boot] to keep the
leads to the ultrasonic transducers
short. This will also make it easy to
tap into the reversing light circuit
for the power supply rail.
The two ultrasonic transducers
can be mounted below the rear
bumper bar and secured using a
suitable bracket. We suggest that
you come up with some sort of plug
and socket arrangement so that the
transducers can be easily removed
when the car is to be washed.
If the transducers do get wet,
they will operate normally again
after they have dried out. But be
warned - if the transducers are
saturated with water (eg, when it
rains] you will not be able to rely on
the circuit when parking.
!§;l
.,..__,SPECit~1tR ~ <:;;:i
vKa
::.-:.:::=:::;:
NEW
SPEAK
1lw-::::::
]1~l
I-lti
I,,,:
%t
::.¾1~
Since the introduction of VIFA speaker kits
in Australia in 1985, thousands of speakers
have been built with superb results . VIFA is
now proud to release four new speaker
kits ranging from a mere $399 to $1199 per
pair including cabinets.
Never before have speaker kits been so
popular in Australia than after the heavy
devaluation of the dollar. Similar fully
imported quality loudspeakers are today
typically 2-2½ times more expensive. And
these speakers may very well be using
Danish VIFA drivers anyway, as VIFA
supply more than 50 of the world's most
respected loudspeaker manufacturers
with drivers.
But why the big savings? Because
fully imported speakers suffer from 25%
import duty, 20-30% freight, 30% sales tax
and 28% handling charges (typically). So if
you would rather put your money into better
quality than in other people's pockets, VIFA
speaker kits are the only way to go.
Are they difficult to build? No, the kits
are supplied with all parts needed including
fully built crossovers and pre-cut flatpack
cabinets ready to assemble. No soldering
or carpentry skills are needed; just a
Phillips head screwdriver, some simple
hand tools and a few hours of your leisure
time.
Are they as good as people say? Read
the reviews, listen and compare with any
other speakers twice the price or more.
Need we say anymore?
VIFA for the quality conscious
audiophile.
I·•-❖❖
!
For full details please contact
Sole Australian Distributor:
SCAN AUDIO Pty. Ltd.
P.O. Box 242, Hawthorn 3122.
Fax (03)4299309
Phone: (03! 4292199 (Melbourne)
(02 5225697 (Sydney)
(07 3577433 (Brisbane)
(09) 3224409 (Perth)
Stocked by leading stores throughout Australia
Polystyrene capacitors
YES
Made here in Australia?
YES
Made Special to Type?
YES
Where From?
Allied Capacitors Australia
Allied Capacitors Australia specialises in custom made good quality, high
stability polystyrene capacitors. Why design circuitry which requires additional
components to achieve a specific capacitance; we can wind exactly the
capacitance you need to match your design criteria within the ranges of 1 OpF to
1µF and up to 1 0,000VDC.
Capacitors are manufactured to 0.25% , 0.5%, 1 .0%, 2.0%, 2.5%, 5%, 10%
and 20% and are priced according to tolerance. All capacitors are tested to 2.5
times the rated voltage.
--.--,-.- ----------
,
Interested?
Call us now on:
1 Yes, I am interested in your capacitors.
(02) 938 4690
I ./ ... VDC ... / ... VDC.
OR Cut out and post this coupon to
Post Office Box 740
~ B
_r_oo_k_v_a1_e,_ N._s_.w_._ 2_1_o_o___
I Please post me
Name
details of the fol lowing values:
VDC ... / .. VDC
(Please print)
I Address
L~~~~~- ~~~~~~J
JANUARY
1989
31
|