From 1156d9b26a59ae45ec34b2fcb7ac782f4bf03b40 Mon Sep 17 00:00:00 2001 From: Josh Blum Date: Tue, 21 Feb 2012 17:42:15 -0800 Subject: usrp1: fix advertised samples per packet in send streamer Must subtract off the 511 for 512 modulus remainder commit. This bug was introduced by the conversion to streamer API. --- host/lib/usrp/usrp1/io_impl.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/host/lib/usrp/usrp1/io_impl.cpp b/host/lib/usrp/usrp1/io_impl.cpp index f27135562..ff2b6017f 100644 --- a/host/lib/usrp/usrp1/io_impl.cpp +++ b/host/lib/usrp/usrp1/io_impl.cpp @@ -651,7 +651,8 @@ tx_streamer::sptr usrp1_impl::get_tx_stream(const uhd::stream_args_t &args_){ _iface->poke32(FR_TX_FORMAT, bmFR_TX_FORMAT_16_IQ); //calculate packet size - const size_t bpp = _data_transport->get_send_frame_size()/args.channels.size(); + size_t bpp = _data_transport->get_send_frame_size()/args.channels.size(); + bpp -= alignment_padding - 1; //minus the max remainder after LUT commit const size_t spp = bpp/convert::get_bytes_per_item(args.otw_format); //make the new streamer given the samples per packet -- cgit v1.2.3