Shop OBEX P1 Docs P2 Docs Learn Events
MCP320X question — Parallax Forums

MCP320X question

w4fejw4fej Posts: 264
edited 2012-11-26 15:40 in Propeller 1
Hi all.

I am using a battery powered Prop for a remote control application. I am using a 9.6VDC Li-on, 1600 Mha battey. I am going to monitor the +5.0 VDC and the 3.3VDC voltage levels with a MCP3208 and display the results. I would also like to monitor the battery voltage but with the voltage being 9.6 I don't think I can monitor it directly. Would something like a 1 meg/100k voltage divider be the way to go and measure 1/10th the battery and multiply the result for display?? Any better way to do this??

Also I am using only 5 of the 8 ADC channels in the 3208. Do the unused channels need to be terminated some way or can they be just left to float??

I'm getting to where I really love this Prop as I learn more and more about how to use it...

Thanks, Mike B.

Comments

  • Mark_TMark_T Posts: 1,981
    edited 2012-11-26 08:49
    w4fej wrote: »
    Hi all.

    I am using a battery powered Prop for a remote control application. I am using a 9.6VDC Li-on, 1600 Mha battey. I am going to monitor the +5.0 VDC and the 3.3VDC voltage levels with a MCP3208 and display the results. I would also like to monitor the battery voltage but with the voltage being 9.6 I don't think I can monitor it directly. Would something like a 1 meg/100k voltage divider be the way to go and measure 1/10th the battery and multiply the result for display?? Any better way to do this??

    Also I am using only 5 of the 8 ADC channels in the 3208. Do the unused channels need to be terminated some way or can they be just left to float??

    I'm getting to where I really love this Prop as I learn more and more about how to use it...

    Thanks, Mike B.

    You'll need a reference voltage in order to be able to measure the supplies - are you running the ADC at 5V or 3V3? Something like a 2.048V reference chip and voltage dividers for each channel - no need to divide by as much as 11 though (a 1M/100k divides by 11, not 10!!), divide by 2 for 3V3, by 3 or so for 5V and by 5 or 6 for the 9.6V. High value resistors in the dividers would generate some noise, but adding 1nF caps on the ADC inputs will cure that. Unused inputs can float.
  • Duane DegnDuane Degn Posts: 10,588
    edited 2012-11-26 13:16
    As Mark said you need some sort of voltage reference. I'm bet the 5V regulator you're using will work well enough to see if the battery is getting low. There's not much use monitoring the 5V line if it's used as the reference (the chip would be able detect a change).

    And yes, a voltage divider is the way to monitor voltage levels above Vdd. The MCP3208 doesn't measure high impedence sources well so I'd use a 10 K (or less) resistor between the battery and chip (with the other resistor in the divider chosen to give the desired voltage).
  • Mark_TMark_T Posts: 1,981
    edited 2012-11-26 15:40
    Duane Degn wrote: »
    The MCP3208 doesn't measure high impedence sources well so I'd use a 10 K (or less) resistor between the battery and chip (with the other resistor in the divider chosen to give the desired voltage).

    It handles high impedance at DC perfectly well, leakage is +/- 1nA, so all you need is a capacitor to stiffen up the input from ac noise/pickup. The MCP3208 has sample/hold cap of about 20pF which by itself would be susceptible to pickup, but 1nF or so cap on the input should make it work well, make it 0.1uF if you like, battery voltages don't change that fast.

    1nF is 158 ohms at 1MHz, 10k at 15kHz...
Sign In or Register to comment.