Important Notice: Our web hosting provider recently started charging us for additional visits, which was unexpected. In response, we're seeking donations. Depending on the situation, we may explore different monetization options for our Community and Expert Contributors. It's crucial to provide more returns for their expertise and offer more Expert Validated Answers or AI Validated Answers. Learn more about our hosting issue here.

What could cause interrupts to reset the device or jump to incorrect addresses when using extended memory?

0
Posted

What could cause interrupts to reset the device or jump to incorrect addresses when using extended memory?

0

In CCE v3 interrupt code needs to be placed in lower Flash memory for interrupt to function correctly. If it is not in lower Flash memory, unexpected resets/hangs may occur. The reason for this is that interrupt vectors have only 16 bits available hence only the lower 16 bits of these addresses are saved as interrupt vector. If the interrupt routine is in upper Flash memory, only the lower 16 bits of the address is taken and the device jumps to the wrong address. The compiler tools in CCE v3 do not force the interrupt routines into low memory. So when code exceeds 64k the linker is free to allocate to upper Flash. If you are running into unexpected resets/hangs, you can confirm if this is the cause of your issue by generating a link map file and looking at whether the code (.text) sections for the interrupt functions are being placed in upper Flash memory.

Related Questions

What is your question?

*Sadly, we had to bring back ads too. Hopefully more targeted.

Experts123