I have an MSP430 (FG4618/F2013) Experimental Board connected to Windows 7 via MSP-FET430UIF/USB cable as a power and Serial RS232 cable.
I am trying to run the sample code that reads the input and echoes back to the HyperTerminal.
#include <msp430xG46x.h>
void main(void)
{
WDTCTL = WDTPW+WDTHOLD; // Stop WDT
P5DIR |= BIT1; // Set P5.1 to be output
P2SEL |= BIT4 + BIT5; // P2.4,5 = USCI_A0 RXD/TXD
UCA0CTL1 |= UCSSEL_2; // SMCLK
UCA0BR0 = 0x09; // 1MHz/115200 (lower byte)
UCA0BR1 = 0x00; // 1MHz/115200 (upper byte)
UCA0MCTL = 0x02; // Modulation (UCBRS0=0x01)(UCOS16=0)
UCA0CTL1 &= ~UCSWRST; // **Initialize USCI state machine**
IE2 |= UCA0RXIE; // Enable USCI_A0 RX interrupt
_BIS_SR(LPM0_bits + GIE); // Enter LPM0, interrupts enabled
}
// Echo back RXed character, confirm TX buffer is ready first
#pragma vector=USCIAB0RX_VECTOR
__interrupt void USCIA0RX_ISR (void)
{
while(!(IFG2&UCA0TXIFG)); // Wait until can transmit
UCA0TXBUF = UCA0RXBUF; // TX -> RXed character
P5OUT^=BIT1; // Toggle LED4
}
Since this is a sample demo code, my issue is not with the code, but with the setup. When I run the following code in IAR editor, I pick the COM149 port in the FET Debugger settings since that is the port recognized via the Device Manager.
Then I try to connect the HyperTerminal to that same port and it says "Another device is using the selected Telephony device"
That COM port is used by the TI tools to communicate with the FET.
According to the schematic in the MSP-EXP430FG4618 manual, UCA0TXD and UCA0RXD are connected to the isolated RS-232 port, and to pins 5 and 6 of header H4. Neither of these is connected to the FET.
And the MSP-FET430UIF does not have a backchannel/application UART.