When using DCM this IP core, its input clock is the global clock pin input, the output has two cases, first, can be directly connected to the global clock pin, second, can be connected to the ordinary IO pin through the ODDR2 primitive, the second way is how to use;
DCM Dcm_inst (
. Clkin (Clkin),
. Clkout (Clkout_w)
);
If the clkout_w is to receive a normal IO pin, it needs to pass the ODDR2 primitive, as follows:
Wire Clkout_w;
ODDR2 # (
. Ddr_alignment ("None"),//sets output ALIGNMENT to "none", "C0", "C1"
. INIT (1 ' b0),//set initial state of the Q
. Srtype ("Sync")//specifies "Sync" or "ASYNC" Set/reset
)
Oddr2_inst (
. Q (clkout),//1-bit DDR output data
. C0 (clkout_w),//1-bit clock input
. C1 (~clkout_w),//1-bit clock input
. CE (1 ' B1),//1-bit clock Enable input
. D0 (1 ' B1),//1-bit data input (associated with C0)
. D1 (1 ' b0),//1-bit data input (associated with C1)
. R (1 ' b0),//1-bit Reset input
. S (1 ' b0)//1-bit set input
);
The clkout_w output to the Clkout,clkout can be configured directly on the normal IO pin via the ODDR2 primitive.
DCM Global clock in Ise converted to normal IO