PLL With Dual Modulus Prescaler
This example shows how a PLL (phased locked loop) model works with a dual modulus prescaler frequency divider.
model = 'MSPLLDualModulusPrescaler';
open_system(model);
sim(model);
PLL Model Architecture
The PLL is relatively simple and consists of the following:
A pulse generator block as an ideal clock reference source operating at
10
MHz.Phase and Frequency detector (PFD) block from Mixed-Signal Blockset™.
Charge pump and loop compensator filter modeled with Simscape™ components with values specified in the subsystem mask.
Ring oscillator based Voltage Controlled Oscillator block from Mixed-Signal Blockset™.
A spectrum analyzer block from DSP System Toolbox™
A dual modulus prescaler from Mixed-Signal Blockset™ that implements a divider ratio equal to 8*18+6=150, thus generating a PLL output frequency of
1.5
GHz.
Dual Modulus Prescaler
A prescaler is typically used before a programmable divider to get the frequency down to a manageable value for the programmable divider which is a more complex design than the fixed value prescaler. The consequence of this design is that the frequency resolution of the PLL is now where N is the prescaler divider value.
A clever solution to this problem is to dynamically switch the prescaler division between N and N+1
by using two low frequency programmable dividers. These dividers are clocked with or which makes them far easier to implement. By dithering the divider ratio between two factors you can achieve the desired resolution.
open_system([model '/Dual Modulus Prescaler'],'force')
If the two counters are called P and S the overall frequency division is .
Since and P has a resolution of 1 the PLL resolution is back to . Aside from more hardware (two counters) and the complexity in programming them, there is one other important detail to consider and that is S is bounded in value and needs to be in the range of .
Therefore certain values of N may not be realizable.
Additional Information
In order to achieve optimal simulation duration and accuracy, change the default solver settings. In particular, this model uses 'ode45'
.
myConfigObj = getActiveConfigSet(model); openDialog(myConfigObj)
You can inspect the solver settings in the Model Configuration Parameters for more details.
See Also
Ring Oscillator VCO | Dual Modulus Prescaler