Verilog HDL:三态实例化

author-image

作者

此简单示例展示了如何使用关键字 bufif1 在 Verilog HDL 中对三态缓冲器进行实例化。输出类型为 tri。缓冲器通过变量名为 b1 的 bufif1 进行实例化。

有关在项目中使用此示例的更多信息,请参阅 Verilog 网页上的“如何使用 Verilog HDL 示例”部分。

tristate.v

module Tristate (in, oe, out);

    input   in, oe;
    output  out;
    tri     out;

    bufif1  b1(out, in, oe);

endmodule