In Xilinx, how do I delay a signal by a fraction of a clock cycle?

I am outputting a data with a clock 12.5MHz, which will latch the data into external chip whose input delay is unknown. I am trying to connect eight FPGA IO pads to the same clock, and delay each of them 1/8 of my main clock period, i.e. 10 ns, expecting one of them will work correctly. What constraint can I use in UCF file?

Thanks in advance

Reply to
Frank
Loading thread data ...

Not the right way to solve the problem, as the delay can vary by a lot depending on part, VCC and temperature.

For a suggestion of better idea, first, what part? Second, what other clocks do you have available?

If you have a 50 MHz clock available, the design can move an output by

10 ns by just changing the clock edge, and by 20 ns by delaying to the next clock.

A "DCM" might help as well.

--
Phil Hays to reply solve: phil_hays at not(coldmail) dot com  
 If not cold then hot
Reply to
Phil Hays

Hi Frank, I guess you want to be able to constrain the maximum clock to data delay of your FPGA output. If not ignore this message :-) You can use the OFFSET - OUT - AFTER constraint in the UCF file to do that. eg. NET "" OFFSET = OUT 5 ns AFTER "" HIGH;

Reply to
Kunal Shenoy

Do you have a faster clock available (50 MHz or 100 MHz) ? Are you sending data to a latch or to an edge-triggered flip-flop or register? With a flip-flop or register, just use the opposite clock polarity, i.e. the clock edge that did NOT generate the output data. That edge is

40 ns later than the data change, and that should be a very safe margin. Peter Alfke, Xilinx Applications
Reply to
Peter Alfke

correctly.

that.

Thank you, I used to think OFFSET gives a maximum delay, which means an offset value of 60ns or 70ns gives same result, since the real offset is 50ns. Am I right? I will try out this OFFSET technique.

Reply to
Frank

Just wanna make sure we are talking about the same thing. Your situation: You have an FPGA and another device being clocked by the same signal. The FPGA outputs some data to the external device. On active clock edge 1 (for example), the FPGA will output some data. The external device will register that data (as input) on active clock edge 2. Now you want to be able to satisfy the setup time of the external device's input flip flop, which means you want to be able to specify the MAXIMUM delay from the 1st active clock edge to the FPGA data being output. That can be done using the OFFSET-OUT-AFTER constraint in the UCF. It will take into account not only the delay of the data but also of the clock that activates the output flip flop.

Kunal @ Xilinx

Reply to
Kunal Shenoy

Frank schrieb:

Hi Frank, I would recommend you to use or generate somehow a higher Clock frequency. 50MHz would be just fine. Unfortunately you may be unable to generate this Clock from your 12.5 MHz with the builtin DLLs/DCMs for these require some minimum frequency (see the datasheets for details).

So, when I assume for a moment that you have a 50 MHZ Clock available you can build two cyclic shiftregister that shifts a single '1' over 4 FFs. One must be clocked by the rising edge one by the falling edge of the 50 MHz. Then you can use these 8 outputs as clock enable signals for your output FFs which also have to use rising and falling edge clocks alternating from one FF to the next.

A 12.5MHz Clock for the rest of your design can be derived from that 50 MHz easily by the DLLs/DCMs and your output value can be stored in an internal register that feeds the IOB-FFs which take the values with their respective delays due to the generated CE-Signals.

Thus the design wil be totally synchronous, and the Output to PAD delays of the IOBs should be quite equal anyway.

have a nice synthesis Eilert

Reply to
backhus

Frank schrieb:

Other posters helped you with your suggested approach. But I doubt that what you are trying to do is neccessary.

Whtat do you men by input delay? If data is clocked into a device usually there are two important parameters: Setup and hold time. It should be possible to find out what these are for your device. If you give us a part number maybe someone even knows the values.

Also, for virtually all devices that I know of both parameters are an order of magnitude smaller than 40ns. Therefore if you register the data at the opposite edge of your clock you are very likely meeting both requirements.

Also, hold times tend to be very small. Probably smaller than the Tco parameter of the FPGA. If this is true you can achieve a simpler design by registering the data with the same clock edge for both devices.

Kolja Sulimma

Reply to
Kolja Sulimma

References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-15 Content-Transfer-Encoding: 7bit Lines: 21 Message-ID: Organization: Arcor NNTP-Posting-Date: 10 Nov 2005 12:08:32 MET NNTP-Posting-Host: 8fafde03.newsread2.arcor-online.net X-Trace: DXC=0mCiCGa\TN

Reply to
Kolja Sulimma

Eilert, You can use the DCMs with clock inputs down to 1MHz as long as you use "frequency synthesis" mode, i.e. use the CLKFX output(s). The output clock must be greater than 24 MHz. I'm using the "datasheets for details"! ;-) Cheers then, Syms.

Reply to
Symon

Symon schrieb:

Hi Symon, Thank you for clarifying this on DCMs. I knew there was some limit, but hadn't had the time to look it up. But for DLLs a Minimim Input Frequency of 25 MHz is required (VirtexE Datasheet, Module 3 P.22), which may bother Frank with his 12.5 MHz Clock. Unfortunately he didn't mention his target device family.

Best regards Eilert

Reply to
backhus

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.