reg0 <= 8'b11111001; reg0 <= {reg0[6:0], reg0[0] ^ reg0[3] ^ reg0[7]}; out <= reg0[7]; 给出前20个周期的输出序列
时间: 2024-01-07 10:05:29 浏览: 57
根据给定的Verilog代码,可以得到以下前20个周期的输出序列:
周期1: out = 1
周期2: out = 0
周期3: out = 0
周期4: out = 1
周期5: out = 1
周期6: out = 1
周期7: out = 0
周期8: out = 0
周期9: out = 1
周期10: out = 0
周期11: out = 0
周期12: out = 0
周期13: out = 1
周期14: out = 1
周期15: out = 1
周期16: out = 1
周期17: out = 0
周期18: out = 1
周期19: out = 0
周期20: out = 0
相关问题
reg0 <= 8'b11111001; reg0 <= {reg0[6:0], reg0[0] ^ reg0[3] ^ reg0[7]}; out <= reg0[7]; 给出前20个周期的结果
经过手动模拟,前20个周期的结果如下:
周期 | reg0 | out
---- | ---- | ---
0 | 11111001 | 1
1 | 11110011 | 1
2 | 11100111 | 1
3 | 11001111 | 1
4 | 10011110 | 0
5 | 00111101 | 1
6 | 01111010 | 0
7 | 11110100 | 1
8 | 11101001 | 1
9 | 11010011 | 1
10 | 10100111 | 0
11 | 01001110 | 1
12 | 10011100 | 0
13 | 00111001 | 1
14 | 01110010 | 0
15 | 11100100 | 1
16 | 11001001 | 1
17 | 10010011 | 0
18 | 00100110 | 1
19 | 01001100 | 0
阅读全文