AnsweredAssumed Answered

mpc8360 UCC7 UART issue:  BRGC sometimes  locked incorrect baud rates for autobaud, any solution?

Question asked by Gang Luo on May 4, 2017
Latest reply on May 18, 2017 by Gang Luo

I am  working on a project which is using mpc8360 UCC7 UART auto baud feature.
mpc8360 ERRATA  indicated that mpc8360 UCC7 UART  autbobaud has a hardware bug of missing autbobaud  rate locking interrupt event . The ERRATA also proposed a work-around.

However, even when using this work-around, it looks that  mpc8360 UCC7 UART auto baud has the following issue, seen from our testing:

  • BRGC6 (for UCC7) sometimes  locked incorrect baud rates  for autobaud.

Our connection configuration is as below:

  [ MCP8360 UCC7 DTE (autobaud) ]  <------------->    [XyplexTerminalSeverDCE (fixed baud rate 19200)]

Our testing results are as below:
When manually using mpc8360 UCC7 UART auto baud feature, 

Expected Results (good cases):  mpc8360 BRGC6 sometime could lock the correct baud rates as below:

----------- UCC7 Stats (BRGC:0x1250a [RST:0,EN:1,ATB:1, Operation Baud Rate:19349]) ------------

----------- UCC7 Stats (BRGC:0x1250a [RST:0,EN:1,ATB:1, Operation Baud Rate:19349]) ------------

Incorrect Results (bad cases):  However, mpc8360 BRGC6 frequently  locked  the incorrect baud rates as below:

----------- UCC7 Stats (BRGC:0x127c8 [RST:0,EN:1,ATB:1, Operation Baud Rate:12537]) ------------
----------- UCC7 Stats (BRGC:0x12772 [RST:0,EN:1,ATB:1, Operation Baud Rate:13102]) ------------
----------- UCC7 Stats (BRGC:0x1279a [RST:0,EN:1,ATB:1, Operation Baud Rate:12833]) ------------

  • May you help us to figure out the possible issues of incorrect locked baud rate?


Furthermore, in section 21.8.1 Autobaud Limitations of MPC8360ERM_Rev2.pdf, it said "When using the Autobaud mode, the clock source used by the BRG (internal or external), must be at least    128-times faster than the target divided clock."

  • Is "the clock source used by the BRG" brgclk mentioned in 21.9?  (our brgClk = 200000001)
  • What is "the target divided clock"? For example, if the DCE has the fixed rate of 19200, what is the corresponding "the target divided clock"?

PS: further information:

========= procedure of manually Trigger MPC8360 UCC7 UART autobaud  =======
1. BRGC  programing: Unset EN, set RST and program the new value (e.g. 38400) according to section 21.7.1 of MPC8360ERM_Rev2.pdf

    Result:  BRGC6=0x1028a [RST:0,EN:1,ATB:0, Operation Baud Rate:38343]
2. Set UCCM[Rx] and UCCM[AB].

    Set MRBLR to 1 (BD contains 1 char) on system initialization.
3. Waiting for Rx Receive data  (i.e. waiting for UCCE[Rx]  set) for setting ATB bit at BRGC register.
4.  Set EN & ATB bits at BRGC register for triggering MPC8360 BRGC autobaud
     mechanism that sets BRGCx[CD] and BRGCx[DIV16]
5.  Waiting for Rx Receive data by checking whether UCCE[Rx] is set.
    note:  This UCCE[Rx] bit is used instead of the UCCE[AB] bit since it does not work due to this erratum: MPC8360ECE_errata.pdf
6. Received the first (Rx) after setting EN & ATB bits at BRGC. 
    At this point, BRGC is expected to lock up the incoming baud rate by  setting BRGCx[CD] and BRGCx[DIV16].

    software will read BRGCx[CD] and BRGCx[DIV16], and re-setting them to one of closest standards baud rates (i.e, 9600, 19200, ..., 115200)