Flash Operation Error On Dual Core Application

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

Flash Operation Error On Dual Core Application

Jump to solution
1,207 Views
SpeedyGonzalesss
Contributor III

Hello,

I am using i.mx RT1176 mcu and mcuxpresso ide.

In my application, xip is active. In the project where the M7 processor is the master, when the M4 processor wants to erase and then write to an area in the external nor flash (the M7 processor does not perform any read/write/erase operations to this area), the M7 processor crashes and resets. Before starting the flash operations, the M4 processor makes a request to the M7 processor that it will start operations via MU and then does not perform any operations until it receives a response. Why might I be encountering this problem? How can I prevent this problem in this scenario?

Best Regards,

0 Kudos
Reply
1 Solution
582 Views
SpeedyGonzalesss
Contributor III
I had to move the IVT block before copying it to RAM. This is how I was able to do it. Thank you

View solution in original post

0 Kudos
Reply
6 Replies
1,183 Views
Habib_MS
NXP Employee
NXP Employee

Hello @SpeedyGonzalesss,
In the case that you are currently using XIP mode you cannot Read/write the same FLASH, this because the XIP needs to obtain the next instruction from the flash where is continuously taking the bus. For this reason, if the cortex M4 wants to take this bus will be a coalition

BR
Habib.

0 Kudos
Reply
1,151 Views
SpeedyGonzalesss
Contributor III

Hello @Habib_MS ,

I tried to make XIP mode offline for testing. But I am having problems. I change the following values ​​from 1 to 0

XIP_BOOT_HEADER_DCD_ENABLE

XIP_BOOT_HEADER_ENABLE

After these changes, the treasures are as follows:

SpeedyGonzalesss_0-1736322549825.png

 

After this, i activated the "Link application to RAM" option:

SpeedyGonzalesss_1-1736322549777.png

 

I make these changes in the M4 project, compile and flash, but I cannot run the code. What could be the problem?

0 Kudos
Reply
1,137 Views
Habib_MS
NXP Employee
NXP Employee

Hello @SpeedyGonzalesss,
In order to support you better, can you provide me the example where you are making the changes?

Also, in the SDK (version 2.16) example called "hello_world_cm4" the code was linked in RAM, as shown in the window called "image info":

Habib_MS_0-1736372467027.png

In this example the cortex M7 project is currently using XIP, this is the project that must be linked to RAM with the purpose of freeing the bus to read/write the FLASH.
I highly recommend see this example that could be helpful.
BR
Habib

0 Kudos
Reply
1,116 Views
SpeedyGonzalesss
Contributor III

Hello,

I use my custom project. In my project, M4 runs in RAM while M7 uses XIP. Before making the changes I mentioned above, after compiling the project, 1 percent of the flash was shown to be used, but after making the changes, Flash is not shown to be used.

Best Regards,

0 Kudos
Reply
1,078 Views
Habib_MS
NXP Employee
NXP Employee

Hello again @SpeedyGonzalesss,
If you link the Cortex M7 to RAM, can you read/write the FLASH?
BR
Habib.

0 Kudos
Reply
583 Views
SpeedyGonzalesss
Contributor III
I had to move the IVT block before copying it to RAM. This is how I was able to do it. Thank you
0 Kudos
Reply