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.

MSP430G2553: Basic questions to ultra low power systems

Part Number: MSP430G2553
Other Parts Discussed in Thread: TPS22860, TPL5010, MSP-EXP430FR5969, TPS62730

Hello,

I am currently trying to design my first project with the MSP430 under ultra low power requirements. I have never done an ultra low power application.

My first question is about I2C. I am using the MSP430 as single I2C master with a single slave. Would it be better for current consumption if I only put a pullup on the SDA line and configure the SCK pin as pushpull? This would work as ports are not affected by sleepmodes. This way there would not be so much current flowing while communicating.

Second question is I would like to put the device to sleep for several minutes. I could not quite figure out how to configure the timers. With 8 MHz clock and divider by 8 I still have a clock of 1 MHz and a 16 bit timer would only run 65 ms until it interrupted. Nothing near the few minutes I need. I would not like to wake up so often an count by software. Is there a common practice how to do this?

The device should run from battery for as long as possible (minimum a year). Now I saw some designs using two AA cells directly. I planed to use 4 normal AAA cells in row and a TPS78330 Ultralow Quiescent Current Low-Dropout Linear Regulator. Would 2 batteries connected directly be longer lasting than 4 with the TPS78330?

Does it make sense to turn off peripherals like I2C devices or a bluetooth device with a second TPS78330 when not used? This way only the MSP would have power when the device is idle. I thought of using a  voltage divider to measure battery voltage and shut the resistors of with a TPS22860. What is the common practice here? How does one generally handle ultra low power circuits with peripherals. Is there a book or something that can be recomended?

Sorry for the many questions. But this is a completely new field for me and I have 0 experience or knowledge about it. I would like to learn the common practice that has turned out to work well.

Thanks, kind regards

  • Hi,

    I would suggest to get started with a book about MSP430 basics. There are a couple available like e.g. "MSP430 Microcontroller Basics" from John Davies.
    After understanding the basic concepts like "active mode" and "sleep mode", interrupt handling vs polling etc. you can get started with the code examples. An easy way is to use the MSP-EXP430G2 launchpad. ( www.ti.com/.../MSP-EXP430G2) This HW is perferct to test and get things started. Code examples, hardware design files and more are available online in our TI Resource Explorer. dev.ti.com/.../

    For every MSP430 we provide code examples for the different modules like I2C, SPI, ADC, Clocks, Timer etc. They are a good starting point.

    To your question regarding I2C, please find more information about the size of the resistor here: http://www.ti.com/lit/slva689 The pull up resistors are mandatory for reliable communication.

    To your question about the clock frequency. Every MSP can operate with different clock sources. Usually in active mode the CPU runs fast, eg. 8MHz to compute and do whatever it needs to do. After it is finished the CPU is turned off and the MSP goes into low power mode. Here the clock source is switch to a lower frequency e.g. 32kHz. With an internal or external 32kHz clock source and using only one timer sleep times up to 16 s are possible.

    Please also have a look at Software Coding Techniques for MSP430TM MCUs (http://www.ti.com/lit/slaa294) to learn more about how to program an MSP430.

    Best regards,
    Andre
  • Ok, thank you for the Info on the documents. I will read them. 

    Any tips on how to handle the other devices in the circuit. Is switching them off with a loadswitch a good practice? How does one generally handle circuits where not all IC's are used all the time?

    Kind regards

  • For MCU ultra low power:
    * Use the MSP430FR series.
    * Set all unused I/O as output and set them to logic low.
    * Use a 32.768KHz external crystal.
    * If you do not need 8MHz CPU clock, use the minimum you need. Changing the frequency to 1MHz, for example, will save you a lot of energy.
    * I2C when idle (idle state is VCC) does not consume power. You can minimize I2C dynamic power loss If you do not need a lot of speed (and if the leakage current of I2C lines is small). You could use high pull-up resistors. I have used 100K pull-ups before without problems (just do not expect 400KHz speed).
    * Use LPM3.5 or even LPM4.5. As these are the Lowest Power Modes.
    * For any periodic sleep/wake-up, use the MCU RTC module in combination with the highest possible LPM number.


    For external circuitry:
    * Use hard shutdown to eliminate any sleep or leakage currents of unused or idle parts or peripherals.
    * use switching regulators as these have higher efficiency than LDOs.
    * minimize capacitance for all digital lines as this will minimize your dynamic power loss.


    If you follow the above, you should be able to power a device for multiple years on a single AAA cell.
  • Thanks for the reply. Any suggestion what DCDC regulator is suitable? I found a few that seemed to have a much higher Iq than the TPS78330. I suppose a Buck-Boost Regulator is what I would need too look for. 3 V output for an input of 5 V down to 1 V or so.

  • Yes, you would need a Buck-Boost.

    Try to locate one that provides the highest efficiency for the voltage input and output you have. Their datasheets should provide graphs with that information. Good Luck.

  • Hi,

    thanks for the answers. I searched for switching buck boost converters but did not find any that had quite such a low Iq as the TPS78330. The buck boost ic's seem to have Iq's of > 30 uA. Am I missing something here? The TPS78330 has a Iq if 500 nA.

    I just shortly wanted to discuss the matter of the I2C again. If the slave device does not support clock streching and there is only one master, is it then not better to omit the pullup on SCK and configure the SCK pin as push pull. That way the SCK will never have to fight against the pullup. That should save a lot of energy. Does it make sense?

    Another thing I came across is the TPL5010 Nano-power System Timer. With this I can put the MSP430 into sleep for much longer than 16 mS (7200 s) in the deepest sleep mode with only an external interrupt waiting. Any thoughts on this?

    Sorry for asking again but I don't really know anyone who I can discuss the "ultra low power" matter with. So I am gathering information as much as I can. I guess I will do some test with the MSP-EXP430FR5969 and post my findings in return.

    Kind regards
  • OK. Let first start by correcting your view of the voltage output of batteries. AAA batteries (or any battery) do not discharge to 0V. What happens in reality is that they start with ~1.4V initially then they discharge to ~1V after which they "fail". At ~1V they reach a catastrophic point at which their energy output drops rapidly rendering them useless.

    So, from the above, if you use 4 AAA batteries, your input voltage range would be anywhere between ~6V and ~4V. This now changes the type of switching converter you need to only buck converters.

    Now back to your first question: Yes, there is something you are missing in the case of TPS78330. First, this is an LDO, which means you will have energy waste. Second, the 500nA is a "Shutdown" current. It just means that the TPS78330 will not consume too much current when it is in "shutdown". Well, this might be good if somehow you can create an external "hard shutdown" signal that controls it; otherwise, you will need to look at the "I GND" entry in the datasheet.

    So now let us go over why LDO are not a good choice. Let us say that your battery voltage starts at 6V and your MCU is at 3.3V and the MCU circuitry consumes 1mA. The power consumed at the MCU would be 3.3mW; however, because this is a linear regulator, the batteries will also see a 1mA current consumption, which means the power drained from the batteries is 6mW. This makes the efficiency (regardless of IQ, just by a design choice) be 3.3mW/6mW = 55%. That means, just because you chose to use an LDO, you are throwing away ~50% of the energy stored in the batteries.

    As for the other question, you can put the MCU in deep-sleep for days if you use its RTC.

  • Thanks for the reply (and patience).

    I understand the thing about the LDO and the battery voltage. But I have one more thought about the LDO. Lets say my circuit takes 5µA in standby. If I look at the TPS62730 switcher for example it has an operating quiscent corrent in active mode with 0 mA drawn (which I guess is equivalent to Ignd) of 34 µA. That would sum up my total current to ~40 µA. Now the TPS78330 has an Ignd (thanks for pointing that out) of roughly 1 or 2 µA at 5 µA load. So in total with the efficiency of 50 % it would draw under 20 µA. I guess for applications which are in sleep mode almost all the time and draw only very short some 300µ A the LDO would be better. May that be right?

    The RTC with calendar is of course a good choice. Yet I wanted to use the G2553 wich doesnt have the RTC. Thats why I thought the external nano power timer was a good choice. 

    Any thoughts about the I2C?

  • Your numbers make sense. That might be better for you.

    As for I2C, I do not think it will make any difference. I personally would stick with the I2C protocol being open collector with a pull-up. As I mentioned earlier, you can always choose a larger value for the pull-up (or even use the ones in the MCU IOs), as long as you pay attention to the bus speed.
  • I think the power supply issue may depend on how your device will be used.  If there will be extended periods of time when it is idle, or effectively off, and if it can be awakened with a push button by the operator, then you could put the processor to sleep awaiting the interrupt trigger polarity on an I/O pin.  The G2553 would draw almost no current in this state, with all oscillators off, and an efficient LDO regulator would do the same.  I've used a device that runs on the G2231 which is active for about an hour a day, and which runs on a 9V battery.  There is no ON/OFF switch, and when everything is asleep waiting for the momentary switch to be pushed, total current consumption is under 2 uA.  The battery lasts about a year.  But there's no question that when the device is On, and dropping 9V to 3.3V through the LDO at a mA or two, it's pretty inefficient.  So it kinda depends on what kind of usage pattern you're looking at.  Switching regulators will be very efficient when supplying significant current, but in my experience they aren't very efficient supplying just a tiny amount of current.  But of course it could be that I'm just not doing it right.

    I think the same thing arises concerning using push/pull instead of a pullup on I2C.  Since there's no current through the pullup when I2C is idle, it all kinda depends on how active your I2C bus is going to be.  But I would certainly give push/pull a try.

    As someone else suggested, the slower you can run the CPU when fully On, the less power you will use.  And remember that even though the G2553 has calibrated 1 MHz DCO settings, that doesn't mean you can't go slower.  And if you need a calibrated slower speed, that can be derived on first run on a chip-by-chip basis without needing a crystal.

    In the end, there isn't going to be a substitute for trying some of these things and measuring the resulting current.

  • George, Mike,

    thanks for your great help and your detailed answers! This is great community help!

    Sebastiana,
    do you have further questions related to this topic? If not, please select "Resolved" on one of the posts above so this thread can be closed out.
    Feel free to open new threads on different topics any time!

    Thanks a lot!

    Best regards,
    Andre
  • Ok. Thank you very much!

**Attention** This is a public forum