# Uhd\_fft missing

**URL:** <https://www.ruby-forum.com/t/uhd-fft-missing/239836>\
**Category:** GNU Radio\
**Created:** [March 16, 2014, 8:21pm UTC](https://www.ruby-forum.com/t/uhd-fft-missing/239836 "2014-03-16T20:21:29Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![musicdenotation](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/ea666f/32.png) [@musicdenotation](https://www.ruby-forum.com/u/musicdenotation)\
**Post date:** [March 16, 2014, 8:21pm UTC](https://www.ruby-forum.com/t/uhd-fft-missing/239836/1 "2014-03-16T20:21:29Z")

</div>

Hello,

Using gentoo linux I installed uhd and gnuradio with the commands  
“emerge uhd” and “emerge gnuradio”. According to  
[http://gnuradio.org/redmine/projects/gnuradio/wiki/HowToUse:](http://gnuradio.org/redmine/projects/gnuradio/wiki/HowToUse:)

“GNU Radio comes with a large variety of tools and programs… The  
most commonly used tools include uhd\_fft”

Unfortunately I do not have uhd\_fft on my system. I do have  
uhd\_cal\_rx\_iq\_balance, uhd\_cal\_tx\_iq\_balance , uhd\_images\_downloader,  
uhd\_cal\_tx\_dc\_offset, uhd\_find\_devices, and uhd\_usrp\_probe.

According to  
[http://gnuradio.org/redmine/projects/gnuradio/wiki/InstallingGRFromSource:](http://gnuradio.org/redmine/projects/gnuradio/wiki/InstallingGRFromSource:)

“If you want to be able to use USRP devices, you need to install UHD  
before installing GNU Radio.”

Questions:

Q1: Why do I not have uhd\_fft on my system?

Q2: What is the technically going on that leads to the warning about  
installing UHD before gnuradio? What are the consequences of  
installing UHD after GNU Radio?

Q3: Which package provides the file uhd\_fft: GNU Radio, UHD, or  
something else?

Thank you,

Chris

---

<div class="post-metadata">

**Author:** ![yetanothergeek](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/y/8e8cbc/32.png) [@yetanothergeek](https://www.ruby-forum.com/u/yetanothergeek)\
**Post date:** [March 16, 2014, 8:33pm UTC](https://www.ruby-forum.com/t/uhd-fft-missing/239836/2 "2014-03-16T20:33:06Z")

</div>

On 03/16/2014 03:20 PM, Chris S. wrote:

> uhd\_cal\_rx\_iq\_balance, uhd\_cal\_tx\_iq\_balance , uhd\_images\_downloader,  
> uhd\_cal\_tx\_dc\_offset, uhd\_find\_devices, and uhd\_usrp\_probe.
> 
> According to  
> [http://gnuradio.org/redmine/projects/gnuradio/wiki/InstallingGRFromSource:](http://gnuradio.org/redmine/projects/gnuradio/wiki/InstallingGRFromSource:)
> 
> “If you want to be able to use USRP devices, you need to install UHD  
> before installing GNU Radio.”
> 
> Questions:
> 
> Q1: Why do I not have uhd\_fft on my system?  
> I can’t answer that one
> 
> Q2: What is the technically going on that leads to the warning about  
> installing UHD before gnuradio? What are the consequences of  
> installing UHD after GNU Radio?  
> If you’re building from source, the source-build needs to know where UHD  
> is installed on your system before it can build gr-uhd, since gr-uhd  
> links again UHD libraries. It can’t very well do that until UHD has  
> already been installed…

> Q3: Which package provides the file uhd\_fft: GNU Radio, UHD, or something else?  
> It’s part of gr-uhd/apps

---

<div class="post-metadata">

**Author:** ![yetanothergeek](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/y/8e8cbc/32.png) [@yetanothergeek](https://www.ruby-forum.com/u/yetanothergeek)\
**Post date:** [March 16, 2014, 10:05pm UTC](https://www.ruby-forum.com/t/uhd-fft-missing/239836/3 "2014-03-16T22:05:22Z")

</div>

On Sun, Mar 16, 2014 at 12:48 PM, Sylvain M. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)  
wrote:

> Since you’re using gentoo, I think the most likely scenario is that  
> the ‘wx’ USE flag is disabled.

Sylvain,

Thank you for your help. Turns out I the wxwidgets USE flag us set…  
but the uhd USE flag was unset. Rebuilding now, but I’m sure this  
will fix the problem. BTW, as you might guess, the uhd USE flag  
causes net-wireless/gnuradio to bring in net-wireless/uhd. I should  
have known something was up when I had to manually emerge uhd.

Chris

---

<div class="post-metadata">

**Author:** ![yetanothergeek](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/y/8e8cbc/32.png) [@yetanothergeek](https://www.ruby-forum.com/u/yetanothergeek)\
**Post date:** [March 16, 2014, 8:49pm UTC](https://www.ruby-forum.com/t/uhd-fft-missing/239836/4 "2014-03-16T20:49:36Z")

</div>

> Q1: Why do I not have uhd\_fft on my system?

Since you’re using gentoo, I think the most likely scenario is that  
the ‘wx’ USE flag is disabled.

uhd\_fft is a python WXwidget application, so if you disabled this, you  
will not have it.

Cheers,

Sylvain

---

<div class="post-metadata">

**Author:** ![yetanothergeek](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/y/8e8cbc/32.png) [@yetanothergeek](https://www.ruby-forum.com/u/yetanothergeek)\
**Post date:** [March 16, 2014, 10:11pm UTC](https://www.ruby-forum.com/t/uhd-fft-missing/239836/5 "2014-03-16T22:11:31Z")

</div>

On 03/16/2014 05:06 PM, Chris S. wrote:

> Chris  
> The nice thing about distribution-specific idioms is…there’s too  
> damned many from which to choose. ☹

People often criticize build-gnuradio because it “doesn’t cover _my_  
particular distribution”, as if adding support for a new distrib  
is as easy as dumping Nigerian spam in your junk folder…

One of Linux’ most serious weaknesses has emerged from its most profound  
strength–there are now dozens of distribs extant, each  
with their own peculiar packaging tools, idioms, and filesystem  
layouts, and with that, troubleshooting strategies. If I were in charge  
of  
the world, there would only be one Linux distribution 🙂 🙂

---

<div class="post-metadata">

**Author:** ![yetanothergeek](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/y/8e8cbc/32.png) [@yetanothergeek](https://www.ruby-forum.com/u/yetanothergeek)\
**Post date:** [March 18, 2014, 12:11am UTC](https://www.ruby-forum.com/t/uhd-fft-missing/239836/6 "2014-03-18T00:11:02Z")

</div>

On 03/16/2014 05:06 PM, Chris S. wrote:

> rebuilding now but I’m sure it will work correctly.  
> Just to confirm, is everything working properly for you now, Chris?

Thanks,  
Zero\_Chaos  
Radio Herd  
Gentoo Linux

---

<div class="post-metadata">

**Author:** ![yetanothergeek](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/y/8e8cbc/32.png) [@yetanothergeek](https://www.ruby-forum.com/u/yetanothergeek)\
**Post date:** [March 16, 2014, 10:07pm UTC](https://www.ruby-forum.com/t/uhd-fft-missing/239836/7 "2014-03-16T22:07:13Z")

</div>

On Sun, Mar 16, 2014 at 12:31 PM, Marcus D. Leech [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)  
wrote:

> If you’re building from source, the source-build needs to know where UHD is  
> installed on your system before it can build gr-uhd, since gr-uhd  
> links again UHD libraries.

Marcus,

Thank you. In gentoo speak, what you said typically translates to  
“The gnuradio ebuild has a uhd USE flag. Make sure the uhd USE flag  
is enabled.” Well, I checked and sure enough it was disabled. I’m  
rebuilding now but I’m sure it will work correctly.

Thanks again,

Chris

---

<div class="post-metadata">

**Author:** ![yetanothergeek](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/y/8e8cbc/32.png) [@yetanothergeek](https://www.ruby-forum.com/u/yetanothergeek)\
**Post date:** [March 19, 2014, 9:30pm UTC](https://www.ruby-forum.com/t/uhd-fft-missing/239836/8 "2014-03-19T21:30:40Z")

</div>

On Mon, Mar 17, 2014 at 3:19 PM, Rick F. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> Just to confirm, is everything working properly for you now, Chris?

Yes, with the portage mods below:

package.keywords:  
~net-wireless/gnuradio-3.7.3 ~amd64  
~dev-python/pyqwt-5.2.0 ~amd64  
~dev-libs/boost-1.53.0 ~amd64  
~dev-util/boost-build-1.53.0 ~amd64  
~net-wireless/uhd-3.7.0 ~amd64

package.use:  
net-wireless/gnuradio grc uhd examples

Also, it took me a while to figure out that the UHD examples were  
zipped up and placed at /usr/share/doc/gnuradio-3.7.3/examples/

Thank you,

Chris

---

<div class="post-metadata">

**Author:** ![yetanothergeek](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/y/8e8cbc/32.png) [@yetanothergeek](https://www.ruby-forum.com/u/yetanothergeek)\
**Post date:** [March 20, 2014, 5:31pm UTC](https://www.ruby-forum.com/t/uhd-fft-missing/239836/9 "2014-03-20T17:31:34Z")

</div>

-----BEGIN PGP SIGNED MESSAGE-----  
Hash: SHA1

Hi George,

practical implementation aside: Thanks to Parseval’s theorem, looking  
at relative signal strength in frequency and time domain is equivalent.  
You can just use a number sink or time sink with a low pass filter to  
visualize the received signal power of the carrier. If you’re feeling  
like doing things completely right, you can automatically fine tune to  
the carrier by using PLL carrier tracking 😉

As for implementation: there is the max block. What you could do is:  
PLL → low pass → complex to mag → integrate → stream to vector →   
max/argmax (depends on what you actually want to do)  
but that will not “update” your maximum during runtime but only find  
the maximum within a vector.

However, implementing an “always output the (abs)maximum float value”  
block is really easy as a python block - in fact, doing that might be  
a great start into developing GNU Radio blocks. Doing it somewhat  
optimized might need some thought, though 😉

Greetings,  
Marcus

PS: please make sure not to respond to previous posts when bringing up  
a new topic; otherwise, your post will appear in that thread and is  
more likely to be ignored.

On 20.03.2014 16:05, George S. Williams wrote:

> signal but can’t figure out how to measure the peak. Any advice  
> would be appreciated.
> 
> Thanks, George
> 
> \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_ Discuss-gnuradio  
> mailing list [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)  
> [Discuss-gnuradio Info Page](https://lists.gnu.org/mailman/listinfo/discuss-gnuradio)

-----BEGIN PGP SIGNATURE-----  
Version: GnuPG v1  
Comment: Using GnuPG with Thunderbird - [http://www.enigmail.net/](http://www.enigmail.net/)

iQEcBAEBAgAGBQJTKxeHAAoJEBQ6EdjyzlHtYBgIALINVGpZDTQ962aMmNQfCiNm  
hePnKufnAgC6qL2PWgbnh6CaoIAgx2PF6O4RQlE+fO/qepves6KR5RG5zu5AnIqJ  
QEmBWlkxXn8GawBi27XDKc5X3hECUZzNVDrvXixePolYh/sCgQZdyYksWLEQ10fV  
nVCSvXVtXyEtNZqeabNGwk0xcaeiV85POuHm2j6QWOOGKjvUUCE3za33e0id7ras  
9ykXyph1Nd/3r1Hoj+su9GiKKaWYwRLU/TJGdSpxhiUPk+XxHJEg1BkUyDX1MCFk  
KRaxadKjtJ5kFP/MhZXTqjY4trsS2aMviiwwNKVgD0iLUocOjJyDkTmuly6N8Ks=  
=ma6/  
-----END PGP SIGNATURE-----

---

<div class="post-metadata">

**Author:** ![yetanothergeek](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/y/8e8cbc/32.png) [@yetanothergeek](https://www.ruby-forum.com/u/yetanothergeek)\
**Post date:** [March 20, 2014, 5:04pm UTC](https://www.ruby-forum.com/t/uhd-fft-missing/239836/10 "2014-03-20T17:04:40Z")

</div>

I imagine this is doable, but between experimenting and Google I have  
not been able to find a solution. The application is fairly simple- a  
FCD is connected to a QT GUI Sink. The FCD is tuned to the pilot  
frequency of a ATSC television channel. The attached image shows the  
resulting spectrum. The application is intended to assist in pointing an  
antenna to receive television broadcasts in a rural area.

What I would like to do is measure the peak and display a number that  
represents its level. I have been able to average the entire signal but  
can’t figure out how to measure the peak. Any advice would be  
appreciated.

Thanks,  
George
