kopia lustrzana https://github.com/OpenRTX/OpenRTX
STM32F4xx: fixed bug in gpio driver
Fixed bug causing gpios set in alternate function mode to have the internal pull-up resistor enabled, even if not requested.pull/239/head
rodzic
079b57e383
commit
031eda1d7e
|
@ -98,7 +98,7 @@ void gpio_setMode(const void *port, const uint8_t pin, const uint16_t mode)
|
|||
// (MODE=10 TYPE=0 PUP=00)
|
||||
p->MODER |= 0x02 << (pin*2);
|
||||
p->OTYPER |= 0x00 << pin;
|
||||
p->PUPDR |= 0x01 << (pin*2);
|
||||
p->PUPDR |= 0x00 << (pin*2);
|
||||
setGpioAf(p, pin, af);
|
||||
break;
|
||||
|
||||
|
|
Ładowanie…
Reference in New Issue