NEW: Learning electronics? Ask your questions on the new Electronics Questions & Answers site hosted by CircuitLab.
Basic Electronics » Easy Transistor Question
August 18, 2011 by jimmyw404 ![]() |
I'm creating a fan control circuit with my nerdkits using PWM modulation from a temperature sensor. I'm using http://www.nerdkits.com/videos/motors_and_microcontrollers_101/ as a platform to start. I'm using a power supply set to 12v to power the fan and the 9v battery to power the system. I'm using a 1.5v battery with a potentiometer-based voltage divider to replace the temperature sensor I broke =( The transistor that comes with the nerdkits isn't rated for the amount of amps I'm pulling (Around 2-3 amps at 12volts). I went to radio shack and purchased a BJT transistor (TIP120 http://www.fairchildsemi.com/ds/TI/TIP120.pdf ) to replace the 2N7000 MOSFET that came with nerdkits. The system appears to work okay with one discrepancy. With the 2N7000 I can get a range of 3v to 12v when I get the PWM value on the LED to approach 0 and reach 512 respectively. When changing in the TIP120 I can only get a range of 8v to 12v, even though the display outputs the same PWM values. What is the reason for the discrepancy? Is there something I'm doing wrong? Can I not replace a mosfet with a BJT like this? Should I just get a more powerful mosfet like http://www.fairchildsemi.com/ds/FQ/FQP50N06.pdf ? Is there not enough information here to show what I'm doing wrong? Thanks. |
---|---|
August 19, 2011 by mrobbins (NerdKits Staff) ![]() |
Hi Jimmy, I'm assuming that you've got the the TIP120 connected as follows: emitter to ground, collector to one side of the fan, and base directly to a microcontroller pin -- essentially swapping terminals G,D,S of the MOSFET with B,C,E of the BJT, respectively. There are two issues I see:
Switching to a beefier MOSFET would also work. :) In a pinch, you can also try putting multiple 2N7000s in parallel to handle more current for the same V_GS. Let me know if those two changes make a difference! Mike |
August 19, 2011 by bretm ![]() |
And don't try that with BJTs. MOSFET current flow goes down as they heat up, so MOSFETs in parallel automatically self-balance. BJT current flow increases as they heat up, so if one overheats it will take more and more of the load away from the others which is the opposite of what you want. |
August 20, 2011 by jimmyw404 ![]() |
Thanks, Mike and Bretm for your help. 1_ I think the resistor was the big thing I was missing, I should have picked up on the fact that at a high duty cycle the LED display started to dim. I tried limiting the current with a 680ohm resistor but that didn't have an effect (Though my display no longer dimmed!) I did the same with a ~1500 and a 3300ohm resistor to no avail. Finally I jumped up to 33k and it created a range from 4v to 12v, which was very exciting! I am sure your math is fine, but I don't know if I am missing any other component that prevented the 680ohm resistor from performing as it should. I am not worried about it very much. 2_ I have to admit I do not know how to increase the prescalar division ratio in the pwm_init function. As you know the code in that function is
I looked at the ATmega168.pdf document in the members section and found the descriptions of the registers, but could not accurately determine how to decrease the PWM frequency. So instead I just guessed it had to do with OCR1A. When I set OCR1A to 256 (using the 33k ohm resistor) the minimum was 4v, but it sharply increased to 12v as the PWM increased. When I set it to 1024 it was 4v at a low duty cycle and sharply increased to 12v again, but the PWM actually jumped very high as well. I did not investigate this because the choice to change OCR1A was based on guessing. 3_ I purchased some new mosfets: http://parts.digikey.com/1/parts/1018520-mosfet-n-ch-60v-52-4a-220-fqp50n06l.html http://parts.digikey.com/1/parts/1017627-mosfet-n-ch-60v-14a-220-fdp5800.html http://parts.digikey.com/1/parts/1569320-mosfet-n-ch-60v-80a-d2pak-fdb5800.html I will try these out when I get them. Thanks again for your help! |
Please log in to post a reply.
Did you know that multiple microcontrollers can communicate with each other? Learn more...
|