当前位置:网站首页>Learn FPGA from the bottom structure (16) -- customization and testing of pll/mmcm IP
Learn FPGA from the bottom structure (16) -- customization and testing of pll/mmcm IP
2022-07-25 20:21:00 【Lonely single knife】
Catalog
2、PLL IP Instantiation and testing of
2.1、 Exemplify a PLL IP nucleus
Series catalog and portal
《 Start with the underlying structure FPGA》 Directory and portal
Customizing one PLL IP Before nuclear , It is strongly recommended that you read : Start with the underlying structure FPGA(15)----MMCM And PLL
In this article , Have been to PLL/MMCM IP The key factors of nuclear are explained in detail .
1、PLL IP The custom of
because MMCM Count as PLL A functional superset , The extra dynamic phase shift and spread function are not explained in detail in this chapter , Therefore, the following contents are used PLL IP Kernel Implementation .
- After creating a new project , Click on IP Catalog
- It will appear after clicking IP Catalog page , stay IP Search in the search box of the kernel clocking
- According to the screening , Double click to select PLL nucleus Clocking Wizard

①、 first page

① Clock monitoring
Enable Clock Monitoring : Real time monitoring can detect the clock at any time
② Implementation types
primitive: Can choose PLL still MMCM To achieve , In general PLL Enough to achieve most functions ,MMCM Suitable for more advanced applications , Such as dynamic phase shifting or frequency spreading
③ Clock characteristics
Frequency Synthesis: Frequency synthesis , Check it to modify the desired clock frequency output
Phase Alignment: Phase alignment , When checked, the phase of the input signal and the output signal are consistent , The price is an extra one BUFG
Dynamic Reconfig : Can pass AXI4 The interface is dynamically modified during use IP To configure , Realize more flexible clock output , Specific implementation can refer to :xapp888_7Series_DynamicRecon
Safe Clock Starup : Do not output before the clock is stable , Benefits: the clock is more stable and safe , Disadvantages may affect performance
Minimize Power : Optimize power consumption , The cost is that performance may be affected
④ Clock jitter (Jitter ) Optimize
Balanced: The default option , performance 、 Power balance state
Minimize Output Jitter: Minimize output clock jitter , The cost is that the power consumption becomes larger and may lead to phase error
Maximize Input Jitter filtering: Maximize input clock filtering , Allow the jitter of the input clock signal to increase ( That is to say, the input clock signal with worse quality is allowed ), However, it may cause the jitter of the output clock signal to become larger
⑤ Dynamic reconfiguration options : This function is not checked , So don't say
⑥ Input clock information
Optional input two clock signals as input
Configure the frequency of the input clock 、 shake 、 source
②、 The second page

① Output clock information setting
Check the clock information to be output , Including frequency , Phase relationship and duty cycle , It should be noted that the set value may not be achieved , Everything is subject to the actual value .
We choose 5 Different types of clock frequencies , See the table for specific information .
② Check the output sequence of different signals , Need to be in the ① Page check Safe Clock Starup Options
③ Clock feedback : Only in the ① Page checked Phase Alignment Options can be checked
automatic control on-chip And user-controlled on-chip: If your output clock signal is FPGA For internal use , Then the feedback path is on chip Of , The difference between automatic and user-defined is whether the feedback clock pin is automatically connected or open to the user to connect
automatic control off-chip And user-controlled off-chip: If your output clock signal is to FPGA Used externally , Then the feedback path is off chip Of , The difference between automatic and user-defined is whether the feedback clock pin is automatically connected or open to the user to connect .automatic control off-chip In mode, it is also necessary to specify that the feedback pin is a single ended signal (single ended) Or differential signal (differential)
④ optional
reset: Reset signal
power_down: Power down mode ( close PLL, Stop output )
locked: When set, it means PLL The output signal is valid , Usually use PLL Do not use the output clock signal until the signal is valid
⑤ Reset type
Select high-level reset or low-level reset . Suggested choice xilinx Common high-level reset .
③、 The third page

Rename the signal of the output port , Generally, for the sake of generality , Name change is not recommended .
④、 Page four

Direct pair PLL The underlying primitive operates , Realize more detailed customized design . Generally not used .
⑤、 Page 5

PLL IP Summary of nuclear design information , Confirm the design information .
2、PLL IP Instantiation and testing of
2.1、 Exemplify a PLL IP nucleus
Follow the above steps to generate IP after , Copy IP The instantiation template provided by the core .


2.2、 To write testbench
We write directly testbench To exemplify PLL IP Nuclear testing :
`timescale 1ns / 1ns
module tb_pll();
reg clk_in; // Input clock 50M
reg reset; // Highly effective reset signal
wire locked;
wire clk50_90d; //50M, The offset 90 degree
wire clk50_n90d; //50M, The offset -90 degree
wire clk50_d75; //50M, Duty cycle 75%
wire clk_100; //100M
wire clk_150; //150M
always #10 clk_in = ~clk_in; // Generate input clock
// Initialize the input signal
initial begin
reset = 1'b1;
clk_in = 1'b0;
#100
reset = 1'b0;
wait(locked); //PLL The output is valid
#1000 $finish;
end
// Exemplification PLL IP nucleus
clk_wiz_0 instance_name
(
// Clock out ports
.clk50_90d (clk50_90d), // output clk50_90d
.clk50_n90d (clk50_n90d), // output clk50_n90d
.clk50_d75 (clk50_d75), // output clk50_d75
.clk_100 (clk_100), // output clk_100
.clk_150 (clk_150), // output clk_150
// Status and control signals
.reset (reset), // input reset
.locked (locked), // output locked
// Clock in ports
.clk_in1 (clk_in)
);
endmodule2.3、 The simulation test
Use vivado Built in simulation tools simulator Run the simulation , The simulation results are as follows :

Next, look at each signal separately :
(1)clk50_90d:50M, The offset 90 degree

(2)clk50_n90d:50M, The offset -90 degree

(3)clk50_d75:50M, Duty cycle 75%

(4)clk_100:100M

(5)clk_150:150M

You can see , All output clock signals are consistent with the expected design , The simulation is successful .
3、 Summary and reference
- For general applications ,PLL IP It's very easy to get started ; As for dynamic reconfiguration and dynamic phase shift functions , It may be a little troublesome
- Don't use frequency division clock in ordinary design , Instead, try to use PLL or MMCM To realize the design of clock signal
Reference material 1:pg065-clk-wiz
- Blog home page :wuzhikai.blog.csdn.net
- This paper is written by Lonely single blade original , First appeared in CSDN platform
- The article is still being updated , Do you have any questions , You can communicate with me in the comment area !
- It's not easy to create , Your support is the biggest driving force for me to continuously update ! If this article helps you , Please give me more praise 、 Reviews and collections !
边栏推荐
- 参与开源社区还有证书拿?
- Redis source code -ziplist
- DIY个人服务器(diy存储服务器)
- 毕业从事弱电3个月,我为什么会选择转行网络工程师
- QQ是32位还是64位软件(在哪看电脑是32位还是64位)
- securecrt乱码解决方法[通俗易懂]
- 【高等数学】【1】函数、极限、连续
- wallys//wifi6 wifi5 router IPQ6018 IPQ4019 IPQ4029 802.11ax 802.11ac
- PreScan快速入门到精通第十八讲之PreScan轨迹编辑的特殊功能
- [today in history] July 17: Softbank acquired arm; The first email interruption; Wikimedia International Conference
猜你喜欢

PreScan快速入门到精通第十九讲之PreScan执行器配置、轨迹同步及非配多个轨迹

「分享」DevExpress ASP.NET v22.1最新版本系统环境配置要求

"Share" devaxpress asp Net v22.1 latest version system environment configuration requirements
![[today in history] July 13: the father of database passed away; Apple buys cups code; IBM chip Alliance](/img/2d/c23a367c9e8e2806ffd5384de273d2.png)
[today in history] July 13: the father of database passed away; Apple buys cups code; IBM chip Alliance

【高等数学】【1】函数、极限、连续
![[today in history] June 29: SGI and MIPS merged; Microsoft acquires PowerPoint developer; News corporation sells MySpace](/img/86/abeb82927803712a98d2018421c3a7.png)
[today in history] June 29: SGI and MIPS merged; Microsoft acquires PowerPoint developer; News corporation sells MySpace
![[advanced mathematics] [5] definite integral and its application](/img/b2/62748b7533982f2b864148e0857490.png)
[advanced mathematics] [5] definite integral and its application
![[advanced mathematics] [3] Application of differential mean value theorem and derivative](/img/a9/3b024dbbb201bee4eed6c9f6ce3001.png)
[advanced mathematics] [3] Application of differential mean value theorem and derivative

【NOI模拟赛】字符串匹配(后缀自动机SAM,莫队,分块)

PMP practice once a day | don't get lost in the exam -7.25
随机推荐
飞行器pid控制(旋翼飞控)
Apache Mina framework "suggestions collection"
Share 25 useful JS single line codes
Dataloader reports an error "default_collate: batch must contain tensors, numpy arrays, numbers, dicts" when pytorch trains the model
谷歌Pixel 6a屏下指纹扫描仪存在重大安全漏洞
4. Server startup of source code analysis of Nacos configuration center
Array of sword finger offer question bank summary (I) (C language version)
Link list of sword finger offer question bank summary (III) (C language version)
Google pixel 6A off screen fingerprint scanner has major security vulnerabilities
QQ是32位还是64位软件(在哪看电脑是32位还是64位)
PMP每日一练 | 考试不迷路-7.25
redis源码 -ziplist
Arrow parquet
MySQL date [plus sign / +] condition filtering problem
FormatDateTime说解[通俗易懂]
PMP adopts the latest exam outline, here is [agile project management]
CarSim simulation quick start (16) - ADAS sensor objects of CarSim sensor simulation (2)
What is cluster analysis? Categories of cluster analysis methods [easy to understand]
Three skills of interface request merging, and the performance is directly exploded!
接口请求合并的3种技巧,性能直接爆表!