我正在开发一个包含一个主机和三个从机的SPI模块。在测试台上,我想通过多维数组(它是SPI模块的输入)为每个从机提供并行负载。
reg [7:0] slaves_inload [3:1]= ?
I have no idea what should I write on the RHS of this. Suppose I'd like to pass : 8'b11101101
, 8'b10101010
and 8'b10001000
for slaves [1], [2], [3], respectively.
初始化数组的一种方法如下: