Core Lock up Event Reset after jumping from bootloader to MQX application

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Core Lock up Event Reset after jumping from bootloader to MQX application

1,203 Views
pravinfalcao
Contributor II

Hello,

I am facing very critical problem. We have developed a bootloader to read a source code file via serial z modem and flash into serial flash memory. Also to take the code from serial flash and place in external RAM, extract the vector table and placed the same in internal RAM and then jump to the vector table and then application. This works fine when our application was running on RTXC and codewarrior compiler. Recently we have shifted to MQX with GNU compiler but strange thing is it throws an error stating "Core Lock Up Event Reset" when bootlaoder tries to jump to the application. Again when I run the MQX application using debugger, it works fine but through bootloader, it fails. can anybody help me to solve this problem.

0 Kudos
3 Replies

557 Views
soledad
NXP Employee
NXP Employee

Hi Pravin Falcao,

Please check the below link and let me know if this helps!!

https://community.freescale.com/thread/110446


Have a great day,
Sol

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos

557 Views
pravinfalcao
Contributor II

Hi Sol,

The issue is initialization. In bootloader, CPU and peripherals are already initialize so it gives problem in MQX initialization. Is there any register RESET instruction available?

0 Kudos

557 Views
soledad
NXP Employee
NXP Employee

Hello,

I developed a simple example that shows you how to restart MQX. The example set the LED1 waits for 1 second in the TWR-K60N512. Then the MQX is restarted with the softreset. Following you will find the source code:

void Main_task(uint_32 initial_data)

{

    LWGPIO_STRUCT led1;

      printf("\n Prendiendo LED1 \n");

      lwgpio_init(&led1, BSP_LED1, LWGPIO_DIR_OUTPUT, LWGPIO_VALUE_NOCHANGE);

      lwgpio_set_functionality(&led1, BSP_LED1_MUX_GPIO);

    

      lwgpio_set_value(&led1, 0);

      _time_delay(1000);

      

        SCB_AIRCR = SCB_AIRCR_VECTKEY(0x5FA) | SCB_AIRCR_SYSRESETREQ_MASK;

      //  while(1)

        // {};

    

//  _mqx_exit(0);

}

0 Kudos