Wednesday, August 24, 2011

TTeC 4847 #3


MOSFET. (Metal Oxide Semiconductor Field Effect Transistor) vs BJT (Bi-polar junction transistor)


-The MOSFET is used just like any other transistor where it can be used as a switch in a circuit or used to amplify voltage. just like the Bipolar Junction Transistor (BJT)  it has three main terminals. Where the terminals in the BJT are called Base, Collector and Emitter. The names change in the MOSFET, the terminals are the Gate, Drain and the Source. Also the difference between the BJT and the MOSFET is the BJT requires high current to the Base of the transistor to allow voltage to flow from the collector to the emitter where in the MOSFET it requires voltage at the Gate to allow voltage to flow from the Drain to the Source.
There are two types of different channel MOSFET's, An N-Channel Mosfet, P-Channel Mosfet. 
The N-Channel Mosfet acts like a NPN bipolar junction transistor  where the base of the BJT needs a positive feed to turn on the N-channel Mosfet requires positive voltage at the Gate to turn on. The greater the Gate voltage the increases the size of the channel created.
The P-Channel MOSFET acts like a PNP BJT where the PNP requires a negative feed to the base, so it requires zero voltage to allow voltage to flow the collector to the emitter the MOSFET requires zero voltage at the Gate to allow voltage to flow from the drain to the source but requires positive voltage to switch it off.
These MOSFET's can either be of a Depletion type where it requires voltage at the Gate to turn on or Enhancement type where the voltage at the Gate is used to turn the MOSFET on.



Schematic diagrams of MOSFET's and BJT's
G=GATE
D=DRAIN
S=SOURCE
   P-Channel           N-Channel
 Depletion Type MOSFET's


   P-Channel         N-Channel
Enhancement Type MOSFET's





Operational Amplifiers
Op-Amp

It has two input terminals and an output terminal and a negative and positive  voltage rail. The positive input is known as the inverting terminal and the negative known as the non-inverting terminal and basically the op-amp amplifies the difference between the to inputs.
It can also be used as a comparator in a circuit and the output will be dependant on the difference of the two inoputs and the voltage at the rails.
Below is a diagram of an intergrated circuit chip with four op-amps. I will be using a similar chip to create an oxygen sensor circuit.

Wiring diagram for an oxygen sensor .
The above digram shows four op-amps three LED's three diode's one zener diode and seven resistors all wired together to create an oxygen sensor circuit. But before wiring the circuit together i have to find the values of different resistors to use in the circuit to produce different outputs at each op-amp. Firstly i find the resistor value which is after the power supply and diode so we will call that R5. Also taking not it has a 9.1volt zener diode off that same circuit i created a formula using the ohm's law. resistance = voltage/amperage. Also knowing the amperage required to operate the zener diode at 5.6mA therefore
r5= 12v (power supply)-9.1v(Zener diode)-0.6(rectifying diode)/5.6mA
   = 2.3v/0.0056A (5.6mA)
   = 410.7 ohms
Then going on to find the resistor values for r7 and r8 i have to find the amperage that will flow through as it is a parallel circuit and amperage may vary. As r6 is already given as 10k (10,000 ohms) and the available voltage after the zener diode is 9.1volts and the available voltages given after each resistor
A=voltage/resistance
   = 9.1v-0.63v-0.23/10,000ohms
   =8.24v/10,000ohms
   = 0.000824A (0.824mA)
Now having the amperage we can find r8 which is resistance = voltage/ amperage and since we have two available voltage points
r8 = 0.63v-0.23v/0.824mA
    = 0.4/0.000824
    = 485.4 ohms
r7 = 0.23v/0.824mA
    = 0.23v/0.000824A
    = 279.1 ohms
Now finding the resistor values r2,r3,r4 which lead to the output pins of each op-amp and after the LED. Taking note that the diode creates a voltage drop of 0.6v and the LED's use 1.8volts and require a minimum of 9.5mA to operate according to the datasheet, again using the ohm's law resistance = voltage/ amperage and instead of working with the minimum amperage i decided to go with 10mA, therefore
r2 = 12v-0.6v-1.8v/10mA
    = 9.6v/0.01A
    = 960 ohms
r3 = 12v-(0.6x2)-1.8v/10mA
    = 9v/0.01A
    = 900ohms
r4 = 12v-0.6v- 1.8v/10mA
    = 9.6v/0/01A
    = 960ohms


Tuesday, August 16, 2011

Autotronics TTEC4847



The above diagram is a wiring diagram of the injector circuit and show the different components required to complete this injector circuit and shows calculations to how the different resistors are selected. 

Components: 
                    - 2 x Light Emitting Diodes
                    - 2 x Transistors BC547 NPN
                    - 2 x 220 ohm resistors
                    - 2 x 510 ohm resistors
                    - 12 volt power supply
                    - Function generator

The wiring diagram only gave the value figures of power supply and the amount of voltage delivered by the function generator so i needed to create an equation to find the value resistors i was going to use for each bit of the circuit.
To find the resistor value which leads from the 12 volt power supply to the LED through the collector terminal of the transistor to the emitter terminal of  the transistor i created the following equation using a data sheet i obtained from the Internet in regards to the BC547 NPN transistor and LED's. From the LED data sheet i found it takes 1.8volts with an amperage of 20mA to turn the LED on.

RC = V/A                                                            
      =12 - 1.8(LED)/20mA
      =10.2/0.02A
RC = 510 ohms

To calculate the resistor that leads from the function generator tho the base of the transistor to the emitter, also using the data sheet i had to find what amperage to work with and knowing from the data sheet that the base of the transistor has a peak current of 200mA, I decided to work with half of that as i did not want to damage the transistor. Also the emitter of the transistor is a diode and i know a standard diode uses 0.6volts. I then used the following equation.

RB = V/A
      = 5 - 0.6(diode)/100mA
      = 4.4/0.01A
RB = 210 ohms

After obtaining both resistors to operate one LED I used the same equations to find the values for the resistors in the other side of the circuit.

Breadboard with 2xLED's 2x470 ohm resistors 2x220ohm resistors and 2x BC547 NPN transistors.

The above diagram is a test circuit simulating the injector circuit  on a breadboard. This is to check if the calculations for my injector circuit could operate without complications. In this circuit i use 470 ohm resistors instead of the 510 ohm i calculated as there were no 510 ohm resistors available at the time. As you can see both diodes are emitting light which indicates their current flowing through the circuit and that i have a good earth to complete the circuit.
If light did not emit then there could be a possible break in the circuit or the resistors at the base of the transistors could have too much resistance which wouldn't allow current to flow from the collector to  the emitter which would then not allow current to flow from the collector to the emitter to turn the LED on.





simulation of veraboard injector circuit using  the Lochmaster program

After completing the wiring on the breadboard i then used the Lochmaster program to show how i would wire up the injector on a Vera board which would be my final product. The darker lines of the veraboard are the tracks of the board and that allows voltage to flow through, so basically it is helping eliminate the use of extra wires.
After i completed the circuit on the Lochmaster program i had to do a continuity test to show where the voltage was going and at first i found that i was getting the full 12volt power supply at each end of the resistors and also the LED so i had to put breaks in the tracks of the veraboard in between each terminal of the LED and the terminals of the resistor so only the beginning of the resistor would get the full 12volts. If i had not put breaks in the circuit the injector circuit will not work.

 Picture of injector circuit on a veraboard

 I created an injector circuit on a veraboard using the design from the Lochmaster program and when attached to the function generator and 12volt power supply the LED's both turned on and was blinking accordingly to the function generator which was set at 10hz.
 Using a multimeter i checked voltage drops across the components to compare with my original calculations and also checked for current readings at different terminals of the transistor to determine what kinda region the transistor is in.

Vd across LED = 1.773v
Vd across RB   = 2.538v
Vd across RC   = 5.067v.
Vbe                  = 3.303v
Vce                  = 5.079v
Ic                     = 24.28mA
Ib                     = 12.40mA
Beta                 =  Ic/Ib = 1.95

The above readings are not exact as the function generator pulsates 5volts to the base of the transistor which was set a 10hz. The above current reading of the base and the collector terminals of the transistor show the transistor is in a active region which means it is not fully working as the function generator sends  5volt pulses, which means the transistor acts like a switch to turn on the LED and causing the LED to blink on and off.
 There is a voltage drop across the LED of 1.733volts and voltage drop across the collector and the emitter of 5.079volts which means the resistor at the collector will use the excess voltage which is 5.067volts. If those values are added together it adds up roughly to the power supply.


 Picture of the tracks and soldering on the veraboard

When soldering the components to the veraboard I had to make sure the soldering material did not join the tracks together as then it would act as a conductor and allow voltage to flow to a different part of the circuit causing it to not work.

Function Generator on the left and Power Supply to power my injector circuit on the right

The above diagram shows the power supply i used to supply voltage to my injector circuit. The yellow lead is the positive feed to the circuit and the green represents the negative feed.The function generator on the left will send 5volt pulses to the base of the transistor in my injector circuit. In this case, I'm using the function generator to simulate the RPM's in a motor vehicle.