Isolate analog voltage from ICSP

Status
Not open for further replies.

Overclocked

Member
I am using a 18F13k22, but need to use an external voltage reference. The pin for +Vref on the PIC is also used by ICSP (PGC to be specific). Is there anyway to isolate the voltage reference during programming, but also during use as to not effect the accuracy of the reading of Vref? ICSP will only be used during programming and not during the final application.
 
Would it matter?? During programming that pin is an input... Is your vref a low impedance input? I use the pic16f1825 which has RA0 and Ra1 connected to a joystick... I have the joystick connected with the same connector as the pickit3... BUT!! I have pullup resistors which don't affect the programming..

That chip has a very good FVR... 32 bits for an internal vref Would you be better off with that?
 

The dynamic output impedance is rated at 0.2 Ohms. I couldnt find input impedance. I know the chip has a on board vref, but it varies wildly, from -8% to +6%. The voltage reference I have on hand is rated at 0.5%, which is more than enough for what I need.

LM4040C20IDCKR is my intended vref (its what I have in stock. Trying to use up stock before buying anything else)
**broken link removed**
 
Cheapest way is to use a dual 6 way header and blank if off when not using it.. Another possibility is to put a low ppm resistor in series with the Vref ( check the voltage is still correct ).

Other than that an analogue switch??
 
Two I/O pins Left. Since it consumes a a small amount of current, I could control it with a I/O pin. Turn it on before I need a reading. During programming it will be off and thus be reversed biased since no current will be flowing.

Zener voltage:2.048 V
Iz = 60uA
IL (into the ADC pin): 100uA (I am estimating this)
VS: 3.3v to 3V
My calculated resistor to bias the voltage reference is 8.346kOhms. I think this falls into the recommended impedance for the ADC
 
keep your power and ground away from any clocking signal pwm spi serial don't run them over or under your ADC tracks.
And read this

Also take samples ACD read spitout the first reads and then sample say 10 times see if it's not way better.
 
You certainly need to disconnect VR for programming.

You may be able to run PIC with programmer connected. About all Microchip programmers have pull-down resistors around 4.7K. A typical VR should be able to drive it.
 
Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…