I recently built a unisolder soldering station. One of its features is a sleep mode based on whether or not the soldering iron handle is present in its holder. A SLEEP pin is provided that's weakly pulled up to 3.3V and needs to be pulled to GND to indicate that the iron is in its holder.
Part of the holder I'm using is conductive and makes contact with a part of the soldering iron that's directly connected to protective earth. I'd like to be able to detect when the holder is connected directly to protective earth through the soldering iron handle when it's inserted and pull the SLEEP pin to the controller's GND appropriately.
However, the controller's GND is not referenced to earth by design, and because of that I'm unsure about how to design a circuit to detect the presence of the iron while keeping protective earth isolated from the controller's power-supply.
How could I go about building such a circuit?
This is the schematic of the unisolder board I'm using. I'm supplying it with 23V AC from the secondary of an isolated transformer.