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’)
πŸ’¬ Discuss
βœ… Correct Answer: (B) if (clk’event and clk = ‘1’)
Explanation: 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.

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.

πŸ’¬ Discussion

πŸ“Š Question Analytics

πŸ‘οΈ
358
Total Visits
πŸ“½οΈ
3 y ago
Published
πŸŽ–οΈ
Mr. Dubey
Publisher
πŸ“ˆ
97%
Success Rate