diff options
Diffstat (limited to 'usrp2/fifo')
-rw-r--r-- | usrp2/fifo/packet_generator.v | 20 | ||||
-rw-r--r-- | usrp2/fifo/packet_generator32.v | 2 | ||||
-rw-r--r-- | usrp2/fifo/packet_verifier.v | 2 |
3 files changed, 22 insertions, 2 deletions
diff --git a/usrp2/fifo/packet_generator.v b/usrp2/fifo/packet_generator.v index a751fdfb1..bbcab6db2 100644 --- a/usrp2/fifo/packet_generator.v +++ b/usrp2/fifo/packet_generator.v @@ -2,7 +2,8 @@ module packet_generator (input clk, input reset, input clear, - output reg [7:0] data_o, output sof_o, output eof_o, + output reg [7:0] data_o, output sof_o, output eof_o, + input [127:0] header, output src_rdy_o, input dst_rdy_i); localparam len = 32'd2000; @@ -40,6 +41,23 @@ module packet_generator 5 : data_o <= seq[23:16]; 6 : data_o <= seq[15:8]; 7 : data_o <= seq[7:0]; + 8 : data_o <= header[7:0]; + 9 : data_o <= header[15:8]; + 10 : data_o <= header[23:16]; + 11 : data_o <= header[31:24]; + 12 : data_o <= header[39:32]; + 13 : data_o <= header[47:40]; + 14 : data_o <= header[55:48]; + 15 : data_o <= header[63:56]; + 16 : data_o <= header[71:64]; + 17 : data_o <= header[79:72]; + 18 : data_o <= header[87:80]; + 19 : data_o <= header[95:88]; + 20 : data_o <= header[103:96]; + 21 : data_o <= header[111:104]; + 22 : data_o <= header[119:112]; + 23 : data_o <= header[127:120]; + 32'hFFFF_FFFC : data_o <= crc_out[31:24]; 32'hFFFF_FFFD : data_o <= crc_out[23:16]; 32'hFFFF_FFFE : data_o <= crc_out[15:8]; diff --git a/usrp2/fifo/packet_generator32.v b/usrp2/fifo/packet_generator32.v index 6f8004964..1dc57191d 100644 --- a/usrp2/fifo/packet_generator32.v +++ b/usrp2/fifo/packet_generator32.v @@ -2,6 +2,7 @@ module packet_generator32 (input clk, input reset, input clear, + input [127:0] header, output [35:0] data_o, output src_rdy_o, input dst_rdy_i); wire [7:0] ll_data; @@ -10,6 +11,7 @@ module packet_generator32 packet_generator pkt_gen (.clk(clk), .reset(reset), .clear(clear), .data_o(ll_data), .sof_o(ll_sof), .eof_o(ll_eof), + .header(header), .src_rdy_o(ll_src_rdy), .dst_rdy_i(~ll_dst_rdy_n)); ll8_to_fifo36 ll8_to_f36 diff --git a/usrp2/fifo/packet_verifier.v b/usrp2/fifo/packet_verifier.v index b49ad1bbb..21a4c136e 100644 --- a/usrp2/fifo/packet_verifier.v +++ b/usrp2/fifo/packet_verifier.v @@ -18,7 +18,7 @@ module packet_verifier reg [31:0] length; wire first_byte, last_byte; reg second_byte, last_byte_d1; - + wire match_crc; wire calc_crc = src_rdy_i & dst_rdy_o; crc crc(.clk(clk), .reset(reset), .clear(last_byte_d1), .data(data_i), |