diff options
author | Erik Gilling <konkers@konkers.net> | 2016-06-12 13:56:15 -0700 |
---|---|---|
committer | Erik Gilling <konkers@konkers.net> | 2016-06-12 19:31:35 -0700 |
commit | 4fdf2bffcce690c965186fe292a4c4e479328214 (patch) | |
tree | e5e66bf1c1e31029b1538ef0145483e148edf979 /platform | |
parent | 1656c7320d3aa659128dd01dba33ac3bdbf74d09 (diff) | |
download | common-4fdf2bffcce690c965186fe292a4c4e479328214.tar.gz |
[stm32f0xx] Fix gpio_get().
Diffstat (limited to 'platform')
-rw-r--r-- | platform/stm32f0xx/gpio.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/platform/stm32f0xx/gpio.c b/platform/stm32f0xx/gpio.c index 391f871a..c85b3a8a 100644 --- a/platform/stm32f0xx/gpio.c +++ b/platform/stm32f0xx/gpio.c @@ -187,7 +187,7 @@ void gpio_set(unsigned nr, unsigned on) int gpio_get(unsigned nr) { - stm32_gpio_t *gpio = stm32_gpio_port_to_pointer(nr); + stm32_gpio_t *gpio = stm32_gpio_port_to_pointer(GPIO_PORT(nr)); return (gpio->IDR & (1 << GPIO_PIN(nr))) != 0; } |