Integer N PLL with Dual Modulus Prescaler

Frequency synthesizer with dual modulus prescaler based integer N PLL architecture

  • Library:
  • Mixed-Signal Blockset / PLL / Architectures

Description

The Integer N PLL with Dual Modulus Prescaler reference architecture uses a Dual Modulus Prescaler block as the frequency divider in a PLL system. The frequency divider divides the frequency of the VCO output signal by an integer value to make it comparable to a PFD reference signal frequency.

Ports

Input

expand all

Input clock signal, specified as a scalar. The signal at the clk in port is used as the reference signal for the PFD block in a PLL system.

Data Types: double

Output

expand all

Output clock signal, specified as a scalar. The signal at the clk out port is the output of the VCO block in a PLL system.

Data Types: double

Parameters

expand all

Select to enable increased buffer size during the simulation. This increases the buffer size of all the building blocks in the PLL model that belong to the Mixed-Signal Blockset™/PLL/Building Blocks Simulink® library. The building blocks are PFD, Charge Pump, Loop Filter, VCO, and Dual Modulus Prescaler. By default, this option is deselected.

Buffer size for the loop filter, specified as a positive integer scalar. This sets the number of extra buffer samples available during the simulation to the Convert Sample Time subsystem inside the loop filter.

Selecting different simulation solver or sampling strategies can change the number of input samples needed to produce an accurate output sample. Set the Buffer size for loop filter to a large enough value so that the input buffer contains all the input samples required.

Dependencies

This parameter is only available when the Enable increased buffer size option is selected.

Programmatic Use

  • Use get_param(gcb,'NBufferFilter') to view the current value of Buffer size for loop filter.

  • Use set_param(gcb,'NBufferFilter',value) to set Buffer size for loop filter to a specific value.

Buffer size for the PFD, charge pump, VCO, and prescaler, specified as a positive integer scalar. This sets the buffer size of the PFD, Charge Pump, VCO, and Dual Modulus Prescaler blocks inside the PLL model.

Selecting different simulation solver or sampling strategies can change the number of input samples needed to produce an accurate output sample. Set the Buffer size for PFD, charge pump, VCO, prescaler to a large enough value so that the input buffer contains all the input samples required.

Dependencies

This parameter is only available when the Enable increased buffer size option is selected.

Programmatic Use

  • Use get_param(gcb,'NBuffer') to view the current value of Buffer size for PFD, charge pump, VCO, prescaler.

  • Use set_param(gcb,'NBuffer',value) to set Buffer size for PFD, charge pump, VCO, prescaler to a specific value.

PFD

Configuration

Delay added for active output near zero phase offset, specified as a positive scalar in s. Deadband is the phase offset band near zero phase offset for which the PFD output is negligible.

Programmatic Use

  • Use get_param(gcb,'DeadbandCompensation') to view the current value of Deadband compensation.

  • Use set_param(gcb,'DeadbandCompensation',value) to set up Rise/fall time to a specific value.

Data Types: double

Impairments

Select to add circuit impairments to simulation. By default, this option is deselected.

Determine how output step size is calculated:

  • Select Default to calculate output step size from rise/fall time.

  • Select Advanced to calculate output step size from maximum frequency of interest.

Dependencies

To enable this parameter, select Enable Impairments in the PFD tab.

Maximum frequency of interest at the output, specified as a real positive scalar in Hz.

Dependencies

To enable this parameter, select Enable Impairments in the PFD tab and choose Advanced for Output step size calculation.

Programmatic Use

  • Use get_param(gcb,'MaxFreqInterest') to view the current value of Maximum frequency of interest.

  • Use set_param(gcb,'MaxFreqInterest',value) to set Maximum frequency of interest to a specific value.

20% – 80% rise/fall time for the up output port of the PFD, specified as a real positive scalar.

Dependencies

To enable this parameter, select Enable Impairments in the PFD tab.

Programmatic Use

  • Use get_param(gcb,'RiseFallTime') to view the current value of Rise/fall time.

  • Use set_param(gcb,'RiseFallTime',value) to set Rise/fall time to a specific value.

Delay from the input port to output port of the PFD, specified as a real positive scalar in s.

Dependencies

To enable this parameter, select Enable Impairments in the PFD tab.

Programmatic Use

  • Use get_param(gcb,'PropDelay') to view the current value of Propagation delay.

  • Use set_param(gcb,'PropDelay',value) to set Propagation delay to a specific value.

Charge pump

Configuration

Full scale magnitude of design output current, specified as a real positive scalar in A. This parameter is also reported as Charge pump current in the Loop Filter tab and is used to automatically calculate the filter component values of the loop filter.

Programmatic Use

  • Use get_param(gcb,'OutputCurrent') to view the current value of Output current.

  • Use set_param(gcb,'OutputCurrent',value) to set Output current to a specific value.

Logic switching threshold at input ports, specified as a real scalar in V.

Programmatic Use

  • Use get_param(gcb,'InputThreshold') to view the current value of Input threshold.

  • Use set_param(gcb,'InputThreshold',value) to set Input threshold to a specific value.

Impairments

Select to add circuit impairments to simulation. By default, this option is deselected.

Difference between full scale positive and negative current, specified as a real positive scalar in A.

Dependencies

To enable this parameter, select Enable Impairments in the Charge pump tab.

Programmatic Use

  • Use get_param(gcb,'CurrentImbalance') to view the current value of Current imbalance.

  • Use set_param(gcb,'CurrentImbalance',value) to set Current imbalance to a specific value.

Output current when both inputs are at logic zero, specified as a real nonnegative scalar in A.

Dependencies

To enable this parameter, select Enable Impairments in the Charge pump tab.

Programmatic Use

  • Use get_param(gcb,'LeakageCurrent') to view the current value of Leakage current.

  • Use set_param(gcb,'LeakageCurrent',value) to set Leakage current to a specific value.

Select Default to calculate output step size from rise/fall time.

Select Advanced to calculate output step size from maximum frequency of interest.

Dependencies

To enable this parameter, select Enable Impairments in the Charge pump tab.

Maximum frequency of interest at the output, specified as a real positive scalar in Hz.

Dependencies

To enable this parameter, select Enable Impairments in the PFD tab and choose Advanced for Output step size calculation.

Programmatic Use

  • Use get_param(gcb,'MaxFreqInterestCp') to view the current value of Maximum frequency of interest.

  • Use set_param(gcb,'MaxFreqInterestCo',value) to set Maximum frequency of interest to a specific value.

Up

20% – 80% rise/fall time for the up input port of the charge pump, specified as a real positive scalar in s.

Dependencies

To enable this parameter, select Enable Impairments in the Charge pump tab.

Programmatic Use

  • Use get_param(gcb,'RiseFallUp') to view the current value of Up Rise/fall time.

  • Use set_param(gcb,'RiseFallUp',value) to set Up Rise/fall time to a specific value.

Total propagation delay from the up input port to output port of the charge pump, specified as a real positive scalar in s.

Dependencies

To enable this parameter, select Enable Impairments in the Charge pump tab.

Programmatic Use

  • Use get_param(gcb,'PropDelayUp') to view the current value of up Propagation delay.

  • Use set_param(gcb,'PropDelayUp',value) to set up Propagation delay to a specific value.

Down

20% – 80% rise/fall time for down input port of charge pump.

Dependencies

To enable this parameter, select Enable Impairments in the Charge pump tab.

Programmatic Use

  • Use get_param(gcb,'RiseFallDown') to view the current value of Down Rise/fall time.

  • Use set_param(gcb,'RiseFallDown',value) to set Down Rise/fall time to a specific value.

Total propagation delay from down input port to output port of charge pump, specified as a real positive scalar in s.

Dependencies

To enable this parameter, select Enable Impairments in the Charge pump tab.

Programmatic Use

  • Use get_param(gcb,'PropDelayDown') to view the current value of Down Propagation delay.

  • Use set_param(gcb,'PropDelayDown',value) to set Down Propagation delay to a specific value.

VCO

Measure of change in output frequency for input voltage change, specified as a real positive scalar with units in Hz/V. This parameter is also reported as VCO voltage sensitivity in the Loop Filter tab and is used to automatically calculate the filter component values of the loop filter.

Programmatic Use

  • Use get_param(gcb,'Kvco') to view the current Voltage sensitivity value.

  • Use set_param(gcb,'Kvco',value) to set Voltage sensitivity to a specific value.

Data Types: double

Frequency of the VCO without any control voltage input (0 V), or the quiescent frequency, specified as a real positive scalar in Hz.

Programmatic Use

  • Use get_param(gcb,'Fo') to view current Free running frequency value.

  • Use set_param(gcb,'Fo',value) to set Free running frequency to a specific value.

Data Types: double

Ratio of VCO output voltage to input voltage, specified as a real positive scalar in V. The input voltage has a nontunable value of 1 V.

Programmatic Use

  • Use get_param(gcb,'Amplitude') to view current Output amplitude value.

  • Use set_param(gcb,'Amplitude',value) to set Output amplitude to a specific value.

Data Types: double

Impairment

Select to introduce phase noise as a function of frequency to the VCO. By default, this option is selected.

Frequency offsets of the phase noise from the carrier frequency, specified as a real vector in Hz.

Dependencies

To enable this parameter, select Add phase noise in the VCO tab.

Programmatic Use

  • Use get_param(gcb,'Foffset') to view the current Phase noise frequency offset metric.

  • Use set_param(gcb,'Foffset',value) to set Phase noise frequency offset to a specific metric.

Data Types: double

Real vector specifying the phase noise power in a 1 Hz bandwidth centered at the specified frequency offsets relative to the carrier. The value is specified in dBc/Hz.

Dependencies

To enable this parameter, select Add phase noise in the VCO tab.

Programmatic Use

  • Use get_param(gcb,'PhaseNoise') to view the current Phase noise level metric.

  • Use set_param(gcb,'PhaseNoise',value) to set Phase noise level to a specific metric.

Data Types: double

Prescaler

Value of the program counter inside the dual modulus prescaler, specified as a real positive scalar. Program counter value, P is used to calculate the effective divider value. For more information, see Dual Modulus Prescaler.

Programmatic Use

  • Use get_param(gcb,'ProgramCounter') to view the current Program counter value, P.

  • Use set_param(gcb,'ProgramCounter',value) to set Program counter value, P to a specific value.

Value of the prescaler divider inside the dual modulus prescaler, specified as a real positive scalar. Prescaler divider value, N is used to calculate the effective divider value. For more information, see Dual Modulus Prescaler.

Programmatic Use

  • Use get_param(gcb,'PrescalerDivider') to view the current Prescaler divider value, N.

  • Use set_param(gcb,'PrescalerDivider',value) to set Prescaler divider value, N to a specific value.

Value of the swallow counter inside the dual modulus prescaler, specified as a real positive scalar. Swallow counter value, S is used to calculate the effective divider value. For more information, see Dual Modulus Prescaler.

Programmatic Use

  • Use get_param(gcb,'SwallowCounter') to view the current Swallow counter value, S.

  • Use set_param(gcb,'SwallowCounter',value) to set Swallow counter value, S to a specific value.

Minimum value by which the clock divider can divide input frequency, specified as a real positive scalar. This parameter is also reported in the Loop Filter tab and is used to automatically calculate the filter component values of the loop filter.

Programmatic Use

  • Use get_param(gcb,'Nmin') to view the current value of Min clock divider value.

  • Use set_param(gcb,'Nmin',value) to set Min clock divider value to a specific value.

Loop Filter

Select how filter components for the loop filter are computed:

  • Select Automatic to automatically compute filter components from system specifications. Resistance and capacitance edit boxes in the Loop Filter tab are not editable if this option is selected. Rather, the filter component values are calculated from Loop bandwidth, Phase margin, VCO voltage sensitivity, Charge pump current, and Max clock divider ration. By default, this option is selected.

  • Select Manual to manually enter the resistance and capacitance values to design a customized loop filter.

Frequency at which the magnitude of the open loop transfer function becomes 1, specified as a real positive scalar in Hz. Lower values of Loop bandwidth result in reduced phase noise and reference spurs at the expense of longer lock time and less phase margin.

Dependencies

This parameter is only available when Automatic is selected for the Filter Component values parameter in the Loop Filter tab.

Programmatic Use

  • Use get_param(gcb,'Fc') to view the current value of Loop bandwidth.

  • Use set_param(gcb,'Fc',value) to set Loop bandwidth to a specific value.

Phase of the open loop transfer function at the loop bandwidth subtracted from 180°, specified as a real positive scalar in degrees. For optimum lock time, select a phase margin between 40° and 55°.

Dependencies

This parameter is only available when Automatic is selected for the Filter Component values parameter in the Loop Filter tab.

Programmatic Use

  • Use get_param(gcb,'Phi') to view the current value of Phase margin.

  • Use set_param(gcb,'Phi',value) to set Phase margin to a specific value.

Order of the loop filter. Applies a second-, third-, or fourth-order passive RC loop filter in the PLL system.

Capacitor value C1, specified as a positive real scalar in F.

Dependencies

This parameter is only editable when Manual is selected for the Filter Component values parameter in the Loop Filter tab.

Programmatic Use

  • Use get_param(gcb,'C1') to view the current value of C1.

  • Use set_param(gcb,'C1',value) to set C1 to a specific value.

Data Types: double

Capacitor value C2, specified as a positive real scalar in F.

Dependencies

This parameter is only editable when Manual is selected for the Filter Component values parameter in the Loop Filter tab.

Programmatic Use

  • Use get_param(gcb,'C2') to view the current value of C2.

  • Use set_param(gcb,'C2',value) to set C2 to a specific value.

Data Types: double

Capacitor value C3, specified as a positive real scalar in F.

Dependencies

  • To enable this parameter, select 3rd Order Passive or 4th Order Passive in Loop filter type.

  • This parameter is only editable when Manual is selected for the Filter Component values parameter in the Loop Filter tab.

Programmatic Use

  • Use get_param(gcb,'C3') to view the current value of C3.

  • Use set_param(gcb,'C3',value) to set C3 to a specific value.

Data Types: double

Capacitor value C4, specified as a positive real scalar in F.

Dependencies

  • To enable this parameter, select 4th Order Passive in Loop filter type.

  • This parameter is only editable when Manual is selected for the Filter Component values parameter in the Loop Filter tab.

Programmatic Use

  • Use get_param(gcb,'C4') to view the current value of C4.

  • Use set_param(gcb,'C4',value) to set C4 to a specific value.

Data Types: double

Resistor value R2, specified as a positive real scalar in Ω.

Dependencies

This parameter is only editable when Manual is selected for the Filter Component values parameter in the Loop Filter tab.

Programmatic Use

  • Use get_param(gcb,'R2') to view the current value of R2.

  • Use set_param(gcb,'R2',value) to set R2 to a specific value.

Data Types: double

Resistor value R3, specified as a positive real scalar in Ω.

Dependencies

  • To enable this parameter, select 3rd Order Passive or 4th Order Passive in Loop filter type.

  • This parameter is only editable when Manual is selected for the Filter Component values parameter in the Loop Filter tab.

Programmatic Use

  • Use get_param(gcb,'R3') to view the current value of R3.

  • Use set_param(gcb,'R3',value) to set R3 to a specific value.

Data Types: double

Resistor value R4, specified as a positive real scalar in Ω.

Dependencies

  • To enable this parameter, select 4th Order Passive in Loop filter type.

  • This parameter is only editable when Manual is selected for the Filter Component values parameter in the Loop Filter tab.

Programmatic Use

  • Use get_param(gcb,'R4') to view the current value of R4.

  • Use set_param(gcb,'R4',value) to set R4 to a specific value.

Data Types: double

Select to add circuit impairments to simulation. By default, this option is disabled.

Temperature of the resistor, specified as a real scalar in ℃. Operating temperature determines the level of thermal (Johnson) noise.

Dependencies

To enable this parameter, select Enable impairments in the Loop Filter tab.

Programmatic Use

  • Use get_param(gcb,'Temperature') to view the current value of Operating temperature.

  • Use set_param(gcb,'Temperature',value) to set Operating temperature to a specific value.

Click to export loop filter component values to a spreadsheet (XLS file) or as comma-separated values (CSV file).

Probe

Select to probe the PFD output wires (pfd_up and pfd_down) to view the response of the PFD.

Select to probe the charge pump output wire (cp_out) to view the response of the Charge Pump.

Select to probe loop filter output wire (lf_out) to view the response of the Loop Filter. The loop filter output provides the control voltage to the VCO.

Select to probe the prescaler output wire (ps_out) to view the response of the Fractional Clock Divider with Accumulator.

Analysis

Select to plot the gain margin and phase margin of the PLL system before simulation. By default, this option is selected.

Select to plot the pole-zero map, loop bandwidth, step response, and impulse response of the PLL system before simulation. You must have a license to Control System Toolbox™ to plot the step response and impulse response of the PLL system. By default, this option is deselected.

Click to plot the presimulation loop dynamics of the PLL system.

Introduced in R2019a