Go Down

Topic: Arduino pin to drain a circuit? (Read 1 time) previous topic - next topic

Eight

Aug 19, 2010, 08:47 pm Last Edit: Aug 19, 2010, 08:47 pm by Eight Reason: 1
Apologies for the number of probably very basic questions I've asked over the past few days. But I could use a little more help.

There's an existing circuit I'm trying to hack in to, but before attempting it, I wanted to get the basic idea of something down first.

Let's say I have a circuit, in this example it's a simple LED. It's powered from a 5v source that also powers my Arduino through a USB connector.

What I want to do, is have the Arduino ground that circuit and cut off the power to the LED. I'm only using the LED circuit as an example since if it works with those current hungry buggers then it should work with anything right?



Initially, I tried using a digital output pin driven LOW and connected (first through a resistor, later not) to the LED's anode. That didn't work - it did in Virtual Breadboard but not in real life. Damn.

Then I tried a basic transistor circuit and must have gotten something wrong because when the Arduino pin (HIGH) switched on the transistor, the LED circuit stayed quite happy but the transistor got very hot and then burnt my finger (leaving a nice blister) when I removed it from the breadboard.

Is a relay my only real option here?

Hoping someone can point me in a better direction. Please - before I damage another bass-playing finger?  ::)

TchnclFl

I'm really very confused at what you're trying to do.

Are you simply trying to control whether an LED is on/off from a digital output? :\

Eight

#2
Aug 19, 2010, 09:00 pm Last Edit: Aug 19, 2010, 09:01 pm by Eight Reason: 1
Yes and no.

I know the way I've presented the problem looks a bit daft.

But the actual circuit is a bit more complicated and has a press button switch that grounds the circuit to turn it off (including pulling an IC reset pin low). I need to add an Arduino controlled thing in there to which can ground the circuit in the same way as the switch.

retrolefty

#3
Aug 19, 2010, 09:13 pm Last Edit: Aug 19, 2010, 09:13 pm by retrolefty Reason: 1
Quote
What I want to do, is have the Arduino ground that circuit and cut off the power to the LED. I'm only using the LED circuit as an example since if it works with those current hungry buggers then it should work with anything right?


Well there is probably a valid question in there somewhere  ;), but the example is very poor in my opinion. An Arduino output pin can both actively sink (ground out) and source (provide +5vdc). The problem is there is a maximum current flow allowed from a output pin no matter if it's high or low of 40ma maximum (30ma recommended). So your example of having a output pin 'ground out' the board's +5 volt is generating a 'short circuit' condition and will surely damage the output pin.

So if you can actually supply a circuit drawing of what you are trying to do, there would be a better chance of getting proper advice if it is possible or not.

Lefty

Eight

Quote
Well there is probably a valid question in there somewhere  ;), but the example is very poor in my opinion.

Hahaha, yes fair point. :)

I'll try to come up with a more accurate reflection of the problem in hand.

Go Up