Using a MOSFET as shunt works, but what if it is 'off'?
I came up with this: in meter circuit . remote MOSFET power switch . ------------------------------------- . | | | . g 1k5 18k R 1M R 1M . to ADC ------ d s --- R -- R -- | | . | BF245 | | 1k8 /// 8k2 | . | JFET | - --- R ---------- R -------------------------- | -- o 1k8 8k2 | . sense lines | | + -- R----- R ---------------------- | | LM324 | | | . | | | + | R === === . | | 12V sealed lead acid R |18k |100n |100n . R 100 R
100 | - | 1M R | | . | g | | | |1k5 | | . | | |---------------------------------------------------------------------- d s-------------- | . IRFZ44A /// . Ron 25 mOhm
Gate drive MOSFET not shown for simplicity, some other parts not shown.
The 100 Ohm resistors on the right are protection against cable shorts in the sense line, as that would bridge the MOSFET, and melt the sense lines in this case.
The 100nF are RF decouplings.
Normally, when the MOSFET is 'on', the voltage over it is amplified by the LM324 and applied to the PIC ADC (off screen on the left) via the JFET. The JFET is on because it sees about 0V on its gate. As the circuit is differential, no problems arise due to cable resistance, voltage drops, etc.
However when the MOSFET is off, a _negative_ voltage appears at its source, making it to the - input of the LM324, causing the input transistors-(BJT)-be junction to conduct, its output will go positive, and a positive false reading says there is still current flowing. To prevent this false reading when the MOSFET is off, the JFET is added, it now sees about -6V on its gate (via the 2 x 1M voltage divider), and no longer conducts, causing the ADC to see zero volts.
The resistors in series are to get the right gain, and also to allow the 100nF caps to be placed at a good point for filtering.