GPIO Interrupt Priorities on LPC1343

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

GPIO Interrupt Priorities on LPC1343

986件の閲覧回数
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by ub3r on Sun Feb 12 04:47:48 MST 2012
Hi Guys,
I currently have a radio RX servo pulse signal going to Port2, pin 1.
Im reading the pulse length using timer0 on the rising and falling edges.

I have other interrupts happening as well, however the servo timing is critical. How can i set its prioroty to the highest level.

Ive tried this:
NVIC_SetPriority(EINT2_IRQn, 3);

However i still get random timing happening when other interrupts are active.

cheers
0 件の賞賛
返信
2 返答(返信)

951件の閲覧回数
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Rob65 on Mon Feb 13 13:05:00 MST 2012
What about using a timer with a capture register for this?

this will give you a very accurate timing.

Rob
0 件の賞賛
返信

951件の閲覧回数
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Ex-Zero on Sun Feb 12 05:08:49 MST 2012

Quote: ub3r
Ive tried this:
NVIC_SetPriority(EINT2_IRQn, 3);
However i still get random timing happening when other interrupts are active.



#1 That's the right way, high priority = low priority value :rolleyes:

#2 What about priority of other interrupts?

#3 Are your problems disappearing without other interrupts?

#4 Are your ISRs short enough?

#5 Did you try to use optimization to shorten your code (especially ISRs)?
0 件の賞賛
返信