Hello,
i'm trying to initialize UART1 on STM32F4 Discovery Board with pins PB6 PB7. I can't receive any chars from Computer, but i can send.
does anyone know how to solve it?
thank you.
it was configured like below.
PB6 = pyb.Pin('PB6', mode=pyb.Pin.AF_PP, af=pyb.Pin.AF7_USART1)
PB7 = pyb.Pin('PB7', mode=pyb.Pin.AF_PP, af=pyb.Pin.AF7_USART1)
from pyb import UART
uart = UART(1, 9600)
UART1 Setting Problem on STM32F4Disc. with pins PB6 PB7
-
- Posts: 22
- Joined: Sat Jun 20, 2015 11:48 am
Re: UART1 Setting Problem on STM32F4Disc. with pins PB6 PB7
By default UART1 is on PA9 and PA10. To change it to be on PB6 and PB7 you need to change the settings in the stmhal/boards/STM32F4DISC/mpconfigboard.h file (lines 28 and 29, search for MICROPY_HW_UART1).stmfresser wrote: i'm trying to initialize UART1 on STM32F4 Discovery Board with pins PB6 PB7.
-
- Posts: 22
- Joined: Sat Jun 20, 2015 11:48 am
Re: UART1 Setting Problem on STM32F4Disc. with pins PB6 PB7
thank you a lot. it works!!