62
Abandon Hope All Ye Who Enter: The Optical Mousetrap BE 310 Final Project Brought to you by: Group M3 Thomas Comerota Matthew Dunn Saiful Khandker

Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

Embed Size (px)

Citation preview

Page 1: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

Abandon Hope All Ye Who Enter:

The Optical Mousetrap

BE 310Final Project

Brought to you by: Group M3

Thomas ComerotaMatthew DunnSaiful KhandkerAlison Razinsky

April 28, 1997

Page 2: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

Introduction

“Build a better mousetrap and the world will beat a path to your door.” As

evidenced by the vast variety of mousetraps available on the market today, the

development of an infallible mousetrap has been an unreachable yet frequently reached

for goal for many years. Eradicating such rodents is costly, time consuming and

stressing. The aim of the Optical Mousetrap is to fill the market need by producing an

effective and inexpensive trap.

The Optical Mousetrap uses a beam of infrared light and phototransistor to

ensnare whatever crosses its path. Upon entering the trap, the mouse breaks the beam,

ceasing the photocurrent entering the phototransistor. A solenoid is then activated,

retracting its plunger which drops a door over the opening of the box. The mouse, now

completely enclosed, is prohibited from escaping.

Background

Product Need

Throughout time, man has been burdened by many pests such as gnats, rats,

mosquitoes, and ants; however, one of the greatest nuisances to man and his habitat has

been the mouse. Notorious as carriers of “germs”, mice and their brethren have eluded

our traps and befuddled many an exterminator. They are quick, running at speeds of up

to 11 feet per second, and small, varying in size from 3-5 inches from head to tail,

making them quite elusive.(Bielfeld, 67) They are both social and intelligent, in that

they use each other to “scout” areas before exposing themselves, relaying messages to

their cohorts through a series of high frequency squeaks and chirps. They eat through

plastic bags and articles of clothing, in search of food.

A search through US patents (IBM patent server http://patent.womplex.

ibm.com/ibm.html) gives 50 patents on mouse traps or devices designed as mouse traps.

Over the years many have tried to develop a foolproof method for the trapping of a

mouse, however, few have succeeded. The old wood and spring mouse trap seems just

Page 3: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

as popular today as it did many years ago, indicating that there really has been no major

leap forward in mouse trap technology. Another technique for the trapping of a mouse is

using a method which utilizes an adhesive much like that used for the snaring of flies on

fly paper. A plastic tray, which is coated with an inconspicuous adhesive, is covered

with “mouse bait”. When the mouse steps onto the plastic to eat the bait, it is caught.

The construction of an optically activated mouse trap would seem rather redundant and

unnecessary when compared to the relatively inexpensive, simple, and efficient design of

the more antiquated traps. However, the mere existence of 50 types of traps suggests that

there is a need for traps, and a perfect trap has yet to be designed. The optical sensor

technology used in such a device can be used for various other applications such as anti-

theft devices (with some modification to the circuit and casing — of course). This

mouse trap was intentionally designed so that it did not kill, maim or otherwise injure the

mouse (something most other traps cannot claim). A circuit using dark activated

operations provides one with a valuable learning aid as well as a creative method for

catching a rodent or a thief.

The optical mousetrap’s circuit consists of intricate electrical components

including a transistor, phototransistor, SCR, and solenoid. The mentioned components

are elaborated below.

Transistor

When a semiconductor has impurities added to it in a process called “doping”, the

resulting material is known as an impurity semiconductor. The doping is usually done

with small amounts of arsenic (used in n-type) or gallium (used in p-type) which replace

a few of the atoms in the silicon crystal lattice of the original semiconductor. The

resulting structure, if arsenic is used, is known as an n-type semiconductor. It has an

extra electron (since arsenic has 5 valence electrons and silicon only has 4) and an

increased conductivity since the extra electron contributes to the conduction band of the

semiconductor material. If gallium is used, the semiconductor is known as p-type, and

the effect is to create a “hole” in the crystal lattice structure, since gallium only has 3

valence electrons. These holes are then free to propagate in the direction of the applied

electric field, permitting conduction. Combining 3 pieces of such impurity

Page 4: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

semiconductors such as NPN or PNP results in the formation of a device known as the

transistor.

The transistor was invented in 1948 by William Shockley, John Bardeen, and

Walter Brattain (Tipler, Ch. 39) and has revolutionized electronics, giving us the ability

to construct most of the devices we take for granted today. There are three regions of

semiconductor in a transistor. The center region is known as the base while the two

surrounding regions are known as the collector and the emitter. The base is made of

either p-type or n-type semiconductor, and the collector and emitter are both made of the

opposite type of semiconductor so that there are NPN and PNP transistors. In an NPN

transistor, a small current supplied to the base results in a large amount of conduction

from the collector to the emitter. The resulting current has a current gain, symbolized by

, which occurs between the collector and the base and is written in equation form here:

I Ic b

The NPN transistor, while also a current amplifier, can also act as a switch. The

switch works on the principle that during base ionization (i.e. sufficient current is going

into the base), current flows from the collector to the emitter. The emitter can be

grounded, so that as long as there is current running into the base, current entering the

collector goes into ground. When the base current is interrupted, forward conduction

from the collector to the emitter ceases and any current flowing to the collector must go

another way. Wiring the collector to a load will allow current to pass through the load

only if no current is going to the base, that is, the switch is in the “off” position. If

current is flowing to the base, current will not reach the load and the switch is considered

“on”.

Page 5: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

Phototransistors

Visible light causes ionization in silicon, hence an exposed base region can use a

photocurrent just as it would a normal current to produce charge pairs within its lattice

structure. Though a bipolar transistor has three leads, a phototransistor has only an

emitter and collector, its base being the exposed region discussed above. Most

phototransistors are NPN devices with a base region much larger than that of a standard

NPN transistor, with a response time on the order of 1 microsecond. There are special

phototransistors which respond to only infrared light, which has a wavelength in the

range of 900 - 1000 nm. To construct a switch which responds to such an infrared

stimulus requires the implementation of a special diode which outputs light in the

wavelength range of 940nm. Both are readily available from most suppliers of electronic

paraphernalia.

SCR

An SCR (Silicon Controlled Rectifier) is a device that acts as a one-way switch,

i.e. once turned on, it does not switch off until it is reset. The SCR has three leads, an

anode, a cathode and a gate. It is normally non-conducting, but when the gate-cathode

junction is forward biased, the SCR goes into saturation, thereby switching. It remains in

it’s conducting mode until the anode current drops below a few milliAmps (0.2 mA for

the one used in the actual circuit). The SCR in circuits such as the mousetrap usually

maintains a low voltage while conducting, so there is not often much of a problem with

overheating. However, the SCR has a metal protrusion (which is a minor heat sink in

itself) where a heat sink can be attached to deal with such problems if they arise.

Solenoid

A solenoid is nothing more than a wire wound into a helix of closely spaced

turns. When a current is applied to this wire, the result is the creation of a uniform

magnetic field within the region of the coils. The magnetic field produced is directly

proportion to the number of turns per length of coil and the amount of current going

through it. The magnetic field within the loop is parallel to a center line going straight

Page 6: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

through all the turns of the wire (it tends to diverge slightly where it is closer to the top

or bottom of the coil and diverges totally when outside the coil). As a result, the

solenoid can effectively be used as a pulling or pushing mechanism for magnetic

materials, depending on the direction of the current and the direction of the intended

“pull” or “push”. Prefabricated solenoids can be found with a center plunger built in to

the device. The plunger is nothing more than a metal rod which inserts into the center of

the solenoid in the presence of a magnetic field. This plunger is then retracted when

current is run through the solenoid. Prefabricated solenoids are therefore meant to be run

in only one direction and hence only one direction of current will allow the solenoid to

operate. This is a perfect device to control the movement of something, such as the

dropping of the door in the mouse trap.

Trap design

The characteristics of mice played an important role in the design of the mouse

trap. It was designed keeping the limitations and preferences of the mouse in mind. The

average mouse is approximately 3-5 inches from head to tail (Bielfeld, 67). This means

that the tunnel must be at least 5 inches for effectiveness (considering the size of mice,

there must be room for the bait). In its natural habitat the mouse eats starchy foods such

as grains, millet and rice. For this reason the bait should consist of skinned sunflower

seeds and some random foods that one would naturally find lying around the house.

Otherwise, prefabricated mouse bait is available. Since the mouse is extremely sensitive

to touch, the bottom of the trap is removable so as not to tip off the mouse that it is

entering a foreign area. Mice are extremely quick, with maximum speeds of up to 11 feet

per second, which means that the trapping mechanism must be quick also. The

phototransistor (discussed above) is used for the “tripping” mechanism since it has a

response time on the order of milliseconds (compared with other devices such as a

photoresistor which has a response time of close to 1 second).

Page 7: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

Consumer Safety

Safety precautions when using and constructing this device were necessary. The

circuit was relatively safe, however, some precautions had to be taken when handling the

components after it was run. The transistor was heating up (this was thought to be a

design problem discussed later in the report) and one had to be careful when touching it.

However, it was not heating up to such a high temperature that it would have caught the

box structure on fire. Also, the trap door was light enough so that it would not endanger

human body parts unintentionally put in the box. The circuit was housed in the box so

that there would be no chance of electrocution of unsuspecting humans or there pets.

Page 8: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

System Overview

Circuit #1 : Mousetrap, Final Circuit

List of Components Used

1 9V Radio Shack battery

1 set of Battery Snaps

1 Small BreadBoard —Jameco Product # 20600

1 1 F Capacitor

1 Infra-red Diode— Jameco Part # 112150 Product # TLN100

1 Phototransistor—Jameco Part #124020 Product # TP104

7 Resistors: 100 , 1 k, 2 2 k, 150 k, 2 1 M

1 SCR—Jameco Part#14736 Product # C106B1

1 NPN Transistor

1 Tubular Pull Solenoid—Part # 132003

Large Supply of 22 Gauge Wire (American Wire Gauge)

List of Components used to Construct the Box

Matte Board

Variable length Scotch brand translucent unidirectional bonding strip.

Final Circuit Description

Page 9: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

As a means of catching mice, a beam of infrared light is emitted from the infrared

diode and received by the phototransistor. The infrared diode is powered directly from

the 9V DC battery, through a voltage divider that sets the voltage drop across the diode at

4 V. While the phototransistor is receiving the light beam, it is in its saturated state,

essentially, being “turned on”. This draws the current from the battery through R1 and

the phototransistor, and straight to ground. Due to the high resistances of both R1 and

the phototransistor, there is not enough current leading to the transistor to switch it to the

“on” mode, and the rest of the circuit is therefore bypassed.

Once the beam of light is broken, there is no longer a light supply leading in the

base of the phototransistor, and it switches to the “off” mode. The phototransistor is then

essentially an open circuit, and the current bypasses it and proceeds from R1 to the

transistor. Now that there is enough current, the transistor switches into the “on” mode.

The purpose of this transistor is chiefly to act as a current amplifier. A 9 V passing

through a 2.25 M resistance has a current of ~ 4 Amps, which is below the SCR’s

operating range. The SCR requires a minimum of 200 Amps to function, so the circuit

needs to amplify our current by at least 50 times. The of this transistor is 116 ± 1%

(refer to Operational Specifications), which provides more than enough current to trigger

the SCR.

Once the phototransistor switches to “off”, and the transistor switches to “on”, the

voltage leading into the gate of the SCR jumps from below its threshold value of .71 V

(typically 0.51 ± 0.3 % V) to a point above it (typically 0.80 ± 0.3 % V). The SCR

then switches, allowing current to flow to the solenoid, which also switches. Once the

solenoid switches, the lid on the box closes, and the mouse is then (theoretically) caught.

However, by the nature of the SCR, once it is switched, it will not reset until the power

supply is removed. In this state, the solenoid is closed, and cannot be opened by hand.

To bypass this, a switch was added to the circuit between the power supply and the

circuit. Once the trap is sprung, the customer turns off the power, disposes of the mouse,

resets the trap, and then turns the power back on.

The capacitor in this circuit will be discussed in the section on changes made

from the original circuit.

Circuit #2 : Penultimate Mousetrap Circuit Design

Page 10: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

Circuit Description

The Penultimate Circuit is where most of the testing phase of the project was

conducted. This is essentially the core of the final circuit used, without the bells and

whistles such as the switch and the capacitor. After the circuit evolved into this form, all

that remained was essentially fine tuning. The functioning of the circuit, and the role

each element plays in the functioning of the mousetrap is described above in the

description of the final circuit.

Page 11: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

Circuit #3 : Original Mousetrap Circuit Design

Changes Made from Original Mousetrap Circuit Design

The original circuit called for 2 9V batteries in series to power the circuit. This

was originally planned because the advertisement for the solenoid purchased listed its

switching threshold at 12V DC. Upon receiving the solenoid and testing it, the true

switching threshold was found to be 4.5V DC. The second 9V battery was determined to

be superfluous, and was then removed from the circuit. Consequently, the voltage

divider needed to be rebiased, to allow the necessary voltage to power the solenoid

subcircuit, and still power the infrared diode as well.

It was decided to place the two subcircuits in parallel with each other, rather than

across a single voltage divider. From this decision, it was necessary to create a suitable

voltage divider for the diode. At first, the voltage divider created for the diode had R4 =

7 k and R5 = 2 k1 This was sufficient to power the diode, but towards the end of

testing, there was concern that the infrared light being emitted was not powerful enough

for the phototransistor to receive, so the power to the diode was increased. The final

1

Page 12: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

voltage divider for the diode subcircuit had resistor values of R4 = 2 k, and R5 = 2k2.

Another result of this decision was that the resistors R2, R3, and R53 were removed from

the circuit, as they were no longer in use.

The solenoid subcircuit was then tested, and it did not work. It was observed that

the emitter of the phototransistor led to the gate of the SCR, and could in fact switch the

SCR while the light beam remained unbroken, so this connection needed to be

terminated. The emitter of the phototransistor was then connected to ground. Further,

R64, leading into the SCR, was connected to ground instead of the SCR, and the SCR

was connected to the emitter of the transistor. R6 was intended to be an emitter follower,

but was placed incorrectly in the original circuit. It should have been connected to

ground, but was instead mistakenly drawn as being connected to the SCR. As an emitter

follower, R6 acts in parallel with the SCR/solenoid portion of the circuit, and in essence

dominates the resistance of the parallel circuit. This helps isolate the signal from any

loading effects the SCR and solenoid might cause, as well as reducing the impedance of

the signal leading from the emitter of the transistor to the SCR (Horowitz, 67). This was

a minor oversight which was corrected immediately after it became apparent.

Additionally, there was problem with the variable resistor, R15. Varying the

value of R1 changes the current traveling through R1 and the phototransistor. This, in

turn, controls the sensitivity of the phototransistor to the infrared diode’s emission. By

decreasing the current through the phototransistor, a weaker beam from the diode can

still trigger the phototransistor, allowing the current to flow through it. By allowing a

weaker beam, the distance between the diode and the phototransistor can be increased.

So, the higher the resistance of R1, the lower the current through that subcircuit, and the

farther apart the diode and the phototransistor could be placed. But it was found that the

maximum value of the variable resistor, R1, 100 k, was too low to allow the diode to

trigger the phototransistor at all. R1 then had to be increased to a level where the current

was low enough for the diode to trigger from as far way as the internal width of the box,

3 inches. The resistance found most suitable for this distance was on the order of 2 M.

23 These resistor values refer to the resistors named in circuit 3, the original circuit.4 “5 “

Page 13: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

After experimenting with several resistances of that magnitude, the final resistance

settled upon was 2.15 M.

By the nature of the SCR, once it is triggered, it remains triggered until the power

supply is removed, resetting the SCR. Originally, this could only be accomplished by

disconnecting the battery from the circuit. As a product on the market, this would not be

feasible, as consumers do not want to manually remove and reinsert a battery into a

device after every time they use it. So, as a means of getting around this dilemma, a

switch was installed into the circuit between the power supply and the rest of the circuit,

as described in the description of the final circuit above.

Towards the end of the testing phase, the solenoid was switching constitutively,

and there was concern that there were current spikes left over in the circuit after resetting

the power supply, which would switch the solenoid regardless of the light beam. A 1 F

capacitor was inserted into the circuit, connected from the power supply to ground, as a

means of filtering out these high frequency spikes.

Page 14: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

Circuit #4 : Transistor Switch Testing Circuit

List of Components Used

Resistors: 6.68 k, 5.17 k, 2 1 k

Variable resistor: 50 k

Transistor: N22202 NPN

DC Power Supply

Voltmeter

Function generator

Oscilloscope

Circuit Description

This circuit is used to test the switching speed of a transistor. Resistors R1, R2,

R3, and R4 act as a current regulator, controlling the current entering the base of the

transistor. This in turn controls when the transistor switches. By adding an AC current

as Vin, and varying its frequency, the experimenter is able to record the maximum

switching frequency. When the inverse of this frequency is taken, the result is the

switching speed.

Page 15: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

Circuit #5 : SCR Testing Circuit

List of Components Used

1 SCR

2 Switches

1 LED

1 Function Generator

Circuit Description

This circuit is used to test the switching speed of the SCR. With switch 2 closed,

closing switch 1 allows the SCR to switch, lighting the LED. Then, if switch 1 is opened

again, the LED remains on. Only then opening switch 2 again will allow the SCR to

reset, thus turning off the LED. By powering this circuit with an AC power supply, and

slowly increasing the frequency of the sinusoid, the switching speed of the solenoid can

be determined by taking the inverse of the frequency at which the LED no longer lights.

Page 16: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

Circuit #6: Future Circuit Design

List of Components

2 9V Radio Shack batteries

2 sets of Battery Snaps

1 Small BreadBoard —Jameco Product # 20600

1 1 F Capacitor

1 Infra-red Diode— Jameco Part # 112150 Product # TLN100

1 Phototransistor—Jameco Part #124020 Product # TP104

7 Resistors: 100 , 1 k, 2 2 k, 150 k, 2 1 M

1 SCR—Jameco Part#14736 Product # C106B1

1 NPN Transistor

1 Tubular Pull Solenoid—Part # 132003

Large Supply of 22 Gauge Wire (American Wire Gauge)

1 8V Voltage Regulator

Circuit Description

This circuit is the proposed future design for the mousetrap circuit, including the

addition of a second 9V battery, and a 8V Voltage regulator. See Operation

Specifications for further explanation.

Page 17: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

Construction Procedure

The steps involved in the construction of the final circuit are bolded.During the construction of the box, a 12” ruler was used for all measurements. The error incurred by the ruler was deemed insignificant enough to not be cited with each measurement.

Required parts

Part Name Catalog Part # Product #SCR driver Jameco 14736 C106B1Tubular Pull Solenoid Jameco 132003battery snaps Jameco 101469phototransistors Jameco 112168 IRD500infra-red diodes (940 nm) Jameco 106526 TLN110Small BreadBorad Jameco 20600 9 volt batteries

Additional Parts

Multiple Resistors

22 gauge wire (American Wire Gauge)

1/16“ matte board

Phototransistor and Diode

1. Two 8 inch green wires and two 8 inch white wires were cut and ½ inch was

stripped from one end of each, and ¼ inch was stripped from the remaining

ends.

2. The exposed ½ inch end of one green wire was soldered to the collector of the

phototransistor, and the exposed ½ inch end of the other green wire was

soldered to the positive side of the diode.

3. The exposed ½ inch end of one white wire was soldered to emitter of the

phototransistor, and the exposed ½ inch end of the other white wire to the

negative side of the diode.

Page 18: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

4. When the soldering cooled, electrical tape was taped around the soldered area so

that no metal wiring was exposed.

Solenoid

1. One 8 inch white wire and one 8 inch green wire were cut and ½ inch was

stripped from one end of each, and ¼ inch was stripped from the remaining

ends.

2. The exposed ½ inch end of the green wire was soldered to one of the wires of the

solenoid and the exposed ½ inch end of the white wire to the other.

3. When the soldering cooled, electrical tape was taped around the soldered area so

that no metal wiring was exposed.

Switch

1. A small (about 1cm) six prong on/off switch was selected from a large supply of

switches.

2. One 8 inch green wire and one 8 inch white wire were cut and ½ inch was

stripped from one end of each, and ¼ inch was stripped from the remaining

ends

3. The exposed ½ inch ends of these wires wire soldered separately to two adjacent

colinear prongs of the switch:

Protoboard and Circuit Layout

1. A small protoboard was chosen for the circuit so that it would fit into the 4.5” x

5” trap.

Page 19: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

2. The red column of both sides were connected via a wire cut to the appropriate

size.

3. The blue column of both sides were connected via a wire cut to the appropriate

size.

4. The positive power supply was wired via alligator clips and short wire to the left blue

column. Later this connection was replaced by the + supply voltage of the 9V

battery with a battery snap.

5. The ground of the power supply was wired via alligator clips and short wire to the

left red column. Later this connection was replaced by the - supply voltage of

the 9V battery with a battery snap.

6. The voltage of various batteries was tested on a voltmeter so that the battery with a

voltage level closest to 9V could be used.

7. A voltage divider was constructed for the LED.

8. First the resistors used were 1 k, 1.8 k, 200 k, to get the voltage to

divide to 1 in 10. (The LED was placed after the 1 k resistor.)

9. Alternatives tried were one 1 k and four 2 k to get the voltage to divide by

2 in 9. (The LED was placed before the last 2 k resistor.) For a 3 in 9

division the LED was placed before both the 2 k and the 1 k resistors

10. The final voltage divider consisted of two 2 k resistors which divided

the voltage in half (R4 and R5 in Circuit #1).

11. The white wire of the LED (-) was placed in the red column and the

green (+) in same row where both R4 and R5 were situated.

12. A wire connecting the blue column to a row on the board was inserted on the board.

13. R1 was cut to the appropriate size and placed on the board in the same row as

above. (Refer to system overview for the schematic of the circuit.)

14. The first value chosen for R1 was a variable 100k resistor.

15. R1 was altered in a range of 100k and 12 M when the system was being

fine-tuned for distance for between the LED and phototransistor. Some

values included 2 M, 2.15 M and 2.5 M. This was one of the most

involved steps of the construction.

Page 20: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

16. The final value used for R1 was 2.15 M. This resistance value was

created by putting two 1 M and one 150 k in series. More

specifically, the top of the first was put in the row corresponding to

step 11. The top of the second resistor was placed in the same row as

the bottom of the first resistor. The top of the third placed in the

same row as the bottom of the second. (Refer to Rebiasing

Construction Procedure that follows.)

17. In the last row of step 15, R2 (100 ) was added to the board. Like the previous

resistors, its length was trimmed so that it fit exactly, and lay flat against the

board.

18. The other end of the resistor was placed in the same row as the base of the NPN

transistor.

19. In the row of the emitter, a wire was originally run back to the emitter of the

phototransistor. (See Circuit 3 in System Overview.) It was later discovered that

this was incorrect.

20. Instead, the emitter was grounded. To row where the emitter was situated, R3

was added. The other end of R3 was put into the red column, i.e. grounded.

21. A 1 k resistor connected the transistor emitter to the gate of the SCR, by placing the

one end of the trimmed resistor into the row of the transmitter and the other the

row of the gate of the SCR.

22. This resistor was supposed to be connected from the emitter to ground, and was

repositioned immediately after discovery. The gate of the SCR was attached

directly to the emitter via a small wire.

23. In the row of the cathode, a wire was put in connecting the row to the red

column, or ground.

24. To the row where the anode was situated, the green wire of the solenoid was

inserted.

25. The other wire coming from the solenoid was place in the blue column, i.e.

positive voltage supply.

26. In the final circuit, a 1 F capacitor was placed on the circuit from the blue row

to the red row.

Page 21: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

27. A switch was added to enable the SCR to be reset. One wire was placed in the

blue column and the other in the top row. This was done so that when the

switch was off, there would be no current running though any part of the

circuit, both the solenoid and the transistor. The purpose was to minimize

the drain on the battery, even though, in actuality, the circuit should be in

the on position for the majority of the time.

28. The +V wire from the battery was removed from the blue column and instead

placed in the top row next to the switch wire.

Rebiasing Construction Procedure

The above circuit is designed to operate a 9V. When it was discovered that most

9V batteries do not operate at 9V and that the system drained the battery. An effort was

made to rebias at 6V. A 6V voltage regulator would have been placed after the battery

and would have permitted only 6V to run through the system. The required rebiasing

was mostly a function of the R1 value. The tradeoffs of this rebiasing and reasons 6V

were ultimately not used are discussed in the operational specifications.

Future Construction Addition

Since the actual voltage level of the battery proved to be a problem, a useful

addition to the circuit would have been a push switch to check the voltage. An LED

could have been connected to a voltage divider that was constructed to divide the voltage

such that at greater than 6.1 volts the LED would turn on. At a smaller voltage, the

divider would provide too little voltage to the LED and it would not light. Rather than

have this system operate continually, a push button switch would be placed between the

voltage source and the voltage divider. Therefore, when the user wanted to test the

battery, he would simply need to push the switch, which in turn would close the circuit

and light, or not light, the LED.

Box Prototype Construction

Page 22: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

Initially a prototype box was constructed to provide a rough model in which to

test the circuit. The plans for the final layout of the box can be found in the next section.

The box was made by inverting the base of a Nike Shoe box ( 8 in wide x 13 in long x 6

inches high). Most of the front panel was removed, leaving ½ inch attached to the box

on each side to be used as guide rails. A utility knife was used for steps involving cutting.

The ½ inch stripes were folded to a 90o angle to the side panel. A door (6 in x 7 7/8 in

was cut from the box top. The 1/8 inch was removed from the width in order to prevent

too much friction against the rails and sides as the door fell. Also a semi-circle notch

with ½ radius was cut from the bottom to provide a place for the door to sit on the

solenoid.

Once the rails were secured, and the door was dropped, it typically fell inward at

and angle rather than exactly perpendicular to the floor. To prevent this, a second set of

guide rails was added. To guide the falling door, ½ rails (cardboard protruding ½ inches

from each side) were added behind the front rails. To do this, two strips were cut 6

inches high and 1 inch wide. They were scored down the center and bent at a 90o angle.

It was glued to the side (using Elmer’s Glue) such that one panel was parallel to the side

and the other parallel, but ¼ inches behind the first guide rail. When the glue dried, a

test trial of the door drop was run and the door was found to fall smoothly between the

guide rails.

Because mice detect a change in flooring easily, a permanent floor was not

designed into the system. Instead a piece 15 in long x 8 in wide was cut from black

poster board. A hole was made at both the front and back end, and wire placed through

and attached to the font hole. Guide rails ( ½ in ) were duct taped along the bottom.

When the user set up the trap, he would pull the bottom board about 1” into the box and

pull the wire string out through the front. Ideally, when the door closed, the user could

then pull the string, thus pulling the bottom through. The string would be long enough to

wrap around the box and loop though the back hole, securing the base.

This box was used for the majority of the project, but a new box was constructed to

better meet the size specifications and stability required for the final design.

Page 23: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

Final Box Construction

The base, top and rails were all made with 1/16 inch black/gray matte board. The

black side always faced the exterior while the gray faced the interior. A utility knife

was used for all cutting

Base:

Steps:

1. The above was sketched onto matte board.

2. All edge lines were traced over with the utility knife, using a ruler as a guide

until the matte board was cut.

3. The piece was removed and the smaller two inner squares (as seen above) were

also cut out. They were 1 inch from the back.

4. The two inner lines were scored on the black side using a ruler as a guide.

5. Scoring was completed on the black side to outline the 4 ½ in x 5 in rectangular

base.

6. Along all scored lines, the matte board was bent at a 90o inward toward the

gray.

Page 24: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

7. Once the was completed, all the 900 bent pieces, except the back panel, were

secured on the inside using clear packaging tape.

The final base appeared as follows:

Page 25: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

The Top:

The Top Layout

Steps:

1. The above was sketched onto matte board.

2. All edge lines were traced over with the utility knife, using a ruler as a guide

until the matte board was cut

3. The piece was removed .

4. Scoring was completed on the black side to outline the 4 ½ in x 5 in rectangular

base.

5. Along all scored lines, the matte board was bent at a 90o inward toward the

gray.

Page 26: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

6. Once the was completed, the 900 bent pieces were secured on the inside using

clear packaging tape.

7. Later, a 1/8 square was cut from the top so that the switch could be added.

The final top looked as follows:

Page 27: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

Guide Rails:

Guide Rail Layout:

Steps:

1. The above was sketched onto matte board.

2. All outer edge lines were traced over with the utility knife, using a ruler as a

guide until the matte board was cut through.

3. The piece was removed.

4. Scoring was completed on the black side to the two inner lines.

5. Along all scored lines, the matte board was bent at a 90o inward toward the

gray.

Page 28: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

The final guide rails looked as follows:

These guide rails were then taped to each of the ¾ inch flaps on the base

section. A piece of black electrical tape was run from the inside of the flap to the

outer guide rail in order to maintain the 900 angle of the guide rails and to close off

the bottom of the rail so that the door would not fall through.

Door and Bottom:

The slide door (4 3/8 in x 4.5) and bottom (4 ½ in x 6 in) were also cut from

the matte board. A ¼ in square notch was cut in the bottom of the door, where the

door was to sit on the solenoid. A hole was made 1/8 inch from each end of the

bottom and a wire string attached to the front end through the hole. The door was

tested to ensure that it fell smoothly though the guide rails.

Final Box

Had the circuit functioned properly, the circuit would have been mounted on the

top of the base. The phototransistor would have been pulled downward through the hole

on the left side and the diode pulled through the right side. These would have been

guided along the interior and aligned ¼ inch above the floor on opposite sides. The

switch would have been pulled through and attached to the top. The top would have

been secured to the base by taping the back panels together and taping free ends of the

guide rails to the front panel.

Page 29: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

The finished trap should have appeared as follows:

If this system were to be produced on a large scale and placed on the market, balsa wood

may be a good material for the box. It is inexpensive, light weight (important for the

door and solenoid), and easy to cut, and glue before construction.

Page 30: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

Testing Procedure

To construct the circuit so that it would operate according to the desired

specifications, each component of the circuit needed to be tested. These included, the

solenoid, the door in conjunction with the solenoid, the phototransistor, the photo-

transistor and infra-red LED pair, the SCR, and the output of the batteries. Once the

properties of the components were understood, the circuit was constructed. When the

system did not operate, the circuit was essentially broken down and each section tested to

determine the location of the error.

The Solenoid

In addition to the general information available from the specifications sheets,

information was obtained by various tests. First, the maximum extension length of the

solenoid plunger was determined. The solenoid was powered with 9V from the power

supply while the center was pulled out at increasing distances. The point was found

where the power was not great enough to retract the solenoid. This point was marked

and all successive tests were conducted at distances less than this maximum.

Second, the voltage required to trigger the solenoid needed to be tested. The

solenoid was connected directly to the power supply and the shaft was pulled out to the

marked line. The voltage was slowly increased in increments until the solenoid retracted,

giving the required voltage.

The purpose of the solenoid was to retract so that the trap door would fall. The

solenoid was placed on the system, holding up the door, and powered at 9V. The

cardboard originally used for the door placed too much weight on the solenoid and

prevented it from retracting. Therefore, a lighter material, black poster board was used

instead. This proved successful, and when held in place by the guide rails of the box,

seem to be sufficiently sturdy to keep the mouse from escaping.

Phototransistor

Page 31: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

Several characteristics of the phototransistor needed to be tested in order to use it

optimally in the system. First, the effect of various levels of light versus darkness were

checked by attaching the phototransistor to the voltmeter and measuring the level of

resistance. As light decreased the resistance increased. In complete darkness, the

phototransistor had extremely large resistance. (Refer to operational specifications for

specific values.) An exact value could not be obtained due to the limitations of the

voltmeter. When directly exposed to the infrared LED, the resistance was much lower.

This relationship between resistance and brightness was utilized in the construction of the

circuit.

Infrared LED

Since the LED was infrared, it was impossible to visually establish if the LED

was functioning properly, i.e. that the LED was not blown. Since the circuit was

rearranged and tested a significant number of times, this was a distinct possibility. As a

check, the phototransistor was attached directly to the voltmeter and exposed to the LED.

As long as the resistance exceeded 20 M, the LED was operating correctly.

Phototransistor-LED Pair

The distance between the phototransistor and the LED affected the level of

response of the circuit. When the circuit was in its first stages, it would only operate

when the phototransistor and LED were extremely close in distance, within 1.5 inches.

At larger distances, the circuit triggered automatically or failed to trigger when the light

beam was broken. To adjust for this factor, R1 (Circuit #1) had to be increased so that

circuit would function when the phototransistor and LED were at a distance of 3 inches.

Though the box width was 4.5”, placement of the LED and phototransistor in the box

would place them at a distance of 3” apart. To accomplish this, the maximum distance of

separation was determined for varying resistances values in R1. All testing was done

under a box to minimize the effects of the florescent light and best simulate the actual

conditions of the circuit. In this testing, it was discovered that there was a tradeoff

between sensitivity of the system and distance of separation. The sensitivity was

quantified by the change in voltage entering the gate of the SCR. The voltage had to

Page 32: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

change (increase) enough when the beam was broken in order for the SCR to trigger.

For extremely large resistor values, breaking the beam decreased the level of voltage

variations caused by changes in light.

SCR

Testing was completed on the SCR to add to the information already available on

the provided specification sheet.

To test the SCR in the context of a switch, a switch was made according to

Circuit #5 in the System Overview. This circuit has two switches, and theoretically if

both are closed, the LED should light. To check the SCR, the second switch was kept

closed at all times. When the first switched was closed, the LED turned on and remained

on when this switch was opened. This showed that the SCR worked properly. The LED

then turned off only when the second switch was opened.

The characteristics of the SCR were also tested in this circuit. Both switches

were closed while the voltage was set to zero. The voltage was then increased. It was

later realized that this was not the voltage required to turn trigger the SCR but instead the

voltage required to turn on the LED in the circuit. As a result, a second approach was

taken. Once the actual circuit was completed, the effect of phototransistor and LED

distances was evaluated. At this time, observations were also made on the voltage into

the gate of the SCR, giving the minimum voltage required to trigger the SCR.

Batteries

Once the system was shown to work with the power supply, a 9V battery was

used in place of the supply. When this was done, the circuit failed to operate. To

determine the cause, the voltage of the battery was measured using the voltmeter. The

battery was less than 8V. Because the system was originally biased to work at 9V, this

voltage was too low to operate the system. The first approach to solving this problem was

testing all available batteries until the one with the greatest voltage value was found.

This was 8.7 V. After a few hours in use in the circuit, the voltage was again tested and

found to have dropped to around 8V. This presented a problem in that once the voltage

of the battery dropped a lot, the circuit would not operate. Therefore, as described in

Page 33: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

Operation Specification, another approach was taken to re-bias the system to operate at

6V.

Switching Speed

The switching speed of the circuit needed to be tested in order to ensure that the

door would respond quickly to motion and that it would fall fast enough to trap the

mouse. Three components in the circuit, the phototransistor, transistor, SCR, and the

solenoid, were tested since they were all factors contributing to overall circuit switching

speed.

The phototransistor's switching speed was thought to be the slowest, so it was

looked at first. Connecting the two ends of the phototransistor to a Digital Multi-Meter

(DMM) to read the resistance, the infrared LED was directed at it, created a beam. The

resistance between the collector and emitter of the phototransistor was low, near 1 M.

But when the beam was broken, the resistance jumped to greater than 20 M. The time

between the physical breaking of the beam to the point when the DMM read greater than

20 M was the switching speed of the phototransistor. Using a stopwatch, the time

between these two points was found, and hence this was the switching speed. For a more

accurate measurement, an oscillating beam to the phototransistor should be sent, using an

AC signal to the LED. Varying the frequency to the LED would alter the frequency of

light going into the phototransistor. Increasing the frequency up to the point where the

phototransistor does not switch would give the switching speed. Such is the method in

finding the transistor’s switching speed. But such precision was not needed, as discussed

in the operational specifications.

The transistor’s switching speed was found by employing the same type of

method discussed above. The transistor was placed in a switching circuit (Circuit #4 in

System Overview), such the voltage could be read out of the collector. Using the

function generator, a signal with varying frequency was placed at Vin. Increasing the

frequency up to the point where the transistor does not switch is the switching frequency.

Taking the inverse of this frequency is the switching time.

The switching speed of the SCR was tested using Circuit #5 in the System

Overview. In this circuit, Vin was modified to an AC signal. The frequency was

Page 34: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

increased until the SCR did not switch, resetting switch #2 each time in between. Again,

taking the inverse of the switching frequency is the switching time.

The solenoid’s switching properties were also very important to the mousetrap.

The solenoid was simply hooked up to the power supply with a switch in between.

Using a stopwatch, the time between the flipping of the switch and the retraction of the

plunger in the solenoid is the switching speed of the solenoid. This is not a precise as the

method using the frequency generator, but such accuracy is not needed, as discussed in

the operational specifications.

Testing Ineffective Circuit

At many instances during the circuit construction and adjustment, the circuit

either failed completely or worked for a short period of time and then failed. A series of

tests were conducted at each section of the circuit to locate the problem. Often the errors

were trivial. For instance, in testing the changes in resistance of the phototransistor, it

was discovered that under the electrical tape, the wire was no longer soldered to the

phototransistor. This was immediately repaired. Also for example, in testing the voltage

at various points along the circuit, it was discovered that one connection was improperly

grounded when it was intended to go to the positive voltage supply. Testing each section

separately facilitated the process of finding such errors. This procedure was also useful

in the final stages when the circuit worked for a short time but then failed completely.

The voltage was measured using the voltmeter at each circuit stage, i.e. after the

potentiometer, at the transistor base, at the transistor.

Page 35: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

Operational Specifications

Components

From the spec. sheets, the infrared LED was known to need 1.2 V and 0.020 mA

to light up. The LED was given 2 V, and to was shown to light up. The phototransistor

was tested by shining the LED on top of it and watching the resistance change. The

resistance value of the transistor shows whether the transistor is on or off state. The off

state gave a resistance value across the collector-emitter to be over 20 M, while the on

state was 1.15 ± 0.005 M. In testing the phototransistor properties, it was important

that to cover up the fluorescent light from the ceiling, because they emitted some light in

the infrared region, which caused noise in the system. It can be assumed that this noise is

nonexistent inside the mousetrap because it is closed from a light source.

The transistor in the circuit acted not only as a transistor switch but as a current

amplifier. Placing the EBC prongs of the transistor into the DMM, the hfe was found to

be 116 ± 1%. From the original construction of the circuit (which excluded the SCR

portion of the circuit), the voltage coming out of the emitter end of the transistor varied

from 3.56 - 5.6 ± 0.3 % V as the beam was broken. The current coming into the

transistor was 2.5 ± 0.5 % * 10-7 A, but the current coming out of the emitter was

amplified to 2.7 ± 0.5% * 10-5 A.

However, when the original construction of the circuit was added to the SCR unit

initially, the voltage coming out of the transistor shifted downwards. This was mostly

due to an error in the biasing of the circuit. False calculations of resistors were assumed

true in the circuit and hence, the overall circuit at that time did not work.

It was originally thought that the SCR needed 5 V at the gate to trigger, but this

proved wrong. After further testing, it was discovered that only 0.71 V was needed to

trigger the SCR. The current necessary to trigger the SCR was tested to be a minimum

of 200 A. After reconfiguring the circuit as detailed in the Construction Procedure, the

voltage coming out of the transistor went from 0.51 ± 0.3 % V to 0.80 ± 0.3 % V as the

beam was broken. Thus, the threshold was crossed as the beam was crossed.

Page 36: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

The solenoid was tested by placing zero voltage across it and raising the voltage

until the plunger retracted. The minimum voltage required for the solenoid to retract was

4.5 ± 0.05 V, and since the resistance of the coil was 37.4 ± 0.05 , the current to

trigger the solenoid was 120 ± 7 mA. Using physics, the magnetic strength of the

solenoid is defined by the following formula, B = mo * n * I , where mo = 10-7 T *

meters/A, n = number of coils, and I = current. Given that the number of turns in the

solenoid is 1976 from the spec sheets, the solenoid has a magnetic field of 2.37 ± 0.138

T * meters.

Frequency responses of each individual components could have been taken by

varying the input frequency into the component and measuring the gain (Vout/Vin).

However, this was unnecessary to the design of the mousetrap. Nothing in the system

was a function of the frequency. The power supply, 9 V batteries, were DC powered,

and thus, the signal in the circuit was DC. If the mousetrap were to be hooked up to the

wall and use AC power supply, then frequency responses of all the components would be

essential to the understanding of the circuit at hand.

Switching Speed

An important consideration in this circuit is the switching speed, or how fast does

the circuit react when the beam is broken. Without knowing this, the user cannot be sure

that the circuit will catch mice, because the circuit might be too slow. Three components

in the circuit were factors in the overall circuit switching speed, the phototransistor,

transistor, SCR, and the solenoid. The testing of the switching speed was outlined in the

testing procedure section, and the following are the results.

The switching speed of the phototransistor was determined to 0.8 ± 0.05 s. by the

stopwatch, but there was some human error incorporated within that measurement as

well. Nevertheless, the switching speed of the phototransistor was definitely less than

one second. The switching frequency of the transistor was 1.5 ± 0.075 MHz, which

corresponds to 6.667 ± 0.03 * 10-7 seconds as the switching speed. The switching

frequency of the SCR was 2 ± 0.1 MHz, so the SCR’s switching speed was 5 ± 0.025 *

10-7 s. The solenoid was tested using a stopwatch, and the time between flipping the

switch and retraction of the plunger was less than half a second, 0.4 ± 0.05 s, and again,

Page 37: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

there was human error involved with the measurement because a human had to stop the

watch when the plunger retracted.

Both the phototransistor and solenoid switching speed tests were quasi-

qualitative. There is a reason why a more accurate measurement was not necessary.

Only a general order of magnitude measurement should be enough to differentiate

whether the trap is sufficient or not. The total time for the entire circuit to switch is

1.2000015 ± 0.07 s, assuming each component has to switch before the other switches.

This is enough time to trap the mouse. As stated in the background, a mouse can run as

fast as 11 ft./s during short sprints while the average most likely is around 5-7 ft./s. The

beam is located 4 inches within the box. Doing simple math, one notices that the mouse

can easily run out of the box from the time that the light beam is broken to the point

which the door shuts, because it only takes 0.03 s. for the mouse to travel out of the box.

However, since the beam is infrared and hence invisible to the mouse, the only indication

of a trap to the mouse’s point of view is the elimination of light after the door slams

down. But after the mouse realizes that, it will be too late. Since it takes only 0.11 s. for

the door to slam (using Newton’s theory of falling bodies), it is highly unlikely the

mouse will recognize the situation and react, specially since the lure of peanut butter is at

stake.

Page 38: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

Calibrations

Distance between phototransistor and LED (inches)

Resistance of phototransistor (M)

<1 ± 0.04 0.17 ± 0.1051 ± 0.04 0.35 ± 0.1052 ± 0.04 0.50 ± 0.1053 ± 0.04 0.65 ± 0.1054 ± 0.04 0.80 ± 0.1055 ± 0.04 0.95 ± 0.1056 ± 0.04 1.00 ± 0.1057 ± 0.04 1.20 ± 0.1058 ± 0.04 1.30 ± 0.1059 ± 0.04 1.50 ± 0.10510 ± 0.04 1.60 ± 0.105

This table measures the resistance value of the phototransistor as the distance between the

phototransistor and the LED increases. As stated in the background, the transistor

properties change as the amount of light varies, and the amount of light on the

phototransistor changes as the distance increases. Graphing the relationship, we have the

following:

Resistance vs Distance y = 0.1405x + 0.0682R2 = 0.9958

0

0.2

0.40.6

0.8

1

1.21.4

1.6

1.8

0 2 4 6 8 10 12

Distance(inches)

Res

ista

nce

(Moh

ms)

This is a graph of the data just summarized, with appropriate errors. The actual error values for the y-axis was ± 0.105 M (see summary of error), while the error bars on the x-axis was ± 0.04 inches.

Page 39: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

From this graph and considerations from the dimensions of the box, the ideal distance

between the phototransistor and the LED was initially 8 inches (as mentioned in the

testing procedure). But after reconstruction of a newer box, that distance shrunk to 3

inches. The graph above helped in the determination of the R1 value for the sensitivity

of the circuit

RedesigningAt this stage in the design, the circuit was not working satisfactorily. When the

infrared beam was undisturbed, there was no activity in the circuit. However, when the

beam was broken, and the SCR would switch and the solenoid would retract, causing the

door of the mouse-trap to close. After placing the circuit in the box, it was clear that

project was complete and operational. It seemed that the aims of the device were

actualized, and the project was finished. But, something went wrong.

After the voltage in the battery had sunk to 7.9 V, the system did not work

anymore. The voltage of the battery was lower than the minimum required voltage to

run the circuit. The batteries went from 8.7 to 7.9 V in less than 4 hours, and assuming

constant drainage, the circuit draws 0.2 V per hour. This was unacceptable, because the

user of the mousetrap needs to have the circuit running 24 hours in order to catch mice.

No experienced consumer would purchase a mousetrap that was only good for 4 hours.

Thus, a better design of the circuitry was needed.

The first attempt in redesigning the circuit was re-biasing the input voltage to 6 V

using a 6 V - voltage regulator, as mentioned in the construction procedure. However,

the results of this attempt proved futile. After re-biasing, the circuit lost sensitivity (as

mentioned in the circuit overview, R1 controls the sensitivity of the phototransistor to the

beam), enough sensitivity such that the distance between the LED and Phototransistor

could not exceed 2 inches. This tradeoff was not acceptable. If a compromise in the

distance was down to 2 inches, the chances for catching a mice would be greatly reduced.

Thus, re-biasing the circuit to 6 V could jeopardize the overall objective of the design.

Furthermore, the 6 V voltage regulator required a 10.5 V power supply to work, and the

current power supply was a 9 V battery. Finally, with the biasing done to the circuit, the

base of the transistor was receiving too much power (bordering close to the maximum

Page 40: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

allowable). It started to heat up, and knowing that a NPN-P2N2222A transistor goes into

saturation if heated to more than 8 degrees, this becomes a new factor in the circuit. The

saturation would cause false triggering of the SCR and hence the solenoid. This new re-

biasing did not work. A new solution had to be found.

A Future Design

Running out of time, a new circuit was designed, but not actually built. The

following would have been attempted had more time been allocated to designing the

product. Knowing that the SCR triggers when the power supply is 7.9 - 9.0 V, a constant

power supply of 8 V would fit nicely into the design. Hence, an 8 V power regulator

would be instituted in the beginning of the circuit to moderate the power supply at

exactly 8 V. Since a 8 V power regulator requires 14 V (according to the spec sheets) to

supply it, two batteries instead of one would be used. This would give the user a longer

duration for which the mousetrap could be used for. Also, a battery tester would be

added, such that a manual switch pressed would light an LED if the battery supply was

above the needed power. This gives the user the flexibility of knowing how if the battery

is good or not.

Limitations

The designed circuit has numerous limitations. As was discovered in the design

process, the system can be biased to function only over a small range of voltages. For

example, the system, when biased at 9V, stopped functioning when the battery was less

than 7.8V. The intent of a voltage regulator was to minimize this limitation. However,

at least 10.5 volts were required for the voltage regulator to operate. This would require

two 9V batteries, adding another limitation.

The system also seemed to drain the battery rather quickly. After four hours with

the circuit switched on, the voltage went from 8.7V to 7.9V. During this time,

alterations were made to the circuit, and perhaps some of these changes contributed to the

loss in voltage. However, disregarding these changes, the voltage drop was still very

high. With this design, therefore, the system may be limited to only operating for about

Page 41: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

4 hours. Ideally, the circuit should be resigned to prevent the battery from being drained

so rapidly.

Another limiting factor is the size of the door. The weight of an approximately 8

in x 6 in piece of cardboard was too great on the plunger such that even when powered,

the plunger did not retract. Therefore, the system is limited by the weight of the trap

door. If the box were to be made larger, a lighter material would be needed for the door.

The width of the box is an additional limiting factor. R1 was adjusted so that the

system operated when the infra-red LED and phototransistor were about 3 inches apart.

Adjusting the resistor so that this distance could increase caused a drop in sensitivity for

the switch. Furthermore, at large distances and high resistances it was observed that the

system was inconsistent ( not triggering when expected) and often slow. As a result, the

circuit, even with some minor adjustments, could not operate well in larger system (e.g.

to trap a larger animal)

ErrorAll the error cited in this paper are from the following sources: All resistors and

capacitors in this lab were assumed to have 5% error associated with it. However, the

voltmeter was used in reading all resistance and capacitance values. For resistor values

in between 0-20 , the error was ± 1% + 5 digit, ± 0.5% + 3 digit for 20-200 , and ±

0.5% +1 digit for 2 K to 2M. For capacitance readings, the error is ± 3.0% + 5digit.

When reading voltage values in the range of 200mv to 20 V, an error of ± 0.3% + 1digit,

and current error values were 0.5% for 200 mA to 20mA. Distance measurements were

done using a 12” ruler, such that each increment was 1/12 of an inch.

Page 42: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

Device Specifications

On/ Off Characteristics

Device On Voltage On AmperageInfrared LED 1.2 ± 0.06 V 0.02 ± 0.001 mASCR 0.71 ± 0.036 V 0.2 ± 0.011 mA Solenoid 4.5 ± 0.05 V 120 ± 7 mA

Phototransistor

Properties Values UnitsOff Resistance > 20 ± 0.005 MOn Resistance 1.15 ± 0.005 MMax. distance from the LED 8 ± 0.04 inches

Solenoid

Properties Values UnitsCoil Resistance 37.4 Number of Coils 1976 CoilsMinimum On Voltage 4.5 ± 0.05 VMinimum On Current 120 ± 7 mAMinimum On Magnetic Field 2.37 ± 0.138 T * meters.

Switching Speed

Electronic Unit Switching Time Phototransistor 0.8 ± 0.05 sec.Transistor 0.67 ± 0.03 msec.SCR 0.5 ± 0.025 msec.Solenoid 0.4 ± 0.05 sec.Max Switching Time for Total Circuit 1.2000015 ± 0.07 sec.

As the final circuit was not fully operational, device specifications for the final

product could not be provided.

Page 43: Testing Procedure: - University of Pennsylvania School …belab/LabProjects/1997/BE310S97M3R01.doc · Web view1 1 mF Capacitor 1 Infra-red Diode— Jameco Part # 112150 Product #

Works Cited

Bielfeld, Horst. Mice : Everything about care, nutrition, diseases, behavior,and breeding. Barrons: Woodbury, N.Y.. 1985.

Horrowitz, P., Hill, W. The Art of Electronics. Cambridge University Press: Cambridge, MA. 1989.

Tipler, Paul. Physics for Scientists and Engineers Vol. II. Worth Publishers: New York. 1991.