K60 Interrupt Issue

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

K60 Interrupt Issue

2,321件の閲覧回数
WickedOwl
Contributor I

Hi all,

 

I am working with the TWR-K60N512 and running Codewarrior 10 with Processor Expert. I am trying to do basic SPI initialization using the Init_SPI feature of Processor Expert, but at runtime the code enters the PE_ISR() interrupt service routine immediately after running this line within the generated SPI3.c:

 

SPI0_MCR = (uint32_t)0x0C01UL;

 

I'm having a hard time finding relevant documentation that explains why this interrupt service routine is being called and what specifically about the generated SPI code (that I haven't modified) is causing this to happen.

 

Thanks for any help and I apologize if I am missing something obvious.

0 件の賞賛
3 返答(返信)

1,347件の閲覧回数
ProcessorExpert
Senior Contributor III

Hello,

 

could you please post here the project that leads you to getting the problem? Please also provide CHIP mask of your MCU.

 

best regards
Vojtech Filip
Processor Expert Support Team

 

 

0 件の賞賛

1,347件の閲覧回数
ProcessorExpert
Senior Contributor III

 

Hello,

 

the problem also might be that you have not enabled clock gate. For more details please see enclosed screen-shot.

 

best regards
Vojtech Filip
Processor Expert Support Team

0 件の賞賛

1,347件の閲覧回数
WickedOwl
Contributor I

It was indeed the clock gate not being enabled. I am now able to run through the entirety of the SPI initialization code. Thanks very much for your response.

0 件の賞賛