Continue to Site

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.

  • 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.

Driving LED lighting via a PC soundcard

Status
Not open for further replies.

roborg

New Member
Hi all,
I'm comptemplating driving some LED lighting, say around 100+LEDs per channel, via a PC soundcard. The idea is to simply use the line-out left & right channels to act as a two channel controller. So what i need is a really simple power switching circuit. I have trillions of old PC PSU's kicking around & they are all loaded with pretty generic NPN power transistors suitable for switching. Has anyone done anything like this/suggest a really simple circuit to switch an external 12v supply via the line-out of a PC soundcard using power transistors? I'd prefer to use mosfets, but this is hardcore budget stuff!
The main drive for this is to build a dirt cheap multichannel controller (add extra sound cards for every two extra channels needed) that can drive the LEDs with a pulse width modulated output, so that i can dim them easily/mix colours (have banks of red green & blue LED's) etc... (also driving LEDs pulsed allows for higher optical outputs to be achieved, so i would experiment with that too.) i can write the software no probs, it is the hardware that i need to put together now.

TIA
Rob.
 
Re: reply to LED problem

thisistausif said:
hello
you can use bc147 with a combination of ac187

This seems a really strange combination, a (fairly modern) silicon transistor with an ancient (and long obselete) germanium transistor.

But as for the actual thread, a sound card audio output seems a totally bizarre port to try and use to switch LED's?. Either the serial or parallel ports would be much more sensible.

I'm not saying it couldn't be done, but it would be far more complicated and expensive than using the other ports - and far more restricting as well. I think the lack of replies is because of this!.
 
Yeah serial or parallel would, ultimately, be more sensible, but it would require at least some interface logic. The line-out is beautiful, because it's already a fairly high level, so would only a require a small ammount of amplification & more importantly, i've already got some software that is trivially adapted to driving the LEDs + spare sound cards :p I want to drive them PWM (to dim them mainly) so i'm going to need at the very least audio frequencies. I don't think rs232 will be fast enough directly & my experience of interfacing with the parallel port is too limited to be ensured of getting something working v quickly.
The ideal solution is of course an external controller, but again that would need building/buying, what i've conjured up for zero-cost is the following
**broken link removed**
(check out the less than 1k gif, not very good hosting there :lol:)
all the components have been extracted from broken PC PSU's & the ratings of the transistors seem OK for driving about 200+ LED's with 30ma from another PC PSU (i do like these power supplies!)
 
roborg said:
**broken link removed**
(check out the less than 1k gif, not very good hosting there :lol:)
all the components have been extracted from broken PC PSU's & the ratings of the transistors seem OK for driving about 200+ LED's with 30ma from another PC PSU (i do like these power supplies!)

I wasn't imagining anything quite as crude as that? :lol:

When you mentioned 100 LED's, I didn't expect them all to on the same single channel - it's not a very exciting light control system!.
 
Yeah heh, it's far from any display tech! It's primarily to provide 3 dimmable channels for interior LED lighting, at least 3 channels to provide RGB control for really basic colour fading effects. The whole thing is basically a minimal fuss & cost exercise (save the cost of LED's, but they're suprisingly cheap (~5cents each) when ordered in batches of 1000+, sell any surplus on ebay & probably get away with a profit :lol:
 
It could be done the way you have asked, but it's an ugly way of doing it.


https://www.electronics-lab.com/projects/pc/021/index1.html
Is a complete project guide, complete with free software for a
parallel port solution that runs EIGHT channels in a PWM mode.

https://www.beyondlogic.org/ code samples for the ”Porttalk” driver

Of course if you simply must use the sound card, then why not consider
a simple filter system (google for "sound to light circuit") this way three audio control tones could share the same output.
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top