Hello Champs,
Would you please help whether it's OK or not to insert a user-defined trap in an ISR which is set as HPI(High Priority Interrupt)? Since HPI uses a fast context switch and cannot be nested. Thanks!
Best Regards,
Linda
This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
Hello Champs,
Would you please help whether it's OK or not to insert a user-defined trap in an ISR which is set as HPI(High Priority Interrupt)? Since HPI uses a fast context switch and cannot be nested. Thanks!
Best Regards,
Linda
Hi Linda,
Thank you for your question, we will provide additional responses upon return from Thanksgiving US holiday.
For a potential initial answer, please note that PIE interrupts on modern C2000 C28x core devices like F2837x do not have a concept of "high priority" other than their hard-coded order so if you are not referring to PIE interrupts, please provide more context.
In the case of PIE interrupts, user-defined traps should be okay depending on the context, and PIE interrupts can indeed be software nested (please provide details if this is not what you are referring to).
Regards,
Vince
Hello Vince,
Thank you for your reply.
For HPI, it is referred to "High Priority Interrupt" setting which is described as below in Chapter 6.9.15 of C2000 compiler user's guide (www.ti.com/lit/spru514):
On the FPU, there are two kinds of interrupts - High Priority Interrupt (HPI) and Low Priority Interrupt (LPI). High priority interrupts use a fast context save and cannot be nested. Low priority interrupts behave like normal C28x interrupts and can be nested.
The kind of interrupt can be specified by way of the interrupt pragma using an optional second argument. The C syntax of the pragma is:
#pragma INTERRUPT ( func , {HPI|LPI} )
If a PIE interrupt is defined as HPI, because "High priority interrupts use a fast context save and cannot be nested", if there is still a user-defined trap in the ISR of this interrupt, will problem occur? That is to say, is the user-defined trap in an ISR treated as "nested" or "not nested"?
Would you please help again? Thanks!
Best Regards,
Linda
Hi Linda,
Thanks for the follow up. I will connect you with our FPU expert who can provide better support for this FPU question.
Regards,
Vince