Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

error when synchronizing a asynchronical signal

Status
Not open for further replies.

Kaka_fsk

Newbie level 5
Joined
Jul 6, 2006
Messages
10
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,354
I am trying to synchronize an asynchronical control signal using the following verilog code:

input clk;
input start;
output start_real;

reg [3:0] start_shift;

always@(posedge clk)
begin
start_shift <= { start_shift[2:0], start };
if (start_shift == 4'b1111)
start_real <= 1'b1;
else
start_real <= 1'b0;
end

I think four registers are enough to debounce the signal. But the post-place simulation still report error about setup time violation(see the image).


Could anyone give me some suggestion? Thanks in advance.
 

Is the input signal changed simultaneously with the clock signal in your testbench?

Synchronizing registers are useful when running design in hardware, but during simulation such thing won't help you. So maybe you shouldn't bother yourself with this problem.
 

Thanks for your reply, Ring0.

The input violate the setup time according to the error report.

Do you mean the post-route simulation can't take the debouncer into account, even in real life it works?

Thanks.
 

Well, the setup time is being violated, so the simulator is complaining. It is not intelligent enough to guess that your circuit is there for clock domain crossing purposes. It just sees a netlist and makes no assumptions about what you were trying to do.

You either have to turn off timing checks or ignore the errors.

r.b.
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top