Using STM32 PB PORTB GPIOB Pin Pad Port
Posted: Sat Sep 01, 2012 5:58 am
At reset, the STM32 will have PB4 and PB3 mapped to JTAG function by default.
To use these pins as normal I/O, you must disable JTAG:
// disable JTAG
AFIO->MAPR |= AFIO_MAPR_SWJ_CFG_JTAGDISABLE;
I discovered this when I realized PB4 and PB3 were changing when I was changing PB10
I hope some will find this piece of information useful.
Barry
To use these pins as normal I/O, you must disable JTAG:
// disable JTAG
AFIO->MAPR |= AFIO_MAPR_SWJ_CFG_JTAGDISABLE;
I discovered this when I realized PB4 and PB3 were changing when I was changing PB10
I hope some will find this piece of information useful.
Barry