Wiring Forum
Wiring Hardware >> Tangible computing >> digital out to analog 220V?

Message started by beachmeat on 03/13/06 at 17:35:44

Title: digital out to analog 220V?
Post by beachmeat on 03/13/06 at 17:35:44
Hello there,

for an installation that shall technically simply turn 24 lights (60W) on or off, we are thinking about using a wiring board for this. I am not very experienced with electronics, so I was wondering if its possible to use the boards digital outputs for this task. In my idea, it should be possible to connect the digital output to a relay that switches the light on when a signal is outputted. For the configuration of the relay I would need to know the output current of the digital I/Os - I couldnt find any information here, so I checked at Atmel and they say the digital outputs have a current of 5V and 40 mA - can anyone confirm this? Furthermore it would be great to know with which hardware (relay, transistor) it could be possible to drive these lights...

Many thanks

P.S.: A little side-question - we have a wiring board that got fused accidently... I have a power adapter that has 4.5V or 6V and 1000mA - I read the wiring board normally uses 800 mA - can I use that adapter anyway?

Title: Re: digital out to analog 220V?
Post by Alan_Kilian on 03/13/06 at 19:37:07

There are many ways you can do this. You can make a more complex system that is cheaper, or a simple system that is more expensive.

You say that you are not very experienced with electronics, so I will tell you about the simple method that costs a little more.

You should use a "solid-state relay" to control your lightbulbs.

Jameco.com has a part #175214 relay for US$5.95 each at http://jameco.com/webapp/wcs/stores/servlet/ProductDisplay?langId=-1&storeId=10001&catalogId=10001&productId=175214

You will need 24 of these. You can just connect the relay input to your Wiring board, and you can connect the output to a 240 Volt AC power source and your lightbulb just ilke it was a normal switch.

That's pretty simple, but it will cost  US$142 for the relays.

It can be done cheaper using a normal relay, but you will need to add a transistor and a diode to each relay which adds a lot of complexity for you.

Let us know how you do on this project.

Title: Re: digital out to analog 220V?
Post by beachmeat on 03/13/06 at 20:17:05
Hey Alan,

big thanks for your quick and competent response!
I will research if I can find these parts in the Netherlands, we are a little bit under time pressure here.
If you wouldnt mind explaining the more complicated way in a bit more detail, that would be fantastic...its always good to learn a bit more about these things. Like which kind of relay/transistor and diode I would require....
Basically a transistor amplifies a signal and a diode is as fasr as I know a one-way road for the current.
So I would need to amplify the signal a bit and make sure that it doesnt flow back into the output? But how can I know which values these transistors need?

P.S: Anyone can confirm 40 mA on the output of a digital pin?

Title: Re: digital out to analog 220V?
Post by Alan_Kilian on 03/13/06 at 22:09:01
You can hook a transistor and a diode to the coil of a relay like this:

That way you can use cheaper non-solid-state relays.

I personally wouldn't source or sink 40 mA per pin on more than a couple of pins.

If you draw 40 mA out of 24 pins, the chip will suffer.

Title: Re: digital out to analog 220V?
Post by beachmeat on 03/13/06 at 23:31:36
Hi again and thanks again.
We are goinf to use always just one of those lights  8) so we are not going to have a problem with that. Great.
I will read the PDF and absorb its knowledge liek a sponge. Then I will probably ask more stupid questions.

Your help was very appreciated.

Title: Re: digital out to analog 220V?
Post by uki on 03/15/06 at 18:24:12
Hello man,

My advice is to use opto triacks. Try with MOC3041 or MOC3021. You just have to use resistors 150 Ohm to turn on optotriacks.

Optotriack is one LED + triac driver. See how to connect one LED in wiring learning section and use the same schema for optotriacks.

These parts you can buy everywhere and it's not so expensive.


Title: Re: digital out to analog 220V?
Post by barragan on 03/05/08 at 13:20:03
hi, I think this is what you´re looking for: http://wiring.org.co/learning/examples/Optocoupler_triac.html

Title: Re: digital out to analog 220V?
Post by Titus on 03/05/08 at 17:41:27
hey beachmeat,

eindelijk nog een nederlander:P

there are so many ways you could do this, but the best are already mentioned.

Anyway, I could help you with finding and ordering the parts.
Ik koop ook veel electronica onderdelen etc,
www.dickbest.nl is een goede, je moet alleen wel weten hoe je moet zoeken.

Als we hier tot een bestellijst komen, zal ik kijken waar het het goedkoopst is en je helpen, Mail me of pm of post hier :P

Wolfofwar [at] gmail [dot] com

That was our beautifull language, Dutch :P


Wiring Forum » Powered by YaBB 2.5 AE!
YaBB Forum Software © 2000-2010. All Rights Reserved.