Should the system clock be set before copying the sections from rom to ram?

42 views Asked by At

I am having doubts in when should the system clock be setup in the microcontroller. My question is should the system clock be setup properly before invoking the functions to copy .data & .bss sections from ROM to RAM?

My rationale for setting up the system clock prior to the copying process is to speed up the execution time in copying. Do I make sense? Without the setup clock, I feel that that copying process will be slower due to a lower clock speed. Can anyone corroborate this?

If the clock was not setup, it would be running on some default value(lower than the intended value for operation). The reason for setting up the clock is to offer a quick startup timing before the actual applications run.

Generally, should one copy the required sections from rom to ram before the clock is setup properly(i.e the application should take care in setting up the clock)?Please clarify and point to relevant resources.

Thank You.

0

There are 0 answers