AnsweredAssumed Answered

KBOOT launching application problems (MK22)

Question asked by TERRY COOKE on Jan 22, 2016
Latest reply on Jan 22, 2016 by Mark Butcher

I have been struggling getting my application to boot after programming from KBOOT sometimes. I am using KDS3.0 and KSDK1.3

 

My application will sometimes hang at in the startup_MK22F51212.c file at the second  while loop:

  /* Check that the source of the FLL reference clock is the requested one. */
  if (((SYSTEM_MCG_C1_VALUE) & MCG_C1_IREFS_MASK) != 0x00U) {
    while((MCG->S & MCG_S_IREFST_MASK) == 0x00U) {
    }
  } else {
    while((MCG->S & MCG_S_IREFST_MASK) != 0x00U) {
    }
  }

 

I would imagine it is caused by the different clocking schemes used by the bootloader and my application.

 

Has anyone else encountered this problem? Is there any more documentation which explain the clock settings in the Bootloader Configuration Area (BCA)?

 

In my application I use the internal IRC 48MHz clock, PEE, with the PLL output set to 96MHz. The FLL module is disabled.

 

Thanks,

Terry Cooke

Outcomes