Skip to main content
Visitor II
October 4, 2005
Question

UART0 Baudrate problem

  • October 4, 2005
  • 5 replies
  • 958 views
Posted on October 04, 2005 at 05:17

UART0 Baudrate problem

    This topic has been closed for replies.

    5 replies

    tj2Author
    Visitor II
    October 3, 2005
    Posted on October 03, 2005 at 14:30

    Hi

    I've compiled the AN1797 example and tried it on the evaluation board. This works fine. The board echo back all characterers send from Hyperterminal.

    I then program the same example into our own target board. But the baudrate seems to wrong. Our target board uses a 4MHz crystal, but the UART_Config function uses the RCCU_FrequencyValue to calculate the baudrate on runtime. So the crystal frequency should not be the problem or is it?

    Visitor II
    October 3, 2005
    Posted on October 03, 2005 at 14:42

    Double check your 71x_conf.h header for a proper definition of RCCU_Main_Osc. This is necessary for the Library to calculate a proper baud value. You should see something like...

    /* Main Oscillator Frequency value = 4 Mhz */

    #define RCCU_Main_Osc 4000000

    Best regards,

    Ryan.

    tj2Author
    Visitor II
    October 3, 2005
    Posted on October 03, 2005 at 15:03

    thx...

    I had to remove ''extern const u32 RCCU_Main_Osc;'' from the RCCU.h file to be able to compile. - But it didn't work. Same symptoms as before.

    Visitor II
    October 3, 2005
    Posted on October 03, 2005 at 16:27

    Sounds like you are using the Anglia SARM Toolchain whicj uses a differant method than the standard libs. If so the definition for the RCCU_Main_Osc is at the top of your startup file - should be startup.s by deafult.

    Regards

    sjo

    tj2Author
    Visitor II
    October 4, 2005
    Posted on October 04, 2005 at 05:17

    Yes, Im using the Anglia SARM Toolchain. I've found the constant in the startup.s file. And now it works!

    @ SJO - Thank you very much for your help!