Good day
How do I make the RT1176 enter ISP mode using code?
I want to do In-Application Programming (IAP), but I can't find any information on this.
The IMXRT1170RM mentions IAP briefly, but provides no explanation for how this can be done:
Kind regards
Damon McLoughlin
Solved! Go to Solution.
Hi @jeremyzhou
I found the problem I was having. I was passing the value (BOOTLDR_CONF_ARG -> 0xeb100000) as a pointer, instead of passing a pointer to a variable containing this value (&arg).
This allows me to enter ISP mode in the FreeRTOS example too (you showed the Baremetal Hello World example).
For future readers, note that you need to use arg = 0xeb100000 if you would like to have the option of connecting with UART or USB for flashing (in the attached example code, 0xeb110000 is used). Also, please note that you cannot connect to the ROM via UART if you have the terminal connection open in MCUXpresso.
It would be great if the documentation (IMXRT1170RM) had used the updated name for ROM_RunBootloader(), and if it had included that you need to initialise the driver with ROM_API_Init() and which driver these functions are part of (fsl_romapi).
Anyway, thanks again for your help @jeremyzhou !
Hi,
Thank you for your interest in NXP Semiconductor products and for the opportunity to serve you.
To provide the fastest possible support, I'd highly recommend you refer to the 10.13.3 Enter Bootloader API section.
Have a great day,
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.
-------------------------------------------------------------------------------
Thanks, but that isn't very helpful.
One cannot simply call runBootLoader or reference g_bootloaderTree - is it part of a driver or middleware component in the SDK? Because if so, I haven't found it there.
Hi,
Thanks for your reply.
In the fsl_romapi.c, it provides the ROM_RunBootloader function to call Enter Bootloader API, you can give it a try.
Have a great day,
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.
-------------------------------------------------------------------------------
HI @jeremyzhou
Thanks for your reply.
I added the fsl_romapi driver to the freertos_hello_cm7 SDK example. Then I tried using ROM_RunBootloader( ) by changing the hello_task to this:
Note that BOOTLDR_CONF_ARG is:
This value was based on the RT1170RM's typical use case for runBootloader (Section 10.13.3):
Also note that I added the ROM_API_Init() and SCB_DisableICache() calls because I saw that was done in the fsl_romapi_cm7 SDK example, before any other fsl_romapi functions are called.
However, when I try connecting to the board with MCUXpresso Secure Provisioning Tool, it doesn't pick up the board:
I did try running it without the ROM_API_Init() and SCB_DisableICache() calls too.
If I put the board into ISP mode manually (by shorting the relevant jumper), then the Tool can connect.
Hi,
Thanks for your reply.
It works well on my side, in addition, I can select USB or UART to contact the MCU.
The attachment is my demo code and you can give it a try.
Have a great day,
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.
-------------------------------------------------------------------------------
Hi @jeremyzhou
I found the problem I was having. I was passing the value (BOOTLDR_CONF_ARG -> 0xeb100000) as a pointer, instead of passing a pointer to a variable containing this value (&arg).
This allows me to enter ISP mode in the FreeRTOS example too (you showed the Baremetal Hello World example).
For future readers, note that you need to use arg = 0xeb100000 if you would like to have the option of connecting with UART or USB for flashing (in the attached example code, 0xeb110000 is used). Also, please note that you cannot connect to the ROM via UART if you have the terminal connection open in MCUXpresso.
It would be great if the documentation (IMXRT1170RM) had used the updated name for ROM_RunBootloader(), and if it had included that you need to initialise the driver with ROM_API_Init() and which driver these functions are part of (fsl_romapi).
Anyway, thanks again for your help @jeremyzhou !