GPIO_ENABLE_INTERRUPT_PARAMETERS structure (gpioclx.h)
The GPIO_ENABLE_INTERRUPT_PARAMETERS structure specifies a general-purpose I/O (GPIO) pin and describes the interrupt attributes of this pin.
Syntax
typedef struct _GPIO_ENABLE_INTERRUPT_PARAMETERS {
BANK_ID BankId;
PIN_NUMBER PinNumber;
GPIO_ENABLE_INTERRUPT_FLAGS Flags;
KINTERRUPT_MODE InterruptMode;
KINTERRUPT_POLARITY Polarity;
UCHAR PullConfiguration;
USHORT DebounceTimeout;
PVOID VendorData;
ULONG VendorDataLength;
} GPIO_ENABLE_INTERRUPT_PARAMETERS, *PGPIO_ENABLE_INTERRUPT_PARAMETERS;
Members
BankId
The identifier for the bank that contains the GPIO pin. If M is the number of banks in the GPIO controller, BankId is an integer in the range 0 to M–1. The GPIO framework extension (GpioClx) previously obtained the number of banks in the controller from the CLIENT_QueryControllerBasicInformation event callback function. For more information, see Remarks in CLIENT_CONTROLLER_BASIC_INFORMATION.
PinNumber
The bank-relative pin number. If N is the number pins in this bank, PinNumber is an integer in the range 0 to N–1. GpioClx previously obtained the number of pins in each bank from the CLIENT_QueryControllerBasicInformation event callback function. For more information, see the description of the NumberOfPinsPerBank member in CLIENT_CONTROLLER_BASIC_INFORMATION.
Flags
A set of flags that control the configuration of the GPIO pins. No flags are currently defined for this member.
InterruptMode
Whether the interrupt request from this GPIO pin is level-sensitive or edge-triggered. This member is set to one of the following values:
LevelSensitive
Latched
For more information, see KINTERRUPT_MODE.
Polarity
Whether the interrupt line from this GPIO pin is active-high or active-low. This member is set to one of the following values:
InterruptActiveHigh
InterruptRisingEdge
InterruptActiveLow
InterruptFallingEdge
InterruptActiveBoth
For more information, see KINTERRUPT_POLARITY.
PullConfiguration
Whether this GPIO pin is pulled up or pulled down. This member is typically set to one of the following system-defined constants:
GPIO_PIN_PULL_CONFIGURATION_PULLDEFAULT
GPIO_PIN_PULL_CONFIGURATION_PULLUP
GPIO_PIN_PULL_CONFIGURATION_PULLDOWN
GPIO_PIN_PULL_CONFIGURATION_PULLNONE
If none of these constants appropriately describes the pin configuration, this member can be set to a vendor-defined constant in the range 128-255. For more information about these constants, see GPIO_PIN_PULL_CONFIGURATION.
DebounceTimeout
The debounce time in units of 10 microseconds. For example, a debounce time of 5.84 milliseconds is specified as 584. The debounce time is the time required for an input signal to stabilize at a high level after the start of a low-to-high transition, or at a low level after the start of a high-to-low transition. For example, if an interrupt signal is generated by a mechanical switch, the debounce time is the time required for the metal contact in the switch to stop bouncing after the switch is turned on or off.
VendorData
A pointer to a caller-allocated buffer that contains vendor-defined data for this GPIO pin. This member is optional and is set to NULL if no vendor-defined data is available. For more information about vendor-defined data, see the description of the GPIO connection descriptor in the ACPI 5.0 specification.
VendorDataLength
The size, in bytes, of the data buffer that is pointed to by the VendorData member.
Remarks
The CLIENT_EnableInterrupt and CLIENT_UnmaskInterrupt event callback functions use a GPIO_ENABLE_INTERRUPT_PARAMETERS structure to specify a GPIO pin and to describe the interrupt attributes of this pin.
The GPIO_PIN_PULL_CONFIGURATION_XXX constants specify whether a general-purpose I/O (GPIO) pin is pulled up or pulled down.
#define GPIO_PIN_PULL_CONFIGURATION_DEFAULT (0x0)
#define GPIO_PIN_PULL_CONFIGURATION_PULLUP (0x1)
#define GPIO_PIN_PULL_CONFIGURATION_PULLDOWN (0x2)
#define GPIO_PIN_PULL_CONFIGURATION_NONE (0x3)
The PullConfiguration member of the GPIO_ENABLE_INTERRUPT_PARAMETERS structure is set to a GPIO_PIN_PULL_CONFIGURATION_XXX constant.
If none of the system-defined GPIO_PIN_PULL_CONFIGURATION_XXX constants appropriately describes the pin configuration, this member can be set to a vendor-defined constant in the range 128 to 255.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Supported starting with Windows 8. |
Header | gpioclx.h |
See also
CLIENT_CONTROLLER_BASIC_INFORMATION