discuss-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Discuss-gnuradio] Problem loading Python block


From: Nemanja Savic
Subject: Re: [Discuss-gnuradio] Problem loading Python block
Date: Fri, 1 Feb 2013 16:12:11 +0100

Guys,

As i told you my new installation works fine, I eve tested blocks in python. Now, the problem is following:

I designed block in python which has None for both input and output signature. I wanted to use such block only for receiving messages and for writing to terminal some information, etc.
The constructor of my new block, is executed, but the problem is work function is never executed. I put some printing at the beginning of work function and nothing happens. The work function looks like this:

    def work(self, input_items, output_items):
        print "In work"
        while True:
            print "In loop"
            try: msg = self._msgq.delete_head()
            except: return -1
            print "Message received"
        return len(output_items[0])

In the flow graph, I have vector source and message sink which shares message queue with my block. There are no errors.

Could the problem be no inputs and no outputs? Or maybe something else?

Best and thanks

Nemanja


On Fri, Feb 1, 2013 at 8:45 AM, Nemanja Savic <address@hidden> wrote:
Fortunately it was becuse path in my .bashrc file. it was eithout backslash at the begining.
So everything works now, regarding new installation, I am back to python blocks :).
Concerning this, my LD_LIBRARY_PATH is declared somewhere, cause when I ommit setting it in my .bashrc file it has value of: /usr/bin:/usr/local/lib64:/usr/local/lib. Should I, and how?
Many thanks guys!!

Best


On Fri, Feb 1, 2013 at 4:42 AM, Tom Rondeau <address@hidden> wrote:
On Thu, Jan 31, 2013 at 9:52 AM, Nemanja Savic <address@hidden> wrote:
The problem was bad LD_LIBRARY_PATH.
Can anybody explain:
why with LD_LIBRARY_PATH=/usr/bin:usr/local/lib64:usr/local/lib, GRC won't run, and with LD_LIBRARY_PATH=/usr/local/lib64. it works?

My only guess for that is you have something left over in one of those directories from a previous installation that's pointing to a wrong version. (Also, I wouldn't think that a bin directory ever needs to be in the library path.)

Tom

 
On Thu, Jan 31, 2013 at 2:37 PM, Nemanja Savic <address@hidden> wrote:
I deleted everything that was Gnu Radio-ish and istalled fresh new version. But it doesn't work now. GRC won't start, it complains about environment variable, I checket, they are good.
When I want to start uhd_fft I come the following error:

Traceback (most recent call last):
  File "/usr/local/bin/uhd_fft", line 24, in <module>
    from gnuradio import gr, gru
  File "/usr/local/lib64/python2.6/site-packages/gnuradio/gr/__init__.py", line 27, in <module>
    from gnuradio_core import *
  File "/usr/local/lib64/python2.6/site-packages/gnuradio/gr/gnuradio_core.py", line 23, in <module>
    from gnuradio_core_runtime import *
  File "/usr/local/lib64/python2.6/site-packages/gnuradio/gr/gnuradio_core_runtime.py", line 24, in <module>
    _gnuradio_core_runtime = swig_import_helper()
  File "/usr/local/lib64/python2.6/site-packages/gnuradio/gr/gnuradio_core_runtime.py", line 20, in swig_import_helper
    _mod = imp.load_module('_gnuradio_core_runtime', fp, pathname, description)
ImportError: libgnuradio-core-3.6.4git.so.0.0.0: cannot open shared object fil

The problem is this objest does exist in this location: /usr/local/lib64

I am using RHEL6.

Best


On Thu, Jan 31, 2013 at 11:34 AM, Martin Braun (CEL) <address@hidden> wrote:
Just install 3.6.3, you should be fine.
Otherwise, manually browse through /usr/local and kill everything that
looks GNU Radio-ish.

MB

On Wed, Jan 30, 2013 at 04:13:20PM +0100, Nemanja Savic wrote:
> In order to find which version I am using (since I have few build folders on my
> computer, and I don't know from which gnuradio was installed, because i tried a
> lot of times to install it without success (there were some problems since I am
> using RHEL6)) I decided to uninstall everything and make fresh new installation
> of gnuradio. I am receiving folloowing error from cmake:
>
>
>     -- Uninstalling "/usr/local/share/doc/gnuradio-3.6.0/README"
>     CMake Error at cmake_uninstall.cmake:20 (ELSEIF):
>       had incorrect arguments: IS_SYMLINK "$ENV{DESTDIR}${file}" (Unknown
>       arguments specified).
>
>
>     make[3]: *** [CMakeFiles/uninstall] Error 1
>     make[2]: *** [CMakeFiles/uninstall.dir/all] Error 2
>     make[1]: *** [CMakeFiles/uninstall.dir/rule] Error 2
>     make: *** [uninstall] Error 2
>
>
> I simply tried to make this file, but then there was another file missing, and
> so on.
>
> Is there any other way to uninstall gnuradio?
>
>
> Best
>
>
>
> On Wed, Jan 30, 2013 at 1:36 PM, Martin Braun (CEL) <address@hidden>
> wrote:
>
>
>     On Wed, Jan 30, 2013 at 01:23:19PM +0100, Nemanja Savic wrote:
>     > Today I have tried again, but this time i used block as is designed by
>     > gr_modtool. It wont wen throught test, bu it reports:
>     >
>     > AttributeError: 'module' object has no attribute 'sync_block'
>     >
>     >
>     > It is becoming horror.
>
>
>     Nemanja,
>
>     it seems like you haven't actually changed anything.
>
>     To recap:
>     - If you want Python blocks (gr.sync_block), you need > 3.6.3.
>     - You're doing something with messages (right?) Perhaps you want
>       msg_connect() rather than the old message queues (read
>       Johnathan's release announcement)
>
>     MB
>
>     --
>     Karlsruhe Institute of Technology (KIT)
>     Communications Engineering Lab (CEL)
>
>     Dipl.-Ing. Martin Braun
>     Research Associate
>
>     Kaiserstraße 12
>     Building 05.01
>     76131 Karlsruhe
>
>     Phone: +49 721 608-43790
>     Fax: +49 721 608-46071
>     www.cel.kit.edu
>
>     KIT -- University of the State of Baden-Württemberg and
>     National Laboratory of the Helmholtz Association
>
>
>     _______________________________________________
>     Discuss-gnuradio mailing list
>     address@hidden
>     https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
>
>
>
>
>
> --
> Nemanja Savić
>

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


--
Karlsruhe Institute of Technology (KIT)
Communications Engineering Lab (CEL)

Dipl.-Ing. Martin Braun
Research Associate

Kaiserstraße 12
Building 05.01
76131 Karlsruhe

Phone: +49 721 608-43790
Fax: +49 721 608-46071
www.cel.kit.edu

KIT -- University of the State of Baden-Württemberg and
National Laboratory of the Helmholtz Association

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




--
Nemanja Savić



--
Nemanja Savić

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





--
Nemanja Savić



--
Nemanja Savić

reply via email to

[Prev in Thread] Current Thread [Next in Thread]