How Do You Represent High Impedance States in Verilog?

  • Thread starter Thread starter asd1249jf
  • Start date Start date
  • Tags Tags
    Impedance
Join the discussion
Registration is free. Ask a follow-up in this thread, or start your own.
1 reply · 15K views
asd1249jf
High Impedance in Verilog?

Homework Statement



Provide the correct Verilog text for encoding the following numerical values:

A) A 16 bit hexadecimal with all positions in the high impedance state:

B) An unsized hex number BEEF

Homework Equations



Verilog Problem. There is no relavant equation to be used.

The Attempt at a Solution



What the.. I didn't even know a variable can literally be declared as high impedance. I thought high impedance state occurs when the variable is neither off or on.

Also, I thought the variables you declare in verilog MUST be sized.

How are these accomplished?
 
Last edited by a moderator:
Physics news on Phys.org
l46kok said:

Homework Statement



Provide the correct Verilog text for encoding the following numerical values:

A) A 16 bit hexadecimal with all positions in the high impedance state:

B) An unsized hex number BEEF

Homework Equations



Verilog Problem. There is no relavant equation to be used.

The Attempt at a Solution



What the.. I didn't even know a variable can literally be declared as high impedance. I thought high impedance state occurs when the variable is neither off or on.

Also, I thought the variables you declare in verilog MUST be sized.

How are these accomplished?

You actually can have the states as high-impedance. In your case, it would be

16'h?
or
16'hz

would work.

There is no such thing as unsized hex number. Even if you forget to declare the size, by default, verilog would size it as 32 bit.