#define CY_GPIO_DM_ANALOG (0x00ul) /**< \brief Analog High-Z. Input buffer off */ #define CY_GPIO_DM_PULLUP_IN_OFF (0x02ul) /**< \brief Resistive Pull-Up. Input buffer off */ #define CY_GPIO_DM_PULLDOWN_IN_OFF (0x03ul) /**< \brief Resistive Pull-Down. Input buffer off */ #define CY_GPIO_DM_OD_DRIVESLOW_IN_OFF (0x04ul) /**< \brief Open Drain, Drives Low. Input buffer off */ #define CY_GPIO_DM_OD_DRIVESHIGH_IN_OFF (0x05ul) /**< \brief Open Drain, Drives High. Input buffer off */ #define CY_GPIO_DM_STRONG_IN_OFF (0x06ul) /**< \brief Strong Drive. Input buffer off */ #define CY_GPIO_DM_PULLUP_DOWN_IN_OFF (0x07ul) /**< \brief Resistive Pull-Up/Down. Input buffer off */ #define CY_GPIO_DM_HIGHZ (0x08ul) /**< \brief Digital High-Z. Input buffer on */ #define CY_GPIO_DM_PULLUP (0x0Aul) /**< \brief Resistive Pull-Up. Input buffer on */ #define CY_GPIO_DM_PULLDOWN (0x0Bul) /**< \brief Resistive Pull-Down. Input buffer on */ #define CY_GPIO_DM_OD_DRIVESLOW (0x0Cul) /**< \brief Open Drain, Drives Low. Input buffer on */ #define CY_GPIO_DM_OD_DRIVESHIGH (0x0Dul) /**< \brief Open Drain, Drives High. Input buffer on */ #define CY_GPIO_DM_STRONG (0x0Eul) /**< \brief Strong Drive. Input buffer on */ #define CY_GPIO_DM_PULLUP_DOWN (0x0Ful) /**< \brief Resistive Pull-Up/Down. Input buffer on */
时间: 2024-03-29 07:34:32 浏览: 187
这段代码定义了Cypress PSoC芯片的GPIO模式常量,每个常量对应一个GPIO模式。GPIO模式用于控制GPIO的输入/输出电路和驱动能力。常量名称中的后缀 "_IN_OFF" 表示该模式下输入缓冲关闭,而 "_IN_ON" 则表示输入缓冲打开。常量名称中的前缀表示模式的特性,例如 "PULLUP" 表示上拉电阻,"OD" 表示开漏输出。常量的值是32位无符号整数。
阅读全文