discuss-gnuradio
[Top][All Lists]
Advanced

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

R: R: Cannot run a command


From: Vincenzo Mone
Subject: R: R: Cannot run a command
Date: Mon, 7 Sep 2020 17:04:14 +0200

Hi Chris,

Ubuntu I am using the 20.04 version

To get the module I have used the command:

 

git clone https://github/.com/bg2bhc/gr-lilacsat gr-lilacsat-master

 

you can find the files under gr-lilacsat-master/examples/BY70-2

 

This should be the original one but as I got error with the PYQT5

Someone ( Cannot remember who ) sent me the version modified  but

Also got command how you know but he said that he could not help me more

As I had to find someone that understands about python.

If you want we can go back to the original one or continue with this PqYt5 one.

 

Yes if I hit a couple time CTRL C I got the prompt back but I think it is normal

As when I close the program I should get straight the prompt back.

Thanks once more for your helps.

 

 

 

73’s de Enzo IK8OZV
EasyLog 5 BetaTester
EasyLog PDA BetaTester
WinBollet BetaTester
D.C.I. CheckPoint Regione Campania
Skype: ik8ozv8520





      *********************************

      ******   GSM  +39 328 7110193  ******

      *****     SMS  +39 328 7110193    *****

      *********************************

 

Da: Chris Gorman <chrisjohgorman@gmail.com>
Inviato: lunedì 7 settembre 2020 16:38
A: Vincenzo Mone <vimone@alice.it>
Oggetto: Re: R: Cannot run a command

 

 

 

On Mon, Sep 7, 2020 at 4:24 AM Vincenzo Mone <vimone@alice.it> wrote:

Hi Chris,

I have tried your command and it seems it worked in part as the program started but

it is not complete with the datas

I mean this is what I got when I run the command after ran your suggested command:

 

 

 

 

While I should get like this:

 

 

 

Yes this is my concern.  We are trying to get code built for an old gnuradio working on a new one. They said that they got it working on ubuntu 14.04, but it didn't work on 16.04.  I assume you are using something newer.  You have gotten the gui running, but I don't know about the code being executed by the gui.  When I tried to build the project against gnuradio 3.8.1, I had to make modifications to CMakeLists.txt, pass the python executable and library to cmake and finally pass an include path to cmake to get it to build and it only built about 80% of the module.  I am not an expert at building libraries, but the one that was built, libgnuradio-lilacsat.so, should be linking to some gnuradio libraries and is not.  Because of this the test program tries to link to it and fails complaining about missing symbols.  I will try to get this to build further, but I can't promise anything. 

How you can see I have error in the bottom window and the right top is not filled.

I see your point.  I haven't even gotten this far.  How did you build and install the module?  What version of ubuntu are you using?  Are you only running the python scripts?  If so we need to build the module, install it and then run the python scripts.

Finally when I close it the terminal windows does not close I mean it does not give the prompt back.

Not too sure why the terminal hangs.  Perhaps a CTRL C in the terminal window will give the prompt back.

Thanks for your nice job

Sorry I couldn't get this working properly for you.

 

 

73’s de Enzo IK8OZV

EasyLog 5 BetaTester

EasyLog PDA BetaTester

WinBollet BetaTester

D.C.I. CheckPoint Regione Campania

Skype: ik8ozv8520

Take care.

 

Chris

 

 

 

 

      *********************************

      ******   GSM  +39 328 7110193  ******

      *****     SMS  +39 328 7110193    *****

      *********************************

 

> -----Messaggio originale-----

> Da: Chris Gorman <chrisjohgorman@gmail.com>

> Inviato: domenica 6 settembre 2020 22:27

> A: Vincenzo Mone <vimone@alice.it>

> Oggetto: Re: R: Cannot run a command

>

> Hi Vincenzo,

>

> I just googled what you are working on,

> https://github.com/bg2bhc/gr-lilacsat , looks interesting.  When looking at it,

> they used ubuntu 14.04 LTS, which is likely not what you are using.  He even

> stated on his page that he would welcome changes that fixed this for 16.04,

> which is also probably not what you're using.  You will probably have

> difficulties getting this to work as your development environment is different

> than theirs.  They were using PyQt4 and python2 along with an older

> gnuradio that used xml.  That said, I would try running 2to3 on all the python

> files and change any references to PyQt4 to PyQt5 and cross your fingers,

> when you try running it.

>

> To answer your question, I would try running 2to3 on all python files.

>

> running something like ...

>

> find /home/enzo/gr-lilacsat-pyqt5 -name "*.py" -exec 2to3 -w {} \;

>

> I will give it a try after my supper, if I can.  That said, I don't know if it will work

> with my hardware.

>

> Chris

>

> On Sun, Sep 6, 2020 at 3:11 PM Vincenzo Mone <vimone@alice.it> wrote:

> >

> > Apologies Chris,

> >

> > you said to run the 2to3 command on all the scripts that get called from

> mun_downlink_proxy.py.

> >

> > Please can you tell me all the scripts that I have to run the command

> > or how to do to know

> >

> > Which one are?

> >

> > Thanks for your collaboration and understanding

> >

> >

> >

> >

> >

> >

> >

> > 73’s de Enzo IK8OZV

> > EasyLog 5 BetaTester

> > EasyLog PDA BetaTester

> > WinBollet BetaTester

> > D.C.I. CheckPoint Regione Campania

> > Skype: ik8ozv8520

> >

> >

> >

> >

> >       *********************************

> >

> >       ******   GSM  +39 328 7110193  ******

> >

> >       *****     SMS  +39 328 7110193    *****

> >

> >       *********************************

> >

> >

> >

> > Da: Chris Gorman <chrisjohgorman@gmail.com>

> > Inviato: domenica 6 settembre 2020 20:58

> > A: Vincenzo Mone <vimone@alice.it>

> > Oggetto: Re: R: Cannot run a command

> >

> >

> >

> >

> >

> >

> >

> > On Sun, Sep 6, 2020 at 2:13 PM Vincenzo Mone <vimone@alice.it> wrote:

> >

> > Thank s Chris for your help.

> >

> > As I said before I am not so clever on the Linux so you have to drive

> > me by hand

> >

> > Like a little child when he goes to the school for the first time Lol.

> >

> >

> >

> > No problem, we all have to learn somewhere. :)

> >

> >

> >

> > BTW I have tried as you said with the command:

> >

> >

> >

> > 2to3 -w

> > /home/enzo/gr-lilacsat-pyqt5/examples/BY70-2/DSLWP-Downlink-

> Proxy/mun_

> > downlink_proxy.py

> >

> >

> >

> > But as I do I not had the program I got:

> >

> >

> >

> > Command "2to3" not found, but can be installed with:

> >

> >

> >

> > sudo apt install 2to3

> >

> >

> >

> > so I have installed it with the above suggested commandgr-lilacsat-pyqt5

> and ran again the 2to3 command and got:

> >

> >

> >

> > Command "2to3" not found, but can be installed with:

> >

> >

> >

> > sudo apt install 2to3

> >

> >

> >

> > RefactoringTool: Skipping optional fixer: buffer

> >

> > RefactoringTool: Skipping optional fixer: idioms

> >

> > RefactoringTool: Skipping optional fixer: set_literal

> >

> > RefactoringTool: Skipping optional fixer: ws_comma

> >

> > RefactoringTool: Refactored

> > /home/enzo/gr-lilacsat-pyqt5/examples/BY70-2/DSLWP-Downlink-

> Proxy/mun_

> > downlink_proxy.py

> >

> > ---

> > /home/enzo/gr-lilacsat-pyqt5/examples/BY70-2/DSLWP-Downlink-

> Proxy/mun_

> > downlink_proxy.py  (original)

> >

> > +++ /home/enzo/gr-lilacsat-pyqt5/examples/BY70-2/DSLWP-Downlink-

> Proxy/

> > +++ mun_downlink_proxy.py (refactored)

> >

> > @@ -26,7 +26,7 @@

> >

> > import datetime

> >

> > import xml.dom.minidom as minidom

> >

> > import pickle

> >

> > -import urllib2

> >

> > +import urllib.request, urllib.error, urllib.parse

> >

> >  from PyQt5 import QtGui, QtCore, Qt, QtWidgets

> >

> > # import ui confige

> >

> > @@ -296,7 +296,7 @@

> >

> >              f.close()

> >

> >              self.reload()

> >

> >          except Exception as error:

> >

> > -            print("[File] Configured file read failed. Error: " + str(error))

> >

> > +            print(("[File] Configured file read failed. Error: " +

> > + str(error)))

> >

> >      def reload(self):

> >

> >          '''

> >

> > @@ -593,7 +593,7 @@

> >

> >              Exception: an error occured accessing tle file or

> > grc_param.py

> >

> >          """

> >

> >          try:

> >

> > -            f = urllib2.urlopen(str(self.ui.tle_url_text.text()))

> >

> > +            f =

> > + urllib.request.urlopen(str(self.ui.tle_url_text.text()))

> >

> >              tle = f.read()

> >

> >              tle = tle.split("\n")

> >

> > @@ -641,13 +641,13 @@

> >

> >                      log += "%02X" % ord(i) + " "

> >

> >                      count += 1

> >

> >                  self.log_dict[index].write("Data: " + log + "\n\n")

> >

> > -                print(

> >

> > +                print((

> >

> >                      "[Data] Received time is " +

> >

> >                      datetime.datetime.utcfromtimestamp(

> >

> >

> > float(data['proxy_receive_time']/1000)).strftime(

> >

> > -                            '%Y-%m-%d %H:%M:%S'))

> >

> > -                print(

> >

> > -                    "Data is: " + log + "\n" + "Data Length is: " + str(count))

> >

> > +                            '%Y-%m-%d %H:%M:%S')))

> >

> > +                print((

> >

> > +                    "Data is: " + log + "\n" + "Data Length is: " +

> > + str(count)))

> >

> >                  self.log_dict[index].flush()

> >

> >      def normal_output_written(self, text):

> >

> > RefactoringTool: Files that were modified:

> >

> > RefactoringTool:

> > /home/enzo/gr-lilacsat-pyqt5/examples/BY70-2/DSLWP-Downlink-

> Proxy/mun_

> > downlink_proxy.py

> >

> >

> >

> > Then I have tried to run  again my command:

> >

> >

> >

> > python2

> > ~/gr-lilacsat-pyqt5/examples/BY70-2/DSLWP-Downlink-

> Proxy/mun_downlink_

> > proxy.py

> >

> >

> >

> > and got:

> >

> >

> >

> > Traceback (most recent call last):

> >

> >   File

> > "/home/enzo/gr-lilacsat-pyqt5/examples/BY70-2/DSLWP-Downlink-

> Proxy/mun

> > _downlink_proxy.py", line 29, in <module>

> >

> >     import urllib.request, urllib.error, urllib.parse

> >

> > ImportError: No module named request

> >

> >

> >

> >

> >

> > This is correct for we are converting your scripts to use python3.  I

> > recommend this as I don't think PyQt5 exists for python2.  (You

> > apparently can build it yourself, but it's not very easy to

> > accomplish.)

> >

> >

> >

> >

> >

> > If I run python3……………

> >

> > Instead of python2…….

> >

> > I get:

> >

> >

> >

> > Traceback (most recent call last):

> >

> >   File

> > "/home/enzo/gr-lilacsat-pyqt5/examples/BY70-2/DSLWP-Downlink-

> Proxy/mun

> > _downlink_proxy.py", line 38, in <module>

> >

> >     from core.data import server_data

> >

> >   File

> > "/home/enzo/gr-lilacsat-pyqt5/examples/BY70-2/DSLWP-Downlink-

> Proxy/cor

> > e/data.py", line 2, in <module>

> >

> >     import Queue

> >

> > ModuleNotFoundError: No module named 'Queue'

> >

> >

> >

> > You will have to run 2to3 on all the scripts that get called from

> mun_downlink_proxy.py.  So run ...

> >

> >

> >

> > 2to3 -w

> > /home/enzo/gr-lilacsat-pyqt5/examples/BY70-2/DSLWP-Downlink-

> Proxy/core

> > /data.py

> >

> >

> >

> > This will change Queue to queue which will load under python3.

> >

> >

> >

> > 2to3 -w other_script_that_gets_called_from_mun_downlink_proxy.py

> >

> >

> >

> > Your original scripts will be saved with a .bak extension.  Just rename them

> if you don't like 2to3's changes.

> >

> > eg.

> >

> >

> >

> > mv mun_downlink_proxy.py.bak mun_downlink_proxy.py

> >

> >

> >

> >

> >

> > Thanks

> >

> >

> >

> > No problem.

> >

> >

> >

> > Take care and let me know where you get to next.

> >

> >

> >

> > Chris

> >

> >

> >

> >

> >

> > 73’s de Enzo IK8OZV

> > EasyLog 5 BetaTester

> > EasyLog PDA BetaTester

> > WinBollet BetaTester

> > D.C.I. CheckPoint Regione Campania

> > Skype: ik8ozv8520

> >

> >

> >

> >

> >       *********************************

> >

> >       ******   GSM  +39 328 7110193  ******

> >

> >       *****     SMS  +39 328 7110193    *****

> >

> >       *********************************

> >

> >


reply via email to

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