processor expert events.c

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 
已解决

processor expert events.c

跳至解决方案
1,566 次查看
dougpaulsen
Contributor IV

Greetings:

I'm using CW10.4 with Processor Expert and have questions regarding the way Processor Expert sets up interrupt functions in the generated module Events.c.  The automated setup works, but I don't see any function declarations of __interrupt void functionname(void), or the macro ISR(functionname).  The module Events.c has various xxxx_OnInterrupt() functions and those are properly referenced in the vector table, and they seem to work.  But shouldn't those functions which handle interrupts be declared as such?  I'm surprised Processor Expert doesn't do this since it seems to set up the interrupts and their ISRs otherwise.  Am I supposed to add the ISR declarations manually, or does the system somehow otherwise identify these functions as ISRs?  If I do manually declare the Events.c xxx_OnInterrupt() functions as such, the next time Processor Expert generates code, I creates wholly new ISRs - again with plain ol' vanilla void functionname(void) declarations.  Curious.... 

Thanks for any info

doug

标记 (1)
1 解答
1,451 次查看
dougpaulsen
Contributor IV

OK!  I figured it out.  

The addresses in the vector table are those of properly ISR-identified functions in various functions located the "Generated_Code" project directory.  Those functions in turn reference generic functions located in the Events.c module placed in the "Sources" directory.  Because of the code organization, my code happens to need to call additional function(s) from there, all of which is wholly confusing, but the important point is the first landing place after the vector table jump is properly IDed as an ISR.

I'm satisfied with this.  I've still got a critical race problem to deal with, but at least it's not the result of an absence of of ISRs.

Thanks!

doug

在原帖中查看解决方案

2 回复数
1,451 次查看
Carlos_Mendoza
NXP Employee
NXP Employee

Hi Doug,

Could you tell us which MCU are you using?

Thanks in advance!

Best Regards,
Carlos Mendoza
Technical Support Engineer

0 项奖励
回复
1,452 次查看
dougpaulsen
Contributor IV

OK!  I figured it out.  

The addresses in the vector table are those of properly ISR-identified functions in various functions located the "Generated_Code" project directory.  Those functions in turn reference generic functions located in the Events.c module placed in the "Sources" directory.  Because of the code organization, my code happens to need to call additional function(s) from there, all of which is wholly confusing, but the important point is the first landing place after the vector table jump is properly IDed as an ISR.

I'm satisfied with this.  I've still got a critical race problem to deal with, but at least it's not the result of an absence of of ISRs.

Thanks!

doug