How to change interrupt vector?

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

How to change interrupt vector?

ソリューションへジャンプ
3,022件の閲覧回数
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

ラベル(1)
0 件の賞賛
返信
1 解決策
2,064件の閲覧回数
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 件の賞賛
返信
3 返答(返信)
2,065件の閲覧回数
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 件の賞賛
返信
2,064件の閲覧回数
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 件の賞賛
返信
2,064件の閲覧回数
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