Hello,
I'm working on the Demo Water Flow Measurement project. I want to send data by UART to ESP32 but data is not being received correctly. For this, I configured USCI_A1 so I can use RXD and TXD pins in J1 from EVM430FR6043. Software configuration is shown below, just sending data, not receiving.
WDTCTL = WDTPW | WDTHOLD; // Stop watchdog
// Configure GPIO
P1OUT &= ~BIT5;
P1DIR |= BIT5;
P1SEL0 |= 0x0C;
// Disable the GPIO power-on default high-impedance mode to activate
// previously configured port settings
PM5CTL0 &= ~LOCKLPM5;
UCA1CTLW0 = UCSWRST; // Put eUSCI in reset
UCA1CTLW0 |= UCSSEL__SMCLK; // CLK = SMCLK
UCA1BRW = 8; // 1000000/115200 = 8.68
UCA1MCTLW = 0xD600; // 1000000/115200 - INT(1000000/115200)=0.68
// UCBRSx value = 0xD6 (See UG)
UCA1CTLW0 &= ~UCSWRST; // release from reset
UCA1IE |= UCRXIE; // Enable USCI_A3 RX interrupt
UCA1TXBUF = TXData; // Load data onto buffer
I believe configuration is correct because I communicated correctly between TX and RX pins through the same board, but if I connect TX for example externally to another device it doesn't work. I measured the TX signal with an oscilloscope and the signal is very unstable.
I also tried to use hal_uart_TxByte that is implemented in hal_uart.c but neither works.
Thanks in advance,
Alberto