[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Commit-gnuradio] r10829 - in gnuradio/branches/releases/3.2: . gnuradio
From: |
jcorgan |
Subject: |
[Commit-gnuradio] r10829 - in gnuradio/branches/releases/3.2: . gnuradio-core/src/lib/general gnuradio-core/src/lib/runtime gnuradio-core/src/python/gnuradio/blks2impl gnuradio-core/src/python/gnuradio/gr gr-pager/src gr-wxgui/src/python gr-wxgui/src/python/plotter grc/data/platforms/python/blocks usrp2/firmware/include usrp2/host/lib |
Date: |
Tue, 14 Apr 2009 13:31:58 -0600 (MDT) |
Author: jcorgan
Date: 2009-04-14 13:31:57 -0600 (Tue, 14 Apr 2009)
New Revision: 10829
Modified:
gnuradio/branches/releases/3.2/
gnuradio/branches/releases/3.2/gnuradio-core/src/lib/general/gr_mpsk_receiver_cc.cc
gnuradio/branches/releases/3.2/gnuradio-core/src/lib/general/gri_fft.cc
gnuradio/branches/releases/3.2/gnuradio-core/src/lib/runtime/gr_tpb_thread_body.cc
gnuradio/branches/releases/3.2/gnuradio-core/src/python/gnuradio/blks2impl/qam8.py
gnuradio/branches/releases/3.2/gnuradio-core/src/python/gnuradio/blks2impl/wfm_rcv_pll.py
gnuradio/branches/releases/3.2/gnuradio-core/src/python/gnuradio/gr/pubsub.py
gnuradio/branches/releases/3.2/gr-pager/src/pager_utils.py
gnuradio/branches/releases/3.2/gr-pager/src/usrp_flex.py
gnuradio/branches/releases/3.2/gr-pager/src/usrp_flex_all.py
gnuradio/branches/releases/3.2/gr-pager/src/usrp_flex_band.py
gnuradio/branches/releases/3.2/gr-wxgui/src/python/plotter/grid_plotter_base.py
gnuradio/branches/releases/3.2/gr-wxgui/src/python/scopesink_gl.py
gnuradio/branches/releases/3.2/grc/data/platforms/python/blocks/blks2_wfm_rcv_pll.xml
gnuradio/branches/releases/3.2/grc/data/platforms/python/blocks/gr_add_xx.xml
gnuradio/branches/releases/3.2/grc/data/platforms/python/blocks/gr_multiply_xx.xml
gnuradio/branches/releases/3.2/usrp2/firmware/include/usrp2_eth_packet.h
gnuradio/branches/releases/3.2/usrp2/host/lib/usrp2_impl.cc
Log:
Applied changesets r10681, r10686, r10689, r10691, r10700:10702, r10734,
r10736, and r10745 to release 3.2 branch.
Property changes on: gnuradio/branches/releases/3.2
___________________________________________________________________
Modified: svn:mergeinfo
- /gnuradio/branches/developers/eb/t348:10638-10648
/gnuradio/branches/developers/jblum/gui_guts:10464-10658
/gnuradio/branches/developers/jblum/vlen:10667-10677
/gnuradio/branches/developers/michaelld/am_swig_4:10555-10595
/gnuradio/branches/developers/michaelld/two_mods:10540-10546
/gnuradio/trunk:10356-10359,10481-10482,10497-10499,10506-10507,10511,10514,10521,10523-10524,10529,10531,10535,10537-10538,10550-10551,10556,10558-10560,10562-10563,10565,10574-10576,10578-10579,10581-10582,10585,10587,10596-10600,10623-10624,10629,10632-10634,10645-10646,10649-10650,10653-10655,10660-10661,10671,10673,10678
+ /gnuradio/branches/developers/eb/t348:10638-10648
/gnuradio/branches/developers/eb/t378:10683-10688
/gnuradio/branches/developers/jblum/gui_guts:10464-10658
/gnuradio/branches/developers/jblum/vlen:10667-10677
/gnuradio/branches/developers/michaelld/am_swig_4:10555-10595
/gnuradio/branches/developers/michaelld/two_mods:10540-10546
/gnuradio/trunk:10356-10359,10481-10482,10497-10499,10506-10507,10511,10514,10521,10523-10524,10529,10531,10535,10537-10538,10550-10551,10556,10558-10560,10562-10563,10565,10574-10576,10578-10579,10581-10582,10585,10587,10596-10600,10623-10624,10629,10632-10634,10645-10646,10649-10650,10653-10655,10660-10661,10671,10673,10678,10681,10686,10689,10691,10701-10702,10734-10736,10745
Modified:
gnuradio/branches/releases/3.2/gnuradio-core/src/lib/general/gr_mpsk_receiver_cc.cc
===================================================================
---
gnuradio/branches/releases/3.2/gnuradio-core/src/lib/general/gr_mpsk_receiver_cc.cc
2009-04-14 19:25:48 UTC (rev 10828)
+++
gnuradio/branches/releases/3.2/gnuradio-core/src/lib/general/gr_mpsk_receiver_cc.cc
2009-04-14 19:31:57 UTC (rev 10829)
@@ -257,7 +257,7 @@
phase_error = gr_branchless_clip(phase_error, 1.0);
d_freq += d_beta*phase_error; // adjust frequency based on error
- d_phase += d_freq + d_alpha*phase_error; // adjust phase based on error
+ d_phase += d_alpha*phase_error; // adjust phase based on error
// Make sure we stay within +-2pi
while(d_phase > M_TWOPI)
Modified:
gnuradio/branches/releases/3.2/gnuradio-core/src/lib/general/gri_fft.cc
===================================================================
--- gnuradio/branches/releases/3.2/gnuradio-core/src/lib/general/gri_fft.cc
2009-04-14 19:25:48 UTC (rev 10828)
+++ gnuradio/branches/releases/3.2/gnuradio-core/src/lib/general/gri_fft.cc
2009-04-14 19:31:57 UTC (rev 10829)
@@ -194,6 +194,9 @@
gri_fft_real_rev::gri_fft_real_rev (int fft_size)
{
+ // Hold global mutex during plan construction and destruction.
+ gri_fft_planner::scoped_lock lock(gri_fft_planner::mutex());
+
assert (sizeof (fftwf_complex) == sizeof (gr_complex));
if (fft_size <= 0)
Modified:
gnuradio/branches/releases/3.2/gnuradio-core/src/lib/runtime/gr_tpb_thread_body.cc
===================================================================
---
gnuradio/branches/releases/3.2/gnuradio-core/src/lib/runtime/gr_tpb_thread_body.cc
2009-04-14 19:25:48 UTC (rev 10828)
+++
gnuradio/branches/releases/3.2/gnuradio-core/src/lib/runtime/gr_tpb_thread_body.cc
2009-04-14 19:31:57 UTC (rev 10829)
@@ -23,6 +23,7 @@
#endif
#include <gr_tpb_thread_body.h>
#include <iostream>
+#include <boost/thread.hpp>
gr_tpb_thread_body::gr_tpb_thread_body(gr_block_sptr block)
: d_exec(block)
@@ -33,6 +34,8 @@
gr_block_executor::state s;
while (1){
+ boost::this_thread::interruption_point();
+
d->d_tpb.clear_changed();
s = d_exec.run_one_iteration();
Modified:
gnuradio/branches/releases/3.2/gnuradio-core/src/python/gnuradio/blks2impl/qam8.py
===================================================================
---
gnuradio/branches/releases/3.2/gnuradio-core/src/python/gnuradio/blks2impl/qam8.py
2009-04-14 19:25:48 UTC (rev 10828)
+++
gnuradio/branches/releases/3.2/gnuradio-core/src/python/gnuradio/blks2impl/qam8.py
2009-04-14 19:31:57 UTC (rev 10829)
@@ -192,7 +192,7 @@
gr.hier_block2.__init__(self, "qam8_demod",
gr.io_signature(1, 1, gr.sizeof_gr_complex), #
Input signature
- gr.io_signature(1, 1, gr.sizeof_gr_char)) #
Output signature
+ gr.io_signature(1, 1, gr.sizeof_char)) #
Output signature
# do this
pass
Modified:
gnuradio/branches/releases/3.2/gnuradio-core/src/python/gnuradio/blks2impl/wfm_rcv_pll.py
===================================================================
---
gnuradio/branches/releases/3.2/gnuradio-core/src/python/gnuradio/blks2impl/wfm_rcv_pll.py
2009-04-14 19:25:48 UTC (rev 10828)
+++
gnuradio/branches/releases/3.2/gnuradio-core/src/python/gnuradio/blks2impl/wfm_rcv_pll.py
2009-04-14 19:31:57 UTC (rev 10829)
@@ -38,7 +38,7 @@
"""
gr.hier_block2.__init__(self, "wfm_rcv_pll",
gr.io_signature(1, 1, gr.sizeof_gr_complex), #
Input signature
- gr.io_signature(1, 2, gr.sizeof_float)) #
Output signature
+ gr.io_signature(2, 2, gr.sizeof_float)) #
Output signature
bandwidth = 250e3
audio_rate = demod_rate / audio_decimation
@@ -187,5 +187,7 @@
# The result of Make_Right gets (L+R) - (L-R) and results in 2*R
self.connect(self.Make_Left , self.deemph_Left, (self, 0))
self.connect(self.Make_Right, self.deemph_Right, (self, 1))
- else:
- self.connect (self.fm_demod, self.audio_filter, self)
+ # NOTE: mono support will require variable number of outputs in
hier_block2s
+ # See ticket:174 in Trac database
+ #else:
+ # self.connect (self.fm_demod, self.audio_filter, self)
Property changes on:
gnuradio/branches/releases/3.2/gnuradio-core/src/python/gnuradio/gr/pubsub.py
___________________________________________________________________
Modified: svn:mergeinfo
-
/gnuradio/branches/developers/eb/t348/gnuradio-core/src/python/gnuradio/gr/pubsub.py:10638-10648
/gnuradio/branches/developers/jblum/vlen/gnuradio-core/src/python/gnuradio/gr/pubsub.py:10667-10677
/gnuradio/trunk/gnuradio-core/src/python/gnuradio/gr/pubsub.py:10653-10655,10660-10661,10671,10673,10678
+
/gnuradio/branches/developers/eb/t348/gnuradio-core/src/python/gnuradio/gr/pubsub.py:10638-10648
/gnuradio/branches/developers/eb/t378/gnuradio-core/src/python/gnuradio/gr/pubsub.py:10683-10688
/gnuradio/branches/developers/jblum/vlen/gnuradio-core/src/python/gnuradio/gr/pubsub.py:10667-10677
/gnuradio/trunk/gnuradio-core/src/python/gnuradio/gr/pubsub.py:10653-10655,10660-10661,10671,10673,10678,10681,10686,10689,10691,10701-10702,10734-10736,10745
Modified: gnuradio/branches/releases/3.2/gr-pager/src/pager_utils.py
===================================================================
--- gnuradio/branches/releases/3.2/gr-pager/src/pager_utils.py 2009-04-14
19:25:48 UTC (rev 10828)
+++ gnuradio/branches/releases/3.2/gr-pager/src/pager_utils.py 2009-04-14
19:31:57 UTC (rev 10829)
@@ -1,5 +1,5 @@
#
-# Copyright 2008 Free Software Foundation, Inc.
+# Copyright 2008,2009 Free Software Foundation, Inc.
#
# This file is part of GNU Radio
#
@@ -18,7 +18,10 @@
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
#
+from gnuradio import gr
import gnuradio.gr.gr_threading as _threading
+from string import split, join, printable
+import time
def make_trans_table():
table = 256 * ['.']
@@ -34,14 +37,24 @@
def make_printable(s):
return s.translate(_trans_table)
-class top_block_runner(_threading.Thread):
- def __init__(self, tb):
+
+class queue_runner(_threading.Thread):
+ def __init__(self, msgq):
_threading.Thread.__init__(self)
- self.setDaemon(1)
- self.tb = tb
+ self.msgq = msgq
self.done = False
self.start()
def run(self):
- self.tb.run()
+ while 1:
+ msg = self.msgq.delete_head() # Blocking read
+ if msg.type() != 0:
+ break
+
+ page = join(split(msg.to_string(), chr(128)), '|')
+ s = make_printable(page)
+ print msg.type(), s
+
+ def end(self):
+ self.msgq.insert_tail(gr.message(1))
self.done = True
Modified: gnuradio/branches/releases/3.2/gr-pager/src/usrp_flex.py
===================================================================
--- gnuradio/branches/releases/3.2/gr-pager/src/usrp_flex.py 2009-04-14
19:25:48 UTC (rev 10828)
+++ gnuradio/branches/releases/3.2/gr-pager/src/usrp_flex.py 2009-04-14
19:31:57 UTC (rev 10829)
@@ -1,7 +1,6 @@
#!/usr/bin/env python
-
#
-# Copyright 2006,2007 Free Software Foundation, Inc.
+# Copyright 2006,2007,2009 Free Software Foundation, Inc.
#
# This file is part of GNU Radio
#
@@ -25,7 +24,6 @@
from gnuradio.eng_option import eng_option
from optparse import OptionParser
import time, os, sys
-from string import split, join
"""
This example application demonstrates receiving and demodulating the
@@ -108,9 +106,9 @@
print "Channel filter has", len(taps), "taps."
self.chan = gr.freq_xlating_fir_filter_ccf(10, # Decimation rate
- taps, # Filter taps
- 0.0, # Offset frequency
- 250e3) # Sample rate
+ taps, # Filter taps
+ 0.0, # Offset frequency
+ 250e3) # Sample rate
if options.log:
chan_sink = gr.file_sink(gr.sizeof_gr_complex, 'chan.dat')
@@ -160,24 +158,15 @@
# Flow graph emits pages into message queue
queue = gr.msg_queue()
tb = app_top_block(options, queue)
- runner = pager.top_block_runner(tb)
+ runner = pager.queue_runner(queue)
try:
- while 1:
- if not queue.empty_p():
- msg = queue.delete_head() # Blocking read
- page = join(split(msg.to_string(), chr(128)), '|')
- s = pager.make_printable(page)
- print s
- tb.adjust_freq()
- elif runner.done:
- break
- else:
- time.sleep(1)
-
+ tb.run()
except KeyboardInterrupt:
- tb.stop()
- runner = None
+ pass
+ runner.end()
+
+
if __name__ == "__main__":
main()
Modified: gnuradio/branches/releases/3.2/gr-pager/src/usrp_flex_all.py
===================================================================
--- gnuradio/branches/releases/3.2/gr-pager/src/usrp_flex_all.py
2009-04-14 19:25:48 UTC (rev 10828)
+++ gnuradio/branches/releases/3.2/gr-pager/src/usrp_flex_all.py
2009-04-14 19:31:57 UTC (rev 10829)
@@ -1,4 +1,24 @@
#!/usr/bin/env python
+#
+# Copyright 2006,2007,2009 Free Software Foundation, Inc.
+#
+# This file is part of GNU Radio
+#
+# GNU Radio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 3, or (at your option)
+# any later version.
+#
+# GNU Radio is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with GNU Radio; see the file COPYING. If not, write to
+# the Free Software Foundation, Inc., 51 Franklin Street,
+# Boston, MA 02110-1301, USA.
+#
from gnuradio import gr, gru, usrp, optfir, eng_notation, blks2, pager
from gnuradio.eng_option import eng_option
@@ -21,10 +41,10 @@
subdev = usrp.selected_subdev(src, options.rx_subdev_spec)
src.set_mux(usrp.determine_rx_mux_value(src,
options.rx_subdev_spec))
src.set_decim_rate(20)
- result = usrp.tune(src, 0, subdev, 930.5e6+options.calibration)
+ result = usrp.tune(src, 0, subdev, 930.5125e6+options.calibration)
if options.verbose:
print "Using", subdev.name(), " for receiving."
- print "Tuned USRP to", 930.5e6+options.calibration
+ print "Tuned USRP to", 930.5125e6+options.calibration
taps = gr.firdes.low_pass(1.0,
1.0,
@@ -76,23 +96,14 @@
queue = gr.msg_queue()
tb = app_top_block(options, queue)
+ runner = pager.queue_runner(queue)
- runner = pager.top_block_runner(tb)
try:
- while 1:
- if not queue.empty_p():
- msg = queue.delete_head() # Blocking read
- page = join(split(msg.to_string(), chr(128)), '|')
- s = pager.make_printable(page)
- print s
- elif runner.done:
- break
- else:
- time.sleep(0.05)
+ tb.run()
+ except KeyboardInterrupt:
+ pass
- except KeyboardInterrupt:
- tb.stop()
- runner = None
+ runner.end()
if __name__ == "__main__":
main()
Modified: gnuradio/branches/releases/3.2/gr-pager/src/usrp_flex_band.py
===================================================================
--- gnuradio/branches/releases/3.2/gr-pager/src/usrp_flex_band.py
2009-04-14 19:25:48 UTC (rev 10828)
+++ gnuradio/branches/releases/3.2/gr-pager/src/usrp_flex_band.py
2009-04-14 19:31:57 UTC (rev 10829)
@@ -1,10 +1,28 @@
#!/usr/bin/env python
+#
+# Copyright 2006,2007,2009 Free Software Foundation, Inc.
+#
+# This file is part of GNU Radio
+#
+# GNU Radio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 3, or (at your option)
+# any later version.
+#
+# GNU Radio is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with GNU Radio; see the file COPYING. If not, write to
+# the Free Software Foundation, Inc., 51 Franklin Street,
+# Boston, MA 02110-1301, USA.
+#
from gnuradio import gr, gru, usrp, optfir, eng_notation, blks2, pager
from gnuradio.eng_option import eng_option
from optparse import OptionParser
-from string import split, join, printable
-import time
class app_top_block(gr.top_block):
def __init__(self, options, queue):
@@ -54,10 +72,6 @@
if options.log:
self.connect((bank, i), gr.file_sink(gr.sizeof_gr_complex,
'chan_'+'%3.3f'%(freq/1e6)+'.dat'))
- def __del__(self):
- # Avoid weak-ref error
- del self.subdev
-
def main():
parser = OptionParser(option_class=eng_option)
@@ -82,23 +96,15 @@
queue = gr.msg_queue()
tb = app_top_block(options, queue)
+ runner = pager.queue_runner(queue)
- runner = pager.top_block_runner(tb)
try:
- while 1:
- if not queue.empty_p():
- msg = queue.delete_head() # Blocking read
- page = join(split(msg.to_string(), chr(128)), '|')
- s = pager.make_printable(page)
- print s
- elif runner.done:
- break
- else:
- time.sleep(0.05)
+ tb.run()
+ except KeyboardInterrupt:
+ pass
- except KeyboardInterrupt:
- tb.stop()
- runner = None
+ runner.end()
+
if __name__ == "__main__":
main()
Property changes on:
gnuradio/branches/releases/3.2/gr-wxgui/src/python/plotter/grid_plotter_base.py
___________________________________________________________________
Modified: svn:mergeinfo
-
/gnuradio/branches/developers/jblum/vlen/gr-wxgui/src/python/plotter/grid_plotter_base.py:10667-10677
/gnuradio/trunk/gr-wxgui/src/python/plotter/grid_plotter_base.py:10673,10678
+
/gnuradio/branches/developers/eb/t378/gr-wxgui/src/python/plotter/grid_plotter_base.py:10683-10688
/gnuradio/branches/developers/jblum/vlen/gr-wxgui/src/python/plotter/grid_plotter_base.py:10667-10677
/gnuradio/trunk/gr-wxgui/src/python/plotter/grid_plotter_base.py:10673,10678,10681,10686,10689,10691,10701-10702,10734-10736,10745
Modified: gnuradio/branches/releases/3.2/gr-wxgui/src/python/scopesink_gl.py
===================================================================
--- gnuradio/branches/releases/3.2/gr-wxgui/src/python/scopesink_gl.py
2009-04-14 19:25:48 UTC (rev 10828)
+++ gnuradio/branches/releases/3.2/gr-wxgui/src/python/scopesink_gl.py
2009-04-14 19:31:57 UTC (rev 10829)
@@ -76,6 +76,7 @@
ac_couple=False,
num_inputs=1,
frame_rate=scope_window.DEFAULT_FRAME_RATE,
+ **kwargs #do not end with a comma
):
if not t_scale: t_scale = 10.0/sample_rate
#init
Modified:
gnuradio/branches/releases/3.2/grc/data/platforms/python/blocks/blks2_wfm_rcv_pll.xml
===================================================================
---
gnuradio/branches/releases/3.2/grc/data/platforms/python/blocks/blks2_wfm_rcv_pll.xml
2009-04-14 19:25:48 UTC (rev 10828)
+++
gnuradio/branches/releases/3.2/grc/data/platforms/python/blocks/blks2_wfm_rcv_pll.xml
2009-04-14 19:31:57 UTC (rev 10829)
@@ -27,7 +27,11 @@
<type>complex</type>
</sink>
<source>
- <name>out</name>
+ <name>Lout</name>
<type>float</type>
</source>
+ <source>
+ <name>Rout</name>
+ <type>float</type>
+ </source>
</block>
Property changes on:
gnuradio/branches/releases/3.2/grc/data/platforms/python/blocks/gr_add_xx.xml
___________________________________________________________________
Modified: svn:mergeinfo
-
/gnuradio/branches/developers/eb/t348/grc/data/platforms/python/blocks/gr_add_vxx.xml:10638-10648
/gnuradio/branches/developers/jblum/gui_guts/grc/data/platforms/python/blocks/gr_add_vxx.xml:10464-10658
/gnuradio/branches/developers/michaelld/am_swig_4/grc/data/platforms/python/blocks/gr_add_vxx.xml:10555-10595
/gnuradio/branches/developers/michaelld/two_mods/grc/data/platforms/python/blocks/gr_add_vxx.xml:10540-10546
+
/gnuradio/branches/developers/eb/t348/grc/data/platforms/python/blocks/gr_add_vxx.xml:10638-10648
/gnuradio/branches/developers/eb/t378/grc/data/platforms/python/blocks/gr_add_xx.xml:10683-10688
/gnuradio/branches/developers/jblum/gui_guts/grc/data/platforms/python/blocks/gr_add_vxx.xml:10464-10658
/gnuradio/branches/developers/michaelld/am_swig_4/grc/data/platforms/python/blocks/gr_add_vxx.xml:10555-10595
/gnuradio/branches/developers/michaelld/two_mods/grc/data/platforms/python/blocks/gr_add_vxx.xml:10540-10546
/gnuradio/trunk/grc/data/platforms/python/blocks/gr_add_xx.xml:10681,10686,10689,10691,10701-10702,10734-10736,10745
Property changes on:
gnuradio/branches/releases/3.2/grc/data/platforms/python/blocks/gr_multiply_xx.xml
___________________________________________________________________
Modified: svn:mergeinfo
-
/gnuradio/branches/developers/eb/t348/grc/data/platforms/python/blocks/gr_multiply_vxx.xml:10638-10648
/gnuradio/branches/developers/jblum/gui_guts/grc/data/platforms/python/blocks/gr_multiply_vxx.xml:10464-10658
/gnuradio/branches/developers/michaelld/am_swig_4/grc/data/platforms/python/blocks/gr_multiply_vxx.xml:10555-10595
/gnuradio/branches/developers/michaelld/two_mods/grc/data/platforms/python/blocks/gr_multiply_vxx.xml:10540-10546
+
/gnuradio/branches/developers/eb/t348/grc/data/platforms/python/blocks/gr_multiply_vxx.xml:10638-10648
/gnuradio/branches/developers/eb/t378/grc/data/platforms/python/blocks/gr_multiply_xx.xml:10683-10688
/gnuradio/branches/developers/jblum/gui_guts/grc/data/platforms/python/blocks/gr_multiply_vxx.xml:10464-10658
/gnuradio/branches/developers/michaelld/am_swig_4/grc/data/platforms/python/blocks/gr_multiply_vxx.xml:10555-10595
/gnuradio/branches/developers/michaelld/two_mods/grc/data/platforms/python/blocks/gr_multiply_vxx.xml:10540-10546
/gnuradio/trunk/grc/data/platforms/python/blocks/gr_multiply_xx.xml:10681,10686,10689,10691,10701-10702,10734-10736,10745
Modified:
gnuradio/branches/releases/3.2/usrp2/firmware/include/usrp2_eth_packet.h
===================================================================
--- gnuradio/branches/releases/3.2/usrp2/firmware/include/usrp2_eth_packet.h
2009-04-14 19:25:48 UTC (rev 10828)
+++ gnuradio/branches/releases/3.2/usrp2/firmware/include/usrp2_eth_packet.h
2009-04-14 19:31:57 UTC (rev 10829)
@@ -150,6 +150,7 @@
*/
#define U2_MAX_SAMPLES 371
+#define U2_MIN_SAMPLES 9
typedef struct {
u2_eth_packet_t hdrs;
Modified: gnuradio/branches/releases/3.2/usrp2/host/lib/usrp2_impl.cc
===================================================================
--- gnuradio/branches/releases/3.2/usrp2/host/lib/usrp2_impl.cc 2009-04-14
19:25:48 UTC (rev 10828)
+++ gnuradio/branches/releases/3.2/usrp2/host/lib/usrp2_impl.cc 2009-04-14
19:31:57 UTC (rev 10829)
@@ -932,10 +932,8 @@
if (nitems == 0)
return true;
- // FIXME there's the possibility that we send fewer than 9 items in a
frame.
- // That would end up glitching the transmitter, since the ethernet will
pad to
- // 64-bytes total (9 items). We really need some part of the stack to
- // carry the real length (thdr?).
+ // FIXME can't deal with nitems < U2_MIN_SAMPLES (will be fixed in VRT)
+ // FIXME need to check the MTU instead of assuming 1500 bytes
// fragment as necessary then fire away
@@ -965,7 +963,12 @@
init_etf_hdrs(&hdrs, d_addr, flags, channel, timestamp);
- size_t i = std::min((size_t) U2_MAX_SAMPLES, nitems - n);
+ // Avoid short packet by splitting last two packets if reqd
+ size_t i;
+ if ((nitems - n) > U2_MAX_SAMPLES && (nitems - n) < (U2_MAX_SAMPLES +
U2_MIN_SAMPLES))
+ i = (nitems - n) / 2;
+ else
+ i = std::min((size_t) U2_MAX_SAMPLES, nitems - n);
eth_iovec iov[2];
iov[0].iov_base = &hdrs;
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Commit-gnuradio] r10829 - in gnuradio/branches/releases/3.2: . gnuradio-core/src/lib/general gnuradio-core/src/lib/runtime gnuradio-core/src/python/gnuradio/blks2impl gnuradio-core/src/python/gnuradio/gr gr-pager/src gr-wxgui/src/python gr-wxgui/src/python/plotter grc/data/platforms/python/blocks usrp2/firmware/include usrp2/host/lib,
jcorgan <=