Electronics > Beginners

Double switch: mains and low voltage safety question

(1/2) > >>

Lusu:
Hi,

Please bare with me, it's my first post here and English is not my native language...

I am doing a schematic + PCB layout for a microcontroller controlled board. In short it does among others AC dimming for lights. I did include a "manual bypass" switch (ON - OFF - ON) that can turn the lights "full on" or "full off" in case of faults or other reasons (see crude block schematic attached). All is fine with this, but I do want to use a double switch that will connect 2 inputs of the microcontroller to ground (one for each "ON" state of the switch).

The switch itself is isolated, but I worry about faults in the switch where the AC mains may reach the microcontroller pins.

Are there any reasons to be worried about the switch sending AC mains over to the MCU? If yes, what can I do to protect against? Should I put in optocouplers just to be safe?

Additional info:

* the switch I plan to use is something like https://www.tme.eu/gb/details/ae-c1570alaad/rocker-switches/bulgin/c1570almbb730w/
* the dimmer schematic is attached, however that's the dimmer MCU only, the main MCU will receive the "Auto" and "Bypass_On" signals directly on its pins.
Thank you.

capt bullshot:
If you want or need to comply with standards and regulations, you most probably cannot use this kind of switch in the way you want to. This is because the switch probably doesn't meet safety insulation ratings between its two poles. Can't tell this from the datasheet, but usually these switches aren't made for your application.
So yes, it would be strongly recommended to a safety isolate the circuit by some other means (e.g. the mentioned optocouplers).

If it's a one-off for your personal use, I would hesitate a bit, but most probably just do it the way you describe.

Edit: No, I wouldn't, but for some other reason: The kind of contact used in these switches isn't made to work reliably on 3.3V ... 5V and a few mA levels. The contacts may get unreliable over time in your non-isolated circuit. One would operate them at voltages above 12 ... 24V. This is due to oxide or whatever coating that happens with this kind of power contacts, and this coating requires a minimum operating voltage and current to break through. 5V usually isn't enough.

Lusu:
It does not need to meet any compliances, it will basically replace all my light switches in my house. I am not worried about the ON contact resistance because all I need to detect is in which position is the switch. The internal pull-up resistance of the MCU is 25-50K, so even 1K contact resistance will beat that (will be few tens of millivolts which will still read as a "zero"). Also, if I'm doing my job properly, the switch will not be used at all, it will just sit in "Auto" position.

I do not need to test if AC is present or anything else... It is not mandatory to have this detection, but I want it :)

capt bullshot:
The issue I mentioned isn't about contact resistance in the milliohm range. The oxide layers cause high resistance (as high as "isolated") to a closed switch if not enough voltage is applied while the switch is in "open" state. The switch would look like an open circuit to your microcontroller, so the uC can't detect the switch is closed.

Anyway, if it was my design, I'd try to get away with a single pole switch and do the sensing by some other arrangement and maybe one additional optocoupler.

rstofer:
Usually the problem with using 'industrial' type switches for logic:  First, the logic voltage isn't high enough to break through any oxide layer on the contacts and second, the current flow isn't high enough to keep oxide from working back in.  If you look around, you will find that logic level switches have gold plated, bifurcated, contacts with a very low current rating.

https://www.nkkswitches.com/pdf/switchcontactmaterial.pdf

The next to the last paragraph recommends gold over silver contacts for your application because the gold will work for logic levels and the gold will vaporize off the power contacts leaving the preferred silver.

I wouldn't do it that way...

Side issue:  In the bad old days, the pull-up resistor for switch inputs was quite low - maybe 1k - to guarantee at least 5 mA of current.  It's a waste of power but low resistance values is one way to get around the contact problems.

Navigation

[0] Message Index

[#] Next page

There was an error while thanking
Thanking...
Go to full version
Powered by SMFPacks Advanced Attachments Uploader Mod