Meaning of routing and pin assignment for UART

Status
Not open for further replies.

yefj

Advanced Member level 4
Joined
Sep 12, 2019
Messages
1,212
Helped
1
Reputation
2
Reaction score
3
Trophy points
38
Activity points
7,269
Hello, I am trying to understand the link between the two parts of this UART example code which is taken from the link bellow.
At first we set PORT C pint 1 to be RX input and port C pin 0 as output(push pull amplified)
What exactly happens next in the USART-> ROUTE line?
I see bitwise OR but i can see how its linked to the locations we defined previosly.
Thanks.
 

For an detailed explanation, read the processor reference manual. In a short, writing to the USART1->ROUTE register is activating the above configured pins. The processor as several sets of dedicated GPIO pins that can be selected for the USART by a specific location code. The present code is apparently using default location 0, unless the LOC bits in USART1->ROUTE haven't been set differently before.

 

    yefj

    Points: 2
    Helpful Answer Positive Rating
Status
Not open for further replies.

Similar threads

Cookies are required to use this site. You must accept them to continue using the site. Learn more…