yosys/manual/APPNOTE_011_Design_Investig.../splice.v

11 lines
212 B
Verilog
Raw Normal View History

2013-11-28 10:39:16 -06:00
module splice_demo(a, b, c, d, e, f, x, y);
input [1:0] a, b, c, d, e, f;
output [1:0] x = {a[0], a[1]};
output [11:0] y;
2013-11-29 05:51:16 -06:00
assign {y[11:4], y[1:0], y[3:2]} =
{a, b, -{c, d}, ~{e, f}};
2013-11-28 10:39:16 -06:00
endmodule