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.

XT2 - MSP430F5528

Other Parts Discussed in Thread: MSP430F5528

All,

Thank you so much for reading and responding to this post. I reallly appreciate it.

1.) We are using the MSP430F5528 and want to run as fast as possible.  That being said,  what crystal frequency should we be using for XT2?

2.) The maximum processor frequency accorindg to the datasheet looks to be  25 MHz.

3.) When I look at the specifications in the datasheet for XT2 I see:

Mode 0 - frequency range 4-8 MHz

Mode 1 - frequency range 8-16 MHz

Mode 2 - frequency range 16-24 MHz

Mode 3 - frequency range 24-32 MHz

Isn't mode 3 invalid since the maximum processor frequecy  25 Mhz not 32 MHz?

Please advise.

Thanks.

  • Mike Thornhill said:

    Mode 3 - frequency range 24-32 MHz

    Isn't mode 3 invalid since the maximum processor frequecy  25 Mhz not 32 MHz?

    No. Because Mode3 which is XT2 strongest drive strength is only mode specified for 25MHz. Quartz crystal define frequency, not drive strength so use 25MHz quartz with mode3 and you will be fine.

  • Mike,

    The XT2 frequency spec is different than the CPU frequency spec.  The CPU frequency (MCLK) has a max of 25MHz, while the XT2 can be up to 32MHz.  If you want to source MCLK from the XT2, you may need to use the DIVM bits of UCSCTL5 to divide the source clock that is used to drive MCLK.  I.e. if you use a 32MHz crystal on XT2, and set DIVM to 010 (divide by 4) and SELM to 101 (use XT2 as MCLK Source), you get an 8MHz MCLK, which is valid.

    To answer your questions:

    1.  The max MCLK freq is 25MHz, what you use for the crystal on XT2 doesn't really matter (as long as you use a crystal valid for whichever mode you specify).  You can then use the FLL to generate whatever DCO frequency you want and source MCLK from the generated DCO frequency.

    2.  Correct

    3.  See the above that explains why XT2 frequency ranges are different than MCLK (CPU) frequency ranges.

    Mike

  • Thanks for the comments.

    Let's say that I am using 4 MHz crystal for XT2 - this would be using mode 0.

    I can then multiple this up by a factor of 6 to get 24 MHz for MCLK.

    I read over the FLL in the user guide and all the multipliers look to be a factor of 2.  How would I get 25 MHz with a 4 MHz crystal?

    Thanks!

    Mike

  • If you just want to run as fast as possible, using REFO and set the FLL to multiply that by 763 is a good way to achieve that. It is simple to do, very reliable, and cost nothing extra.

    The REFO is only accurate to about +/-1.5%. Is that a problem? 

  • Great idea but I would like to stay with a high precision crystal.

  • Get a 25MHz crystal that works with that MSP430. They do exist.

  • Mike Thornhill said:
    I can then multiple this up by a factor of 6 to get 24 MHz for MCLK.

    The closer reference clock and target clock are, the more jitter is produced by FLL regulation. A 1MHz crystal, or even a 32768Hz watch crystal, will not only consume less power, but also result in a less jittery FLL regulation.

    Or directly use a crystal of the desired speed and switch DCO and FLL off completely (it will make up for a significant part of the increased crystal power consumption)

  • Great posts guys!

    The datasheet states that the active mode supply current executing out of flash is 11.0 mA with fdco=fmclk=fsmclk=25 MHz.

    Now with 1 MHz the current draw is shown to be 0.44 mA.  How do I calculate what the current would be using the 1MHz as the source and scaling up to 25 MHz? 

    So is the best choice to select the 1 Mhz or 25 MHz?

    Thank you.

  • Actually, the current consumed by the operating CPU is not a constant current. On each clock cycle, a certain charge (Coulomb) is required to change the state of the CPU. If the state doesn't change, no charge is required.
    The accumulated charge of x Coulomb that is required for all state changes in one second adds up to an average current of x Ampere.

    So the 'average current' linearly scales with the system clock speed (as fast as the CPU is really executing code all the time.) On the bottom line, the number of CPU instructions performed per second defines the average current.

    So if 25MHz require 11mA and 1MHz require 0.44mA, the current per MHz is (10.1-0.46)/(25-1). (using the typical values)
    There is a small offset for ram retention and other things. It more or less equals the current in LPM0. (with the values above, you need 0.4mA/MHz and 0.060mA base current - the datasheet tells 83µA for LMP0, so it fits (there is some non-linearity on the DCO)

    Of course this is only true if all other parameters remain constant: junction temperature, supply voltage etc. However, on slower speed, you can reduce supply voltage, which gives additional savings. E.g. on 1MHz, you can go from maximum core voltage (required for 25MHz) down to minimum, saving another 0.1mA (0.36 instead of 0.46)

    Mike Thornhill said:
    So is the best choice to select the 1 MHz or 25 MHz?

    Depends on your application: do you need things to be done fast 8and the CPU can sleep the remaining time)? Or is the average CPU power per second is enough? Of course, if executing your code takes more than 1 million CPU cycles per second, 1MHz is not an option at all.

    You see, there are many parameters cornering the optimum (which isn't necessarily the absolute minimum)

**Attention** This is a public forum