Re: [Discuss-gnuradio] Creation of a block (PSDU 29 octets) using message passing technique
Hi Josh, I checked the code again. I am almost there, at this stage I don't get any error using gnuradio::block in my .cc file (see below): : gnuradio::block (test_temporal, gr_make_io_signature (0, 0, 0), //This is a source - no inputs gr_make_io_signature(0, 0, 0), msg_signature(false, 1)) and I changed the work function in the following way: int asrp_test_temporal::work (const InputItems input_items, const OutputItems output_items) However, when I compile this block, I am getting some errors with the swig file, which points out that my defined class has no member named 'detail' and 'set_detail'. The errors is shown below: asrp_swig.cc: In function 'PyObject* _wrap_asrp_test_temporal_sptr_detail(PyObject*, PyObject*)': asrp_swig.cc:8800:25: error: 'class asrp_test_temporal' has no member named 'detail' asrp_swig.cc: In function 'PyObject* _wrap_asrp_test_temporal_sptr_set_detail(PyObject*, PyObject*, PyObject*)': asrp_swig.cc:8852:16: error: 'class asrp_test_temporal' has no member named 'set_detail' Do you have any suggestion in this case?. Best Regards, Jose. On Thu, Sep 20, 2012 at 10:47 AM, Josh Blum j...@ettus.com wrote: On 09/19/2012 07:42 PM, Jose Torres Diaz wrote: Hi Josh, I modified in my .h file: #include gnuradio/block.h and also, I inherit from gnu radio as follows: //* This uses the preferred technique: subclassing gr_sync_block. //class asrp_test_temporal : public gr_sync_block class asrp_test_temporal : public gnuradio::block// --Here, I added the inherit { private: // Definition Then, in the .cc file I wrote: : gnuradio::block (test_temporal, gr_make_io_signature(0, 0, 0), gr_make_io_signature(0, 0, 0), msg_signature(false, 1)) When I compile again, the complain is different. It displays: asrp_test_temporal.cc:75:26: error: cannot allocate an object of abstract type 'asrp_test_temporal' ./asrp_test_temporal.h:99:7: note: because the following virtual functions are pure within 'asrp_test_temporal': /usr/local/include/gnuradio/block.h:236:17: note: virtual int gnuradio::block::work(const InputItems, const OutputItems) make[2]: *** [asrp_test_temporal.lo] Error 1 Double check the error, it just wants you to create a work method with the given definition. The signature stuff looks just fine. -josh According to the instruction in block coding: https://github.com/guruofquality/grextras/wiki/Blocks-Coding-Guide, I only need to write the msg_signature(#input,#output), but I decided to use the gr_make_io_signature anyway, because I am reading the code for the example of socket_to_blob.cc. 1. Do I need to use gr_make_io_signature or just msg_signature is enough?. Many thanks for your kind help, Regards, Jose. On Wed, Sep 19, 2012 at 3:33 PM, Josh Blum j...@ettus.com wrote: On 09/19/2012 01:11 AM, Jose Torres Diaz wrote: Hi, I'm trying to use message passing technique in order to create a block that generates 29 Octets. Currently, I'm using a block that generates 29 Octets and then use tag streaming. In the .cc file, IO signature looks like: gr_sync_block (st1_pktsrc_dummy_b, gr_make_io_signature (0, 0, 0), gr_make_io_signature (MIN_OUT, MAX_OUT, sizeof (unsigned char))) While, the stream tags looks like this: add_item_tag(0, tag_pos, d_burst_start_key, pmt_sob, d_my_unique_id) Now, I want to change this approach to message passing as it is explained here: https://github.com/guruofquality/grextras/wiki/Blocks-Coding-Guide . So, I changed the lines indicated above, for the following: : gr_sync_block (test_temporal, gr_make_io_signature(0, 0, 0), gr_make_io_signature(0, 0, 0), msg_signature(false, 1)) Careful here, check the coding guide, you need to #include gnuradio/block.h and inherit from gnuradio::block -josh ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
Re: [Discuss-gnuradio] Creation of a block (PSDU 29 octets) using message passing technique
Hi Josh, In order to add more information, I checked the the file asrp_swig.cc, which generates the error (line 8800) and I have the following: SWIGINTERN PyObject *_wrap_asrp_test_temporal_sptr_detail(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { PyObject *resultobj = 0; boost::shared_ptr asrp_test_temporal *arg1 = (boost::shared_ptr asrp_test_temporal *) 0 ; void *argp1 = 0 ; int res1 = 0 ; PyObject * obj0 = 0 ; gr_block_detail_sptr result; if(!PyArg_UnpackTuple(args,(char *)asrp_test_temporal_sptr_detail,1,1,obj0)) SWIG_fail; res1 = SWIG_ConvertPtr(obj0, argp1,SWIGTYPE_p_boost__shared_ptrT_asrp_test_temporal_t, 0 | 0 ); if (!SWIG_IsOK(res1)) { SWIG_exception_fail(SWIG_ArgError(res1), in method ' asrp_test_temporal_sptr_detail ', argument 1 of type ' boost::shared_ptr asrp_test_temporal const *'); } arg1 = reinterpret_cast boost::shared_ptr asrp_test_temporal * (argp1); { try { result = (*arg1)-detail(); } catch(std::exception e) { SWIG_exception(SWIG_RuntimeError, e.what()); } catch(...) { SWIG_exception(SWIG_RuntimeError, Unknown exception); } This files has the line wrap_asrp_test_temporal_sptr_detail. Also, inside the file block.h there is not detail parameter. I was using before in my block gr_sync_block and I did not get any error, I think because the file gr_sync_block.h does have a detail parameter. Is this right?, is this error due to this detail parameter missing?, how can I overcome/solve this issue?. Many thanks for your help, Jose On Thu, Sep 20, 2012 at 4:58 PM, Jose Torres Diaz torresdiaz.j...@gmail.com wrote: Hi Josh, I checked the code again. I am almost there, at this stage I don't get any error using gnuradio::block in my .cc file (see below): : gnuradio::block (test_temporal, gr_make_io_signature (0, 0, 0), //This is a source - no inputs gr_make_io_signature(0, 0, 0), msg_signature(false, 1)) and I changed the work function in the following way: int asrp_test_temporal::work (const InputItems input_items, const OutputItems output_items) However, when I compile this block, I am getting some errors with the swig file, which points out that my defined class has no member named 'detail' and 'set_detail'. The errors is shown below: asrp_swig.cc: In function 'PyObject* _wrap_asrp_test_temporal_sptr_detail(PyObject*, PyObject*)': asrp_swig.cc:8800:25: error: 'class asrp_test_temporal' has no member named 'detail' asrp_swig.cc: In function 'PyObject* _wrap_asrp_test_temporal_sptr_set_detail(PyObject*, PyObject*, PyObject*)': asrp_swig.cc:8852:16: error: 'class asrp_test_temporal' has no member named 'set_detail' Do you have any suggestion in this case?. Best Regards, Jose. On Thu, Sep 20, 2012 at 10:47 AM, Josh Blum j...@ettus.com wrote: On 09/19/2012 07:42 PM, Jose Torres Diaz wrote: Hi Josh, I modified in my .h file: #include gnuradio/block.h and also, I inherit from gnu radio as follows: //* This uses the preferred technique: subclassing gr_sync_block. //class asrp_test_temporal : public gr_sync_block class asrp_test_temporal : public gnuradio::block// --Here, I added the inherit { private: // Definition Then, in the .cc file I wrote: : gnuradio::block (test_temporal, gr_make_io_signature(0, 0, 0), gr_make_io_signature(0, 0, 0), msg_signature(false, 1)) When I compile again, the complain is different. It displays: asrp_test_temporal.cc:75:26: error: cannot allocate an object of abstract type 'asrp_test_temporal' ./asrp_test_temporal.h:99:7: note: because the following virtual functions are pure within 'asrp_test_temporal': /usr/local/include/gnuradio/block.h:236:17: note: virtual int gnuradio::block::work(const InputItems, const OutputItems) make[2]: *** [asrp_test_temporal.lo] Error 1 Double check the error, it just wants you to create a work method with the given definition. The signature stuff looks just fine. -josh According to the instruction in block coding: https://github.com/guruofquality/grextras/wiki/Blocks-Coding-Guide, I only need to write the msg_signature(#input,#output), but I decided to use the gr_make_io_signature anyway, because I am reading the code for the example of socket_to_blob.cc. 1. Do I need to use gr_make_io_signature or just msg_signature is enough?. Many thanks for your kind help, Regards, Jose. On Wed, Sep 19, 2012 at 3:33 PM, Josh Blum j...@ettus.com wrote: On 09/19/2012 01:11 AM, Jose Torres Diaz wrote: Hi, I'm trying to use message passing technique in order to create a block that generates 29 Octets. Currently, I'm using a block that generates 29 Octets and then use tag streaming. In the .cc file, IO signature looks like: gr_sync_block
[Discuss-gnuradio] GNURadio server is down?
Hi all, I cannot connect to GNURadio home page http://gnuradio.org/ And I cannot install GNURadio by build-gnuradio script. Is there something wrong? Wu ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
Re: [Discuss-gnuradio] variable sink in GRC
Hi! Use Probe Sink and Function Probe blocks. Martin On Thu, Sep 20, 2012 at 6:07 AM, widya agsari chime_aga...@yahoo.com wrote: i want to use variable sink block in GRC but i can`t find the block, could you tell me how i find that? ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
Re: [Discuss-gnuradio] GNURadio server is down?
On Thu, Sep 20, 2012 at 4:42 AM, Ting Wu wu.t...@comf5.comm.eng.osaka-u.ac.jp wrote: Hi all, I cannot connect to GNURadio home page http://gnuradio.org/ And I cannot install GNURadio by build-gnuradio script. Is there something wrong? Wu Wu, Looks like there was some interruption at our hosting service. I received some emails in the middle of the night. But it's back up and working now. Tom ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
Re: [Discuss-gnuradio] GNURadio server is down?
On Thu, Sep 20, 2012 at 6:20 AM, Tom Rondeau t...@trondeau.com wrote: Looks like there was some interruption at our hosting service. I received some emails in the middle of the night. But it's back up and working now. Best I could tell it was temporary network outage. Johnathan ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
Re: [Discuss-gnuradio] how to test sse2 support using cmake
Thanks Nick. Yes, I would like to migrate to volk and avoid all the hassles. Need to take some time to learn volk first. Can I assume volk can perform most of the intrinsics of sse2? Regards KZ On 18/09/2012, at 2:04 AM, Nick Foster wrote: Kyle, superhero This sounds like a job for VOLK! /superhero Seriously, sounds like your block could benefit from all the nice housekeeping that Volk takes care of for you, including runtime auto-detection of platform support, conditional compiling based on compiler support, and alignment reporting. Consider including at least the crunchy SSE core in libvolk. Check out the Volk guide in the documentation for instructions. --n On Sun, Sep 16, 2012 at 9:50 PM, Kyle Zhou kyle...@gmail.com wrote: I have a block which depends on sse2. I need to tell cmake to check if the cpu support sse2 in order to determine if the sse2 acceleated version or a generic version should be used. This should be straight forward. However, I just cannot find an example CMakeLists.txt to get me a quick start. Any suggested readings? thanks K Z ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
Re: [Discuss-gnuradio] how to test sse2 support using cmake
Yes, I did look at it. but that is too overwhelming to me so far. need to work harder :( On 17/09/2012, at 9:40 PM, Robert McGwier wrote: How about looking at the libvolk components and see how SSE is done and mimic? On Sep 17, 2012 12:51 AM, Kyle Zhou kyle...@gmail.com wrote: I have a block which depends on sse2. I need to tell cmake to check if the cpu support sse2 in order to determine if the sse2 acceleated version or a generic version should be used. This should be straight forward. However, I just cannot find an example CMakeLists.txt to get me a quick start. Any suggested readings? thanks K Z ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
[Discuss-gnuradio] frequent phase slip with the new digital.costas_loop_cc
I adapted my codes from gnuradio-3.3 to the new 3.6 version. One of the changes is the new digital.costas_loop_cc is now implemented based on control_loop. The costas loop is used for phase recovery of a QPSK signal. But I noticed that with the new version, the output experiences a lot of phase slips. To be exact, the phase at the output rotate 90 degree from time to time. I changed it back to the old gr.costas_loop_cc and this did not happen. The setting for the old loop is alpha=0.01, beta=alpha*alpha/4, max_freq=2*pi*0.1, min_freq=-max_freq. The setting for the new loop is loop bandwidth = 2*pi/100 The new version is only good when SNR is very high, say 13dB+ Any has encountered the same problem? or am I doing something wrong? KZ ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
Re: [Discuss-gnuradio] 2 complex receive channels on usrp n210
I am getting complex data around my center frequency, but only on one channel, RXA shows the data, while RXB is just zeros. In my code, I have just added a few lines from rx_samples_to_file.cpp to rx_multi_samples.cpp to make rx_multi_samples write out to a file. This is with the subdevice specs A:A and A:B, should I change those? On Wed, Sep 19, 2012 at 6:50 PM, Josh Blum j...@ettus.com wrote: On 09/19/2012 04:54 PM, Anisha Gorur wrote: I tried this out, and I am getting two real signals, while I want two complex signals. From dboards.rst: ^^^ Basic RX and LFRX ^^^ The Basic RX and LFRX boards have 4 frontends: * **Frontend A:** real signal on antenna RXA * **Frontend B:** real signal on antenna RXB * **Frontend AB:** quadrature frontend using both antennas (IQ) * **Frontend BA:** quadrature frontend using both antennas (QI) So choosing A and B as the subdevice specs would give me two real signals, correct? In this case, the DDC chains will zero out Q, and connect A or B to I. So you will get complex data centered at whatever you tune center frequency to. -josh On Wed, Sep 19, 2012 at 2:58 PM, Anisha Gorur at...@virginia.edu wrote: Great! So if i selected 0:A and 0:B as multiple subdevices, I would receive something like I0, Q0 and I1, Q1? On Wed, Sep 19, 2012 at 12:45 PM, Josh Blum j...@ettus.com wrote: On 09/19/2012 10:44 AM, Anisha Gorur wrote: Hello All, I know that on the USRP1, it was possible to have four seperate RX channels, and therefore receive two pairs of IQ samples. I was wondering if there were any way to do this on a USRP N210, using a basic RX daughterboard, even by possible changing the FPGA code, or it you could only have one pair of IQ samples. Yes. Same idea, except, the frontend names for Basic RX are A, B, and AB: http://lists.ettus.com/pipermail/usrp-users_lists.ettus.com/2011-May/001271.html -josh Thanks, Anisha ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio -- Anisha Gorur Class of 2012 Electrical Engineering -- Anisha Gorur Class of 2012 Electrical Engineering ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
Re: [Discuss-gnuradio] Using two daughter boards in USRP1.
On 09/20/2012 09:46 AM, Sajjad Safdar wrote: Hello, I am trying to use two daughter boards in one USRP1. I have RFX400 on one side A and TVRX on side B. When i try to use two seprate terminals to test the daughter cards in such a way that RFX400 is transmitting and TVRX is recieving on the same USRP1 device using uhd_fft and benchmark_tx.py for sending data, but this does not work. when i run uhd_fft the scanning works but when i try to run benchmark_tx in another window, it gives some error tha can not find usrp device, how can i make it possible to work with both cards on the same device rather than using two different devices. You need to use the source and sink block within the same process. Since uhd_fft and benchmark* are two different apps, you may have better luck re-creating those apps within one GRC flowgraph. -josh ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
Re: [Discuss-gnuradio] how to test sse2 support using cmake
On 09/20/2012 09:37 AM, Kyle Zhou wrote: Thanks Nick. Yes, I would like to migrate to volk and avoid all the hassles. Need to take some time to learn volk first. Can I assume volk can perform most of the intrinsics of sse2? Regards KZ On Checkout the next branch (which has the latest in volk work) create volk/kernels/volk/volk_my_kern.h #ifdef LV_HAVE_GENERIC volk_my_kern_generic(params) { //generic c implementation } #endif #ifdef LV_HAVE_SSE2 #include intrinsics headers.h //the _a means that this kernel requires aligned pointers //otherwise use _u if it does not volk_my_kern_sse2_a(params) { //call sse intrinsics here } #endif -- Now just re-run cmake and build. When you include volk/volk.h you will have access to volk_my_kern(params) and that handles the runtime selection. Rename my_kern to follow the naming convention and contribute the work back! :-) -josh 18/09/2012, at 2:04 AM, Nick Foster wrote: Kyle, superhero This sounds like a job for VOLK! /superhero Seriously, sounds like your block could benefit from all the nice housekeeping that Volk takes care of for you, including runtime auto-detection of platform support, conditional compiling based on compiler support, and alignment reporting. Consider including at least the crunchy SSE core in libvolk. Check out the Volk guide in the documentation for instructions. --n On Sun, Sep 16, 2012 at 9:50 PM, Kyle Zhou kyle...@gmail.com wrote: I have a block which depends on sse2. I need to tell cmake to check if the cpu support sse2 in order to determine if the sse2 acceleated version or a generic version should be used. This should be straight forward. However, I just cannot find an example CMakeLists.txt to get me a quick start. Any suggested readings? thanks K Z ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
Re: [Discuss-gnuradio] UHD replacement for write_fpga_reg
Josh, Thanks for your help, everything works now! The set_user_register() function appears to work perfectly with my USRP1. I'm going to submit my design to our sponsor for approval. If they approve, I will make it available for download in a few weeks once I finish cleaning up the code. Colin signature.asc Description: OpenPGP digital signature ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
Re: [Discuss-gnuradio] Creation of a block (PSDU 29 octets) using message passing technique
On 09/20/2012 03:28 AM, Jose Torres Diaz wrote: Hi Josh, I checked the code again. I am almost there, at this stage I don't get any error using gnuradio::block in my .cc file (see below): : gnuradio::block (test_temporal, gr_make_io_signature (0, 0, 0), //This is a source - no inputs gr_make_io_signature(0, 0, 0), msg_signature(false, 1)) and I changed the work function in the following way: int asrp_test_temporal::work (const InputItems input_items, const OutputItems output_items) However, when I compile this block, I am getting some errors with the swig file, which points out that my defined class has no member named 'detail' and 'set_detail'. The errors is shown below: asrp_swig.cc: In function 'PyObject* _wrap_asrp_test_temporal_sptr_detail(PyObject*, PyObject*)': asrp_swig.cc:8800:25: error: 'class asrp_test_temporal' has no member named 'detail' asrp_swig.cc: In function 'PyObject* _wrap_asrp_test_temporal_sptr_set_detail(PyObject*, PyObject*, PyObject*)': asrp_swig.cc:8852:16: error: 'class asrp_test_temporal' has no member named 'set_detail' Looks like swig is trying to understand the boost shared pointer stuff. I usually never see this so you might be missing an include in the .i file. Make sure you have %includegnuradio.i and %includeextras_swig.i -josh ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
[Discuss-gnuradio] gr_block::set_history()
I have a general work function for which I will use GNU Radio's history functionality. In the block's constructor, I call set_history( m ). I cast the input buffer in the standard way: const float *in = (const float *) input_items[0]; My question is wheere in[0] refers to in the buffer. It would make sense to me that noutput_items is the number of new items for the block to consume and ninput_items[0] refers to the total number of data in the buffer. So, in[noutput_items-1] is the last element of the array, in[0] is the start of the new items, and the in[-m] refers to the beginning of the history block. Thus, ninput_items[0] is greater than or equal to m + noutput_items. I don't know if this assumption is true and would be pleased if someone knew how this works. The GNU Radio API is somewhat vague in this respect. Thanks in advance! -- View this message in context: http://gnuradio.4.n7.nabble.com/gr-block-set-history-tp37687.html Sent from the GnuRadio mailing list archive at Nabble.com. ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
[Discuss-gnuradio] Why is my USRP N210 front panel LED E light blinking rapidly all the time?
Hello, As a new user I have just made the uhd_fft.py to display something. I use the LFRX daughter board for initial testing. I have a concern with the front panel LED E light. While the uhd_fft.py is working, both the LED C and E lights are on solidly which is expected. When shutting off the uhd_fft.py, the two lights went off also. But the LED E light starts to first slowly blink and then to pick up speed in blinking. The E light being the ref lock, I am guessing the rx board doesn't like not having a ref? It got really annoying watching the fast blinking light. I fear that this might not be good for the overall health of the system. The only to cure this seem to be power cycle, which is not preferred. What should I do to prevent this or to ensure that everything is working correctly and there is no system complaints? Thanks, LD Zhang ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
Re: [Discuss-gnuradio] Why is my USRP N210 front panel LED E light blinking rapidly all the time?
It's fine, ignore it. The LED is reflecting the fact that the internal oscillator is unlocked from the reference, which is normal when the device isn't being used. When you initialize it again next time, it'll lock up. --n On Thu, Sep 20, 2012 at 4:43 PM, LD Zhang ldz10...@gmail.com wrote: Hello, As a new user I have just made the uhd_fft.py to display something. I use the LFRX daughter board for initial testing. I have a concern with the front panel LED E light. While the uhd_fft.py is working, both the LED C and E lights are on solidly which is expected. When shutting off the uhd_fft.py, the two lights went off also. But the LED E light starts to first slowly blink and then to pick up speed in blinking. The E light being the ref lock, I am guessing the rx board doesn't like not having a ref? It got really annoying watching the fast blinking light. I fear that this might not be good for the overall health of the system. The only to cure this seem to be power cycle, which is not preferred. What should I do to prevent this or to ensure that everything is working correctly and there is no system complaints? Thanks, LD Zhang ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
Re: [Discuss-gnuradio] gr_block::set_history()
I have a general work function for which I will use GNU Radio's history functionality. In the block's constructor, I call set_history( m ). I cast the input buffer in the standard way: const float *in = (const float *) input_items[0]; My question is wheere in[0] refers to in the buffer. It would make sense to me that noutput_items is the number of new items for the block to consume and ninput_items[0] refers to the total number of data in the buffer. So, in[noutput_items-1] is the last element of the array, in[0] is the start of the new items, and the in[-m] refers to the beginning of the history block. Thus, ninput_items[0] is greater than or equal to m + noutput_items. I don't know if this assumption is true and would be pleased if someone knew how this works. The GNU Radio API is somewhat vague in this respect. Thanks in advance! * From you description you should use sync block. Anyway, my knowledge on history is: (assuming 1:1 in-out ratio) in[0] to in[noutput_items+m-2] are what you can use to produce noutput_items outputs. in[0] is the oldest and in[noutput_items+m-2] is the newest sample. ninput_items[0]==noutput_items+m-1 Any one can correct me? KZ ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
[Discuss-gnuradio] tunnel.py problem
At first we able to run the tunnel.py with setting gr0 and then ping to specific machine. Now when we increase the distance little bit we are unable to ping the machine however if we use uhd_fft to see the signal we get the signal.please provide me some pointer related to this issue means how should I debug this problem as when I place the USRP at same places like first experiment , I am still unable to ping the USRP it now always show Destination Host Unreachable ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
Re: [Discuss-gnuradio] frequent phase slip with the new digital.costas_loop_cc
On 21/09/2012, at 12:45 AM, Tom Rondeau wrote: On Thu, Sep 20, 2012 at 9:56 AM, Kyle Zhou kyle...@gmail.com wrote: I adapted my codes from gnuradio-3.3 to the new 3.6 version. One of the changes is the new digital.costas_loop_cc is now implemented based on control_loop. The costas loop is used for phase recovery of a QPSK signal. But I noticed that with the new version, the output experiences a lot of phase slips. To be exact, the phase at the output rotate 90 degree from time to time. I changed it back to the old gr.costas_loop_cc and this did not happen. The setting for the old loop is alpha=0.01, beta=alpha*alpha/4, max_freq=2*pi*0.1, min_freq=-max_freq. The setting for the new loop is loop bandwidth = 2*pi/100 The new version is only good when SNR is very high, say 13dB+ Any has encountered the same problem? or am I doing something wrong? KZ Hi Kyle, I was using this just last week in a demonstration and hadn't noticed any problems. If you can pin-point what's going wrong, though, I'll be sure to fix it. Tom After playing the module for a while, I figured out where the problem is. The default setting to the loop bandwidth 2*pi/100 is too big. I am not familiar with the control loop bandwidth stuff. But change it to 2*pi/1000 makes things working. For a QPSK, Eb/N0=8 dB will cause the loop out of lock if set as 2*pi/100. Even with 10 dB, the frequency offset varies a lot. I know it is certain trade off between max captured offset and performance. But 2*pi/100 is definitely far from optimal. I will learn more about control loop to get an idea how the bandwidth should be determined. Any suggestions? KZ ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
[Discuss-gnuradio] Building blocks of gnuradio-companion - GR file sink
Hi, We are trying to build a simulated model using the building blocks of gnuradio-companion tool. In the GRC model one of the blocks is the GR file sink block which is intended for storage of the data. Now the issue is that if the program is run for a longer period of time(say 40-60m mins) the data file size would grow huge(may be in GB), somehow we want to prevent/restrict the data file size to a few MB's - like a fixed size circular buffer. Is there any way GRC API which would allows us to set the filesize? Another harder way is to write code to check file size and if that exceeds certain limit, we can backup the data and flush the file to restart storing again. Please comment what would be an easier way to achieve this? Regards, Hussain ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
Re: [Discuss-gnuradio] Creation of a block (PSDU 29 octets) using message passing technique
Hi Josh, I've been playing around with this block and indeed it was missing in the .i file extras_swig.i. I included as: %include extras_swig.i //add on 21 Sept %include extras_blobs.i //add on 21 Sept -- I added this line also Also, I tried to change other parameters, but the problem still there. The error is: asrp_swig.cc: In function 'PyObject* _wrap_asrp_test_temporal_sptr_detail(PyObject*, PyObject*)': asrp_swig.cc:8800:25: error: 'class asrp_test_temporal' has no member named 'detail' asrp_swig.cc: In function 'PyObject* _wrap_asrp_test_temporal_sptr_set_detail(PyObject*, PyObject*, PyObject*)': asrp_swig.cc:8852:16: error: 'class asrp_test_temporal' has no member named 'set_detail' I thought that I could remove the lines 8800 and 8852 in asrp_swig.cc for the variables that is complaining about (detail and set_detail). However, it does not compile anymore if I tried this option. Thanks for your help, Regards, Jose. On Fri, Sep 21, 2012 at 5:37 AM, Josh Blum j...@ettus.com wrote: On 09/20/2012 03:28 AM, Jose Torres Diaz wrote: Hi Josh, I checked the code again. I am almost there, at this stage I don't get any error using gnuradio::block in my .cc file (see below): : gnuradio::block (test_temporal, gr_make_io_signature (0, 0, 0), //This is a source - no inputs gr_make_io_signature(0, 0, 0), msg_signature(false, 1)) and I changed the work function in the following way: int asrp_test_temporal::work (const InputItems input_items, const OutputItems output_items) However, when I compile this block, I am getting some errors with the swig file, which points out that my defined class has no member named 'detail' and 'set_detail'. The errors is shown below: asrp_swig.cc: In function 'PyObject* _wrap_asrp_test_temporal_sptr_detail(PyObject*, PyObject*)': asrp_swig.cc:8800:25: error: 'class asrp_test_temporal' has no member named 'detail' asrp_swig.cc: In function 'PyObject* _wrap_asrp_test_temporal_sptr_set_detail(PyObject*, PyObject*, PyObject*)': asrp_swig.cc:8852:16: error: 'class asrp_test_temporal' has no member named 'set_detail' Looks like swig is trying to understand the boost shared pointer stuff. I usually never see this so you might be missing an include in the .i file. Make sure you have %includegnuradio.i and %includeextras_swig.i -josh ___ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio