2
\$\begingroup\$

I wanted to use 12v led, so I tried to switching 5v(gpio pin) to 12v.

This is my 12v switching circuit. enter image description here

And this circuit broke down my raspberry pi. When I wired this circuit, they worked well. But I switched on and off several times, the transistor and raspberry pi broke down.

Why my raspberry pi and transistor died??

\$\endgroup\$
  • \$\begingroup\$ What pins on the RPi were you using? \$\endgroup\$ – Oskar Skog Nov 2 '17 at 4:48
  • \$\begingroup\$ PS. The RPI uses 3.3V not 5V. It doesn't explain why it died in this case though. \$\endgroup\$ – Oskar Skog Nov 2 '17 at 4:49
  • \$\begingroup\$ You need 330 ohm resistors (or more), the max limit of output current is 16mA, safe limit is 8mA. That would only explain dead GPIO pins however. \$\endgroup\$ – user2497 Nov 2 '17 at 6:03
  • \$\begingroup\$ @OskarSkog I used 22 pin. \$\endgroup\$ – juae Nov 2 '17 at 6:15
  • \$\begingroup\$ @user2497 Max limit that you said is gpio pin's or transistor's? If gpio pin, I used gpio pin only output.. So I cannot understand why gpio pin died. \$\endgroup\$ – juae Nov 2 '17 at 6:37
1
\$\begingroup\$

When those transistors are turned on, there's what amounts to a short circuit through the associated LED to ground. You need an appropriately sized resistor in series with those LEDs.

I suspect what happened (the failure mode you experienced) is that the transistors got damaged by overcurrent, and the failed transistor inadvertently fed 12V back into your GPIO pin and that baked your Pi.

\$\endgroup\$
  • \$\begingroup\$ Why transistor causes overcurrent? Current flows led to emitter? And how to know appropriately sized resistor? Thanks! \$\endgroup\$ – juae Nov 2 '17 at 1:33
  • \$\begingroup\$ ohm's law ... google it \$\endgroup\$ – jsotola Nov 2 '17 at 3:29
  • 1
    \$\begingroup\$ what kind of an LED runs on 12V ? \$\endgroup\$ – jsotola Nov 2 '17 at 3:30
  • \$\begingroup\$ @jsotola A lot of LEDs run on 12V lol :) car LEDs is a good example. And it's not as simple as Ohm's Law. One should research about the modes of operation for a BJT transistor. \$\endgroup\$ – KingDuken Nov 2 '17 at 4:57
  • \$\begingroup\$ @jsotola I used led in push button switch; looks like this[ kr.misumi-ec.com/linked/material/el/HNX1/PHOTO/… ] \$\endgroup\$ – juae Nov 2 '17 at 6:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.