3.2.14.5 DIAG_GPIO_PullUpPullDown
Returns the status of the IO_PORTS_PULLUP_PULLDOWN diagnostic
This function verifies if the pull up or pull down can be enabled for a GPIO.
It performs the following operations:
- Sets the direction of both the port pin to input
-
Enables the pull up or pull down for a GPIO and confirms its status by reading appropriate registers.
DIAG_TEST_STATUS DIAG_GPIO_PullUpPullDown
(
DIAG_GPIO_PORT_INDEX port,
DIAG_GPIO_PORT_PIN pin,
DIAG_GPIO_PULL_DIR pull_dir
);
Diagnostic verifies the following faults do not exist
- Cannot set pin to desired status, pullup/pulldown
Operating Mode
- Interface can be used at POST and ‘On Demand’
Precondition
- none
Parameters
- port - gpio port
- pin - gpio pin
- pull_dir - enum for pull direction
Returns
- DIAG_STATUS
