Parcourir la source

fix for flash & bus clock divider

main
duff2013 il y a 9 ans
Parent
révision
0e5922acfb
1 fichiers modifiés avec 2 ajouts et 2 suppressions
  1. +2
    -2
      teensy3/mk20dx128.c

+ 2
- 2
teensy3/mk20dx128.c Voir le fichier

@@ -658,7 +658,7 @@ void ResetHandler(void)
#if defined(KINETISK)
SIM_CLKDIV1 = SIM_CLKDIV1_OUTDIV1(1) | SIM_CLKDIV1_OUTDIV2(1) | SIM_CLKDIV1_OUTDIV4(1);
#elif defined(KINETISL)
SIM_CLKDIV1 = SIM_CLKDIV1_OUTDIV1(1) | SIM_CLKDIV1_OUTDIV4(1);
SIM_CLKDIV1 = SIM_CLKDIV1_OUTDIV1(1) | SIM_CLKDIV1_OUTDIV4(0);
#endif
#elif F_CPU == 4000000
// config divisors: 4 MHz core, 4 MHz bus, 2 MHz flash
@@ -669,7 +669,7 @@ void ResetHandler(void)
#if defined(KINETISK)
SIM_CLKDIV1 = SIM_CLKDIV1_OUTDIV1(3) | SIM_CLKDIV1_OUTDIV2(3) | SIM_CLKDIV1_OUTDIV4(3);
#elif defined(KINETISL)
SIM_CLKDIV1 = SIM_CLKDIV1_OUTDIV1(3) | SIM_CLKDIV1_OUTDIV4(3);
SIM_CLKDIV1 = SIM_CLKDIV1_OUTDIV1(3) | SIM_CLKDIV1_OUTDIV4(0);
#endif
#elif F_CPU == 2000000
// since we are running from the fast internal reference clock 4MHz

Chargement…
Annuler
Enregistrer