Skip to content

Commit

Permalink
Merge ba5349c into 9883d8e
Browse files Browse the repository at this point in the history
  • Loading branch information
dhylands committed Aug 11, 2020
2 parents 9883d8e + ba5349c commit d4f68a8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ports/stm32/pin_defs_stm32.c
Expand Up @@ -8,7 +8,7 @@
uint32_t pin_get_mode(const pin_obj_t *pin) {
GPIO_TypeDef *gpio = pin->gpio;
uint32_t mode = (gpio->MODER >> (pin->pin * 2)) & 3;
if (mode != GPIO_MODE_ANALOG) {
if (mode != GPIO_MODE_ANALOG && mode != GPIO_MODE_INPUT) {
if (gpio->OTYPER & pin->pin_mask) {
mode |= 1 << 4;
}
Expand Down

0 comments on commit d4f68a8

Please sign in to comment.