0
\$\begingroup\$

I need to sample 8 power switches connected to 230 Volt supply. I want to record the status of these switch every 10 seconds and send to cloud for which I am using arduino with ethernet shield.

For example if status of switches is as below

On Off on On Off Off Off Off

then output should be a single byte 10110000.

I am a novice in electronic so bare with me if its quite straight forward.

As i want this circuit to be place in box for switch space is a concern.

Also my digital pins on Arduino are already used for other purposes.

One option which I was thinking was to use 8 differnt LM7805 to convert AC to dc from all switches and then use some D to A converter, and feed back this Analog signal to analog pin of Arduino from where I can convert that to byte and send to web.

Please guide if LM7805 will take 220V supply (home supply in India) and if not how that can be managed. Also I think using 8 LM7805 will take lot of space.

\$\endgroup\$
2
  • \$\begingroup\$ "my digital pins on Arduino are already used for other purposes", this is your main problem. How can you possibly get the information in to the chip? \$\endgroup\$
    – pipe
    Commented Feb 3, 2016 at 10:57
  • \$\begingroup\$ If you are going to work with electronics, you really need to learn to look-up and read datasheets: Datasheet for LM7805 \$\endgroup\$
    – Tut
    Commented Feb 3, 2016 at 13:57

1 Answer 1

4
\$\begingroup\$

No. You definitely can not use LM7805 regulators for this task.

  • They are low-voltage DC regulators. They expect, typically, 8 - 20 V DC in.
  • YOU NEED ELECTRICAL ISOLATION between the mains and your Arduino. The isolation should be rated to at least 1,000 V.

You need to either use a 230 V relay to monitor each switch or use an opto-isolator with mains dropping resistors. The relay is the safer option in your case. Mount the relays securely and keep all mains wiring away from the Arduino wiring.

schematic

simulate this circuit – Schematic created using CircuitLab

Figure 1. Relay signalling of mains voltage.

In this configuration inputs are pulled 'low'. You need to configure internal pull-up resistors in the Arduino.

Judging by your question you have limited knowledge about electricity so I urge extreme caution.

\$\endgroup\$
1

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.