MSP430G2553 clock speed

Started by arshadnatasha 3 years ago3 replieslatest reply 3 years ago335 views

Hi all:

I am having trouble figuring out this problem. Maybe someone here can give me some ideas. I am using the TI MSP430 Launchpad. 

I have fixed  the MSP430G2553 clock speed at 8 MHz in the code, and according to the datasheet, the clock speed should increase with increasing voltage. However, when I measure it using DCO calibration technique, I get a decreasing clock speed with increasing voltage. The variation is not too much; it varies between 7.92 to 8.16MHz. But shouldn't it be fixed at 8MHz, or maybe increase? I see nothing in the datasheet that explains this anomaly. 

Any ideas?

[ - ]
Reply by iansMay 29, 2017

What are you using as the MCLK source? There are a variety of clock sources on the MSP430 (internal and external) so you need to be sure that your basic clock is accurate (hint: the internal clocks can vary a lot...)

If you want to use an external clock make sure you initialise it correctly - the MSP430 clock system is highly configurable and there are plenty ways to get it wrong (I know from bitter experience!)

[ - ]
Reply by danharresMay 29, 2017

It sounds like you're using a calibrated DCO clock speed.  If so, the clock speed should be at the specified frequency of 8MHz.  However, this can be off by some tolerance (I believe +/-2%, although I didn't find that looking at the datasheet just now).  I don't see anything in the datasheet that indicates the DCO frequency change with operating voltage.

[ - ]
Reply by kabelltexMay 29, 2017
I think you may have a chart of voltage versus speed and misinterpreted it -- pick the speed (in this case 8 Mgz) and the chart will show the minimum voltage you need to run at that speed.  Keep in mind the MSP430 series chips are targeted for the low-power --

 running at speed takes generally more power than running slower related to all those transistors albeit small switching on and off drawing current -- the speed will not change (with one caveat  in a bit) with voltage per se but if you don't have sufficient Vdd at the speed you want to run. it may not execute properly.  The caveat: Any speed variation is likely related to clock drift due to heating effects -- more voltage, a bit more power, more heat leading to more drift.  Internal micro-proc oscillators are inherently less accurate (not crystals) and they drift.  I know of chips (not a specific comment on the 2553 just anecdotal on other micros) with internal clocks that will drift up and down and the period of one cycle may not be the same as the period of another cycle and why most chips have provision for external clocks/crystals with what ever tolerance you're willing to pay for.