Calculating Valid Data Rates with RAMix PMC421 , PMC422, and PMC423 Serial I/O Cards


RAMix/GE Fanuc serial cards to support a specific data rate.  For supported rates, what are the best ways to derive the correct output?


The PMC421 / PMC422 / PMC423 serial interface cards support standard POSIX data rates with their default crystal oscillators installed.  The PMC682 and PMC684 serial functions also support the standard POSIX rates with their default oscillators.  Occasionally there is the need for non-POSIX output rates in unique circumstances.  In order to achieve a desired output data rate (or to verify it's feasibility), the crystal oscillator may have to be be changed and specific variables modified to produce a given output.

Customers contemplating oscillator changes should consult their GE Fanuc Sales and Support representative for additional details.


Oscillator Frequency - The component vendor's specified output.  Care should be taken to verify the vendor's output range tolerance and it's affect on the desired output rate.

Oscillator Divisor (1 or 4) - An input to the BRG calculation function that can have a value of either 1 or 4.   Generally, this value is almost always set to 1.  Only in very rare circumstances will the oscillator be required to be further divided by a factor of four.  The only valid values of this variable are 1  or  4

Baud Rate Generator (Integer) - Variable defined in the driver.  This variable will be an integer value.

Ideal BRG - An estimate of the desired BRG calculated by entering the Osc. Frequency, the Osc. Divisor, Sample Rate, and the desired output rate.  This is an estimate only.  The actual BRG that is used will be an integer value.

Sample Rate (8 or 16) - A variable specifying the number of samples to be used in deriving the output.  The only valid values are either 8 or 16.

Formula for Calculating Actual Output Rate (in bits per second)

(Oscillator Frequency/Oscillator Divisor)/(Baud Rate Generator * Sample Rate) = Rate in bps

Step by Step Instructions

  1. Open spreadsheet "Baud Rate Calculator.xls"
  2. Enter Oscillator Frequency value (in hertz) in cell C2.
  3. Enter Oscillator Divisor value in cell C3.
  4. Enter desired Output Data Rate (in bps) in cell C4.
  5. Enter Sample Rate in cell C5.
  6. Review the resultant "Required BRG Value" and estimate the nearest integer value, then enter this value in cell C11, "Baud Rate Generator"
  7. The actual output data rate is displayed in cell C14.

Use this spreadsheet to quickly try various values for frequency, divisor, sample rate and BRG to determine the feasibility of a specific output rate.

Example Solution

Testing the feasibility of deriving an output of 512Kbps on a PMC421 with the standard 24 Mhz oscillator.

  1. Enter a frequency of 24000000 in cell C2.
  2. Enter a divisor value of 1 in cell C3.
  3. Enter a desired output rate of 512000 in cell C4.
  4. Enter a sample rate of 16 in cell C5.
  5. Rounding the Required BRG Value to the nearest integer value, enter a BRG value of 3 in cell C11.

The result is an actual data rate of 500 Kbps. Through trial and error of the parameters, we demonstrate that 500Kbps is the closest rate obtainable to 512 Kbps using the standard 24 Mhz oscillator. 

You can also use this spreadsheet to analyze various oscillators to calculate various output rates.  There are two key issues to remember.

  1. The UART has a maximum input rate. 
  • The PMC421's UART is limited to 24.00 Mhz.
  • The PMC422 / PMC423 UART is limited to 50.0 Mhz
  • The desired oscillator frequency value must be practically obtainable.
  • References

    1. PMC421 Hardware Reference Manual, DDC No. Rx-URMH 002 Rev - Issued 12 November 2002
    2. PMC422 Hardware Reference Manual, DDC No. Rx-URMH 069 Rev B Issued 29 October 2003
    3. PMC423 Hardware Reference Manual, DDC No. Rx-URMH 006 Rev A Issued 26 January 2004