diff options
Diffstat (limited to 'libmaple')
-rw-r--r-- | libmaple/include/libmaple/gpio.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libmaple/include/libmaple/gpio.h b/libmaple/include/libmaple/gpio.h index f7773c0..ca7b2bf 100644 --- a/libmaple/include/libmaple/gpio.h +++ b/libmaple/include/libmaple/gpio.h @@ -63,7 +63,7 @@ void gpio_set_mode(gpio_dev *dev, uint8 pin, gpio_pin_mode mode); * @param val If true, set the pin. If false, reset the pin. */ static inline void gpio_write_bit(gpio_dev *dev, uint8 pin, uint8 val) { - val = !!val; + val = !val; /* "set" bits are lower than "reset" bits */ dev->regs->BSRR = BIT(pin) << (16 * val); } |