Hi All,
We are using MIMXRT1052 custom board and trying to configure the flexram(DTCM = 256K, ITCM = 128K, OCRAM = 128k) in startup file with below changes
__irq __stackless __noreturn void StartUp(void)
{
// Exception for rule no. BARR-C:2018 Rule 7.1c and BARR-C:2018 Rule 7.1j.
extern pfInterruptVectorTableEntry_t __vector_table[]; // Vector table defined in startup code
#if FLEXRAM_TO_CONFIG
// Disable interrupts
__disable_interrupt();
__DSB();
__ISB();
// Set FlexRAM banks configuration
IOMUXC_GPR->GPR17 = MEM_RAM_BANK_CFG;
#if (MEM_RAM_DTCM_SIZE_GPR14_VALUE != 0U)
// Set DTCM memory size
IOMUXC_GPR->GPR14 &= ~IOMUXC_GPR_GPR14_CM7_CFGDTCMSZ_MASK;
IOMUXC_GPR->GPR14 |= IOMUXC_GPR_GPR14_CM7_CFGDTCMSZ(MEM_RAM_DTCM_SIZE_GPR14_VALUE);
// Enable DTCM
IOMUXC_GPR->GPR16 |= IOMUXC_GPR_GPR16_INIT_DTCM_EN_MASK;
#else
// Disable DTCM
IOMUXC_GPR->GPR16 &= ~IOMUXC_GPR_GPR16_INIT_DTCM_EN_MASK;
#endif
#if (MEM_RAM_ITCM_SIZE_GPR14_VALUE != 0U)
// Set ITCM memory size
IOMUXC_GPR->GPR14 &= ~IOMUXC_GPR_GPR14_CM7_CFGITCMSZ_MASK;
IOMUXC_GPR->GPR14 |= IOMUXC_GPR_GPR14_CM7_CFGITCMSZ(MEM_RAM_ITCM_SIZE_GPR14_VALUE);
// Enable ITCM
IOMUXC_GPR->GPR16 |= IOMUXC_GPR_GPR16_INIT_ITCM_EN_MASK;
#else
// Disable ITCM
IOMUXC_GPR->GPR16 &= ~IOMUXC_GPR_GPR16_INIT_ITCM_EN_MASK;
#endif
// Enable FlexRAM configuration from registers instead of fuse
IOMUXC_GPR->GPR16 &= ~IOMUXC_GPR_GPR16_FLEXRAM_BANK_CFG_SEL_MASK;
IOMUXC_GPR->GPR16 |= IOMUXC_GPR_GPR16_FLEXRAM_BANK_CFG_SEL(1u);
// Enable interrupts
// __enable_interrupt();
// __DSB();
// __ISB();
#endif
For first time after powered up board it is entering to the main but after that if we try to reset the debugged program then it enters in to the unknown location .
Please if any one is having any idea let us know.
Thanks in advance.
Regards,
Shriram
Hi,
Thank you for your interest in NXP Semiconductor products and for the opportunity to serve you.
To be prudent, I was wondering if you can introduce your testing environment, such as IDE, debug tool, demo code, board, etc.
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 ,
We are using the eclipse environment with IAR 8.42 toolchain and using MIMXRT1052 custom board with Quad flash loader. and using the ncache linker file to build.
Please be informed if any more information required.
Thanks and Regards,
Shriram Madhavai
Hi,
Thanks for your reply.
Can you replicate the phenomenon with the MIMXRT1050 EVK board and demo that comes from the SDK library?
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.
-------------------------------------------------------------------------------