Skip to content

Commit b75b7a4

Browse files
committed
Nucleo F103RB - gpio_is_connected method readdition
1 parent bad3d04 commit b75b7a4

File tree

1 file changed

+4
-0
lines changed
  • libraries/mbed/targets/hal/TARGET_STM/TARGET_NUCLEO_F103RB

1 file changed

+4
-0
lines changed

libraries/mbed/targets/hal/TARGET_STM/TARGET_NUCLEO_F103RB/gpio_object.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,10 @@ static inline int gpio_read(gpio_t *obj)
6464
return ((*obj->reg_in & obj->mask) ? 1 : 0);
6565
}
6666

67+
static inline int gpio_is_connected(const gpio_t *obj) {
68+
return obj->pin != (PinName)NC;
69+
}
70+
6771
#ifdef __cplusplus
6872
}
6973
#endif

0 commit comments

Comments
 (0)