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.

[SOLVED] sensing a signal async to clk

Status
Not open for further replies.

emresel

Full Member level 5
Joined
Feb 12, 2008
Messages
267
Helped
61
Reputation
122
Reaction score
61
Trophy points
1,308
Location
Turkiye
Activity points
2,862
Dear friends;
Is it possible to catch a signal like attached, it is async to clk and duration might be shorter than a half period of clk.
It should be catched until next rising edge of clk and reset output again.
Do you have any synthesizable vhdl proposal circuit?

signal.GIF

Regards
 

if sygnal = '1' then
out <= '1';
elsif Clk'event and Clk = '1' then
out <= '0';
end if;
 
  • Like
Reactions: emresel

    emresel

    Points: 2
    Helpful Answer Positive Rating
Thanks friends;
That helped me. But i have a few questions more. Since i am trying to learn vhdl/fpga concept myself sometimes need more expertised help. Hope you appreciate.
The code above is woking but when i change it like below, it is not synthesizable any more.

process (input, clk)
begin
if clk'event and clk = '1' then
output2 <= '0';
elsif input = '1' then
output2 <= '1';
end if;
end process;

It says "statement is not synthesizable since it does not hold its value under NOT(clock-edge) condition". Actually i can't figure out what is going wrong.
Could please explain some more on it?
Thank you

PS:I am doing this kinds of things sometimes and then stuck.
 

It says "statement is not synthesizable since it does not hold its value under NOT(clock-edge) condition". Actually i can't figure out what is going wrong.
Could please explain some more on it?
The construct is not following the required syntax for aysnchronous + synchronous register action which have been previously suggested in this thread by treger. The order of statements matters.
 
Thanks,
While i am checking the net also found the note in a tutor;
The condition for synchronous actions has to be the last condition of the if structure because asynchronous control signals are usually treated with higher priority by the underlying hardware cells


I think it may be noted as a general rule...
 

I think it may be noted as a general rule...
Yes, you can read more about it in text books dedicated to VHDL for hardware synthesis. You can also refer to IEEE Std 1076.3, which tries to define a portable subset of synthesizable VHDL.
 
Thank you FvM;
While searching 1076.3, I found also 1076.6 which seems a useful doc.
That tells "A clock edge shall only appear in the last elsif condition." point, too.
 

Although 1076.3 is also related to synthesis, I actually meant 1076.6. Please apologize for the confusion.
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top