verilog赋多位值_verilog赋值
我現(xiàn)在要用且只能用八位的撥片開(kāi)關(guān)對(duì)兩個(gè)四位變量t1l,t1h賦值,且這兩個(gè)變量t1l,t1h是要輸出的,所以我編了一下程序,先通過(guò)撥片開(kāi)關(guān)對(duì)輸入變量d0,d1賦值,然后將d0,d1的值賦給t1l,t1...
我現(xiàn)在要用且只能用八位的撥片開(kāi)關(guān)對(duì)兩個(gè)四位變量t1l,t1h賦值,且這兩個(gè)變量t1l,t1h是要輸出的,所以我編了一下程序,先通過(guò)撥片開(kāi)關(guān)對(duì)輸入變量d0,d1賦值,然后將d0,d1的值賦給t1l,t1h,再將t1l,t1h輸出,但總是不對(duì),錯(cuò)誤代碼:ERROR:Cpld:892 - Cannot place signal t2h<1>. Consider reducing the collapsing input limit or the product term limit to prevent the fitter from creating high input and/or high product term functions.
整個(gè)程序太長(zhǎng),這里只是部分我認(rèn)為和賦值相關(guān)的代碼:
module wash(clk1k,d0,d1,reset,t1l,t1h,t2l,t2h);
input clk1k,reset;
input d0,d1;
output t1l,t1h,t2l,t2h;
wire forward_wire,back_wire,stop_wire,sound_dc_wire;
wire start;
reg [3:0]t1l,t1h,t2l,t2h;
wire [3:0]d0,d1;
always @(posedge clk1k)
if (reset)
begin
{t1l,t1h,t2l,t2h}<= 16'd0;
end
else
begin
if({d0,d1}!=8'h0)
begin
t1h<=d0;
t1l<=d1;
end
謝謝各位了,我還是個(gè)新手,這個(gè)問(wèn)題困擾我好幾天了
展開(kāi)
創(chuàng)作挑戰(zhàn)賽新人創(chuàng)作獎(jiǎng)勵(lì)來(lái)咯,堅(jiān)持創(chuàng)作打卡瓜分現(xiàn)金大獎(jiǎng)總結(jié)
以上是生活随笔為你收集整理的verilog赋多位值_verilog赋值的全部?jī)?nèi)容,希望文章能夠幫你解決所遇到的問(wèn)題。
- 上一篇: 三星电子在印度面临税收纠纷,此前有消息称
- 下一篇: “vector”: 不是“std”的成员