Ton of resistance from my transistor
willthiswork89
Posts: 359
i have an external battery and when i try to let the 9 volts through the transistor it only lets out 3? its just the normal 2n2222 transistor so i dunno? can it not handle 9 volts?
Comments
You did not mention whether or not you have tied the emitter and the Stamp's Vss (Ground, GND) together. And trying to connect "through" a voltmeter (what it sounds like you are doing) is not the right way to measure voltage. Using just what you have listed, add one resistor (1K should be "safe" enough) between your collector and the "positive" side of your external power source. Next, tie your emitter to the "negative" (Ground) side of your external power source. Then connect the emitter to the Vss (Ground) side of the Stamp's circuit. Now, attach your voltmeter's probes on each side of the resistor connected to the collector. Lastly, attach the base of the transistor through an appropriate resistor (1K is fine) to your Stamp's pin.
Now, making the following assumptions:
1. You have correcxtly interpreted the transistor's data sheet and your circuit is set up according to the above description
2. Your external supply is providing 9V
3. Your Stamp is functioning correctly (i.e. not damaged due to previous miswirings)
4. I have not knocked this off too quickly for my morning tea to kick in (and I accept no responsibility for that possibility and the possible smoke escape pertaining thereunto...<g>)
A HIGH on the attached Stamp pin should result in a reading of ~8.3 V on your voltmeter and a LOW should result in a reading of 0 V.
Now, the above having been said (written, whatever...)...
All of this should have been relatively straightforward and simple if you had, indeed, read through and performed the experiments in the "What's a Microcontroller?" as you earlier claimed to have done. Do not continue with your own misguided (because of a lack of basic theory understanding) experimentation until you can answer the following questions about this circuit:
1. What is the value of the base current?
2. Why was your voltmeter not reading what you thought it should when you had things hooked up "your way"? (Exclude the effect of not having a "common ground".)
3. Why does your voltmeter only read 8.3V instead of the 9V you expected?
4. Why would you put a resistor between the collector and your external supply instead of just hooking it up directly?
The following is not a condescending statement:
Try not to skip steps in the excitement of this journey of discovery...I know that it can be very tempting, if for no other reason than "actually doing something" or "making your vision come to life" is (and should be) such an exciting prospect...but it's that whole "walk before you crawl" thing...we've all been there...
<teaching_mode=OFF>
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Truly Understand the Fundamentals and the Path will be so much easier...
Post Edited (Tom Walker) : 8/9/2006 2:13:26 PM GMT
·· You keep referring to a lack of information in the "What's A Microcontroller?" kit, but I am failing to see how what you're trying to do is related to a specific experiment in the book.· By all means if you feel we are lacking on material covered let us know and we will attempt to address it if necessary.· Thank you.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Tech Support
csavage@parallax.com
http://www.parallax.com/dl/docs/cols/nv/vol1/col/nv23.pdf
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
- Stephen
Thats exactly my point people keep referring me to the book WAM because i dont know how to get a transistor to be used with an external power source, there is no where in that book thats related to that. What this company lacks is sufficiently cought up by this wonderful forum which im grateful for, ive never had one account that i can remember on this forum where i was treated rudely regardless of my lack of knowledge and my failed attempts to understand the material presented to me. Regardless i was pointing out people say "Read the WAM" you lack basic electronic fundamentals.... but i dont understand where the fundamentals gained in WAM will come to part my answer for why the transistor is putting out 3 volts from an external power source.
This company makes alot of dreams acheivable by the great prices and thats why im still here! Its a hard life for a working 16 year old going to school and a job [noparse]:)[/noparse]
Anyway, just to help you out, I think the Nuts and Volts column that comes closest to explaining what you are trying to do is this one:
www.parallax.com/dl/docs/cols/nv/vol1/col/nv6.pdf
I've found the Nuts and Volts columns to be a huge help when trying to figure out how to do something with one of the Parallax Stamps. But after reading through all 100+, it can be hard to remember where you saw what.
- Rick
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Tech Support
csavage@parallax.com
http://ww1.microchip.com/downloads/en/devicedoc/41233A.pdf
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
- Stephen
It is admirable to see a young fellow trying to accomplish something worthwhile. Without sounding critical, you were given numerous links to study that were packed with fundamentals on npn and pnp transistors. I am no EE, but I can turn on transistors and can offer some simple advice. I would suggest you re-read the earlier posts, and even the ones that I directly included simple schematics for transistors that you could not mess up! A transistor is (A). Cheap, and (B). only has a minimum of combinationms of hookup, so even if you had NO pin out, you'd still get one to work right in a few trys. In your case, only think of the transistor as a switch. Your pin from the Stamp is the singal to turn the switch on. Here is a hint: On the 2n2222, you put the Stamp pin to it via a 1k resistor to the CENTER PIN(base) on the 2n2222. That leaves ONLY 2 possibilities remaining for how to connect the GROUND and the relay. See the link below, the LOAD shown is the relay.
Rather than stay on the the path of searching for some elusive info that you think you have yet to come across, please go back and trace your steps, as the info is already there to run your motors. Save up $5 and get a breadboard, stop soldering until the breadboard works. Tie all GROUND together from multiple supplies.
There are 27,400 hits on google for 2n2222 relay driver . In most examples they are used as a SWITCH to take one side of the motor to GROUND, NOT to supply the +V, although that can be achieved as well. In a swiitching scenerio, you are either going to switch the +V OR GROUND to the motor. In an Hbridge, there are switchs for both +v and GND sides as the polarity needs to be reversed as desired, and thats why the NPN and PNP transistors are used, the PNP is usually shown switching the +v side, and the NPNs are usually shown switching the GROUND side. Someone please correct me if I am wrong, but I think this explaination will help you grasp why you use both types(npn/pnp) on an Hbridge. For now though, breadboard the schematic attached and tell us the results. I for one would be glad to hear that you got that much to work. ANOTHER HINT: WHEN YOU PUT A HIGH FROM THE STAMP TO THE CIRCUIT SHOWN
the transistor will read GND. Why? What happens if you bought a regular light switch that is found on a typical wall, and you put one side of the switch to GND, and you meter the other side.... as you switch flip the switch, you read ground in one position, and nothing in the other--same as the transistor, EXCEPT that when you put +V on one side of the relay, then when the Stamp is low, the +V goes THROUGH the coil, and to the one side of the transistor, making you read a HIGH when the Stamp is at LOW. But when the transistor is turned on, the transistor reads LOW. The opposite is true if switching a PNP transitor on the +V side of the coil. Stamp is High = Transistor output is HIGH.
Many are willing to help, but you must first at least show some progress and grasp of what has already been shown. At this point, you don't need WAM or anything else, you have been given the answer here to study and apply.
Keep at it
Todd
If the Radio Shack ones are NPN use them, it doesn't matter.
Ok great so hopefully that makes some sense to you.
"the only way ive seen was using one either positive or negative not both"
Will, that statement makes no sense in its present form, but lets move forward. If you will do the work, we'll get the car moving.
Please print out the schematic from what you just did and keep it handy.
OK next, will you get out a PNP transistor, and breadboard the schematic below.
It should turn ON the relay when the Stamp is LOW. So, you could make your variable say:
RelayOn = 0 'makes relay turn on
RelayOff = 1 'makes relay turn off`
Again, use pin 2 for the Stamp pin via 1k, leaving you only 2 possibilities for the transistor if you don't have a pinout.
Report the results please, taking note of how the relay works based on the current flowing into the base. You can meter the collector without the relay if you want as well. Getting an understanding is the key.
Ignore that comment it wasnt clicking what the load was haha i just hurried at as glance and thought okay? a resistor from the positive to the emitter? i corrected my self before attempting it and continued on. post results back shorly! oh... and i wouldnt neccicarily called it soldered to a PCB because its holes drilled into an electrical tape case haha! there is reasoning for this though, the resistors are micro minis and the positioning of the pins is not what you would consider normal
: :
.
it was like that... so you can see that trying to breadboard that the coils would end up going to the same row and the pins were way to short to bend to different holes.
Be careful with using that circuit. It will ONLY work if +Vs is less than or equal to the same voltage powering the stamp( in other words ... 5V)
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Beau Schwabe
IC Layout Engineer
Parallax, Inc.
Page 265 of the "What's a Microcontroller?" text gives a brief introduction to the use of a transistor and points the reader to the "Industrial Control" text (also a free download) which, on page 86, explains what you are trying to do, albeit with a motor instead of a relay.
As Chris implied, the text is broadly based to allow the reader to get general concepts...not to provide ready-made solutions for them. Sometimes you gotta dig a little. Learning it is the fun part...
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Truly Understand the Fundamentals and the Path will be so much easier...