I am trying to control a 120V heater with 3-phase AC using a arduino and relay. I am using the relay module KY-019 as in the following instruction.
Following which I have successfully turn on an Adufruit heating pad with only positive and negative power wires.
However, when it comes to a 3-phase heater with hot, neutral and ground wires, how can I control it with relays? Should I use a relay with two units to connect any two of the 3 wires to the relays and leave one stay connected to wall outlet with something like this:
That's not 3-phase. It sounds like regular regular-American single-phase house wiring. You can just switch the hot or you can use a DPDT relay and switch the hot & neutral.
...A light switch just switches the hot (black) and the neutral (white) remains connected.
In the U.S. we don't have 3-phase coming into the house. 3-phase is only used industrially. We have "split phase", which is two 120V out-of-phase "hot" legs, a neutral, and a ground. Between these two wires you get 240V for certain high-power appliances. Otherwise one phase goes to half the house and the other phase goes to the other half of the house.
The neutral and ground are connected together at the outlet box. The "return" current is supposed to flow through the neutral and current only flows through ground in the case of certain faults.
Those colors are standard for NON_USA made devices. Yellow-green stripe is ground. Brown is hot and blue is common. So your diagram is what you need to follow.
The hot is the only lead that is switched. Neutral will complete your power circuit. The ground is there for your safety!
Paul
My understanding now is that
Hot -> relay,
Neutral -> wall outlet,
I am still not so sure about the ground, can I connect it with the ground of arduino? Or should I leave it hanging? Or can I connect it to the wall too? My feeling is that it can be connected to the wall for safety. Is this correct?
For what you are doing, connect ALL the grounds together, including the ground pin on your wall outlet. IF you have one of those cheap detectors that show the power , common and ground are correct for that outlet, use it to be sure the ground is really a "ground" and was not left unwired.
Paul
You may already be aware but still, use a solid-state relay (SSR) rated for 110VAC (load), 5VDC (control). The current rating can be calculated using the heater's wattage. If its 1kW then current will be 1000/110 which is approx. 10A. So choose a SSR rated for atleast 20A.
Note: SSRs are not very suitable for fast on/off. If you want power control then its better to use thyristors. SSRs can be used for simple on/off that mimics human usage.