Wednesday, June 30, 2010

Re: [Discuss-gnuradio] Long-running app getting into trouble

On 05/31/2010 12:58 AM, Eric Blossom wrote:
>
> When it wedges, does it continue to consume CPU, or does it appear to
> be blocked?
>
>
Looks like it continues to consume cpu, but at a lower rate than "normal".

> When it wedges, you should be able to attach to it with gdb.
> Run gdb on /usr/bin/python, then attach it to the PID that corresponds
> to your app.
>
> (gdb) attach <pid>
> (gdb) thread apply all bt
>
> will generate a backtrace for all threads.
>
> Eric
>
>
>
Did that. But, well, there are 148 threads in this thing, so I'm not
really sure the torrent of data can
be understood by a single mind :-)


--
Marcus Leech
Principal Investigator
Shirleys Bay Radio Astronomy Consortium
http://www.sbrac.org

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

[Discuss-gnuradio] find_usrps not working

Hi,

I am trying to get USRP2 with RFX2400 daughterboard working on Ubuntu
9.10 (karmic). I have followed the instructions here
(http://gnuradio.org/redmine/wiki/1/UbuntuInstall).

I installed the firmware and FPGA code on the SD card from
http://code.ettus.com/redmine/ettus/projects/public/wiki/U2binaries. I
specifically used the "Raw Ethernet" FPGA image (rel-20100603) and the
"Raw Ethernet, No WBX or XCVR" Firmware image (Jun 08, 2010).

When I power up the USRP2, all the lights first glow, followed by only D
and F staying lit. The green light on the ethernet is also lit. However,
find_usrps returns with "No USRP2 found".

I ran it with wireshark. The command does send a broadcast ping packet
from the machine but receives no response. The orange light briefly
flashes at the time the packet is sent, both on the PC and on the USRP.

I tried the command with both the ethernet cards on the machine after
running ethtool to ensure that the problem might not be due to some
autonegotiation settings etc. On one of the cards, it says the command
is not supported, but on the other, it says "rx unmodified, ignoring"
and "no pause parameters changed, aborting".

I have tried the command with two different USRPs to try and eliminate
the possibility that it might be a USRP issue too.

At this point, I am not sure what to do. Maybe the problem is a
firmware/FPGA mismatch with the installed gnuradio software, but I am
not sure, and I don't know what versions to use if that is indeed the
problem.

(The sketch of my problem seems similar to the one outlined by another
person here:
http://www.mail-archive.com/discuss-gnuradio@gnu.org/msg24002.html
except that I am _not_ using the WBX daughterboard. I also tried all the
above with and without my RFX2400 daughterboard connected in case the
problem was with the RFX2400).

Any suggestions about how to fix the problem?

Thanks,
Rahul

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

[Discuss-gnuradio] Coherent de-dispersion

Anyone on this list know anything about coherent de-dispersion
filtering, and how it's supposed to work?

I've had one implemented for years, and still don't really know whether
it works or not, looking for
clueage about how to test it. Maybe there's *somebody* who knows
something about 'em?


--
Marcus Leech
Principal Investigator
Shirleys Bay Radio Astronomy Consortium
http://www.sbrac.org

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Re: [Discuss-gnuradio] gri_mmse_fir_interpolator_cc::interpolate returns NaN

Tom Rondeau wrote:
> The error suggests that the d_mu value is < 0, which is unrelated to
> the inputs being all 0. There should be no problem with inputs being
> all 0, and if d_mu is less than 0, something is going wrong. Not sure
> what to tell you right now, but more debug information would be
> helpful.
>
> Tom
>
>
Thanks Tom.
Yes, you are right. the error is unrelated to the inputs being all zeros.
Actually, d_mu is not negative either. d_mu is NaN when the error occurs.
By doing some debugging, I have located the problem in
gr_fir_ccf_simd::filter(), which is called by
gri_mmse_fir_interpolator_cc::interpolate(), which in turn is called by
gr_mpsk_receiver_cc::general_work().
For the first call, gr_fir_ccf_simd::filter() returned a value with NaN
as its imaginary part.
Then this value (interp_sample in gr_mpsk_receiver_cc) is passed into
mm_error_tracking(), which causes mm_error, and particularly, d_mu to be
NaN.
Then when gri_mmse_fir_interpolator_cc::interpolate() is called again
with d_mu passed in, the first line
imu = (int) rint(mu*NSTEPS);
will produced a negative imu, which raises the assertion failure.

So the problem lies in gr_fir_ccf_simd::filter(). But why does it return
NaN? I am not sure.
This only happens in Cygwin.

I put aside the problem and switched to Ubuntu to continue my work.

Strangely, after some time of augmenting my codes, when I return to
Cygwin with the augmented codes, that problem disappeared secretly!

Now I cannot reproduce that problem, which prevents me from further
debugging.

Kyle


_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Re: [Discuss-gnuradio] Power,Bandwidth and spectrum switch problems

On 06/30/2010 08:05 PM, Eric Blossom wrote:
> On Tue, Jun 29, 2010 at 11:23:36PM -0700, Johnson_lu wrote:
>
>> Hi guys,
>> Could anybody can help me for these problems?
>> 1、I varied Tx_amplitude from 0.1 to 1 and measured the output with a
>> spectrum analyzer. But the changes are very little. The output is almost the
>> same when Tx_amplitude is 0.1 and 1. How can I reduce the transmit power to
>> a very little value?
>>
All else being equal that should produce a 10dB change in signal power,
unless *something* in the
chain is already at saturation due to other factors in the Tx chain.
Keep in mind that a 10dB change
on a logarithmic scale isn't very much.

>> 2、How do I know bandwidth of transmission and reception channels in
>> tunnel.py?
>>
There seem to be *two* versions of tunnel.py in the examples--which one
are you talking about?
Have you put the output of the transmit side on a spectrum analyser?
That would tell you
unambiguously what the bandwidth is, but also careful and
knowledgeable inspection of the
code will tell you what the theoretical bandwidth is.

--
Marcus Leech
Principal Investigator
Shirleys Bay Radio Astronomy Consortium
http://www.sbrac.org

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Re: [Discuss-gnuradio] Power,Bandwidth and spectrum switch problems

On Tue, Jun 29, 2010 at 11:23:36PM -0700, Johnson_lu wrote:
>
> Hi guys,
> Could anybody can help me for these problems?
> 1、I varied Tx_amplitude from 0.1 to 1 and measured the output with a
> spectrum analyzer. But the changes are very little. The output is almost the
> same when Tx_amplitude is 0.1 and 1. How can I reduce the transmit power to
> a very little value?
>
> 2、How do I know bandwidth of transmission and reception channels in
> tunnel.py?
>
> 3、I am using an USRP2 with Gnu Radio and XCVR2450 as daughterboard. I want
> to switch frequency among different channels 2.4G~2.5G. However, I find that
> switch only can succeed about 20 times, then fails.
> The python code is:
> self.tb.lock()
> ok = self.tb.txpath.set_freq(new_freq)
> if not ok:
> print "Failed to set Tx frequency"
> raise SystemExit
> ok = self.tb.rxpath.set_freq(new_freq)
> if not ok:
> print "Failed to set Rx frequency"
> raise SystemExit
> self.tb.unlock()

FWIW, there's no need to use lock/unlock to change the frequency.
You only need to use those when you are reconfiguring the topology of
the graph.

Try it without those and see if it works.

Eric

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

[Discuss-gnuradio] Re: Fwd: Re: USB2 <-> fast ADC & DAC

Where i can find this praticular module Microtune 4702 DT5? i need for now=/


_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Re: [Discuss-gnuradio] Power,Bandwidth and spectrum switch problems

1. Change tx-gain if you are using tunnel.py. The default value is set to the mid value. Use -h to find out more.
2. Spectrum analyzer would help you to observe. I believe you can also "calculate" based on your settings. Maybe someone can point out where in the code the bandwidth relationship is determined.
 
3. Not sure why. I thought someone had implemented a FH system.
 
An
On Wed, Jun 30, 2010 at 2:23 AM, Johnson_lu <Johnson_lu2010@163.com> wrote:

Hi guys,
Could anybody can help me for these problems?
1、I varied Tx_amplitude from 0.1 to 1 and measured the output with a
spectrum analyzer. But the changes are very little. The output is almost the
same when Tx_amplitude is 0.1 and 1.  How can I reduce the transmit power to
a very little value?

2、How do I know bandwidth of transmission and reception channels in
tunnel.py?

3、I am using an USRP2 with Gnu Radio and XCVR2450 as daughterboard. I want
to switch frequency among different channels 2.4G~2.5G. However, I find that
switch only can succeed about 20 times, then fails.
The python code is:
       self.tb.lock()
       ok = self.tb.txpath.set_freq(new_freq)
       if not ok:
           print "Failed to set Tx frequency"
           raise SystemExit
       ok = self.tb.rxpath.set_freq(new_freq)
       if not ok:
           print "Failed to set Rx frequency"
           raise SystemExit
       self.tb.unlock()


--
View this message in context: http://old.nabble.com/Power%EF%BC%8CBandwidth-and-spectrum-switch-problems-tp29031239p29031239.html
Sent from the GnuRadio mailing list archive at Nabble.com.


_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Re: [Discuss-gnuradio] Make error on Mandriva 2010.0

Thank you for the hint. Installation was successful with gnuradio 3.3.1.

--- On Tue, 29/6/10, Thomas Tsou <ttsou@vt.edu> wrote:

From: Thomas Tsou <ttsou@vt.edu>
Subject: Re: [Discuss-gnuradio] Make error on Mandriva 2010.0
To: "Monica Sit" <sit_monica@yahoo.com>
Cc: discuss-gnuradio@gnu.org
Date: Tuesday, 29 June, 2010, 17:52

On Tue, Jun 29, 2010 at 9:46 AM, Monica Sit <sit_monica@yahoo.com> wrote:
>
> Hi,
>
> I am trying to install gnuradio-3.2.2 on Linux Mandriva 2010.0 i586.
> The PC is a 32 bit Intel P4 machine.
> When I run the command './configure', all gnuradio components passed the configuration tests except

[snip]

> libtool: link: g++ -g -O2 -Wall -Woverloaded-virtual -pthread -o .libs/usrper usrper.o  /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so -L/usr/lib -L/lib -lusb -lboost_thread-mt -lrt -pthread -Wl,-rpath -Wl,/usr/local/lib
> /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_clear_halt'
> /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_get_device_address'
> /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_close'
> /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_unref_device'
> /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_open'
> /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_claim_interface'
> /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_set_configuration'
> /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_free_device_list'
> /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_get_device_list'
> /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_control_transfer'

gnuradio 3.2.2 requires libusb-0.1 instead of the newer version 1.0
that you have installed. According to their wiki, Mandriva Linux 2010
only provides libusb-1.0 along with the compatibility layer for
version 0.1 support. The latter does not work with gnuradio.

You can either install (or build from source) the libusb-0.1 devel
package or obtain a newer version of gnuradio from git that supports
libusb-1.0.

  Thomas

Re: [Discuss-gnuradio] Error in python (XML file)

Hi Josh,

Thanks for replying.

I tried what you told me to do. I added %include<usrp2/usrp2.h> and maked
the directory. However, I receive this error;

usrp2.cc: In function 'PyObject* _wrap_usrp2_start_rx_streaming(PyObject*,
PyObject*, PyObject*)':
usrp2.cc:7970: error: 'time_spec_t' was not declared in this scope

This line has:
usrp2::time_spec_t const &arg3_defvalue = time_spec_t() ;

Before this line there are a lot of occurrences of time_spec_t and there is
no compiling error. This means that the usrp2.h is indeed accessed but why
do you think I receive this error? Any clue or hint, please?

Cheers,
Zohair


Josh Blum-2 wrote:
>
> Zohair,
>
> You can check what is in the module like so: python -c "from gnuradio
> import usrp2; print dir(usrp2)"
> ['MC_PROVIDE_CLK_TO_MIMO', 'MC_WE_DONT_LOCK', 'MC_WE_LOCK_TO_MIMO',
> 'MC_WE_LOCK_TO_SMA', 'SwigPyIterator', 'SwigPyIterator_swigregister',
> '_MC_MIMO_CLK_INPUT', '_MC_WE_LOCK', '__adc_rate', '__builtins__',
> '__dac_rate', '__daughterboard_id', '__default_tx_scale_iq', '__doc__',
> '__file__', '__fpga_master_clock_freq', '__freq_range', '__gain_range',
> '__name__', '__package__', '__read_gpio', '__set_center_freq',
> '_newclass', '_object', '_swig_getattr', '_swig_property', '_swig_repr',
> '_swig_setattr', '_swig_setattr_nondynamic',
> '_swig_setattr_nondynamic_method', '_usrp2', 'cvar', 'deref_int_ptr',
> 'deref_long_ptr', 'deref_uint16_ptr', 'free_int_ptr', 'free_long_ptr',
> 'free_uint16_ptr', 'make_int_ptr', 'make_long_ptr', 'make_uint16_ptr',
> 'rx_metadata', 'rx_metadata_swigregister', 'sink_16sc', 'sink_32fc',
> 'sizeof_char', 'sizeof_double', 'sizeof_float', 'sizeof_gr_complex',
> 'sizeof_int', 'sizeof_short', 'source_16sc', 'source_32fc',
> 'tune_result', 'tune_result_swigregister', 'tx_metadata',
> 'tx_metadata_swigregister', 'uint32_t_vector',
> 'uint32_t_vector_swigregister', 'usrp2_base', 'usrp2_base_swigregister',
> 'usrp2_sink_16sc_sptr', 'usrp2_sink_16sc_sptr_swigregister',
> 'usrp2_sink_32fc_sptr', 'usrp2_sink_32fc_sptr_swigregister',
> 'usrp2_sink_base', 'usrp2_sink_base_swigregister',
> 'usrp2_source_16sc_sptr', 'usrp2_source_16sc_sptr_swigregister',
> 'usrp2_source_32fc_sptr', 'usrp2_source_32fc_sptr_swigregister',
> 'usrp2_source_base', 'usrp2_source_base_swigregister']
>
> Looks like time_spec is not present. The gr-usrp2 swig file probably
> needs a line added: %include <usrp2/usrp2.h>
> This is where the time spec is defined.
>
> I encourage you to use the UHD if you are interested in timestamped
> samples if you want a supported solution that works with the latest
> gnuradio: http://ettus-apps.sourcerepo.com/redmine/ettus/projects/uhd/wiki
>
> It also seems that I need to add the import for time_spec_t to the
> uhd_swig.i file :-)
>
> -Josh
>
>
> On 06/29/2010 03:38 AM, Zohair wrote:
>>
>> Dear all,
>>
>> I am trying to modify the USRP2 block so that the timer is reset at the
>> beginning. I added this line to the make tag in the xml file:_
>>
>> self.$(id).set_time_at_next_pps(time_spec_t(0,0))
>>
>> I receive this error:
>>
>> Traceback (most recent call last):
>> File "/media/ZOHAIR/top_block.py", line 64, in<module>
>> tb = top_block()
>> File "/media/ZOHAIR/top_block.py", line 36, in __init__
>> self.usrp2_sync_source_xxxx_0.set_time_at_next_pps(time_spec_t(0,0))
>> NameError: global name 'time_spec_t' is not defined
>>
>> Any help or hint please? I am using GRC 3.3git-23e45f33
>>
>> Cheers,
>> Zoh
>
> _______________________________________________
> Discuss-gnuradio mailing list
> Discuss-gnuradio@gnu.org
> http://lists.gnu.org/mailman/listinfo/discuss-gnuradio
>
>

--
View this message in context: http://old.nabble.com/Error-in-python-%28XML-file%29-tp29022268p29033168.html
Sent from the GnuRadio mailing list archive at Nabble.com.


_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Tuesday, June 29, 2010

[Discuss-gnuradio] Power,Bandwidth and spectrum switch problems

Hi guys,
Could anybody can help me for these problems?
1、I varied Tx_amplitude from 0.1 to 1 and measured the output with a
spectrum analyzer. But the changes are very little. The output is almost the
same when Tx_amplitude is 0.1 and 1. How can I reduce the transmit power to
a very little value?

2、How do I know bandwidth of transmission and reception channels in
tunnel.py?

3、I am using an USRP2 with Gnu Radio and XCVR2450 as daughterboard. I want
to switch frequency among different channels 2.4G~2.5G. However, I find that
switch only can succeed about 20 times, then fails.
The python code is:
self.tb.lock()
ok = self.tb.txpath.set_freq(new_freq)
if not ok:
print "Failed to set Tx frequency"
raise SystemExit
ok = self.tb.rxpath.set_freq(new_freq)
if not ok:
print "Failed to set Rx frequency"
raise SystemExit
self.tb.unlock()


--
View this message in context: http://old.nabble.com/Power%EF%BC%8CBandwidth-and-spectrum-switch-problems-tp29031239p29031239.html
Sent from the GnuRadio mailing list archive at Nabble.com.


_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

[Discuss-gnuradio] Re: On the maximum transmission distance

By the way the VERT400 144MHz, 400 MHz, and 1200 MHz Tri-band 7-inch vertical
antenna is used.

On Tue, Jun 29, 2010 at 10:21 PM, An He <tech.sub.online@gmail.com> wrote:
Hi,
 
I am sure someone has tried to find out the maximum transmission distance using USRP2. For example, I am interested in the maximum transmission range in the following setting:
 
USRP2 with WBX, 400MHz/900MHz, outdoor, los, static, benchmark_tx/benchmark_rx with default except tx_gain=25 (maximum).
 
We are interested in extending the transmission range by adding external amplifier module. If anyone can share the experience, it would be greatly appreciated.
 
Thanks,
An

[Discuss-gnuradio] On the maximum transmission distance

Hi,
 
I am sure someone has tried to find out the maximum transmission distance using USRP2. For example, I am interested in the maximum transmission range in the following setting:
 
USRP2 with WBX, 400MHz/900MHz, outdoor, los, static, benchmark_tx/benchmark_rx with default except tx_gain=25 (maximum).
 
We are interested in extending the transmission range by adding external amplifier module. If anyone can share the experience, it would be greatly appreciated.
 
Thanks,
An

Re: [Discuss-gnuradio] gri_mmse_fir_interpolator_cc::interpolate returns NaN

On Tue, Jun 22, 2010 at 11:31 PM, Kyle Zhou <kylenix@gmail.com> wrote:
> I am testing the gr_mpsk_receiver_cc module using the code attached at the
> end.
> It is gnuradio v3.3.1git-11-ge20160b7 on cygwin 1.7.5-1 with gcc 3.4.4.
> When I run the code, the following error pops up:
> ===========================
> assertion "imu >= 0" failed: file "gri_mmse_fir_interpolator_cc.cc", line
> 67, fu
> nction: gr_complex gri_mmse_fir_interpolator_cc::interpolate(const
> gr_complex*,
> float)
> Aborted (core dumped)
> ===========================
>
> Digging into the source code, I found that the interpolator at line 306 of
> gr_mpsk_receiver_cc.cc return NaN when the inputs are all zeros.
> line 306: gr_complex interp_sample = d_interp->interpolate(&d_dl[d_dl_idx],
> d_mu);
>
> trying it on ubuntu produced no problem.
>
> Is this an known bug?
> Kyle

The error suggests that the d_mu value is < 0, which is unrelated to
the inputs being all 0. There should be no problem with inputs being
all 0, and if d_mu is less than 0, something is going wrong. Not sure
what to tell you right now, but more debug information would be
helpful.

Tom

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Re: [Discuss-gnuradio] synchronizing the daughterboard LOs

On 06/29/2010 10:35 AM, mehmet kabasakal wrote:
> Hi everyone,
>
> I want to synchronize the daughterboard LOs for an application.
> I have a Rev 4 USRP board and FLEX1800 daughterboard then i followed
> the instructions on
> http://gnuradio.org/redmine/wiki/1/USRPClockingNotes . At this page it
> is given that "Recent boards don't need these mods, only early
> RFX-boards".
> What does recent boards mean? There is a date written on the DBoard
> (3.10.2006).
> My DB is a "recent board"?


If it has X1 and X101 populated then you need to do the mod. If not,
then it is not necessary.

Matt


_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Re: [Discuss-gnuradio] Memory allocation woes

On Tue, Jun 29, 2010 at 02:16:24PM -0400, Marcus D. Leech wrote:
> On 06/29/2010 01:37 PM, Eric Blossom wrote:
> > The place to add some debugging outout would be
> > gr_flat_flowgraph.cc::allocate_buffer. Something like:
> >
> > std::cout << "allocate_buffer " << block
> > << " nitems " << nitems << " item_size " << item_size << std::endl;
> >
> >
> > For the case of the 6M bin FFT, I could see us getting to
> >
> > 6M * sizeof(gr_complex) * 2 * 2 --> 192MB. Not that big.
> >
> >
> > Add the debugging output and let us know what you find.
> >
> >
> allocate_buffer complex_to_mag(1) nitems 4 item_size 25000000
> gr_buffer::allocate_buffer: warning: tried to allocate
> 4 items of size 25000000. Due to alignment requirements
> 64 were allocated. If this isn't OK, consider padding
> your structure to a power-of-two bytes.
> On this platform, our allocation granularity is 4096 bytes.
> gr_vmcircbuf_sysv_shm: shmget (1): Invalid argument
> gr_buffer::allocate_buffer: failed to allocate buffer of size 1562500 KB
> terminate called after throwing an instance of 'std::bad_alloc'
> what(): std::bad_alloc
>
>
> This is the complex_to_mag(1) right after the HUGE FFT.
>
> That item size must be the size of the *output* vector (6M *
> sizeof(float) + 'slop'??).

There won't be any slop in the item_size. That comes from the
io_signature. 25,000,000/sizeof(gr_complex) = 3,125,000. Does that sound familiar?
It must be the number of bins in the FFT.

> Now, see what happens? It's rounding up that 4 items to 64 items, which
> is ballooning out
> the request size considerably!!

If you pick a size with more factors of 2 and fewer factors of 5, life
will get better :-)

I have on occasion thought that it would be a good idea to switch to
an alternate circular buffer strategy when the size blows up too much
because of the alignment requirement. The alternate would probably
use memcpy to duplicate the appropriate portion of the buffer on
return from general_work instead of the MMU trick. I probably won't
get to it this lifetime, but if you're interested, let me know and
I'll give you my ideas on how to go about it.

Eric

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Re: [Discuss-gnuradio] Memory allocation woes

On 06/29/2010 01:37 PM, Eric Blossom wrote:
> The place to add some debugging outout would be
> gr_flat_flowgraph.cc::allocate_buffer. Something like:
>
> std::cout << "allocate_buffer " << block
> << " nitems " << nitems << " item_size " << item_size << std::endl;
>
>
> For the case of the 6M bin FFT, I could see us getting to
>
> 6M * sizeof(gr_complex) * 2 * 2 --> 192MB. Not that big.
>
>
> Add the debugging output and let us know what you find.
>
>
allocate_buffer complex_to_mag(1) nitems 4 item_size 25000000
gr_buffer::allocate_buffer: warning: tried to allocate
4 items of size 25000000. Due to alignment requirements
64 were allocated. If this isn't OK, consider padding
your structure to a power-of-two bytes.
On this platform, our allocation granularity is 4096 bytes.
gr_vmcircbuf_sysv_shm: shmget (1): Invalid argument
gr_buffer::allocate_buffer: failed to allocate buffer of size 1562500 KB
terminate called after throwing an instance of 'std::bad_alloc'
what(): std::bad_alloc


This is the complex_to_mag(1) right after the HUGE FFT.

That item size must be the size of the *output* vector (6M *
sizeof(float) + 'slop'??).

Now, see what happens? It's rounding up that 4 items to 64 items, which
is ballooning out
the request size considerably!!


--
Marcus Leech
Principal Investigator
Shirleys Bay Radio Astronomy Consortium
http://www.sbrac.org

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Re: [Discuss-gnuradio] Make error on Mandriva 2010.0

On Tue, Jun 29, 2010 at 9:46 AM, Monica Sit <sit_monica@yahoo.com> wrote:
>
> Hi,
>
> I am trying to install gnuradio-3.2.2 on Linux Mandriva 2010.0 i586.
> The PC is a 32 bit Intel P4 machine.
> When I run the command './configure', all gnuradio components passed the configuration tests except

[snip]

> libtool: link: g++ -g -O2 -Wall -Woverloaded-virtual -pthread -o .libs/usrper usrper.o  /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so -L/usr/lib -L/lib -lusb -lboost_thread-mt -lrt -pthread -Wl,-rpath -Wl,/usr/local/lib
> /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_clear_halt'
> /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_get_device_address'
> /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_close'
> /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_unref_device'
> /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_open'
> /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_claim_interface'
> /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_set_configuration'
> /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_free_device_list'
> /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_get_device_list'
> /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_control_transfer'

gnuradio 3.2.2 requires libusb-0.1 instead of the newer version 1.0
that you have installed. According to their wiki, Mandriva Linux 2010
only provides libusb-1.0 along with the compatibility layer for
version 0.1 support. The latter does not work with gnuradio.

You can either install (or build from source) the libusb-0.1 devel
package or obtain a newer version of gnuradio from git that supports
libusb-1.0.

Thomas

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Re: [Discuss-gnuradio] Make error on Mandriva 2010.0

On Tue, Jun 29, 2010 at 04:46:32PM +0000, Monica Sit wrote:
> Hi,
>  
> I am trying to install gnuradio-3.2.2 on Linux Mandriva 2010.0 i586.
> The PC is a 32 bit Intel P4 machine.
> When I run the command './configure', all gnuradio components passed the configuration tests except
>  
> usrp2-firmware
>
> gcell
> gr-gcell
>
> gr-audio-windows
> gr-audio-osx
>  
>
> When I run the command 'make' the following error is given:

Looks like you may be missing the libusb development package, or you
have more than one of them installed. Not sure what it's called on
Mandriva, or why configure didn't barf.

Eric


> make[4]: Entering directory
> `/home/user/gnuradio-3.2.2/usrp/host/apps'
> g++
> -DHAVE_CONFIG_H -I. -I../../.. 
> -I/home/user/gnuradio-3.2.2/usrp/host/lib/legacy           
> -I/home/user/gnuradio-3.2.2/usrp/firmware/include           
> -I/home/user/gnuradio-3.2.2/usrp/host/lib/legacy -I/usr/include    -g
> -O2  -Wall -Woverloaded-virtual -pthread -MT usrper.o -MD -MP -MF
> .deps/usrper.Tpo -c -o usrper.o usrper.cc
> mv -f .deps/usrper.Tpo .deps/usrper.Po
> /bin/sh
> ../../../libtool --tag=CXX   --mode=link g++ -g -O2  -Wall
> -Woverloaded-virtual -pthread   -o usrper usrper.o
> /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/libusrp.la
> libtool:
> link: g++ -g -O2 -Wall -Woverloaded-virtual -pthread -o .libs/usrper
> usrper.o 
> /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so
> -L/usr/lib -L/lib -lusb -lboost_thread-mt -lrt -pthread -Wl,-rpath
> -Wl,/usr/local/lib
> /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_clear_halt'
> /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_get_device_address'
> /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_close'
> /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_unref_device'
> /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_open'

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Re: [Discuss-gnuradio] Memory allocation woes

On Mon, Jun 28, 2010 at 09:14:34PM -0400, Marcus D. Leech wrote:
> Spent some time tracking down a memory allocation issue. The SYSV shm
> allocator was getting errors on
> a request for 1.56GB. Now, it turns out that the segment size used by
> SYSV shm uses a signed 32-bit
> int for the size of the segment, which means you can't allocate
> segments larger than 2*31 bytes. But
> why was the request for 1.56GB being blown away? Because the SYSV shm
> allocator in Gnu Radio
> multiplies the request size by 2 before asking the system for that
> much shared memory.
>
> So, why does it do that? And why is the memory allocation so incredibly
> piggish? We went through this
> question a couple of years ago, and I'm running into similar problems
> again--my application uses
> *HUGE* FFTs--1Hz resolution at up to 16MHz (USRP1) or 25MHz (USRP2)
> bandwidth. This, not surprisingly,
> leads to some large memory requirements, but Gnu Radios allocator
> seems to allocate a significant amount
> more than is really needed.
>
> In the case cited above, the FFT size was 6M bins, which granted is
> outside the "usual" range of most
> Gnu Radio applications, but I was able to make this work last year up
> to 16M bins.
>
> The flowgraph involved is quite simple. A source, a short FFT-based
> filter, the main HUGE FFT, and then
> a complex-to-mag**2, then a file sink.
>
> Should this really require gigabytes of memory?

Maybe.

The actual amount allocated depends on a bunch of factors, including
the characteristics of the blocks upstream and downstream from the
buffer in question.

In general, there's a factor of 2x to allow double buffering. When
using any of the vmcircbuf allocators, there is a temporary request
for twice the desired memory. This is to ensure that we get a big
enough hole to map what we really want (1/2 that much) into the VM
space twice, contiguously. This is to allow us to implement the
circular buffer by mapping the same memory into the VM twice, avoiding
the need to special case the boundary condition.

Do you know if it's the buffer upstream or downstream from the FFT
that's failing to be allocated? Is the block downstream from the FFT
a decimator? In that case, we allocate N (where N is the decimation
factor) * <the-other-number-we-would-have-chosen> to ensure that
there's enough input for the downstream block to generate a single
output on one call to work.

In general that's not a problem, but in your case, this could be the
part that's causing the large allocation. It could be worked around
by writing a version of the decimator that doesn't require the factor
of N on its input. This requires more complicated state tracking in
the block (which is why we don't normally do it), but is possible.


The place to add some debugging outout would be
gr_flat_flowgraph.cc::allocate_buffer. Something like:

std::cout << "allocate_buffer " << block
<< " nitems " << nitems << " item_size " << item_size << std::endl;


For the case of the 6M bin FFT, I could see us getting to

6M * sizeof(gr_complex) * 2 * 2 --> 192MB. Not that big.


Add the debugging output and let us know what you find.


Also, you could try using an alternate vmcircbuf allocator,
gr_vmcircbuf_mmap_shm, by writing the string "gr_vmcircbuf_mmap_shm_open_factory"
into ~/.gnuradio/prefs/gr_vmcircbuf_default_factory. Note that there
is no trailing newline in that file. The last byte of the file
should by "y".

gr_vmcircbuf_mmap_shm_open uses an off_t which is 64-bits.
Details in gr_vmcircbuf_mmap_shm_open.cc


Eric


_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

[Discuss-gnuradio] synchronizing the daughterboard LOs

Hi everyone,

I want to synchronize the daughterboard LOs for an application.
I have a Rev 4 USRP board and FLEX1800 daughterboard then i followed
the instructions on
http://gnuradio.org/redmine/wiki/1/USRPClockingNotes . At this page it
is given that "Recent boards don't need these mods, only early
RFX-boards".
What does recent boards mean? There is a date written on the DBoard
(3.10.2006).
My DB is a "recent board"?

THanks guys.

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Re: [Discuss-gnuradio] Testing USRP2 on 6-core Phenom II X6 server

Thankyou for this information. It would be useful to have a catalog of
benchmarked systems for reference purposes. Perhaps a wikipage with
this information could be created?

~Jeffrey Lambert

On 6/28/2010 6:16 PM, Marcus D. Leech wrote:
> I took delivery on a server (well, the parts to build a server, which I
> did) about a week ago. I've been
> running tests on it with USRP2.
>
> It's a Gigabyte GA880GM-UD2H motherboard, with 8G of 1333 DDR3 memory,
> and a AMD Phenom II 1090T,
> six-core CPU at 3.2GHz.
>
> I'm running Fedora 12 x86_64, with the latest Gnu Radio GIT.
>
> I was able to run usrp2_fft.py with decim=4 (25Msps!!) after increasing
> the net.core.rmem_max and
> net.core.wmem_max parameters to 500000 each.
>
> With this configuration, usrp2_fft.py consumes about 25% of the
> available CPU, or roughly 1.5 of the 6 CPUs
> of the system.
>
>


--
~Jeffrey Lambert, K1VZX

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

[Discuss-gnuradio] Make error on Mandriva 2010.0

Hi,
 
I am trying to install gnuradio-3.2.2 on Linux Mandriva 2010.0 i586.
The PC is a 32 bit Intel P4 machine.
When I run the command './configure', all gnuradio components passed the configuration tests except
 
usrp2-firmware

gcell
gr-gcell

gr-audio-windows
gr-audio-osx
 

When I run the command 'make' the following error is given:

make[4]: Entering directory
`/home/user/gnuradio-3.2.2/usrp/host/apps'
g++ -DHAVE_CONFIG_H -I. -I../../..  -I/home/user/gnuradio-3.2.2/usrp/host/lib/legacy            -I/home/user/gnuradio-3.2.2/usrp/firmware/include            -I/home/user/gnuradio-3.2.2/usrp/host/lib/legacy -I/usr/include    -g -O2  -Wall -Woverloaded-virtual -pthread -MT usrper.o -MD -MP -MF .deps/usrper.Tpo -c -o usrper.o usrper.cc
mv -f .deps/usrper.Tpo .deps/usrper.Po
/bin/sh ../../../libtool --tag=CXX   --mode=link g++ -g -O2  -Wall -Woverloaded-virtual -pthread   -o usrper usrper.o /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/libusrp.la
libtool: link: g++ -g -O2 -Wall -Woverloaded-virtual -pthread -o .libs/usrper usrper.o  /home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so -L/usr/lib -L/lib -lusb -lboost_thread-mt -lrt -pthread -Wl,-rpath -Wl,/usr/local/lib
/home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_clear_halt'
/home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_get_device_address'
/home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_close'
/home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_unref_device'
/home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_open'
/home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_claim_interface'
/home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_set_configuration'
/home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_free_device_list'
/home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_get_device_list'
/home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_control_transfer'
/home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_get_config_descriptor'
/home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_interrupt_transfer'
/home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_get_bus_number'
/home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_free_config_descriptor'
/home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_set_debug'
/home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_ref_device'
/home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_init'
/home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_reset_device'
/home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_set_interface_alt_setting'
/home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_detach_kernel_driver'
/home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_get_device_descriptor'
/home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_kernel_driver_active'
/home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_bulk_transfer'
/home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_release_interface'
/home/user/gnuradio-3.2.2/usrp/host/lib/legacy/.libs/libusrp.so: undefined reference to `libusb_get_string_descriptor_ascii'
collect2: ld returned 1 exit status
make[4]: *** [usrper] Error 1
make[4]: Leaving directory `/home/user/gnuradio-3.2.2/usrp/host/apps'
make[3]: *** [all-recursive] Error 1
make[3]: Leaving directory `/home/user/gnuradio-3.2.2/usrp/host'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/home/user/gnuradio-3.2.2/usrp'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/user/gnuradio-3.2.2'
make: *** [all] Error 2
 
What could be the problem?
Regards
Mo

Re: [Discuss-gnuradio] Error in python (XML file)

Zohair,

You can check what is in the module like so: python -c "from gnuradio
import usrp2; print dir(usrp2)"
['MC_PROVIDE_CLK_TO_MIMO', 'MC_WE_DONT_LOCK', 'MC_WE_LOCK_TO_MIMO',
'MC_WE_LOCK_TO_SMA', 'SwigPyIterator', 'SwigPyIterator_swigregister',
'_MC_MIMO_CLK_INPUT', '_MC_WE_LOCK', '__adc_rate', '__builtins__',
'__dac_rate', '__daughterboard_id', '__default_tx_scale_iq', '__doc__',
'__file__', '__fpga_master_clock_freq', '__freq_range', '__gain_range',
'__name__', '__package__', '__read_gpio', '__set_center_freq',
'_newclass', '_object', '_swig_getattr', '_swig_property', '_swig_repr',
'_swig_setattr', '_swig_setattr_nondynamic',
'_swig_setattr_nondynamic_method', '_usrp2', 'cvar', 'deref_int_ptr',
'deref_long_ptr', 'deref_uint16_ptr', 'free_int_ptr', 'free_long_ptr',
'free_uint16_ptr', 'make_int_ptr', 'make_long_ptr', 'make_uint16_ptr',
'rx_metadata', 'rx_metadata_swigregister', 'sink_16sc', 'sink_32fc',
'sizeof_char', 'sizeof_double', 'sizeof_float', 'sizeof_gr_complex',
'sizeof_int', 'sizeof_short', 'source_16sc', 'source_32fc',
'tune_result', 'tune_result_swigregister', 'tx_metadata',
'tx_metadata_swigregister', 'uint32_t_vector',
'uint32_t_vector_swigregister', 'usrp2_base', 'usrp2_base_swigregister',
'usrp2_sink_16sc_sptr', 'usrp2_sink_16sc_sptr_swigregister',
'usrp2_sink_32fc_sptr', 'usrp2_sink_32fc_sptr_swigregister',
'usrp2_sink_base', 'usrp2_sink_base_swigregister',
'usrp2_source_16sc_sptr', 'usrp2_source_16sc_sptr_swigregister',
'usrp2_source_32fc_sptr', 'usrp2_source_32fc_sptr_swigregister',
'usrp2_source_base', 'usrp2_source_base_swigregister']

Looks like time_spec is not present. The gr-usrp2 swig file probably
needs a line added: %include <usrp2/usrp2.h>
This is where the time spec is defined.

I encourage you to use the UHD if you are interested in timestamped
samples if you want a supported solution that works with the latest
gnuradio: http://ettus-apps.sourcerepo.com/redmine/ettus/projects/uhd/wiki

It also seems that I need to add the import for time_spec_t to the
uhd_swig.i file :-)

-Josh


On 06/29/2010 03:38 AM, Zohair wrote:
>
> Dear all,
>
> I am trying to modify the USRP2 block so that the timer is reset at the
> beginning. I added this line to the make tag in the xml file:_
>
> self.$(id).set_time_at_next_pps(time_spec_t(0,0))
>
> I receive this error:
>
> Traceback (most recent call last):
> File "/media/ZOHAIR/top_block.py", line 64, in<module>
> tb = top_block()
> File "/media/ZOHAIR/top_block.py", line 36, in __init__
> self.usrp2_sync_source_xxxx_0.set_time_at_next_pps(time_spec_t(0,0))
> NameError: global name 'time_spec_t' is not defined
>
> Any help or hint please? I am using GRC 3.3git-23e45f33
>
> Cheers,
> Zoh

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

[Discuss-gnuradio] ofdm_frame_acquisition module

   in gr_ofdm_frame_acquisition.cc file ,the coarse frequency compensation is gr_expj(-2*PI*freq_delta*d_cplen/d_fft_length*symbol_count)
 .i don't know why ,could somebody give me an explanation or tell me which peper i can refer to ?
  thanks in advance



Re: [Discuss-gnuradio] High frequency OFDM

> > Hi,
> >
> > I successfully implemented OFDM with two USRPs with LFRX/LFTX at
> 1-50MHz, connect by cable. Now I tried switching over to higher frequencies via
> TVRX/WBX. While I receive a perfectly valid looking spectrum with a good SNR,
> it does not seem to decode at >200MHz.
> > If I increase the sub-carrier spacing of the transmission and thus the
> bandwidth, it works again. But why do I have to do that if the signal and
> SNR look okay?
> >
> > What destroys a OFMD signal at high frequencies? Is it phase noise? Is
> the USRPs frequency resolution different at higher frequencies?
> >
> > Any literature/papers on this topic would also be helpful - I am kind of
> stuck here.
>
> It's probably due to the frequency offset. Since the local oscillator
> has a certain offset at its nominal frequency, that offset is
> multiplied when the signal is multiplied to a higher frequency. So the
> higher the frequency, the more you are offset. In the case of the OFDM
> signals, you are now farther off frequency than the lock-in range of
> the receiver.
>
> You already found one fix for this, which is making the subcarriers
> larger. The other thing to do is look at the frequency offset between
> the two devices and try to compensate for it.
>
> There was a discussion about this a few months ago that you can look
> for that explains a way to handle larger offsets better than the look
> and tune method, which, while it works, isn't a realistic solution.
>
> Tom

Thanks for the reply!

Sadly I already noticed and compensated for the frequency offset you mentioned and manually centered the frequency block that OFDM consists of. I also adjusted the respective levels, so clipping should not be an issue as well.

I just wonder why you can't use my OFDM configuration (that works perfectly at low frequencies) at a higher frequency. My two USRPs are connected via cable and the SNR and signal spectrum look good, so it should work, shouldn't it? :(

--
GRATIS für alle GMX-Mitglieder: Die maxdome Movie-FLAT!
Jetzt freischalten unter http://portal.gmx.net/de/go/maxdome01

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Re: [Discuss-gnuradio] Memory allocation woes

On 06/29/2010 05:23 AM, Stefan Bruens wrote:
>
> If your demands are really so high, why aren't you using a 64bit machine. On
> top of the larger memory space, you get more registers and guranteed existence
> of SSE (only an issue, if you use prebuilt packages). The last time I used GR,
> it worked fine on 64bit.
>
> Stefan
>
>
>
I *am* using a 64-bit machine. The problem appears to be that the SYSV
shm interface uses
signed 32-bit values for the size of the desired segment, which tops
out around 2Gbyte.


--
Principal Investigator
Shirleys Bay Radio Astronomy Consortium
http://www.sbrac.org

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Re: [Discuss-gnuradio] Error in python (XML file)

I also tried this:
zeroise=usrp2.time_spec_t(0,0)
self.$(id).set_time_at_next_pps(zeroise)

and receive:
Traceback (most recent call last):
File "/media/ZOHAIR/top_block.py", line 66, in <module>
tb = top_block()
File "/media/ZOHAIR/top_block.py", line 35, in __init__
zeroise=usrp2.time_spec_t(0,0)
AttributeError: 'module' object has no attribute 'time_spec_t'

The problem in my code or in time_spec_t accessibility? What do you think?

Thanks
Zohair


Zohair wrote:
>
> Dear all,
>
> I am trying to modify the USRP2 block so that the timer is reset at the
> beginning. I added this line to the make tag in the xml file:
>
> self.$(id).set_time_at_next_pps(time_spec_t(0,0))
>
> I receive this error:
>
> Traceback (most recent call last):
> File "/media/ZOHAIR/top_block.py", line 64, in <module>
> tb = top_block()
> File "/media/ZOHAIR/top_block.py", line 36, in __init__
> self.usrp2_sync_source_xxxx_0.set_time_at_next_pps(time_spec_t(0,0))
> NameError: global name 'time_spec_t' is not defined
>
> Any help or hint please? I am using GRC 3.3git-23e45f33
>
> Cheers,
> Zoh
>

--
View this message in context: http://old.nabble.com/Error-in-python-%28XML-file%29-tp29022268p29022492.html
Sent from the GnuRadio mailing list archive at Nabble.com.


_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

[Discuss-gnuradio] Error in python (XML file)

Dear all,

I am trying to modify the USRP2 block so that the timer is reset at the
beginning. I added this line to the make tag in the xml file:

self.$(id).set_time_at_next_pps(time_spec_t(0,0))

I receive this error:

Traceback (most recent call last):
File "/media/ZOHAIR/top_block.py", line 64, in <module>
tb = top_block()
File "/media/ZOHAIR/top_block.py", line 36, in __init__
self.usrp2_sync_source_xxxx_0.set_time_at_next_pps(time_spec_t(0,0))
NameError: global name 'time_spec_t' is not defined

Any help or hint please? I am using GRC 3.3git-23e45f33

Cheers,
Zoh
--
View this message in context: http://old.nabble.com/Error-in-python-%28XML-file%29-tp29022268p29022268.html
Sent from the GnuRadio mailing list archive at Nabble.com.


_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Re: [Discuss-gnuradio] Memory allocation woes

This is just an educated guess, so anyone, please correct me if I am wrong:

GR tries to hide the fact that even for a ringbuffer, memory space is always
linear. Now lets assume you try to do an fft with overlap, with an fft size as
large as your buffer.

The first time, you memory area might be at the beginning of the buffer. The
next time, it is shifted somewhat into the buffer, therefor the last part of
your buffer is actually at the beginning of the buffer. To get a linear (with
monotonically increasing adresses) buffer, the physical memory pages backing
your buffer are mapped into virtual memory space twice, where the second
mapping directly follows the first.

Physical memory usage is equal to buffer size, whereas virtual memory space
uses twice as much memory. So for current applications on todays computer it
is really easy to run out of virtual memory space.

If your demands are really so high, why aren't you using a 64bit machine. On
top of the larger memory space, you get more registers and guranteed existence
of SSE (only an issue, if you use prebuilt packages). The last time I used GR,
it worked fine on 64bit.

Stefan

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Monday, June 28, 2010

[Discuss-gnuradio] Switch frequency with Usrp2 can only succeed about 20 times

Hi guys,
I am using an USRP2 with Gnu Radio and XCVR2450 as daughterboard. I want to
switch frequency among different channels 2.4G~2.5G. However, I find that
when switch only can succeed about 20 times, then fails. Is there any body
having the same problem?
The python code is:
self.tb.lock()
ok = self.tb.txpath.set_freq(new_freq)
if not ok:
print "Failed to set Tx frequency"
raise SystemExit
ok = self.tb.rxpath.set_freq(new_freq)
if not ok:
print "Failed to set Rx frequency"
raise SystemExit
self.tb.unlock()
--
View this message in context: http://old.nabble.com/Switch-frequency-with-Usrp2-can-only-succeed-about-20-times-tp29014163p29014163.html
Sent from the GnuRadio mailing list archive at Nabble.com.


_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

[Discuss-gnuradio] Memory allocation woes

Spent some time tracking down a memory allocation issue. The SYSV shm
allocator was getting errors on
a request for 1.56GB. Now, it turns out that the segment size used by
SYSV shm uses a signed 32-bit
int for the size of the segment, which means you can't allocate
segments larger than 2*31 bytes. But
why was the request for 1.56GB being blown away? Because the SYSV shm
allocator in Gnu Radio
multiplies the request size by 2 before asking the system for that
much shared memory.

So, why does it do that? And why is the memory allocation so incredibly
piggish? We went through this
question a couple of years ago, and I'm running into similar problems
again--my application uses
*HUGE* FFTs--1Hz resolution at up to 16MHz (USRP1) or 25MHz (USRP2)
bandwidth. This, not surprisingly,
leads to some large memory requirements, but Gnu Radios allocator
seems to allocate a significant amount
more than is really needed.

In the case cited above, the FFT size was 6M bins, which granted is
outside the "usual" range of most
Gnu Radio applications, but I was able to make this work last year up
to 16M bins.

The flowgraph involved is quite simple. A source, a short FFT-based
filter, the main HUGE FFT, and then
a complex-to-mag**2, then a file sink.

Should this really require gigabytes of memory?


--
Marcus Leech
Principal Investigator
Shirleys Bay Radio Astronomy Consortium
http://www.sbrac.org

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Re: [Discuss-gnuradio] channel model question

Yes, that is it. Thanks a lot for your help Josh.



On Mon, Jun 28, 2010 at 4:26 PM, Josh Blum <josh@joshknows.com> wrote:
That ratio of frequency/sample_rate tells the signal source how much to change the output per sample such that it will take 1.0/ratio samples to make a complete sinusoid period or cycle.

Try this out in grc. Look at the signal source in the scope sink, and then try it with 1.0 as the sample rate and freq/samp_rate as the frequency. It will look the same.

-Josh


On 06/28/2010 03:56 PM, John Andrews wrote:
But still there is a problem. 1000/100,000 = 0.01 so the channel_model must
consume 100,000 samples coming into it to represent an offset of 1000Hz.
How, does it know how many samples to consume as the ratio can be the same
for a different combination such as 100/10000.

If x(i) = sin(2*pi*freq_offset_ratio*i) , i must vary from
{1,sampling_rate}.

On Mon, Jun 28, 2010 at 3:00 PM, Josh Blum<josh@joshknows.com>  wrote:

For some reason, the channel model's frequency_offset is not in Hz. Rather
its a fraction of the sample rate. You should pass in
my_offset_in_hz/my_sample_rate to this parameter.

The signal source works like that. I suppose that means that the sample
rate and frequency are redundant because you really only care about the
ratio between them.

_josh

oh consistency...


On 06/28/2010 02:12 PM, John Andrews wrote:

Hi,
I have a nagging doubt about how the channel model is implemented in
gnuradio. Suppose I have an input signal entering the channel model at
100,000 samples/sec. Let's say the channel model has to add an offset of
1000Hz to the input signal. Then I must have 100,000 samples of a 1000Hz
SINE_WAVE signal and multiply each input sample with a corresponding input
sample. Am I right? If I am right then i don't see this happening here
with
the sampling rate given as 1 in the line below

d_freq_offset = gr_make_sig_source_c(1, GR_SIN_WAVE, frequency_offset,
1.0,
0.0);

If I am wrong then will someone please correct me here.

thank you very much
John




_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio


_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio



Re: [Discuss-gnuradio] channel model question

That ratio of frequency/sample_rate tells the signal source how much to
change the output per sample such that it will take 1.0/ratio samples to
make a complete sinusoid period or cycle.

Try this out in grc. Look at the signal source in the scope sink, and
then try it with 1.0 as the sample rate and freq/samp_rate as the
frequency. It will look the same.

-Josh

On 06/28/2010 03:56 PM, John Andrews wrote:
> But still there is a problem. 1000/100,000 = 0.01 so the channel_model must
> consume 100,000 samples coming into it to represent an offset of 1000Hz.
> How, does it know how many samples to consume as the ratio can be the same
> for a different combination such as 100/10000.
>
> If x(i) = sin(2*pi*freq_offset_ratio*i) , i must vary from
> {1,sampling_rate}.
>
> On Mon, Jun 28, 2010 at 3:00 PM, Josh Blum<josh@joshknows.com> wrote:
>
>> For some reason, the channel model's frequency_offset is not in Hz. Rather
>> its a fraction of the sample rate. You should pass in
>> my_offset_in_hz/my_sample_rate to this parameter.
>>
>> The signal source works like that. I suppose that means that the sample
>> rate and frequency are redundant because you really only care about the
>> ratio between them.
>>
>> _josh
>>
>> oh consistency...
>>
>>
>> On 06/28/2010 02:12 PM, John Andrews wrote:
>>
>>> Hi,
>>> I have a nagging doubt about how the channel model is implemented in
>>> gnuradio. Suppose I have an input signal entering the channel model at
>>> 100,000 samples/sec. Let's say the channel model has to add an offset of
>>> 1000Hz to the input signal. Then I must have 100,000 samples of a 1000Hz
>>> SINE_WAVE signal and multiply each input sample with a corresponding input
>>> sample. Am I right? If I am right then i don't see this happening here
>>> with
>>> the sampling rate given as 1 in the line below
>>>
>>> d_freq_offset = gr_make_sig_source_c(1, GR_SIN_WAVE, frequency_offset,
>>> 1.0,
>>> 0.0);
>>>
>>> If I am wrong then will someone please correct me here.
>>>
>>> thank you very much
>>> John
>>>
>>>
>>>
>>>
>>> _______________________________________________
>>> Discuss-gnuradio mailing list
>>> Discuss-gnuradio@gnu.org
>>> http://lists.gnu.org/mailman/listinfo/discuss-gnuradio
>>>
>>
>> _______________________________________________
>> Discuss-gnuradio mailing list
>> Discuss-gnuradio@gnu.org
>> http://lists.gnu.org/mailman/listinfo/discuss-gnuradio
>>
>

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

[Discuss-gnuradio] benchmark_tx/rx with RFX 2400

Hello,

I am new to the USRP/gnu-radio world, trying to understand the basic working. I have been trying the following 2 experiments which I've not been able to successfully debug or find documentation for. Can somebody help me out to explain what is going wrong or point to some useful references.

The hardware I am using is the RFX2400 daughterboard with USRP and a 2.4-2.48G antenna. I'm using two separate boards in receive and transmit configuration.

1. I tried the digital/benchmark_tx/rx.py provided with the examples (3.2.2 tarball).  I tried to read from a simple ascii file containing a sequence of numbers repeated 1000 times. I've tried different options modulation schemes but the problems persist. Two main problems in this example
     a) It seems that using the default gmsk modulation, although 179 packets are sent, only 147 are received. Essentially, the last packet is always received in error and the end 15% of the file is always lost.
     b) The transmission seems to be very sensitive to the bit rate specified. i.e. there are several combination of big-rates at which the receiver receives nothing.

2. I tried so send a simple tone across by hooking a sine wave generator to the USRP using the grc. Even that seems the just end up in noise reception. I'm attaching a small snippet of the code generated.

I appreciate any help.

Thanks
Shalabh
 
-------------------------------tx-------------------------------------------
                self.gr_float_to_complex_0 = gr.float_to_complex(1)
                self.gr_sig_source_x_0 = gr.sig_source_f(500000, gr.GR_COS_WAVE, 100000, .5, 0)
                self.gr_sig_source_x_1 = gr.sig_source_f(500000, gr.GR_SIN_WAVE, 100000, .5, 0)
                self.usrp_simple_sink_x_0 = grc_usrp.simple_sink_c(which=0, side="A")
                self.usrp_simple_sink_x_0.set_interp_rate(256)
                self.usrp_simple_sink_x_0.set_frequency(2.44e9, verbose=True)
                self.usrp_simple_sink_x_0.set_gain(80)
                self.usrp_simple_sink_x_0.set_enable(True)

                self.connect((self.gr_float_to_complex_0, 0), (self.usrp_simple_sink_x_0, 0))
                self.connect((self.gr_sig_source_x_0, 0), (self.gr_float_to_complex_0, 0))
                self.connect((self.gr_sig_source_x_1, 0), (self.gr_float_to_complex_0, 1))

------------------------------rx-------------------------------------------
                self.usrp_simple_source_x_0 = grc_usrp.simple_source_c(which=0, side="A", rx_ant="TX/RX")
                self.usrp_simple_source_x_0.set_decim_rate(256)
                self.usrp_simple_source_x_0.set_frequency(2.44e9, verbose=True)
                self.usrp_simple_source_x_0.set_gain(80)
                self.wxgui_fftsink2_2 = fftsink2.fft_sink_c(
                        self.GetWin(),
                        baseband_freq=0,
                        y_per_div=10,
                        y_divs=10,
                        ref_level=50,
                        sample_rate=500000,
                        fft_size=1024,
                        fft_rate=30,
                        average=False,
                        avg_alpha=None,
                        title="FFT Plot",
                        peak_hold=False,
                )
                self.Add(self.wxgui_fftsink2_2.win)
                self.connect((self.usrp_simple_source_x_0, 0), (self.wxgui_fftsink2_2, 0))

-----------------------------------------------------------------------------

Re: [Discuss-gnuradio] channel model question

But still there is a problem. 1000/100,000 = 0.01 so the channel_model must consume 100,000 samples coming into it to represent an offset of 1000Hz. How, does it know how many samples to consume as the ratio can be the same for a different combination such as 100/10000.

If x(i) = sin(2*pi*freq_offset_ratio*i) , i must vary from {1,sampling_rate}.

On Mon, Jun 28, 2010 at 3:00 PM, Josh Blum <josh@joshknows.com> wrote:
For some reason, the channel model's frequency_offset is not in Hz. Rather its a fraction of the sample rate. You should pass in my_offset_in_hz/my_sample_rate to this parameter.

The signal source works like that. I suppose that means that the sample rate and frequency are redundant because you really only care about the ratio between them.

_josh

oh consistency...


On 06/28/2010 02:12 PM, John Andrews wrote:
Hi,
I have a nagging doubt about how the channel model is implemented in
gnuradio. Suppose I have an input signal entering the channel model at
100,000 samples/sec. Let's say the channel model has to add an offset of
1000Hz to the input signal. Then I must have 100,000 samples of a 1000Hz
SINE_WAVE signal and multiply each input sample with a corresponding input
sample. Am I right? If I am right then i don't see this happening here with
the sampling rate given as 1 in the line below

d_freq_offset = gr_make_sig_source_c(1, GR_SIN_WAVE, frequency_offset, 1.0,
0.0);

If I am wrong then will someone please correct me here.

thank you very much
John




_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

[Discuss-gnuradio] Testing USRP2 on 6-core Phenom II X6 server

I took delivery on a server (well, the parts to build a server, which I
did) about a week ago. I've been
running tests on it with USRP2.

It's a Gigabyte GA880GM-UD2H motherboard, with 8G of 1333 DDR3 memory,
and a AMD Phenom II 1090T,
six-core CPU at 3.2GHz.

I'm running Fedora 12 x86_64, with the latest Gnu Radio GIT.

I was able to run usrp2_fft.py with decim=4 (25Msps!!) after increasing
the net.core.rmem_max and
net.core.wmem_max parameters to 500000 each.

With this configuration, usrp2_fft.py consumes about 25% of the
available CPU, or roughly 1.5 of the 6 CPUs
of the system.


--
Marcus Leech
Principal Investigator
Shirleys Bay Radio Astronomy Consortium
http://www.sbrac.org

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Re: [Discuss-gnuradio] UHD CMake error Boost not found

On 6/28/2010 3:42 PM, Josh Blum wrote:
> On 06/28/2010 02:14 PM, Criss Swaim wrote:
>> I am trying to upgrade the USRP2 firmware/fpga and UHD code to the most
>> current releases.
>> Fedora 11, 64-bit
>>
>> After upgrading the firmware/fpga (and before installing the new UHD
>> code) I can ping the USRP2, but the uhd_find_devices returns 'No USRP
>> found'
>>
>> I pulled the newest UHD code from the repository and when I run the
>> cmake ../ - receive an error that the boost libraries cannot be found.
>> After comparing the CMakelist.txt files between the old and new, the
>> only difference around the find boost was the new required boost 1.36
>> and the old required 1.37. Even after changing the required version to
>> 1.37, the new cmake fails.
>
> When you run cmake try:
>
> cmake -DBOOST_LIBRARYDIR=/usr/lib64 ../
>
> Ive seen this on a few fedora 64 bit machines, but the problem doesnt
> seem consistent... Anyway, let me know if that fixes it for you.
>
> -Josh

That corrected the problem. System compiles and can access the
USRP....thanks

>
>
> _______________________________________________
> Discuss-gnuradio mailing list
> Discuss-gnuradio@gnu.org
> http://lists.gnu.org/mailman/listinfo/discuss-gnuradio
>

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Re: [Discuss-gnuradio] channel model question

For some reason, the channel model's frequency_offset is not in Hz.
Rather its a fraction of the sample rate. You should pass in
my_offset_in_hz/my_sample_rate to this parameter.

The signal source works like that. I suppose that means that the sample
rate and frequency are redundant because you really only care about the
ratio between them.

_josh

oh consistency...

On 06/28/2010 02:12 PM, John Andrews wrote:
> Hi,
> I have a nagging doubt about how the channel model is implemented in
> gnuradio. Suppose I have an input signal entering the channel model at
> 100,000 samples/sec. Let's say the channel model has to add an offset of
> 1000Hz to the input signal. Then I must have 100,000 samples of a 1000Hz
> SINE_WAVE signal and multiply each input sample with a corresponding input
> sample. Am I right? If I am right then i don't see this happening here with
> the sampling rate given as 1 in the line below
>
> d_freq_offset = gr_make_sig_source_c(1, GR_SIN_WAVE, frequency_offset, 1.0,
> 0.0);
>
> If I am wrong then will someone please correct me here.
>
> thank you very much
> John
>
>
>
>
> _______________________________________________
> Discuss-gnuradio mailing list
> Discuss-gnuradio@gnu.org
> http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Re: [Discuss-gnuradio] Setting UHD kernel buffers

put these settings in /etc/sysctl.conf

you either have to reboot or login-logout

-Josh

On 06/28/2010 02:30 PM, Charles Brain wrote:
> When setting the kernel max buffers for UHD the manual
> suggests using sudo sysctl -w net.core.rmem_max=<new value>
> sudo sysctl -w net.core.wmem_max=<new value>
>
> I have done that on my system and it has made a huge difference to
> the performance of my software. I can now transmit my DVB-T signal
> continuously at 10 Ms/s with no dropouts.
>

excellent

> Unfortunately everytime I reboot my system I have to run the commands
> again. What is the procedure for making these settings permanent?
> I am no Linux guru hence the question. I am using Fedora 12.
>
> - Charles
>
> _______________________________________________
> Discuss-gnuradio mailing list
> Discuss-gnuradio@gnu.org
> http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Re: [Discuss-gnuradio] UHD CMake error Boost not found

On 06/28/2010 02:14 PM, Criss Swaim wrote:
> I am trying to upgrade the USRP2 firmware/fpga and UHD code to the most
> current releases.
> Fedora 11, 64-bit
>
> After upgrading the firmware/fpga (and before installing the new UHD
> code) I can ping the USRP2, but the uhd_find_devices returns 'No USRP found'
>
> I pulled the newest UHD code from the repository and when I run the
> cmake ../ - receive an error that the boost libraries cannot be found.
> After comparing the CMakelist.txt files between the old and new, the
> only difference around the find boost was the new required boost 1.36
> and the old required 1.37. Even after changing the required version to
> 1.37, the new cmake fails.

When you run cmake try:

cmake -DBOOST_LIBRARYDIR=/usr/lib64 ../

Ive seen this on a few fedora 64 bit machines, but the problem doesnt
seem consistent... Anyway, let me know if that fixes it for you.

-Josh


>
> Any suggestions would be appreciated.
>

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

[Discuss-gnuradio] Setting UHD kernel buffers

When setting the kernel max buffers for UHD the manual
suggests using
sudo sysctl -w net.core.rmem_max=<new value>
sudo sysctl -w net.core.wmem_max=<new value>

I have done that on my system and it has made a huge difference to
the performance of my software. I can now transmit my DVB-T
signal continuously at 10 Ms/s with no dropouts.

Unfortunately everytime I reboot my system I have to run the commands
again. What is the procedure for making these settings permanent?
I am no Linux guru hence the question. I am using Fedora 12.

- Charles

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

[Discuss-gnuradio] Re: channel model question

sorry guys my bad. The frequency_offset here is a ratio of the input sampling frequency. I should be RTFMing more carefully. :)

Thanks
John

On Mon, Jun 28, 2010 at 2:12 PM, John Andrews <gnu.fanz@gmail.com> wrote:
Hi,
I have a nagging doubt about how the channel model is implemented in gnuradio. Suppose I have an input signal entering the channel model at 100,000 samples/sec. Let's say the channel model has to add an offset of 1000Hz to the input signal. Then I must have 100,000 samples of a 1000Hz SINE_WAVE signal and multiply each input sample with a corresponding input sample. Am I right? If I am right then i don't see this happening here with the sampling rate given as 1 in the line below

d_freq_offset = gr_make_sig_source_c(1, GR_SIN_WAVE, frequency_offset, 1.0, 0.0);

If I am wrong then will someone please correct me here.

thank you very much
John

[Discuss-gnuradio] Simultaneous transmit and multichannel receive on USRP1

Hello everyone,

I was wondering if someone could either point me to an example or give
me some tips on how I can get setup gnuradio to do simultaneous
transmit and receive on multiple channels. At the moment, I just need
to transmit on one channel but need to receive on 4 independent
channels.

I am running gnuradio 3.2.2 on Ubuntu 9.04. I have a USRP-1 with 2
LFRX boards and 1 LFTX board.

Following the USRP code examples that came with gnuradio, what I've
been able to do successfully so far is:
--simultaneously transmit and receive on single channels.
--receive on 4 independent channels.

If I then take my working multi-channel receiver and just add a line
to create a transmitter sink object with usrp.sink_c(), all 4 receive
channels show sequences of alternating 0, -1 values instead of the
digitization of the signal that I'm putting into the input channels. I
don't have this problem if I modify my receiver to receive on just one
channel -- I can then transmit and receive simultaneously without
problems.

Any ideas on what I'm doing wrong here?

thanks
Young

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

[Discuss-gnuradio] UHD CMake error Boost not found

I am trying to upgrade the USRP2 firmware/fpga and UHD code to the most
current releases.
Fedora 11, 64-bit

After upgrading the firmware/fpga (and before installing the new UHD
code) I can ping the USRP2, but the uhd_find_devices returns 'No USRP found'

I pulled the newest UHD code from the repository and when I run the
cmake ../ - receive an error that the boost libraries cannot be found.
After comparing the CMakelist.txt files between the old and new, the
only difference around the find boost was the new required boost 1.36
and the old required 1.37. Even after changing the required version to
1.37, the new cmake fails.

Any suggestions would be appreciated.

--
Criss Swaim
cswaim@tpginc.net
cell: 505.301.5701


_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

[Discuss-gnuradio] channel model question

Hi,
I have a nagging doubt about how the channel model is implemented in gnuradio. Suppose I have an input signal entering the channel model at 100,000 samples/sec. Let's say the channel model has to add an offset of 1000Hz to the input signal. Then I must have 100,000 samples of a 1000Hz SINE_WAVE signal and multiply each input sample with a corresponding input sample. Am I right? If I am right then i don't see this happening here with the sampling rate given as 1 in the line below

d_freq_offset = gr_make_sig_source_c(1, GR_SIN_WAVE, frequency_offset, 1.0, 0.0);

If I am wrong then will someone please correct me here.

thank you very much
John

Re: [Discuss-gnuradio] High frequency OFDM

On Mon, Jun 28, 2010 at 7:37 AM, Joachim Roop <no.dr@gmx.de> wrote:
> Hi,
>
> I successfully implemented OFDM with two USRPs with LFRX/LFTX at 1-50MHz, connect by cable. Now I tried switching over to higher frequencies via TVRX/WBX. While I receive a perfectly valid looking spectrum with a good SNR, it does not seem to decode at >200MHz.
> If I increase the sub-carrier spacing of the transmission and thus the bandwidth, it works again. But why do I have to do that if the signal and SNR look okay?
>
> What destroys a OFMD signal at high frequencies? Is it phase noise? Is the USRPs frequency resolution different at higher frequencies?
>
> Any literature/papers on this topic would also be helpful - I am kind of stuck here.

It's probably due to the frequency offset. Since the local oscillator
has a certain offset at its nominal frequency, that offset is
multiplied when the signal is multiplied to a higher frequency. So the
higher the frequency, the more you are offset. In the case of the OFDM
signals, you are now farther off frequency than the lock-in range of
the receiver.

You already found one fix for this, which is making the subcarriers
larger. The other thing to do is look at the frequency offset between
the two devices and try to compensate for it.

There was a discussion about this a few months ago that you can look
for that explains a way to handle larger offsets better than the look
and tune method, which, while it works, isn't a realistic solution.

Tom

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Re: [Discuss-gnuradio] Synchronising USRP2's in GRC.

So guys, I want try to to modify the xml of the already existing
usrp2_source_xxxx by adding these line at the end of the <make> tag:
self.$(id).set_time_at_next_pps(time_spec_t(0,0))
time.sleep(1);
self.$(id).start_rx_streaming(0,time_spec_t(4,0))

So i set the time to zero at the next PPS, and make sure this happens by
waiting for a second, then start streaming at time 4 seconds. Of course,
this will be done for all USRP2's used.

Is this going to solve the issue? Any further suggestions?


Douglas Geiger-2 wrote:
>
> On Mon, Jun 21, 2010 at 10:05 AM, Douglas Geiger
> <doug.geiger@bioradiation.net> wrote:
>>
>>  The particular problem I run into is that time_spec_t is defined to
>> want a boost::uint32_t in the constructor (for the number of seconds),
>> along with a double (for fractional seconds) - but SWIG apparently
>> doesn't recognize boost::uint32_t is a typedef for an integer type, so
>> while I don't get compile-time errors, by the time I fire up python to
>> test out the function call (set_type_next_pps(const uhd::time_spec_t
>> &time_spec) in this case) - and try to construct a time_spec_t object
>> to pass, python throws an error as it doesn't believe I'm passing the
>> correct type.
>>
>
> Of course shortly after sending this, I figure out a solution - adding
> some typedefs to the SWIG .i file.
> It may not be the most elegant, but I do have something to work with now.
> Doug
>
> --
> Doug Geiger
> doug.geiger@bioradiation.net
>
> _______________________________________________
> Discuss-gnuradio mailing list
> Discuss-gnuradio@gnu.org
> http://lists.gnu.org/mailman/listinfo/discuss-gnuradio
>
>

--
View this message in context: http://old.nabble.com/Synchronising-USRP2%27s-in-GRC.-tp28947018p29008563.html
Sent from the GnuRadio mailing list archive at Nabble.com.


_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

[Discuss-gnuradio] High frequency OFDM

Hi,

I successfully implemented OFDM with two USRPs with LFRX/LFTX at 1-50MHz, connect by cable. Now I tried switching over to higher frequencies via TVRX/WBX. While I receive a perfectly valid looking spectrum with a good SNR, it does not seem to decode at >200MHz.
If I increase the sub-carrier spacing of the transmission and thus the bandwidth, it works again. But why do I have to do that if the signal and SNR look okay?

What destroys a OFMD signal at high frequencies? Is it phase noise? Is the USRPs frequency resolution different at higher frequencies?

Any literature/papers on this topic would also be helpful - I am kind of stuck here.
--
GMX DSL: Internet-, Telefon- und Handy-Flat ab 19,99 EUR/mtl.
Bis zu 150 EUR Startguthaben inklusive! http://portal.gmx.net/de/go/dsl

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Sunday, June 27, 2010

[Discuss-gnuradio] Bandwidth of a channel in tunnel.py

Hi all,
I hope one of you can help me with these questions,
How do I know bandwidth of transmission and reception channels in tunnel.py?
Is this determined by chan_coeffs produced by gr.firdes.low_pass?

thanks

Juan Quiroz


_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Re: [Discuss-gnuradio] Miller/Delay decoding

Dora,

I can help.
Can you describe VERY PRECISELY and concisely the encoding you are
trying to implement.
Once you do that I will help you construct the right FSM to describe it.

Achilleas

On Thu, Jun 24, 2010 at 5:16 PM, Dora Pa <mailinglistyard@gmail.com> wrote:
> Hi Achilleas.
>
> I've tried to describe an FSM and understand trellis but it seems that
> I'm not smart enough (have no experience with FSMs/trellis). Maybe you
> can help me.
>
> I got so far:
> 4 outputs: There are 4 kinds of outputs  = {1,00,01, previousBit}
> 2 inputs = state of the signal = {High, Low}
> 2 states = I assume this is the last bit so = {0,1}
>
> But I'm not sure about this. Because Miller does depend as far is I
> understand, on the delay between the edges.
>
> Is there an easier way to do this? I've tried to write a code block
> based on the bit-slicer code (count till an edge -> reset counter ->
> count till the next edge ... and then to decode the signal based on
> the length of the gap) but the results are weren't repeatable.
>
> Dora
>
> 2010/6/22 Achilleas Anastasopoulos <anastas@umich.edu>:
>> Dora,
>>
>> you can describe Miller encoding with an FSM with 2 states 2 inputs and 4
>> outputs. Once you do that both encoding and decoding can be done easily
>> using the gr-trellis framework.
>>
>> Achilleas
>>
>

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio