This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

ADC10 for battery level monitoring

Other Parts Discussed in Thread: CC1101

Hi

I intend to use MS430F22x2 (with radio CC1101) for a wireless app.  If I choose to use ADC10 to monitor battery level (single Li -ion), am I better advised to use 22x4 with opamps to buffer battery voltage level?  I intend triggering an interrupt when Vbat gets to 3.0V or thereabouts. 

Rgds

Tony

  • If you simply want to monitor battery voltage around 3 V, you probably won't need the op-amps.

  • There's no real need to buffer a battery input with an op-amp for the purposes of signal loading since by definition a battery is a low impedance device that should be able to drive the ADC input easily.

    I suppose there could be an argument to conserve battery leakage current to use a CMOS / JFET / high impedance input op-amp so that the leakage current out of the battery into the chip would be minimized when the chip is powered on (fA, pA, nA vs uA for the ADC directly maybe -- check the input current specs on ADC in and see what it draws).

    Another consideration would be how the chip's ADC input behaves when the chip is powered down.  In that case applying say 3.6V to the ADC input pin when the chip's Vsupply is 0V (off) could cause large / catastrophic currents to flow since the ADC input would be above the supply rail.

    Also you'd want to check the common mode input range of the ADC input and the op-amp, as well as the absolute maximum / recommended value for analog input voltage to ensure that the peak battery voltage when fully charged or when charging will always be less than the maximum allowed / recommended / operational value the ADC input can process. 

    Another major concern might be the situation where the battery is handled or recharged, this could present an input route for electro static discharge from the battery terminal to the ADC or op amp input.  You'd want to provide adequate protection against any reasonably possible levels of ESD on such an exposed input.

    One solution to help add any needed impedance to the ADC input might be to use a series resistor of high value between the battery and the ADC input, though the ADC input itself is probably not a very high impedance input, so your externally added input resistance should be kept reasonably low.

    If you want to limit the common mode input range and help reduce ESD voltages, you could always use a 1/10 voltage divider so that you'd be measuring 0.3V signals at your cut off limit instead of 3.0V signals, et. al.  The ADC should still have plenty of resolution to suit your needs even at 1/10 or 1/20 divisors.  Keep in mind the maximum recommended input resistance and leakage currents though...

    I suppose that for at least some of these reasons, using a moderately high impedance input op-amp  with a high [several meg ohm?] external input resistor added --  as a buffer --  with external ESD protection components and added protection against current flow through an IC input with its power off but applied battery voltage, and possibly adding in a 1/10 or higher voltage divider into the mix would make your design more fail safe against any external input problems. 

    Of course the op-amp built into a lot of MCU chips isn't particularly ESD resistant, isn't particularly high impedance on its inputs, and isn't particularly free of high input leakage currents, so check to see what you're really buying by using a MCU+internal Op-amp solution instead of using some external CMOS/JFET op-amp which probably is more robust against ESD and much higher input impedance than some MCU op amp inputs.

     

  • Well the part series seems to have an input leakage current for the ADC10 specified as a maximum of +/- 50nA, assuming the part hasn't been damaged by ESD, and that power is applied and the input voltage is somwhere between Vcc and GND.  During sampling it is charging a 27pF or less internal to the chip capacitance through a 2kOhm or less multiplexor resistor.  Input signals can range from ground to chip VCC potential.

    The op-amp is specified also to have an +/-50nA maximum leakage current, though below 85C the maximum leakage is guaranteed to be substantially less than that, for an ESD undamaged part.  This may or may not in fact be better at lower temperatures than what you'd get going straight into the ADC10.   However the op-amp may only accept a maximum input voltage of Vcc - 1.2V, so the op-amp input would certainly need to have a voltage divider between it and your battery positive terminal voltage.

    If your external input series resistance was 10M ohm your possible 50nA leakage current would cause a 500mV drop across your added input resistance, which would start to become a significant voltage measurement error.  Also at 10M ohm input resistance you'd have to sample no more frequently than every several milliseconds to allow the internal ADC sample input capacitance to settle to the required accuracy through the large resistance.

    Hence you could do something like use a 6.8M ohm resistor from the battery going into a voltage divider with a 680K resistor to ground for a 1:10 voltage divider from the battery to the ADC input.  Put something like a 0.1uF ceramic capacitor between the ADC input and ground to stabilize the ADC input voltage and provide additional ESD pulse suppression, and you should have decent ESD tolerance.  Wait 5 seconds for any battery voltage changes to be reflected in the ADC sample due to the R-C time constant in this scenario.  Your leakage current (due to the voltage divider) from the battery would be something like 0.5uA which may be too high if you're trying for extremely long battery lifetimes with extremely low system power consumption and low battery leakage.

    You could just go 6.8M series into the ADC10 input with a ceramic low leakage 0.1uF cap to ground from the ADC10 input and that would also help reduce ESD pulses without the DC leakage current and DC voltage divider effect, in which case you'd be theoretically down to your 50nA level (due to the IC itself)  battery leakage current level.

    I suppose you could add a 10k resistor in series with the ADC input before you get to the 0.1uF cap if you want to control the possible discharge pulse of the cap through the IC protection diodes to 2mA if the IC loses power but the cap is still charged (as it would tend to be for a long time).  It would also protect some against a possible case where you might switch the port bit to an output accidentally when it had the charged cap. connected to it.

    Anyway I don't think the internal op-amp will buy you much in this case since its input leakage / ESD characteristics are not hugely (or any) better than the ADC10 input itself for a very low frequency / low precision DC measurement application like this.

     

  • Hi,

    Do a simple resistor divider, I am doing something like this for my project, use a 47K and 15K resistor in series and tied the 47K to the bat positive and the 15K to the ground, so the voltage in the center is applied to ADC, you can monitor from 5V down to 0V , place a 0.1uF capacitor in parallel with 15K, use internal 2.5V REF.

    Good luck

  • Hi,

    Thanks for the replies.  In the end I used a potential divider (6M8 and 68k in series from Vbat to ground.  100nF in parallel with 68k to ground).  Then a 10k in series to ADC input.

    Built but not yet tested. 

    Rgds

    Tony

     

  • Tony

    What is the reason to use the 10K in series to ADC ?

    I have made a similar circuit but as described above I used different resistors value ,but I am having some problem, I have made 2 boards and they are showing differents counts , like 13 counts different from board to board even when I have the same voltage applied in the ADC pin , any idea why ??

    Thanks

     

  • Hi Marcelo,

    Added series 10k at C. Hayes's suggestion, see previous message in thread,...

     

     

  • Sounds good, good luck with it, that should give you a fairly stable and robust sampling of the battery voltage with the

    caveat that the ADC value will take a few seconds to update if there are very sudden battery voltage changes, which

    there shouldn't be to that extent with a properly sized battery except if you're running from non-battery power and are looking to

    detect the physical removal / replacement of batteries, and of course also just for a few seconds after booting from the battery power if the battery has just been inserted.

    .

    BTW you mentioned using 6M8 + 68K0 resistive dividers, which is fine, but it is a 100:1 resistor or 1/101th voltage division

    ratio, which would be appropriate for connecting to a battery pack up into the 100-300VDC range, but would be an

    excessively large voltage division ratio if you're only expecting 4V or so on the battery terminals if you're using a single cell

    Lithium or something like that.  It would give you a usable measurement even so down to the 0-4V battery level, but if you

    did want a bit better ADC resolution you could switch to a 10:1 (1/11th) 6M8/680K0 divider if you only need to measure

    0VDC-15VDC range battery voltages.

     

    Just to detect if it drops under 3V or whatever, though, it's really not particularly critical either way.

     

    Tony Garvey said:

    Hi,

    Thanks for the replies.  In the end I used a potential divider (6M8 and 68k in series from Vbat to ground.  100nF in parallel with 68k to ground).  Then a 10k in series to ADC input.

    Built but not yet tested. 

    Rgds

    Tony

     

     

  • Hi C. Hayes,

     

    Thank you.  Actually the 68k was a typo, I used 680k as you recommended.

     

    Will update in a couple of weeks once tested.

     

    Tony

     

     

  • I you are only interested in monitoring the battery because you want to know when the processors supply voltage gets to low, you could monitor the supply voltage internally by using the setting 1011 in the input channel select for ADC10, (VCC – VSS) / 2..

    I have tried it and it works fine..

     

  • Hi

    I am new to the MSP430, and I am doing a project now, can you tell me more details about how it works? Thank you so much.

**Attention** This is a public forum