I have a MCU that powers up periodically to log some data and then powers down (full power off -- not sleep). When powered on, it runs off a battery and I want to connect the battery to an analog pin on the MCU to measure its voltage, but I don't want it to backpower my MCU when it is powered off.
Is there a recommended type of component that I could use to effectively isolate the MCU from the battery when the MCU is off? This would need to work without interfering with the voltage value being read by the analog pin.
I was thinking about possibly using an analog switch IC like: https://www.ti.com/lit/ds/symlink/tmux1101.pdf
I once used a similar 2 channel IC for isolating I2C with good results: https://www.ti.com/lit/ds/symlink/ts5a23159.pdf
Wondering if this is a reasonable solution or if I should consider other options? I'm an EE hobbyist, not anywhere close to an expert. Thanks.
Update: Thanks to @DKNguyen for pointing me to an existing answer that was for a different but similar problem that requires the same solution: Low current battery monitoring
I implemented this solution and can confirm that it works.