This circuit will detect AC line currents of about 250 mA or more without making any electrical connections to the line.
I'd like to use a single comparator or OpAmp with an output that could be connected directly to a PIC micro input. Also a 12V or 5V single supply device would be preferred.
You could probably use an LM311 - it's output is open-collector. Just use a pull-up resistor on the output to your +5v supply rail to set the logic "1" output voltage to 5v. When the comparator switches on, it's output goes to ground. Here's a link to a datasheet: https://www.electro-tech-online.com/custompdfs/2006/04/LM211-DPDF.pdf
JB
just get an optical coupler and 2 resistors on the input to detect I then th output is your to to do whatever simple the isolation is 1000v or more why make complex of something so simple