M

Mr. Dubey • 52.74K Points
Coach

Q. Which of the following line is correct for detecting positive edge of a clock?

(A) if (clk’event and clk = ‘0’)
(B) if (clk’event and clk = ‘1’)
(C) if (clk’event or clk = ‘0’)
(D) if (clk’event or clk = ‘1’)
Share

Explanation by: Mr. Dubey
 the correct way to identify the positive edge of the clock signal is shown in option b. the ‘event attribute will detect the event and clk = ‘1’ will check whether its high on clock or not. in this way the positive edge is monitored. we need to use and operator because both of the conditions should be true.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.


Question analytics