Documentation

fc422mexcalcbits

Calculate parameter values for Fastcom 422/2-PCI board

Syntax

[a,b] = fc422mexcalcbits(frequency)
[a,b,df] = fc422mexcalcbits(frequency)

Description

example

[a,b] = fc422mexcalcbits(frequency) accepts a baud and converts this value into a vector containing values for the parameter Clocks Bits of the Fastcom® 422/2-PCI driver clock. These values set the phase-locked-loop parameters for the board.

example

[a,b,df] = fc422mexcalcbits(frequency) accepts a baud and converts this value into a vector containing the phase-locked-loop parameters for the board and the resulting baud value.

Examples

collapse all

[a,b] = fc422mexcalcbits(30e3)
a =

     2111792


b =

    23

In the RS-232/RS-422/RS-485 Send/Receive (Composite) block parameters, Board Setup tab, set Clock Bits to [2111792 23].

[a,b,df] = fc422mexcalcbits(1.49e6)
a =

     3805896


b =

    23


df =

   1.4901e+06

In the RS-232/RS-422/RS-485 Send/Receive (Composite) block parameters, Board Setup tab, set Clock Bits to [3805896 23].

Input Arguments

collapse all

The baud must be between 30e3 and 1.5e6. This limitation is a physical limitation of the clock circuit.

Example: 30e3

Data Types: double

Output Arguments

collapse all

a,b – Values for the driver block parameter. These values set the phase-locked-loop parameters for the board.

  • a,b – Values for the driver block parameter. These values set the phase-locked-loop parameters for the board.

  • df – The actual baud value that the driver block parameter creates. The clock circuit has limited resolution and is unable to match an arbitrary frequency perfectly.

Introduced in R2014a

Was this topic helpful?