diff options
| author | Josh Blum <josh@joshknows.com> | 2010-10-13 11:59:15 -0700 | 
|---|---|---|
| committer | Josh Blum <josh@joshknows.com> | 2010-10-13 11:59:15 -0700 | 
| commit | 35eda148fc3979c022c58166fa628d5b7dbfd80b (patch) | |
| tree | ca5b83f9a7a73963af1da32d1adff2a955ab76c3 | |
| parent | 2c08c9a7e62b2ad7f75047cc54b0256173f1b674 (diff) | |
| download | uhd-35eda148fc3979c022c58166fa628d5b7dbfd80b.tar.gz uhd-35eda148fc3979c022c58166fa628d5b7dbfd80b.tar.bz2 uhd-35eda148fc3979c022c58166fa628d5b7dbfd80b.zip | |
usrp2: increment tx sequence after commit
| -rw-r--r-- | host/lib/transport/vrt_packet_handler.hpp | 3 | ||||
| -rw-r--r-- | host/lib/usrp/usrp2/io_impl.cpp | 1 | 
2 files changed, 3 insertions, 1 deletions
| diff --git a/host/lib/transport/vrt_packet_handler.hpp b/host/lib/transport/vrt_packet_handler.hpp index 939517411..d5f03de0e 100644 --- a/host/lib/transport/vrt_packet_handler.hpp +++ b/host/lib/transport/vrt_packet_handler.hpp @@ -318,7 +318,7 @@ template <typename T> UHD_INLINE T get_context_code(      ){          //load the rest of the if_packet_info in here          if_packet_info.num_payload_words32 = (num_samps*chans_per_otw_buff*otw_type.get_sample_size())/sizeof(boost::uint32_t); -        if_packet_info.packet_count = state.next_packet_seq++; +        if_packet_info.packet_count = state.next_packet_seq;          //get send buffers for each channel          managed_send_buffs_t send_buffs(buffs.size()/chans_per_otw_buff); @@ -345,6 +345,7 @@ template <typename T> UHD_INLINE T get_context_code(              size_t num_bytes_total = (vrt_header_offset_words32+if_packet_info.num_packet_words32)*sizeof(boost::uint32_t);              send_buffs[i]->commit(num_bytes_total);          } +        state.next_packet_seq++; //increment sequence after commits          return num_samps;      } diff --git a/host/lib/usrp/usrp2/io_impl.cpp b/host/lib/usrp/usrp2/io_impl.cpp index 48ff7d509..d6f7e8476 100644 --- a/host/lib/usrp/usrp2/io_impl.cpp +++ b/host/lib/usrp/usrp2/io_impl.cpp @@ -211,6 +211,7 @@ void usrp2_impl::io_impl::recv_pirate_loop(                  //print the famous U, and push the metadata into the message queue                  if (metadata.event_code & underflow_flags) std::cerr << "U" << std::flush; +                //else std::cout << "metadata.event_code " << metadata.event_code << std::endl;                  async_msg_fifo->push_with_pop_on_full(metadata);                  continue;              } | 
