Slowing down the processor clock

I’ve tried searching to forum, but can’t find any reference to cutting back the clock speed on a FEZ Domino. I am guessing that it will require some register manipulation. If anyone has a suggestions for getting stared appreciated they will be.

Why do you need to slow the processor down? What can that accomplish that delay’s can’t?

Slower speeds = less power consumption. My ap doesn’t require the full 72 MHZ native processor speed so I can run it slower and and extend battery life.

You can do something like this:
Register CCLKCFG = new Register(0xE01FC104);
// set the clock to 24Mhz

But when you change processor clock, other clocks might be affected like UART and USB… So you have to be very careful. This is an advanced thing to do. You have very familiar with the processor.

Thanks for the reply, Mike. This will get me started.

Is it safe to say that if there’s a problem caused by changing the clock you’ll be able to recover by accessing the bootloader to delete your code on power up?

Yes or better only change the clock when a button is pressed. Should you crash the system, you can always restart the board and not press that button while changing the software again.

That worked nicely Mike and Gus. Thanks for the info. The slowdown does affect local time and sleep values as I guess as one might expect. I suspect that the UART communications might also be affected, but haven’t checked yet.

Is there some reference you can point me to for the register addresses and definitions? I’ve searched the NXP documents, but can’t find anything that tells you to set “Register(0xE01FC104)” to # (11 binary) to slow down the clock by a factor of 3. Thnaks

The register definitions can be referenced here;

Chapter 4 of the LPC23XX User Manual (Rev. 03) refers to the clock configuration register (sub-section 7.1).

Thanks, Richard4 - just what I was looking for.