# converting 220v ac sognal to 5v or 3.3v signal

i need to convert 220v signal to 5v or 3.3 v signal if push button pressed..

i tried the following circuts:

1)using neon lamp and ldr:

**this circuit works fine and do what i need but if push button has indication lamp across it it doesn't work as neon lamp alwyas on.

so i decide to go through second circuit.

2-)using 220v coil relay :

this circuit also works fine but as in circuit 1 ih i used push button has indication neon lamp across it the relay stay always on.

so i decide to go to 3rd circuit

3-)using optocoupler

this circuit not tested because i dont know the type and rated power of R2 and type of C1.

my question if i use this circuit i will face the same problem as in circuits 2 & 2 ?

if yes how can i solve this problem.

regards

• can you elaborate; is your indication lamp is in parallel with your push button? – Navaro Aug 1 '18 at 17:53
• Are you requiring an indicator lamp showing that 220 VAC is available, regardless of the push button? – jonk Aug 1 '18 at 18:00
• @navaro yes :) _____________________ – vtc Aug 1 '18 at 18:23
• @jonk there are 20 push buttons in our staircase all of them has indication lamp. – vtc Aug 1 '18 at 18:23
• @vtc Each of the 20 indication lamps are always-on, regardless of the state of any one or more push-button(s)? You didn't actually answer that question, as I read you. (Sorry to ask, but these are questions that come to mind and some of us would rather not make assumptions. A direct and detailed answer would help. [Writing "too much" is almost always better.]) – jonk Aug 1 '18 at 18:30

If the circuit holds a 220VAC relay closed it is passing a fair bit of current. A typical small relay coil might be 30K or so. The neon probably has 50-100K in series for a high brightness short life bulb @240VAC.

You can probably use any of those circuits if you parallel the input with a relatively low value resistor or a small incandescent lamp.

For the relay, try 10K 10W wirewound. It will get hot if the switch is held down (or shorted).

Edit: I see from your comments you have many switches connected in parallel. So you may have to use a lower resistance resistor (which means more watts). Or use an incandescent bulb if you can find one.

• Since OP indicated that all buttons have neons in parallel and all buttons wired in parallel as well, what is basically needed is a circuit that detects zero voltage across. – Maple Aug 1 '18 at 19:32
• you said if i parallel the input .. which input you mean ? – vtc Aug 1 '18 at 19:57
• Across the coil in the case of the relay. – Spehro Pefhany Aug 1 '18 at 19:59
• @Maple That's certainly a possibility to detect the presence or lack of current near (not at) the zero crossing- you want to propose a design in an answer? – Spehro Pefhany Aug 1 '18 at 20:02
• @SpehroPefhany Not really. First, you already started an answer, so you can simply add that option. And second, at this point I am not sure if what I said about wiring was correct. Need something definite from OP first. – Maple Aug 1 '18 at 20:11

If you want the neon bulbs in the buttons to stay on you can add a shunt resistor in parallel with the relay. This will prevent enough current from flowing through the relay to activate it and allow enough current through both the relay and the shunt to light up the bulbs. When the button is pressed, then there is enough current available to activate the relay. Mind you this is not the most efficient method, but it is simple. You'll have to choose a resistor that will divert enough current from the relay so that it is below the holding current of the relay.

Or if you don't care about the neon bulbs lighting up, you can add a resistor in series with the relay such that the current available from the neon bulbs is less than the holding current of the relay.

Both methods require knowing more about the relay in order to choose a suitable resistor.

• thank you if i add the series resistor .the indication lamp will be on when the button not pressed ? and you say using the relay not the most efficient method ,could you tell me what is the most efficient method ? what about circuit 1 ? – vtc Aug 1 '18 at 19:53
• Using the relay is fine for efficiency, it's the adding of the shunt resistor that is not very power efficient. You can use the same concepts for circuit 1, I'm just not as familiar with neon bulbs. – Aaron Aug 1 '18 at 20:15
• thank you for your appreciated effort.. i used resistor it solved my problem :) can i use capacitor instead of parallel resistor ? – vtc Aug 6 '18 at 9:07
• I would avoid that in this application. A capacitor in parallel with a coil is what is known as a tank circuit; they oscillate together. – Aaron Aug 13 '18 at 20:14