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.

what's the difference between them

Status
Not open for further replies.

tigerajs

Member level 3
Joined
Feb 8, 2006
Messages
55
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,286
Activity points
1,638
"@posedge clk" and "@posedge clk;"
 

First is a condition, another is a statement.
 

A semicolon ! Kidding ............ :) . Let me put it is code snipet and tell you .
1.
@posedge clk
a = 0 ;
// here the value of a is assigned to 0 after the event of posedge of clk .

2.
@posedge clk;
a = 0;
// Here value of a =0 after the event posedge of clk.
 

semiconductorman said:
A semicolon ! Kidding ............ :) . Let me put it is code snipet and tell you .
1.
@posedge clk
a = 0 ;
// here the value of a is assigned to 0 after the event of posedge of clk .

2.
@posedge clk;
a = 0;
// Here value of a =0 after the event posedge of clk.

If you only contian a assignmets in one block, there's no difference for these two ways; however, if there are more than one block which will assign some values to a with these two methods, then the result may be different.

Thomson
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top