This is only a preview of the June 2021 issue of Silicon Chip. You can view 0 of the 112 pages in the full issue. For full access, purchase the issue for $10.00 or subscribe for access to the latest issues. Items relevant to "Advanced GPS Computer - Part 1":
Articles in this series:
Items relevant to "Recreating Arcade Pong":
Articles in this series:
Items relevant to "PIC Programming Helper":
Items relevant to "Programmable Hybrid Lab Supply with WiFi – Part 2":
Purchase a printed copy of this issue for $10.00. |
CIRCUIT NOTEBOOK
Interesting circuit ideas which we have checked but not built and tested. Contributions will be
paid for at standard rates. All submissions should include full name, address & phone number.
Building a better mousetrap
Here in rural SE Queensland, there
has recently been a proliferation of
mice. Apart from spreading nasty diseases like leptospirosis, they can also
do a lot of damage. We had one in
the house, and every night it would
go through the pantry, ripping open
packets and destroying the contents.
So I purchased a cage trap from
the local hardware store. This has a
mechanical trigger, operating via a rod
to release a hinged door. This door is
spring-loaded with a bar which falls
as it closes, preventing the door from
being pushed back open. This looked
like a good concept, but unfortunately,
that was not the case. Most times, the
bait would be taken, but the trap would
not trigger. Who said mice were dumb?
I concluded that a more sensitive
trigger would be the solution, and
decided to design a light-beam trigger
for the trap. This subsequently proved
successful.
I removed all the existing trigger parts
siliconchip.com.au
and made an aluminium plate which
clips onto the cage and can be easily
removed to facilitate mouse removal.
This plate was fitted with a solenoid
release mechanism, a microswitch (to
turn off the power once triggered), and
also provides support for the electronics and the IR LED and receiver.
A primary criterion was to minimise current consumption so that it
could be powered by dry cells (eight
AA cells giving around 12V). My final
design draws only 1mA, so it should
run for at least a year.
I selected an IR receiver as used
in all manner of remote-controlled
devices. They cost less than $1 and
are easily sourced from local suppliers or eBay. They have an amplifier
with AGC, and a bandpass filter at
38kHz plus a data detector and output driver. The 38kHz BPF provides
immunity from outside optical interference. They run from 5V.
I initially tried sending a 38kHz
square wave via an IR LED, but the
receiver detects for only about 200ms
then stops. I concluded that the IR LED
needs to be modulated to simulate data
so that the IR receiver will operate continuously; the data sheet is not clear
about this. I subsequently pulsed the
38kHz IR LED at 15Hz, and this gave
a continuous 15Hz square wave at the
receiver output.
IC1a-IC1d are schmitt trigger NAND
gates. The 470nF capacitor is alternately charged and discharged as output pin 10 of IC1c toggles, producing
a 15Hz square wave. This is fed to pin
1 of 38kHz oscillator IC1a, switching
it on and off.
The pin 3 output of IC1a feeds the
180pF/10kW RC high-pass filter, and on
each falling edge, a short pulse toggles
IC1c, reducing the output duty cycle to
1.7µs. This greatly reduces the current
drawn by the IR LED, which is driven
by 2N7000 N-channel Mosfet Q1.
I found that the optical path had a
range of a few metres, far more than
required for my application, so in the
61
interest of minimising current drain I
adjusted the dropping resistor for the
IR LED to 3.3kW, giving a range of about
300mm. Too much LED current can also
saturate the area with the optical signals, causing reflections to prevent the
beam from breaking when it should.
The receiver output is a steady
15Hz signal, and to detect that the
beam is broken, this is fed to IC2a, a
monostable wired as a missing-pulse
detector. The R & C values set it to
about 160ms, so the light beam has to
be broken for at least that long to trigger
the trap. This prevents false triggering.
I used a solenoid purchased from
eBay, rated at 28V AC, but found it
works fine on 12V DC. The 5600µF
capacitor delivers a hefty pulse and the
solenoid closes very rapidly (I wouldn’t
want to put my finger into it!).
The output of IC2a feeds a pulse
to another 2N7000 (Q2) via a 4.7µF
capacitor, and Q2 switches on P-channel Mosfet Q3 which drives the solenoid. Q3 is seriously oversized for the
job, but I had it in my junk box. The
diode across the solenoid protects
against any back-EMF.
The reason for the RC network on
the output of IC2a is to deliver a single drive pulse. Without this RC network, if the power were left on with
the light beam broken, the solenoid
would be permanently activated, flattening the battery.
The red LED in series with the 5V
regulator input shows that the power is
on, and it flickers with the 15Hz modulation. I wired it in series as the regulator only draws about 1mA, and that
gives a noticeable glow without adding
to the overall current consumption.
The IR detector I used was mounted
on a small PCB, with a 10kW pull-up
resistor. Checking the data sheet
revealed that the device already has
an internal pull-up, so I removed that
external resistor to save current. I then
placed this PCB in a small box to prevent the entry of unwanted external
light.
If you have an oscilloscope, you can
monitor the optical receiver’s signal
output to set the correct amount of
transmitter LED current.
Editor’s note: due to variation in
schmitt trigger thresholds, it’s worth
checking that the signal at pin 3 of IC1a
is close to 38kHz, and if not, adjust the
value of the 6.8kW resistor.
Bruce Boardman VK4MQ,
Highfields, Qld. ($125)
62
Silicon Chip
Australia’s electronics magazine
siliconchip.com.au
|