So now i have a DC relay being controlled by a microcontroller that turns an AC device on/off using a control line from the microcontroller being fed into a transistor to provide the necessary current for the relay coil.
The relay output is connected to a AC mains plug(female) in which the AC device plugs in(male connector).
I would like to add a status led display with the following states
- red (device not plugged in)
- yellow (device plugged in + off state / not drawing any current)
- green (device plugged in + on state / drawing current)
Any ideas on how would i go detecting these 3 states from the microcontroller?