1.1.4.20 uint32_t GPIO_GroupPinRead(GPIO_PIN pin) Function

C

uint32_t GPIO_GroupPinRead(GPIO_PIN pin)

Summary

Returns the value of the given pin by reading it from the Group GPIO input register.

Description

Returns the state of the given pin by reading its status from the Group GPIO input register

Precondition

None

Parameters

Param Description
pin One of the GPIO pins from the enum GPIO_PIN

Returns

A 32-bit value indicating the status of the pin. A non-zero value indicates that the pin is read as 1. A value of zero indicates that the pin is read as 0.

Example

uint32_t pin_val = GPIO_GroupPinRead(GPIO_PIN_GPIO012);

Remarks

None