From b2b85afbf933c23849584b2c391e46986020b189 Mon Sep 17 00:00:00 2001 From: edolomb Date: Wed, 10 Jan 2018 16:48:28 +0000 Subject: Added INTERRUPT SOURCE TYPE mode macros git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@11252 35acf78f-673a-0410-8e92-d51de3d6d3f4 --- os/hal/ports/SAMA/SAMA5D2x/aic.h | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) (limited to 'os/hal/ports/SAMA') diff --git a/os/hal/ports/SAMA/SAMA5D2x/aic.h b/os/hal/ports/SAMA/SAMA5D2x/aic.h index 47b8ec173..73f9888c1 100644 --- a/os/hal/ports/SAMA/SAMA5D2x/aic.h +++ b/os/hal/ports/SAMA/SAMA5D2x/aic.h @@ -28,6 +28,32 @@ /*===========================================================================*/ /* Driver constants. */ /*===========================================================================*/ +/** + * @name INTERRUPT SOURCE TYPE mode macros + * @{ + */ +/** + * @brief High-level sensitive for internal source. + * Low-level sensitive for external source. + */ +#define INT_LEVEL_SENSITIVE 0x0U + +/** + * @brief Negative-edge triggered for external source. + */ +#define EXT_NEGATIVE_EDGE 0x1U + +/** + * @brief High-level sensitive for internal source. + * High-level sensitive for external source. + */ +#define EXT_HIGH_LEVEL 0x2U + +/** + * @brief Positive-edge triggered for external source. + */ +#define EXT_POSITIVE_EDGE 0x3U +/** @} */ /** * @brief AIC unique redirect key. @@ -72,6 +98,7 @@ extern "C" { #endif void aicInit(void); void aicSetSourcePriority(uint32_t source, uint8_t priority); + void aicSetIntSourceType(uint32_t source, uint8_t type); void aicSetSourceHandler(uint32_t source, bool (*handler)(void)); void aicSetSpuriousHandler(bool (*handler)(void)); void aicEnableInt(uint32_t source); -- cgit v1.2.3