PAN1080 Peripheral API
|
Panchip series gpio driver header file. More...
#include <stdint.h>
Go to the source code of this file.
Macros | |
#define | GPIO_PIN_MAX 8 |
#define | GPIO_PIN_ADDR(Port, Pin) (*((volatile uint32_t *)((GPIOBIT0_BASE+(0x20*(Port))) + ((Pin)<<2)))) |
Define gpio pin Data input/output. It could be used to control each . More... | |
#define | P00 GPIO_PIN_ADDR(0, 0) |
#define | P01 GPIO_PIN_ADDR(0, 1) |
#define | P02 GPIO_PIN_ADDR(0, 2) |
#define | P03 GPIO_PIN_ADDR(0, 3) |
#define | P04 GPIO_PIN_ADDR(0, 4) |
#define | P05 GPIO_PIN_ADDR(0, 5) |
#define | P06 GPIO_PIN_ADDR(0, 6) |
#define | P07 GPIO_PIN_ADDR(0, 7) |
#define | P10 GPIO_PIN_ADDR(1, 0) |
#define | P11 GPIO_PIN_ADDR(1, 1) |
#define | P12 GPIO_PIN_ADDR(1, 2) |
#define | P13 GPIO_PIN_ADDR(1, 3) |
#define | P14 GPIO_PIN_ADDR(1, 4) |
#define | P15 GPIO_PIN_ADDR(1, 5) |
#define | P16 GPIO_PIN_ADDR(1, 6) |
#define | P17 GPIO_PIN_ADDR(1, 7) |
#define | P20 GPIO_PIN_ADDR(2, 0) |
#define | P21 GPIO_PIN_ADDR(2, 1) |
#define | P22 GPIO_PIN_ADDR(2, 2) |
#define | P23 GPIO_PIN_ADDR(2, 3) |
#define | P24 GPIO_PIN_ADDR(2, 4) |
#define | P25 GPIO_PIN_ADDR(2, 5) |
#define | P26 GPIO_PIN_ADDR(2, 6) |
#define | P27 GPIO_PIN_ADDR(2, 7) |
#define | P30 GPIO_PIN_ADDR(3, 0) |
#define | P31 GPIO_PIN_ADDR(3, 1) |
#define | P32 GPIO_PIN_ADDR(3, 2) |
#define | P33 GPIO_PIN_ADDR(3, 3) |
#define | P34 GPIO_PIN_ADDR(3, 4) |
#define | P35 GPIO_PIN_ADDR(3, 5) |
#define | P36 GPIO_PIN_ADDR(3, 6) |
#define | P37 GPIO_PIN_ADDR(3, 7) |
#define | P40 GPIO_PIN_ADDR(4, 0) |
#define | P41 GPIO_PIN_ADDR(4, 1) |
#define | P42 GPIO_PIN_ADDR(4, 2) |
#define | P43 GPIO_PIN_ADDR(4, 3) |
#define | P44 GPIO_PIN_ADDR(4, 4) |
#define | P45 GPIO_PIN_ADDR(4, 5) |
#define | P46 GPIO_PIN_ADDR(4, 6) |
#define | P47 GPIO_PIN_ADDR(4, 7) |
#define | P50 GPIO_PIN_ADDR(5, 0) |
#define | P51 GPIO_PIN_ADDR(5, 1) |
#define | P52 GPIO_PIN_ADDR(5, 2) |
#define | P53 GPIO_PIN_ADDR(5, 3) |
#define | P54 GPIO_PIN_ADDR(5, 4) |
#define | P55 GPIO_PIN_ADDR(5, 5) |
#define | P56 GPIO_PIN_ADDR(5, 6) |
#define | P57 GPIO_PIN_ADDR(5, 7) |
#define | GPIO_EnableEINT0 GPIO_EnableInt |
Enable External GPIO interrupt 0. More... | |
#define | GPIO_DisableEINT0 GPIO_DisableInt |
Disable External GPIO interrupt 0. More... | |
#define | GPIO_EnableEINT1 GPIO_EnableInt |
Enable External GPIO interrupt 1. More... | |
#define | GPIO_DisableEINT1 GPIO_DisableInt |
Disable External GPIO interrupt 1. More... | |
Typedefs | |
typedef enum _GPIO_ModeDef | GPIO_ModeDef |
typedef enum _GPIO_IntAttrDef | GPIO_IntAttrDef |
typedef enum _GPIO_ClkSrcDef | GPIO_ClkSrcDef |
typedef enum _GPIO_ClkSelDef | GPIO_ClkSelDef |
Functions | |
__STATIC_INLINE void | GPIO_ClrIntFlag (GPIO_T *gpio, uint32_t PinMask) |
Clear GPIO Pin Interrupt Flag. More... | |
__STATIC_INLINE void | GPIO_ClrAllIntFlag (GPIO_T *gpio) |
Clear GPIO Pin Interrupt Flag. More... | |
__STATIC_INLINE void | GPIO_DisableDebounce (GPIO_T *gpio, uint32_t PinMask) |
Disable Pin De-bounce Function. More... | |
__STATIC_INLINE void | GPIO_EnableDebounce (GPIO_T *gpio, uint32_t PinMask) |
Enable Pin De-bounce Function. More... | |
__STATIC_INLINE void | GPIO_DisableDigitalPath (GPIO_T *gpio, uint32_t PinMask) |
Disable I/O Digital Input Path. More... | |
__STATIC_INLINE void | GPIO_EnableDigitalPath (GPIO_T *gpio, uint32_t PinMask) |
Enable I/O Digital Input Path. More... | |
__STATIC_INLINE void | GPIO_DisablePullupPath (GPIO_T *gpio, uint32_t PinMask) |
Disable I/O Digital pull up Path. More... | |
__STATIC_INLINE void | GPIO_EnablePullupPath (GPIO_T *gpio, uint32_t PinMask) |
Enable I/O Digital pull up Path. More... | |
__STATIC_INLINE void | GPIO_DisablePulldownPath (GPIO_T *gpio, uint32_t PinMask) |
Disable I/O Digital pull down Path. More... | |
__STATIC_INLINE void | GPIO_EnablePulldownPath (GPIO_T *gpio, uint32_t PinMask) |
Enable I/O Digital pull down Path. More... | |
__STATIC_INLINE void | GPIO_DisableDoutMask (GPIO_T *gpio, uint32_t PinMask) |
Disable I/O DOUT mask. More... | |
__STATIC_INLINE void | GPIO_EnableDoutMask (GPIO_T *gpio, uint32_t PinMask) |
Enable I/O DOUT mask. More... | |
__STATIC_INLINE bool | GPIO_GetIntFlag (GPIO_T *gpio, uint32_t PinMask) |
Get GPIO Pin Interrupt Flag. More... | |
__STATIC_INLINE void | GPIO_SetDebounceTime (GPIO_ClkSrcDef ClkSrc, GPIO_ClkSelDef ClkSel) |
Set De-bounce Sampling Cycle Time. More... | |
__STATIC_INLINE uint32_t | GPIO_GetInData (GPIO_T *gpio) |
Get GPIO Port IN Data. More... | |
__STATIC_INLINE void | GPIO_SetOutData (GPIO_T *gpio, uint32_t data) |
Set GPIO Port OUT Data. More... | |
__STATIC_INLINE uint32_t | GPIO_GetOutData (GPIO_T *gpio) |
Get GPIO Port OUT Data. More... | |
__STATIC_INLINE void | GPIO_Toggle (GPIO_T *gpio, uint32_t u32PinMask) |
Toggle Specified GPIO pin. More... | |
__STATIC_INLINE void | GPIO_TogglePin (uint32_t u32Pin) |
Toggle Specified GPIO pin. More... | |
__STATIC_INLINE void | GPIO_EnableInt (GPIO_T *gpio, uint32_t Pin, GPIO_IntAttrDef IntAttribs) |
Enable GPIO interrupt. More... | |
__STATIC_INLINE void | GPIO_DisableInt (GPIO_T *gpio, uint32_t Pin) |
Disable GPIO interrupt. More... | |
void | GPIO_SetMode (GPIO_T *gpio, uint32_t PinMask, GPIO_ModeDef Mode) |
Set GPIO Work Mode. More... | |
Panchip series gpio driver header file.