Hi aggarg
I really appreciate your effort to support the customer.
You mentioned, you also reproduce the issues with the MIMXRT1050-EVKB and the Murata 1DX M.2 module + Murata uSD M.2 Adapter board, with the SDK2.8.2 evkbimxrt1050_aws_shadow_wiced, right?
Could you tell me detail reproduce? Just download and enter the debug mode, then the fault happens?
Before you download the code, could you please do the external flash mass erase at first, then download it again, whether you still can reproduce the issues or not? Please try it.
BTW, do you have the IAR IDE, do you try the IAR project, whether still the same issues or not?
Now, answer your original questions at first:
1. All the faults are in mflash_drv_write_page_internal function which disables interrupts at the beginning and as soon as it re-enables interrupts, there is a fault. Sometimes it a memfault and sometimes it is a bus error. Does it ring any bell?
Answer: The flash operation need to disable interrupt at first, to make sure the flash operation won't be interrupt. From your and the customer test result, seems related to this part. But the SDK original examples is tested before launch, seems some bug happens. So, I need to do more checking, if really has issues, I will also talk with our SDK team about these issues. I want to know, whether this issue is just in the MCUXPresso project or all other IDE the same project. Please give me more details to reproduce the issues, I will find time to test it on my side. Please erase all the external flash at first before the new project debugging.
2. I want to use Segger Ozone with Segger JLink probe and for that I need the ROM bootloader address. What is the address of the ROM bootloader? Is it 0x1C00_0000? I tried configuring Ozone to jump to that address but that does not seem to work.
Answer: I think you don't need to use the ROM bootloader, as this project is mainly run the flash API code, not the ROM code. The ROM will check the external 0X60000000 related data, eg, FCBD, if the code is valuable, it will jump to the related main code directly.
3. Is there anything extra (like removing/putting some jumpers) that I need to do to be able to use an external debug probe?
Answer: You can use the external JLINK debugger through the JTAG interface, you just need to remove the on board J32 J33, which will remove the on board CMSIS DAP debugger.
About your new updated post, you comment #ifndef XIP_EXTERNAL_FLASH , then the code will reconfigure the FlexSPI interface again instead of using the XIP hyperflash_config.
When you comment this, all the function still works without any issues? AWS still connect OK?
Please give me more testing details on your side, then I will try to reproduce the issue on my side and check with our internal related team.
Best Regards,
Kerry