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.

CC2541 A-to-D Converter Input Issue

Other Parts Discussed in Thread: CC2541

All,

Shown below is a circuit that I designed to monitor the battery voltage using one of the A-to-D converters inside of the CC2541.  When we want to determine what the battery voltage is, we use a GPIO to provide to the VBATT_EN signal to the base of transistor Q2.  Q2 turns ON and pulls the gate of P-Channel MOSFET Q1 to ground.
When Q1 is ON the battery voltage is then divided by R17 and R19 and provided as an input voltage to the A-to-D converter input of the CC2541.

What we are seeing when we enable the circuit is that the voltage divider is not working properly.  For a 3V VBATT voltage we expect to see a VBATT_MON_ADC voltage of 1 volt via the divider.  The voltage that we measure for VBATT_MON_ADC is around 2 volts instead of 1 volts. Does anyone have any ideas on why our voltage divider is not working properly for this circuit?  Any comments, suggestions, etc would be greatly appreciated.


Thanks,

James












































































































































































































































































































































































































                            







































































































































































































































































































































































































































































































































































































































































































































  • The schematic is now attached for your review.  Please reference the lower left portion of schematic for circuit I am referencing in previous post.


    THanks,

    James

    SCH000005B BLEHRM 012514.pdf
  • Hi James,

    First thing that I notice is you have very large resistors in the divider.  If you look at the datasheet you will see the effective input impedance of the ADC is 197kOhm so with Mega Ohm resistors the resulting voltage at VBATT_MON_ADC will be incorrect. 

    If you can try putting in resistors much lower than 197k for your divider OR as an experiment cut the trace connecting the divider to the CC2541 and you should be able to verify this is indeed the problem.

    Regards,

    BK

  • BK,

    Thanks for your help.  I am revising the resistor values to 10K and 20K  for the divider network.  Will give these values a try and see how these values work for the battery monitor circuit.

    I have another question in regards to CC2541.  Our current design uses a surface mount chip antenna with the Murata balun.  We want to revise our design to use the inverted F antenna embedded into our PCB board.  Do you know if we can use the Murata balun in the design and interface directly with the inverted F antenna?  All of the TI reference designs show the inverted F antenna used with discrete components and not the Murata balun.  Our schematic with the inverter F antenna is provided below for reference.  We are using the Antenna IIFA BLE that is used in the TI Wireless Heart Rate Monitor Reference Design.  Reference TI document tidu195.pdf.

  • Hi James,

    The pcb antenna should work fine with the Murata balun.  You can see that the Murata balun has an unbalanced port impedance of 50 ohms and that will match correctly with the 50 ohm antenna.  Of course going to a pcb antenna you will need to take more care with the layout. 

    If you take a look at the following app note you will see a few 2.4G pcb antenna examples.  You can get the details of these antennas by following the links on page 40.

    http://www.ti.com/lit/an/swra161b/swra161b.pdf

    Regards,

    BK

  • BK,

    Thanks for the information.  I reviewed the information that you provided.  I copied the antenna used in the TI Bluetooth Low Energy Heart Rate Monitor reference design for use in my design.  The TI reference design was completed in Altium so it was easy for me to copy the antenna and use in my design.  I also used the same PCB layer stackup that is used in the TI reference design. 

    Thanks again for your help.

    James

  • Hello James,

    I also had the problem of measuring the battery voltage with the regulator in between. I solved the issue without adding any additional hardware. The CC2541 can measure its supply pins with an internal voltage divider. Next I changed the Firmware in the way that I measure the voltage when the regulator is in bypass mode. This is usually the case when the device wakes up from sleep. Best ADC read timing is just before the regulator gets switched on. In order to conserve battery I only measure the battery voltage every 256th wake-up event, then I latch the last battery voltage in RAM. So once the user wants to know the battery voltage I just pass the last known lowest value.

    Please note that the CR2032 lithium batteries have quite an high impedance (e.g. 60 Ohms) so the current the CC2541 drains in active mode (e.g. 10mA) makes a break down on the battery voltage. In order to avoid this I used a larger capacity on the battery. I used 100uF. I observed that the application becomes unstable in low temperatures without such cap (there is also an app  note on this). Now it works in my freezer down to -25C :-) .

    I wanted to avoid any additional HW as well as putting an additional drain on the battery. In this way it works fine now.

  • Kai,

    Thanks for the additional information.  Question I have for you is if you have the regulator between the battery and the CC2541 how are you measuring the battery voltage if the regulator is supplying the voltage to the power supply input pins of the CC2541?  Would you please provide me with additional information with the specifics on how you are doing this in your design?

    Thanks,

    James

  • Hello James,

    read my post above how I solved it. The TPS regulator has a bypass mode. During sleep of the cc2541 the regulator is usually driven to bypass mode to conserve battery. Thus the battery voltage gets propagated to the supply pins of the cc2541. You then need to modify the firmware to measure the supply pins only when the device wakes from sleep before the bypass is disabled (the voltage on the supply pins needs to be settled to the battery voltage). Keep in mind that the supply voltage needs time to rise and fall according to the bypass switch. 

    Kai

  • Kai,

    Thanks now I get it.  I understand exactly what you are doing.  I will implement this change and see how it works.  

  • Hello James,

    Can you do us all a favour and delete the image you tried to attach in your first post.  When I am using a mobile device, I have to scroll down for hours to get to the end of the first post. :)

    Thanks,

  • Hi all,

    I'm trying to do the same thing as James, except from the fact that I repalced the TSP with an LDO.
    My question is very simple: is there a reason James uses 2 transistors? Is it possible to do exactly the same thing with one mosfet, controlled with a GPIO Pin. The drain and source shall be connected to the GND and the Battery respectively. This seems simpler than two transistors, but if James did it I guess there must be a reason, which I am missing.

    Here is the scematic


    Thank you for your help!

    Regards,
    Artem

  • in your scematic,  S connected to GND, so G will be higher voltage than S, this will make it impossilbe to open the FET. 

    to make it work ,you need N channel FET, you managed to make it work with a BSH103 MOSFET.

  • The NTR020 also won't work because if you look at page 1 of the datasheet you will see there is a diode between source and drain.  In your configuration the diode will always be active.

    An NMOS also won't work because when the NMOS is not active then the VBAT voltage will reach P0_7.  This will violate device operation since VBAT is higher than the supply.

     

    Regards,

    BK