GPIO Interrupt Handler

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

GPIO Interrupt Handler

1,048 次查看
kesanli_cinci
Contributor I

Hello, 

I configured a GPIO as an interrupt and wrote a callback function for this GPIO. 

At the end of the callback function, interrupt flag is cleared. Inside this callback function, a task is notified. Before jumping to the task, interrupt flag is cleared at the the end of the callback function. 

However, I use this GPIO's status (HIGH, LOW) in order to read some registers in the task. Because I clear interrupt, I am not able to read this pin as HIGH. Operating system is FreeRTOS. That's why, I can not put this read operation inside Callback function because I use SPI_send function in this read operation.

 

How can I make read operation without clearing the interrupt flag? 

 

 

 

 

0 项奖励
回复
1 回复

1,025 次查看
PetrS
NXP TechSupport
NXP TechSupport

Hi,

could you please describe your intention in more details, maybe share piece of code you have?
Also what S32K1 device and RTD version is used in fact?
You should be able to read pin status/level at any time using Gpio_Dio_Ip_ReadPin function.
 
BR, Petr
0 项奖励
回复