Electronics circuit calculation > PIC32 UART Baud rate calculation.


The UART module includes a dedicated 16-bit Baud Rate Generator. The BRGx register controls the period of a free-running 16-bit timer. Equation 19-1 shows the formula for computation of the baud rate with BRGH = 0.

PIC32 uart diagram
BRGH = 0 : UxBRG = [Fpb / 16 x Baud Rate] - 1 Where Fpb is peripheral bus clock frequency.
BRGH = 1 : UxBRG = [Fpb / 4 x Baud Rate] - 1 Where Fpb is peripheral bus clock frequency.

Fpb =  MHz
BRGH  BRGH=0    BRGH=1