Using PB7/6 port of STMF051
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2016-07-14 5:51 PM
Posted on July 15, 2016 at 02:51
Hi,
I configured USART1 to PA9/10. And I want to use PB6/7 to GPIO.First I initial the USART1 function(using PA9/10), and works well(putchar works well). But when I initial PB6/7 to GPIO by GPIO_Init() function, USART1 function does not work at this moment.PB6/7 can be configured USART1 also. I think something is related this.Please help me.Paul
This discussion is locked. Please start a new topic to ask your question.
3 REPLIES 3
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2016-07-14 5:56 PM
Posted on July 15, 2016 at 02:56
Perhaps you should show the code, it might be more apparent then what the problem actually is...
Is this on some specific board, if so state which and the connectivity.
Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
Up vote any posts that you find helpful, it shows what's working..
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2016-07-15 4:21 AM
Posted on July 15, 2016 at 13:21
Hi sangdo.lee,
Check GPIO_Init configuration, if you are not assigning the PB6/PB7 to UASRT1 AF also. As mentionned in STM32F0xx reference manual , part 8.3.2 I/O pin alternate function multiplixer and mapping: ''The device I/O pins are connected to on-board peripherals/modules through a multiplexer that allows only one peripheral alternate function (AF) connected to an I/O pin at a time. In this way, there can be no conflict between peripherals available on the same I/O pin.
'' If it is the casen PA9/PA10 no more assigned to USART1 but PB6/7 instead. -Hannibal-Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2016-07-17 3:46 AM
Posted on July 17, 2016 at 12:46
Hi, Hannibal,
I had a mistake to call GPIO_Init, passing ridiculous parameter for GPIO_TypeDef* GPIOx ...THX for helpPaul