47 /* uncomment if necessary 48 input wire [0:0] inaux, 49 output wire [0:0] outaux, **/ 52 uncomment if necessary 53 // bypass auxilary informational signals 56 always @ (posedge clk) 61 assign outaux = aux_rr; 63 // split incoming data in 2 bytes 70 // get decoded values after 2 clock cycles, all '1's = cannot be decoded 83 // last clock disparity 85 // disparity after 1st byte 92 always @ (
posedge clk)
99 // overall expected disparity when the table values would apper - disp0_r. 100 // disp1_rr shows expected after 0st byte would be considered 108 // invert disparity after a byte 109 // if current encoded word containg an equal amount of 1s and 0s (i.e. 5 x '1'), disp shall stay the same 110 // if amounts are unequal, there are either 4 or 6 '1's. in either case disp shall be inverted 120 // to correct disparity if once an error occured 124 // calculate disparity on table values 129 // table_pos_disp - for current 10-bit word disparity can be positive 130 // _neg_ - can be negative 131 // neg & pos - can be either of them 139 // TODO change mem to 18 instead of 36, so the highest address bit could be dropped
14732correct_table_dispreg
[14-LOG2WIDTH_A:0] 12040addr_a
wire [1:0] 14719disperror
14734expected_disparity_intermwire
14733expected_disparitywire
wire [1:0] 14718notintable
[1 << LOG2WIDTH_A-1:0] 12045data_in_a
decoding_table ramt_var_w_var_r
[1 << LOG2WIDTH_B-1:0] 12052data_in_b
14723table1_outwire[15:0]
14727disparity_intermwire
[1 << LOG2WIDTH_A-1:0] 12044data_out_a
[14-LOG2WIDTH_B:0] 12047addr_b
[1 << LOG2WIDTH_B-1:0] 12051data_out_b
14722table0_outwire[15:0]