/ * @brief * Read the pad value for a single pin in a GPIO port. * * @param[in] port * The GPIO port to access. * * @param[in] pin * The pin number to read. * * @return * The pin value, 0 or 1. ******************************************************************************/
| 195 | * The pin value, 0 or 1. |
| 196 | ******************************************************************************/ |
| 197 | unsigned int GPIO_PinInGet(GPIO_Port_TypeDef port, unsigned int pin) |
| 198 | { |
| 199 | EFM_ASSERT(GPIO_PORT_VALID(port) && GPIO_PIN_VALID(pin)); |
| 200 | |
| 201 | return((unsigned int)((GPIO->P[port].DIN >> pin) & 0x1)); |
| 202 | } |
| 203 | |
| 204 | |
| 205 | /***************************************************************************//** |
no outgoing calls
no test coverage detected