Question
How to correctly configure UART pins in asembler
Posted on December 17, 2012 at 22:07
I'm willing to init UART in asm and not sure is it required to configure specific IO port pin as output pin with Px_DDR and only then then I can use UART_TX or
the pin configures in output type automatically when UART is enabled in UART register? Example: There is shared UART1_TX/PA5 pin. After reset it is ''input'' - PA_DDR = $00 I want to use UART1 - prior that do I need this code or not?: ld A,♯%00100000 ; makes PA.5 - output ld PA_DDR,A #stm8s-uart-asm