Skip to content

Commit 54a2309

Browse files
committed
corrected digitalPinToBitMask(P)
1 parent be69e9b commit 54a2309

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

STM32F4/variants/generic_f407v/variant.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44

55
#define digitalPinToPort(P) ( PIN_MAP[P].gpio_device )
6-
#define digitalPinToBitMask(P) ( BIT(PIN_MAP[P].gpio_bit) )
6+
#define digitalPinToBitMask(P) ( BIT(P&0x0F) )
77
#define portOutputRegister(port) ( &(port->regs->ODR) )
88
#define portInputRegister(port) ( &(port->regs->IDR) )
99

0 commit comments

Comments
 (0)