iMXRT reboot

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

iMXRT reboot

Jump to solution
1,533 Views
mspenard603
Contributor IV

How does one reboot, in software, an iMXRT1062?

0 Kudos
Reply
1 Solution
1,429 Views
jeremyzhou
NXP Employee
NXP Employee

Hi Mike,

Thanks for your reply.
it can make the RT1062 reboot via calling NVIC_SystemReset();
I've attached a sample code that inherits from the hello_world demo in the SDK library. And the testing result is also presented below.

/*
 * Copyright (c) 2013 - 2015, Freescale Semiconductor, Inc.
 * Copyright 2016-2017 NXP
 * All rights reserved.
 *
 * SPDX-License-Identifier: BSD-3-Clause
 */

#include "fsl_device_registers.h"
#include "fsl_debug_console.h"
#include "board.h"

#include "pin_mux.h"
#include "clock_config.h"
/*******************************************************************************
 * Definitions
 ******************************************************************************/


/*******************************************************************************
 * Prototypes
 ******************************************************************************/

/*******************************************************************************
 * Code
 ******************************************************************************/
/*!
 * @brief Main function
 */
int main(void)
{
    char ch;

    /* Init board hardware. */
    BOARD_ConfigMPU();
    BOARD_InitPins();
    BOARD_BootClockRUN();
    BOARD_InitDebugConsole();

    PRINTF("\r\n hello world.\r\n");

    while (1)
    {
        ch = GETCHAR();
        if(ch == 'y')
        {
          NVIC_SystemReset();
        }
        PUTCHAR(ch);
    }
}

pastedImage_1.png

TIC

 

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

 

- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------

View solution in original post

3 Replies
1,429 Views
jeremyzhou
NXP Employee
NXP Employee

Hi Mike Spenard,

Thank you for your interest in NXP Semiconductor products and for the opportunity to serve you.
Actually, I'm not very clear about your question, please you can clarify it.

TIC

 

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

 

- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------

0 Kudos
Reply
1,429 Views
mspenard603
Contributor IV

Sure, I'm simply looking for a way to make a call that reboots the MCU.

0 Kudos
Reply
1,430 Views
jeremyzhou
NXP Employee
NXP Employee

Hi Mike,

Thanks for your reply.
it can make the RT1062 reboot via calling NVIC_SystemReset();
I've attached a sample code that inherits from the hello_world demo in the SDK library. And the testing result is also presented below.

/*
 * Copyright (c) 2013 - 2015, Freescale Semiconductor, Inc.
 * Copyright 2016-2017 NXP
 * All rights reserved.
 *
 * SPDX-License-Identifier: BSD-3-Clause
 */

#include "fsl_device_registers.h"
#include "fsl_debug_console.h"
#include "board.h"

#include "pin_mux.h"
#include "clock_config.h"
/*******************************************************************************
 * Definitions
 ******************************************************************************/


/*******************************************************************************
 * Prototypes
 ******************************************************************************/

/*******************************************************************************
 * Code
 ******************************************************************************/
/*!
 * @brief Main function
 */
int main(void)
{
    char ch;

    /* Init board hardware. */
    BOARD_ConfigMPU();
    BOARD_InitPins();
    BOARD_BootClockRUN();
    BOARD_InitDebugConsole();

    PRINTF("\r\n hello world.\r\n");

    while (1)
    {
        ch = GETCHAR();
        if(ch == 'y')
        {
          NVIC_SystemReset();
        }
        PUTCHAR(ch);
    }
}

pastedImage_1.png

TIC

 

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

 

- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------