mirror of
https://github.com/annoyatron255/yosys4gal.git
synced 2024-12-22 10:42:24 +00:00
15 lines
151 B
Coq
15 lines
151 B
Coq
|
module reg_tristate (
|
||
|
input clk,
|
||
|
input a, b, c,
|
||
|
output y
|
||
|
);
|
||
|
|
||
|
reg x;
|
||
|
|
||
|
assign y = c && b ? x : 1'bz;
|
||
|
|
||
|
always @ (posedge clk)
|
||
|
x <= a && b;
|
||
|
|
||
|
endmodule
|