What is the best way to receive a 5VDC control signal on the Photon from a 120VAC line?
I am looking for a quick and easy yet ‘up to code’ solution for use in an industrial environment. Essentially, what the problem boils down to, is being able to detect when a float switch is triggered. Essentially this float switch connects and disconnects a 120VAC line. I need to be able to tell from the Photon, the current status of this 120VAC line.
The easiest solution I can think of is to use a cheap USB ‘wall-wort’ that one typically uses to charge cell phones and the like. This would convert the 120VAC into a 5VDC which can then be monitored via the photon. I don’t really like this idea though as it doesn’t seem like the proper / professional way of doing things and I am concerned that the Photon may not be truly isolated from the 120VAC signal.
The alternative that I thought of was to use a relay that is controlled via a 120VAC signal. This seems like a proper solution. So all that to say, can someone help me out in verifying that this 120 VAC, 10 AMP, AC Control Solid State Relay will actually do what I want?
Or even if someone can suggest a better method (with links to actual products), I am here to learn!