[Tinyos-help] MSP430 Increasing clock speed (MCLK)
cire831 at gmail.com
Tue Nov 16 22:59:40 PST 2010
The parameters used to program the UART clocks are based on what clock is
used to clock the main CPU.
When you change from 4 MHz to 8 MHz you have to program the uart h/w with
different parameters. You'll have to study the users guide to figure out
how to program the h/w and what needs to be different.
Another issue but I don't know if it is a problem, is the 1611 is spec'd
according to TI to be able to run at 8MHz but in the spec sheet it says Vcc
is 3.6 V. It is my understanding that the telosb uses 3.3V for power. So
if you are clocking at 8MHz there might be a problem with 3.3V. It isn't
clear from the spec sheet. I suspect it depends on the die and would
probably show up as intermittent behaviour.
Another issue is the timing system. The core timing system, timerA, is set
up to run with a basic tick of 1uis (binary micro second). If you just
change the main cpu clock to 8MHz, you also have to change divisors to
maintain the 1uis tick. Otherwise all the basic timing in the system (ie.
Timer<TMilli> etc.) is inaccurate.
But at 4MHz we actually program the DCO to run at 4MHiz (4 binary
megahertz), 4x1024x1024 MHz. And the divisors are powers of 2.
I don't think you want to run the 1611 at 8MHiz because it is only specd to
8MHz. So if you program it for 8MHz you have to take this into account for
your calculations. And this then makes the basic tick 1us rather than 1uis
and TMilli will actually be 1ms rather than 1mis. I don't know how this
effects the system.
So why exactly do you want to increase the main clock frequency? What does
it buy you? Be aware that increasing the clock frequency usually causes
more power to be consumed by the cpu. For example, doubling the clock will
make the code execute twice as fast but will typically take more than twice
the power. Although it is hard to figure this out from the TI spec sheets.
My h/w guy tells me that is what typically is true.
On Tue, Nov 16, 2010 at 4:01 AM, "José A. Tarifa" <jostargal at alum.us.es>wrote:
> I'm using Tmote Sky (TelosB) for an application. I'd like to increase the
> main clock frequency (from 4MHz -> 8MHz). I've tried to change some files,
> like "MoteClockP"... but it doesn't work!
> I've discovered a solution, which is provided by "rincon":
> I've used it with these flags: ENABLE_SPI0_DMA: yes; HAVE_ROSC_P2_5:
> no; FAST_SMCLK: no.
> With that configuration, the clock must work at 8MHz ¿? All peripherals
> work except the UART (I'm using "printf" library). I get "bad packet",
> "packet too long"... messages in Cygwin. I've tried all options... but
> transmit messages through the USB port doesn't work. I suppose the UART
> speed is too fast... but in "TelosSerialP" file the UART configuration seems
> Anybody has used this component?
> Jose A.
> Seville, Spain
> Tinyos-help mailing list
> Tinyos-help at millennium.berkeley.edu
Eric B. Decker
Senior (over 50 :-) Researcher
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Tinyos-help