I'd like to connect a bridge (full wave) rectifier to my Raspberry Pi (RPi), GPIO pin 22 (configured as an input). I have configured the rectifier such that it has a 120VAC input and 3VDC output (I used a voltage divider on the DC output). The circuit works fine. I'm able to power an LED from the 3VDC output. Now my question is, how do I connect this 3VDC output to the RPi? Do I just tie the grounds together (rectifier DC ground to RPi ground) and then connect the bridge rectified 3VDC to the RPi GPIO pin 22? I measured a 68V difference between the RPi ground and the bridge rectifier DC ground. I decided to hold off on connecting anything until I figured out why there is such a large voltage difference between the two grounds. Any help would be appreciated. BTW, the RPi is being powered by the same 120VAC source that is connected to the AC input of the bridge rectifier.
Here's the circuit I ended up implementing: 120VAC Detector Circuit