LoginSignup
0
0

More than 5 years have passed since last update.

Zybo > Chronicles blog 13 > GPIO > interrupt > トリガタイプの設定 > XGpioPs_SetIntrTypePin() > エッジトリガ / レベルトリガ

Last updated at Posted at 2016-05-15

MicroZed Chronicles リスト http://adiuvoengineering.com/?page_id=285
@ Adam Taylor blog
https://forums.xilinx.com/t5/Xcell-Daily-Blog/More-About-MicroZed-Interrupts-Adam-Taylor-s-MicroZed-Chronicles/ba-p/398357

We also need to configure the interrupt correctly: edge triggered or level triggered and which edge or level? We configure the interrupt using this function:

void XGpioPs_SetIntrTypePin(XGpioPs *InstancePtr, int Pin, u8 IrqType);

Where the IrqType is defined by one of the five definitions within the xgpiops.h file:

#define XGPIOPS_IRQ_TYPE_EDGE_RISING 0      /**< Interrupt on Rising edge */
#define XGPIOPS_IRQ_TYPE_EDGE_FALLING 1   /**< Interrupt Falling edge */
#define XGPIOPS_IRQ_TYPE_EDGE_BOTH 2        /**< Interrupt on both edges */
#define XGPIOPS_IRQ_TYPE_LEVEL_HIGH 3        /**< Interrupt on high level */
#define XGPIOPS_IRQ_TYPE_LEVEL_LOW 4         /**< Interrupt on low level */
0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0