This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

MSP430FR5043: What is the Max Baud Rate on MSP430FR5043

Part Number: MSP430FR5969
Other Parts Discussed in Thread: MSP430FR5043, MSP430F5436A, , MSP430FR6989

Hello,

I would like to know what is the maximum Baud Rate on the UART model for an MSP430FR5043. 

Have a BRCLK of 8Mhz or I can even go upto 12Mhz, that is not a problem, But I Can not achieve a baud rate of 2Mbps?

I want to set the baud rate to 2Mbps.  Also I want to try setting other baud rates and test for something (sending a character from MSP430F5436A through serial port to Docklight Software the character is not being received as sent.) . Could someone please let me know how to set the baud rate 2Mbps in MSP430F5436A.

Thanks.

  • 2 Mbps is not a problem for 5xx with precise UART clock source. For setup with BRCLK from XT2 I used my offline calculator.

    0121.MSP430UartCalc.rar

  • Hi Vijay,

    I would recommend looking at the Baud Rate Calculator for MSP430. If there's a configuration that's not possible it will return N/A for the results.

    Regards,

    Luke

  • Hi Zrno soli,

    I tried that but it didn't work.

  • Hi Luke Ledbetter,

    I tried that but it didn't work.

    it works at a minimum of 1.5Mbps. I have 2Mbps Baud Rate at UART Mode from MSP430fr5043

  • Part Number: MSP430FR5043

    Hi,

    MSP430FR5043 and MSP430F5436A Microcontroller does not Support 2Mbps Baud Rate on UART But a maximum of 1.5 Mbps is working.

    I have to achieve the Baud Rate of 2Mbps on This Microcontroller.  

    How to Achieve the 2Mbps Baud Rate on UART?

    Thanks.

  • Part Number: MSP430FR5969

    Hi,

    I am working on a project in which MSP430FR5969 Microcontroller. I want to replace this controller

    I will achieve the Baud Rate of UART is 2Mbps on MSP430FR6989 and MSP430F5436A Microcontroller. That's not Support 2Mbps Baud Rate on this controller. But a maximum of 1.5 Mbps is working.

    The MSP430FR5969 controller is work on 2Mbps Baud Rate.

    I will need to make these two (MSP430FR6989 and MSP430f5436A) controllers work on 2Mbps like MSP430FR5969 Controller.

    What should I do?

  • What is your clock speed?

  • MSP430FR5043 SMCLK is 16MHz and  MSP430F5436A SMCLK is 6MHz.

  • What have you tried, and what is not working? Can you show us some not working code?

  • Hi Vijay, 

    Can you send me the code portions for you initializing the UART and the BRCLK. 

    Regards,

    Luke

  • The data sheets include a maximum bit rate.The two parts mentioned have different maximums with one being 1 Mbps (F5436) and the other 4Mbps.

  • I tried 2Mbps Baud Rate on UART With Use External crystal 6MHz From MSP430F5436A Microcontroller.

    C Code:

    //*********************************************************** 2Mbps Baud Rate*****************************************************

    #include <msp430f5436a.h>

    unsigned int i;

    int main(void)
    {
    WDTCTL = WDTPW + WDTHOLD; // Stop WDT


    P3SEL = 0x30;         // P3.4 = USCI_A0 TXD --- P3.5 = USCI_A0 RXD


    P5SEL |= 0x0C;       // Port select XT2
    P7SEL |= 0x03;       // Port select XT1


    UCSCTL6 &= ~(XT1OFF + XT2OFF);                   // Set XT1 & XT2 On
    UCSCTL6 |= XCAP_3;                                          // Internal load cap

                                                                                  // Loop until XT1,XT2 & DCO stabilizes
    do
    {
    UCSCTL7 &= ~(XT2OFFG + XT1LFOFFG + XT1HFOFFG + DCOFFG);
                                                                                                                          // Clear XT2,XT1,DCO fault flags
    SFRIFG1 &= ~OFIFG;                                                                                  // Clear fault flags
    }while (SFRIFG1&OFIFG);                                                                           // Test oscillator fault flag

    UCSCTL6 &= ~XT2DRIVE0;                                                                        // Decrease XT2 Drive according to
    // expected frequency
    UCSCTL4 |= SELA_0 + SELS_5;                                                                // Select SMCLK, ACLK source and DCO source

    UCA0CTLW0 |= 0x0081;
    UCA0BRW = 3;                                            // BRCLK = SMCLK = 6MHz
    UCA0MCTL |= 0x0000;
    UCA0CTLW0 &= ~0x0001;

    while(1)
    {
    UCA0TXBUF='1';
    for(i=0; i < 60000; i++){}

    }

    }

  • Hi Luke,

    I tried 2Mbps Baud Rate on UART With Use External crystal 16MHz From MSP430FR5043 Microcontroller.

    C Code:

    //************************************************* 2Mbps Baud Rate (16MHz External Oscillater)**********************************************


    #include <msp430fr5043.h>

    unsigned int i;

    int main(void)
    {
    WDTCTL = WDTPW | WDTHOLD; // Stop Watchdog
    PM5CTL0 &= ~LOCKLPM5;

    P2SEL0 &= ~(BIT0 | BIT1);
    P2SEL1 |= BIT0 | BIT1; // USCI_A3 UART operation

    PJSEL0 |= BIT4 | BIT5 | BIT6 | BIT7; // For XT1 and XT2


    CSCTL0_H = CSKEY_H; // Unlock CS registers
    CSCTL1 = DCOFSEL_6; // Set DCO to 8MHz
    CSCTL2 = SELA__VLOCLK | SELS__HFXTCLK | SELM__DCOCLK;
    CSCTL3 = DIVA__1 | DIVS__1 | DIVM__1; // Set all dividers to 1
    CSCTL4 |= LFXTDRIVE_3 | HFXTDRIVE_3;
    CSCTL4 &= ~(LFXTOFF | HFXTOFF);

    while (!(SFRIFG1 & OFIFG)); // Test oscillator fault flag

    CSCTL5 &= ~(LFXTOFFG | HFXTOFFG); // Clear XT1 and XT2 fault flag
    SFRIFG1 &= ~OFIFG;

    CSCTL0_H = 0; // Lock CS registers


    // Configure USCI_A3 for UART mode
    UCA3CTLW0 = 0x0081; // Put eUSCI in reset,CLK = SMCLK
    UCA3BRW = 8;
    UCA3MCTLW |= 0x0000;
    UCA3CTLW0 &= ~0x0001; // Initialize eUSCI

    while(1)
    {
    UCA3TXBUF='1';

    for(i=0; i < 60000; i++){}

    }
    }

    Regards,

    Vijay

  • Hi David,

    Can You Clearly Explain Plz?

  • What happens when you run this code?

    The first thing I see is that i should be volatile to keep it from being optimised away.

  • Hi Vijay,

    David was pointing out the datasheet spec for UART 

    MSP430FR5043 Datasheet

    MSP430FR5436A Datasheet

    You can't reach 2 Msps as the baud rate with the  MSP430FR5436A device is limited to 1 MHz, but you can with the MSP430FR5043. It looks like you are setting your DCO to 8 MHz instead of 16 MHz. Since your clock is 8 MHz you need UCA3BRW = 4 to get 2 Msps. With your current settings you should be getting 1 Msps.

    Regards,

    Luke

  • Transmit Char = '1';

    Receiving application is docklight software. But receiving Char is not correct

  • Hi Luke,

    I tried at 16MHz, 8MHz, 4MHz and 1MHz but didn't reach 2Mbps Baud Rate on MSP430FR5043

  • Did you make i volatile so that you get an actual delay? Have you checked the serial output with an oscilloscope?

  • __delay_cycles() usually works better than an arbitrary delay loop that the compiler could optimize away.

    Waiting for TXIFG to be set before writing to TXBUF is almost always a good idea.

    Default for DIVS and DIVM after a PUC is to divide by 8. I see no change to UCSCTL3 that would alter that.

    For that matter, I don't see a write of CSKEY to UCSCTL0 that would unlock the clock control registers.

  • Hi Vijay,

    I noticed that the threads were similar so I have joined them together.

    Is there a reason you need to run UART at 2 Msps? Looking at the error rate in our table of recommended settings for the MSP430FR5043

    The error rate is close to linear so if you need ~4x the 460800 speed you're going to run close to an error of ~5.7% at 2Msps. (Check out this TI Precision Labs video on UART Error)

    Is it possible to use SPI in your use case instead?

    Regards,

    Luke

  • Hi Luke.

    Our requirement is specific to UART only, we want to send the data to an external application.

  • What is the baud rate you are seeing with the settings that "should" give 2 Msps?

    Also is this a custom board and not a TI EVM?

    Regards,

    Luke

  • Hi Luke, 

    We will get 2Mbps BaudRate in Uart From MSP430FR5943 Board

    Thanks For Help

    Luke

**Attention** This is a public forum