Why does the fifth pin of port D stay on?
STM32F407
Why does the fifth pin of port D stay on?
Here is the code:
RCC->AHB1ENR|=RCC_AHB1ENR_GPIODEN;
GPIOD->MODER&=0UL;
GPIOD->IDR&=0UL;
There are 3 volts on pin 5 of port D (I checked with a multimeter).
The IDR register looks like this: IDR: 0000 0000 0010 0000
The ODR register looks like this: ODR: 0000 0000 0000 0000

