I am learning and practicing Verilog HDL. I wanted to design a 16 bit parallel in series out shift register.
module verilog_shift_register_test_PISO( din, clk, load, dout );
output reg dout ;
input [15:0] din ;
input clk ;
input load ;
reg [15:0]temp;
always @ (clk or load) begin
if (load)
temp <= din;
else begin
dout <= temp[0];
temp <= {1'b0, temp[15:1]};
end
end
endmodule
I wrote this code and tried to simulate it.
simulation_result I could not understand the reason why data output (dout) signal is always LOW