How to change interrupt vector?

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

How to change interrupt vector?

Jump to solution
2,863 Views
enzino
Contributor II

I Had configured and initialized my K60 microcontroller using Processor Expert.

Now I need to change some elements "manually" in the file "vectors.c", for example to use another function for some interrupt.

How should I do? Obviously I wanna avoid to manually write my functions in vectors.c because at a new Code generation the PE will overwrite my changes.

Thank you

Labels (1)
0 Kudos
Reply
1 Solution
1,905 Views
ProcessorExpert
Senior Contributor III

Hello,

in CW V10.3, there will be available InterruptVector component to provide such functionality (including possibility to handling reserved vectors). Unfortunately it is not available in CW V10.2.

As workaround you have to modify the Vectors.c manually. To avoid regeneration of this file, please set it as read-only.

Note:

Making vectors.c read only will cause problems when another component using interrupt will be added and code re-generated. In this case the read-only flag must be removed, Vectors.c regenerated and the manual modification added back.

best regards

Vojtech Filip

Processor Expert Support Team


View solution in original post

0 Kudos
Reply
3 Replies
1,906 Views
ProcessorExpert
Senior Contributor III

Hello,

in CW V10.3, there will be available InterruptVector component to provide such functionality (including possibility to handling reserved vectors). Unfortunately it is not available in CW V10.2.

As workaround you have to modify the Vectors.c manually. To avoid regeneration of this file, please set it as read-only.

Note:

Making vectors.c read only will cause problems when another component using interrupt will be added and code re-generated. In this case the read-only flag must be removed, Vectors.c regenerated and the manual modification added back.

best regards

Vojtech Filip

Processor Expert Support Team


0 Kudos
Reply
1,905 Views
enzino
Contributor II

Thank you.

I've just walked on this way...

I saw an option in "Processor expert project options", it is  "Generate ISR", now it's "NO".

What about this option? It is not involved with my question, isn't it?

0 Kudos
Reply
1,905 Views
ProcessorExpert
Senior Contributor III

Hello,

"Generate ISR" feature is intended for Initialization components. In case you select yes and enter a ISR name into some init. component, such ISR will be generated into Events.c otherwise it is users responsibility to create the ISR.

best regards

Vojtech Filip

Processor Expert Support Team