1#
发表于 2015-06-19 11:07:04
这个问题我也遇到过,处理起来很简单。AD的时钟还是用全局时钟,在IO和全局时钟之间加入一个ODDR原语模块,这样就可以解决map报错的问题和程序不稳定的问题。下面是一段代码,你可以参照一下。
PLL_Wizard g1 ( //DCM Block;
.CLK_IN1(T_clk), //T_clk = 30MHz;
.RESET(Asyn_rst),
.CLK_OUT1(clk_40), //clk_40 = 40MHz;
.CLK_OUT2(clk_yc), //clk_yc = 9.231MHz;
.CLK_OUT3(clk_sp), //clk_sp = 19.2MHz;
.LOCKED(locked)
);
ODDR2 #(
.DDR_ALIGNMENT("NONE"), // Sets output alignment to "NONE", "C0" or "C1"
.INIT(1'b0), // Sets initial state of the Q output to 1'b0 or 1'b1
.SRTYPE("SYNC") // Specifies "SYNC" or "ASYNC" set/reset
) ODDR2_inst (
.Q(ADC_clk), // 1-bit DDR output data
.C0(clk_40), // 1-bit clock input
.C1(!clk_40), // 1-bit clock input
.CE(Init_ce), // 1-bit clock enable input
.D0(Init_ce), // 1-bit data input (associated with C0)
.D1(!Init_ce), // 1-bit data input (associated with C1)
.R(Syn_rst), // 1-bit reset input
.S() // 1-bit set input
);
|