aboutsummaryrefslogtreecommitdiffstats
path: root/usrp2/fifo
diff options
context:
space:
mode:
authorMatt Ettus <matt@ettus.com>2011-03-06 22:51:38 -0800
committerMatt Ettus <matt@ettus.com>2011-03-06 22:51:38 -0800
commit942b7039f0449a90f9b0dfd2c35160d05748fcbb (patch)
treef4d2e3080054730690059dd6b64be5f4d9da54c7 /usrp2/fifo
parent440dc1f85c487a31572463ee041abb8c1379d25a (diff)
downloaduhd-942b7039f0449a90f9b0dfd2c35160d05748fcbb.tar.gz
uhd-942b7039f0449a90f9b0dfd2c35160d05748fcbb.tar.bz2
uhd-942b7039f0449a90f9b0dfd2c35160d05748fcbb.zip
u2/u2p: fix off-by-one error in dsp_framer
Diffstat (limited to 'usrp2/fifo')
-rw-r--r--usrp2/fifo/dsp_framer36.v3
1 files changed, 2 insertions, 1 deletions
diff --git a/usrp2/fifo/dsp_framer36.v b/usrp2/fifo/dsp_framer36.v
index 77a0ac5f7..d99b1fcaf 100644
--- a/usrp2/fifo/dsp_framer36.v
+++ b/usrp2/fifo/dsp_framer36.v
@@ -34,12 +34,13 @@ module dsp_framer36
.dataout(tfifo_data), .src_rdy_o(tfifo_out_src_rdy), .dst_rdy_i(tfifo_out_dst_rdy),
.space(), .occupied() );
+ // FIXME won't handle single-line packets, will show wrong length
always @(posedge clk)
if(reset | clear)
pkt_len_in <= 0;
else if(do_xfer_in)
if(data_i[32]) // sof
- pkt_len_in <= 1;
+ pkt_len_in <= 2; // fixes off by one since number is stored before increment
else
pkt_len_in <= pkt_len_in + 1;