Clocked Delay in VHDL

J

jra

Hi --

I'm trying to create a VHDL module that acts as a clocked delay line.
There are two inputs -- SIG and CLK -- and one output -- RESULT.

I want all clock transitions on SIG (both positive and negative) to be
delayed by CLK cycles and then assigned to RESULT. The delay will very
likely be longer than the pulse width of SIG (but obviously shorter
than the repetition rate).

For example SIG may be a 100us long pulse repeating every second. CLK
could be 100kHz. The requirement may be to delay SIG by 1ms. There is
no system clock available to provide a calibrated delay; I need to use
the CLK signal which is being derived within the CPLD (and which is not
related to the global clock in the chip/.

I've spent the afternoon playing with this, and can get the rising edge
to delay the way I want it to. But when SIG falls, RESULT does not
follow. I suspect this is because my simple process is is looping
through its delay when SIG falls, and therefore the transition is
missed.

Any suggestions on how to implement this would be greatly appreciated.

Thanks,

John
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Members online

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,020
Latest member
GenesisGai

Latest Threads

Top