ainfosec / FISSURE

The RF and reverse engineering framework for everyone. Follow and ★ to show your support!
https://twitter.com/FissureRF
GNU General Public License v3.0
1.56k stars 85 forks source link

Fixed_threshold_b2x0.py does not work in 3.10 branch #35

Open seanee opened 1 year ago

seanee commented 1 year ago

Hi, I've found that _fixed_thresholdb2x0.py is broken. It tries to import GrRangeWidget from gnuradio.qtgui but GrRangeWidget does not exist (that I can see) in qtgui. I'm not sure if this is a version or something odd in my environment but I've checked that I am running the correct version of GNU radio and the most recent version of FISSURE. Has anyone seen this or had problems calling GrRangeWidget from other device types?

Here is the error: " TSI: Starting TSI Detector... Traceback (most recent call last): File "/home/johndoe/FISSURE/Flow Graph Library/TSI Flow Graphs/fixed_threshold_b2x0.py", line 41, in from gnuradio.qtgui import Range, GrRangeWidget ImportError: cannot import name 'GrRangeWidget' from 'gnuradio.qtgui' (/usr/lib/python3/dist-packages/gnuradio/qtgui/init.py) "

cpoore1 commented 1 year ago

What version of GNU Radio are you using and what happens if you drop a QT GUI Range block in GNU Radio Companion?

  1. gnuradio-companion
  2. Get version in the Console Panel
  3. Ctrl+F and type "Range"
  4. Drop block on any flow graph

If that works fine for version 3.10, you can try running the flow graph manually or rebuilding it. It should pop up a window and run from GNU Radio companion regardless of what FISSURE is doing.

seanee commented 1 year ago

I'm running GNU Radio Companion 3.10.5.1. The range widget opens fine but I don't really know how to drop it onto a flow graph. I will note that using a HackRF instead of the USRP B210 works fine but the HackRF code uses RageWidget instead of GrRangeWidget.

cpoore1 commented 1 year ago

Ok, I see the differences in GrRangeWidget and RangeWidget too. Each flow graph appears to have been compiled with a different version of 3.10. I would expect the flow graph to run fine if there are no clear errors present after you go into the flow graph and click either "play" or "generate the flow graph" or alternatively use the grcc command on the .grc file. If that doesn't work, you can search for a new range block, click the name, and drag it onto the canvas (or double click) and then swap out the existing block with the same parameters.

If that is all it takes to fix it, I can recompile them for the latest version or compile them all as part of the install. I'll look into it and check it again with your version. I have 3.10.4.0 in front of me now and it replaces RangeWidget with GrRangeWidget. Hopefully that's all it is and not some other Qt thing going on.

cpoore1 commented 1 year ago

I ran through it on a fresh install and you are correct. I get the same error but it goes away after running grcc. I will add an extra step to the installer for all the FISSURE flow graphs. I may hold off on other people’s OOT modules until I can test them out.

cpoore1 commented 1 year ago

I added a "Compile Flow Graphs" option in the installer. It should take around 15 minutes to do everything. I will try to keep the FISSURE flow graphs compiled and updated to match the GNU Radio version that gets installed going forward. This command in the "/FISSURE/Flow Graph Library" folder will do the same thing: find . -name '*.grc' -exec grcc {} \;