• Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

PIC to Transistor

Status
Not open for further replies.

itzme

New Member
Hi all,
I need your advice on something. May I know why do we need a 1kOhm resistor between a transistor and the output pin from a PIC? can it be any value?
 

3v0

Coop Build Coordinator
Forum Supporter
Hi all,
I need your advice on something. May I know why do we need a 1kOhm resistor between a transistor and the output pin from a PIC? can it be any value?
It is a current limiting resistor. Without it the transistor base would use too much current. This is similar to the current limiting resistor used with an LED.

If it is too small the transistor will draw more base current then needed. If it is too large the transistor will not turn on fully or just partway.

The actual value depends on the application.

Did I just answer a homework question ?
 
Last edited:

Sceadwian

Banned
It's just there to limit the current going into the base of the transistor. It has to be of a value that will allow enough current to go into the base to saturate the transistor. You could chose the resistor for some other bias point but I'm not sure why you'd want to do that. Generally you want to use as high of a value resistor as you can that still provides saturation. Using no resistor will either damage the I/O line of the pick or simply waste current and produce heat in the chip.
 

audioguru

Well-Known Member
Most Helpful Member
The max allowed output current from a PIC is 25mA.
The PIC is made with High Speed Cmos (74HCxxx) so it will try to drive 60mA and blow up with out current-limiting.

There is a Mood Light project where the author did not use current-limiting resistors from the PIC to LEDs. The PIC got so hot that it failed or stopped.
 

Sceadwian

Banned
If you're driving multiple I/O lines you're not gonna get 25ma out of every I/O line so you need to keep in mind total power output not just for each pin. I don't know about PIC's but AVR's are typically limited to 100ma per I/O port, and I think the chips total power disipating is around the same, the per I/O line is about the same as a pic.
 

tresca

Member
The max allowed output current from a PIC is 25mA.
The PIC is made with High Speed Cmos (74HCxxx) so it will try to drive 60mA and blow up with out current-limiting.

There is a Mood Light project where the author did not use current-limiting resistors from the PIC to LEDs. The PIC got so hot that it failed or stopped.
I did a charlieplexing project with 20 leds. They switched fast, nanoseconds. So the current is on for only a fraction of the time. Think that will cause problems ? I left it on for a few hours, and everything appeared to be ok. Though the intended purpose is for those charlieplexed leds is to be on no more then 5mins, after that, they turn off.
 

audioguru

Well-Known Member
Most Helpful Member
The datasheets for 74HCxxx and PICs say the max allowed output from each output is 25mA without listing a higher allowed current when the output is pulsed.
there is another limitation of only a certain number of outputs can be at 25mA so that the entire IC does not get too hot.
 
Status
Not open for further replies.

EE World Online Articles

Loading
Top