Jump to content
43oh

There is a problem with MSP430F6723 SPI..


Recommended Posts

Hello.

We are using MSP430F6723, and we want to achieve 20 uA of current consumption.

There is a problem with hardware SPI.

SMCLK doesn't stop after reading from SPI is finished.

If I'm not mistaken, it doesn't stop if UCBUSY = 1.

I don't care about UCBUSY behavior, but I have huge additional current consumption becasue SMCLK doesn't stop.

 

Therefore, I have to use a software implementation of SPI. But in this case I need 160 uSec to read 32-bit word.

With hw SPI it takes 30-40 uSec (4 times faster). It also costs 2 uA additional consumption. This value isn't small, if we want achieve 20 uA for the whole device.

 

Furthermore, sometimes everything works fine (SMCLK stops).

In attachement is the source code, which seems work properly (I don't know why, and how long it will work properly).

If I change to use pull-down instead of pull up - SMCLK doesn't stop again.

What is the reason of such strange behaviour and how to fix it ?

Link to post
Share on other sites

1) Hmm, No attachment visible...

2) What environment? Energia? CCS? IAR?

3) Have you reviewed how the '430 low power states affect when clocks are stopped? Clocks, in many cases, will stay on if any other running activity requires that clock.

4) If you're running an Energia app, import it to CCS where you can use the debugger to examine the registers to see state. Whether you "care" about a state is immaterial, the mcu state drives power requirements, regardless of your desires. Your code needs to manage the state(s) in order to achieve low power.

5) Energia, as well written and efficient as it is, can still cause your app to use more current than a tightly written CCS/IAR C app, which will often use more than a well-written assembler app.

6) How did you design the app to limit current to 20uA and how are you measuring your current consumption?

7) How are you calculating the expected current consumption?

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...