The official Mbed 2 C/C++ SDK provides the software platform and libraries to build your applications.

Dependents:   hello SerialTestv11 SerialTestv12 Sierpinski ... more

mbed 2

This is the mbed 2 library. If you'd like to learn about Mbed OS please see the mbed-os docs.

Committer:
Anna Bridge
Date:
Fri Jun 22 15:38:59 2018 +0100
Revision:
169:a7c7b631e539
Parent:
109:9296ab0bfc11
mbed library. Release version 162

Who changed what in which revision?

UserRevisionLine numberNew contents of line
Kojto 109:9296ab0bfc11 1 /**
Kojto 109:9296ab0bfc11 2 ******************************************************************************
Kojto 109:9296ab0bfc11 3 * @file
Kojto 109:9296ab0bfc11 4 * @author
Kojto 109:9296ab0bfc11 5 * @version
Kojto 109:9296ab0bfc11 6 * @date
Kojto 109:9296ab0bfc11 7 * @brief This file contains all the functions prototypes for the GPIO
Kojto 109:9296ab0bfc11 8 * firmware library.
Kojto 109:9296ab0bfc11 9 ******************************************************************************
Kojto 109:9296ab0bfc11 10 *
Kojto 109:9296ab0bfc11 11 ******************************************************************************
Kojto 109:9296ab0bfc11 12 */
Kojto 109:9296ab0bfc11 13
Kojto 109:9296ab0bfc11 14 /* Define to prevent recursive inclusion -------------------------------------*/
Kojto 109:9296ab0bfc11 15 #ifndef __W7500X_EXTI_H
Kojto 109:9296ab0bfc11 16 #define __W7500X_EXTI_H
Kojto 109:9296ab0bfc11 17
Kojto 109:9296ab0bfc11 18 #ifdef __cplusplus
Kojto 109:9296ab0bfc11 19 extern "C" {
Kojto 109:9296ab0bfc11 20 #endif
Kojto 109:9296ab0bfc11 21
Kojto 109:9296ab0bfc11 22 /* Includes ------------------------------------------------------------------*/
Kojto 109:9296ab0bfc11 23 #include "W7500x.h"
Kojto 109:9296ab0bfc11 24
Kojto 109:9296ab0bfc11 25
Kojto 109:9296ab0bfc11 26 /**
Kojto 109:9296ab0bfc11 27 * @brief EXTI mode enumeration
Kojto 109:9296ab0bfc11 28 */
Kojto 109:9296ab0bfc11 29
Kojto 109:9296ab0bfc11 30 typedef enum
Kojto 109:9296ab0bfc11 31 {
Kojto 109:9296ab0bfc11 32 EXTI_Mode_Disable = 0x00,
Kojto 109:9296ab0bfc11 33 EXTI_Mode_Interrupt = 0x02
Kojto 109:9296ab0bfc11 34 }EXTIMode_TypeDef;
Kojto 109:9296ab0bfc11 35
Kojto 109:9296ab0bfc11 36 #define IS_EXTI_MODE(MODE) (((MODE) == EXTI_Mode_Rising) || \
Kojto 109:9296ab0bfc11 37 ((MODE) == EXTI_Mode_Interrupt))
Kojto 109:9296ab0bfc11 38
Kojto 109:9296ab0bfc11 39 /**
Kojto 109:9296ab0bfc11 40 * @brief EXTI Trigger enumeration
Kojto 109:9296ab0bfc11 41 */
Kojto 109:9296ab0bfc11 42
Kojto 109:9296ab0bfc11 43 typedef enum
Kojto 109:9296ab0bfc11 44 {
Kojto 109:9296ab0bfc11 45 EXTI_Trigger_Rising = 0x00,
Kojto 109:9296ab0bfc11 46 EXTI_Trigger_Falling = 0x01
Kojto 109:9296ab0bfc11 47 }EXTITrigger_TypeDef;
Kojto 109:9296ab0bfc11 48
Kojto 109:9296ab0bfc11 49 #define IS_EXTI_TRIGGER(TRIGGER) (((TRIGGER) == EXTI_Trigger_Rising) || \
Kojto 109:9296ab0bfc11 50 ((TRIGGER) == EXTI_Trigger_Falling))
Kojto 109:9296ab0bfc11 51
Kojto 109:9296ab0bfc11 52 /**
Kojto 109:9296ab0bfc11 53 * @brief EXTI Init Structure definition
Kojto 109:9296ab0bfc11 54 */
Kojto 109:9296ab0bfc11 55
Kojto 109:9296ab0bfc11 56 typedef struct
Kojto 109:9296ab0bfc11 57 {
Kojto 109:9296ab0bfc11 58 uint32_t EXTI_Line; /*!< Specifies the EXTI lines to be enabled or disabled.
Kojto 109:9296ab0bfc11 59 This parameter can be any combination of @ref EXTI_Lines */
Kojto 109:9296ab0bfc11 60
Kojto 109:9296ab0bfc11 61 EXTIMode_TypeDef EXTI_Mode; /*!< Specifies the mode for the EXTI lines.This parameter can be a value of @ref EXTIMode_TypeDef */
Kojto 109:9296ab0bfc11 62
Kojto 109:9296ab0bfc11 63 EXTITrigger_TypeDef EXTI_Trigger; /*!< Specifies the trigger signal active edge for the EXTI lines.
Kojto 109:9296ab0bfc11 64 This parameter can be a value of @ref EXTIMode_TypeDef */
Kojto 109:9296ab0bfc11 65
Kojto 109:9296ab0bfc11 66 }EXTI_InitTypeDef;
Kojto 109:9296ab0bfc11 67
Kojto 109:9296ab0bfc11 68 /**
Kojto 109:9296ab0bfc11 69 * @}
Kojto 109:9296ab0bfc11 70 */
Kojto 109:9296ab0bfc11 71
Kojto 109:9296ab0bfc11 72 void EXTI_DeInit(void);
Kojto 109:9296ab0bfc11 73 void EXTI_Init(PAD_Type Px, EXTI_InitTypeDef* EXTI_InitStruct);
Kojto 109:9296ab0bfc11 74 void EXTI_Polarity_Set(PAD_Type Px, uint16_t GPIO_Pin, uint16_t Polarity );
Kojto 109:9296ab0bfc11 75 void EXTI_StructInit(EXTI_InitTypeDef* EXTI_InitStruct);
Kojto 109:9296ab0bfc11 76 uint32_t EXTI_GetEXTIConfig(PAD_Type Px, uint16_t GPIO_Pin);
Kojto 109:9296ab0bfc11 77 uint16_t EXTI_Px_GetEXTEN(PAD_Type Px);
Kojto 109:9296ab0bfc11 78 uint16_t EXTI_Px_GetEXTINTPOL(PAD_Type Px);
Kojto 109:9296ab0bfc11 79
Kojto 109:9296ab0bfc11 80
Kojto 109:9296ab0bfc11 81 #ifdef __cplusplus
Kojto 109:9296ab0bfc11 82 }
Kojto 109:9296ab0bfc11 83 #endif
Kojto 109:9296ab0bfc11 84
Kojto 109:9296ab0bfc11 85
Kojto 109:9296ab0bfc11 86 #endif //__W7500X_EXTI_H