Comments Off

WSPR on a Raspberry PI

I am trying to work through the magical process of getting WSPR installed on a current Raspberry PI OS image. Clearly this is a complex process as I have burned up an entire weekend and not been completely successful. I have found a couple of approaches that get close... but this is not horse-shoes or hand grenades so that is not close enough.

WSPR branch release: 4903

After some testing I came up a semi-refined process. I used that base OS image, configured the basic setting for the RPi & Wifi with no extra packages and then created an image of that config that I could deploy & redeploy on multiple 16gb SD cards to refine my process. I also documented EVERY step as I went so that I had some detailed notes. (My engineer / architect background from my day job might have popped out as I tackled this process)

A couple of key themes came up as I tried different approaches that I saw documented on the internet.

  • The Python PIL package has an issue and it is not clear if PILLOW is the fix or not
  • The F2PY path and version can be an issue especially with F2PY3.2
  • There seems to be some complications between Python 2.7, 3.2, and 3.4
  • There is an issue with python-imaging-tk depending on the install order & versions
  • There is an issue with python3-dev depending on the install order & versions
  • There is an issue with jackd2 related to needing to see the speed of the CPU in a text string

My current steps:

  1. sudo -i  (so that you don't have to run sudo for every command)
  2. apt-get remove python-numpy -y
  3. apt-get install python3-numpy autoconf gfortran libsamplerate0-dev cl-fftw3 libhamlib-utils libportaudio2 python3-dev -y
  4. nano /etc/apt/sources.list
  5. Comment out: deb wheezy main contrib non-free rpi
  6. add:  deb jessie main contrib non-free rpi
  7. Save it
  8. apt-get update
  9. apt-get install python3-pil
  10. apt-get install libjack-jackd2-0
  11. nano /etc/apt/sources.list
  12. Comment out:  deb jessie main contrib non-free rpi
  13. Un-comment: deb wheezy main contrib non-free rpi
  14. apt-get update
  15. apt-get install python-imaging-tk
  16. apt-get install python-pmw
  17. apt-get install portaudio19-dev
  18. apt-get install subversion
  19. svn co
  20. cd wspr
  21. ./
  22. make
  23. sudo make install

To redo to the process you can run:

  1. make clean && make distclean &&  ./ 

  2. make && sudo make install

Using the steps above I am currently stuck in the midst of step 22. The output of that sub-step is shown below:

/usr/bin/f2py3 -c --quiet --fcompiler=gnu95 --f77exec=gfortran --f90exec=gfortran \
--opt="-cpp -fbounds-check -O2" thnix.o   -lfftw3f -lgfortran -lportaudio -lpthread -lsamplerate  libwspr.a -m w wspr1.f90 getfile.f90 paterminate.f90 audiodev.f90
rmbadname1: Replacing "len" with "len_bn".
{'attrspec': ['intent(in)']}
{'attrspec': ['intent(in)']}
    Building module "w"...
        Constructing wrapper function "wspr1"...
        Constructing wrapper function "getfile"...
        Constructing wrapper function "paterminate"...
        Constructing wrapper function "audiodev"...
          inbad,outbad = audiodev(jdevin,jdevout)
    Wrote C/API module "w" to file "/tmp/tmpn9wngzym/src.linux-armv6l-3.4/wmodule.c"
    Fortran 77 wrappers are saved to "/tmp/tmpn9wngzym/src.linux-armv6l-3.4/w-f2pywrappers.f"
cc1: error: unrecognized command line option ‘-fstack-protector-strong’
cc1: error: unrecognized command line option ‘-fstack-protector-strong’
error: Command "arm-linux-gnueabihf-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -g -fstack-protector-strong -Wformat -Werror=format-security -D_FORTIFY_SOURCE=2 -fPIC -I/tmp/tmpn9wngzym/src.linux-armv6l-3.4 -I/usr/lib/python3/dist-packages/numpy/core/include -I/usr/include/python3.4m -c /tmp/tmpn9wngzym/src.linux-armv6l-3.4/fortranobject.c -o /tmp/tmpn9wngzym/tmp/tmpn9wngzym/src.linux-armv6l-3.4/fortranobject.o" failed with exit status 1
Makefile:162: recipe for target 'WsprMod/' failed
make: *** [WsprMod/] Error 1


I have tried a couple of other recipes based upon those links at the top of this post but they all had some pretty complex issues with PIL/Pillow and versioning that I was unable to completely resolve. 

It is a bit disappointing that there is a WSJT package (deb) for the Raspberry PI that seems to work without all of this non-sense but not for WSRP. This level of complexity and time commitment is beyond what many ham radio operators (and builders) really want to invest since it is a software issue.

I would love to get this resolved as I think that it would be fun to use my Raspberry PI as the platform for digital mode operations in my shack. Yes, I have more powerful computers with more full featured operating systems but that is not really what I want. I was thinking of the RPi + FLDigi + WSPR +WSJT tied my Elecraft K2 or something similar in a dedicated position in my shack away from the other operating positions. Digital + QRP (5 watts or less) seems like a good use the RPi.

Hopefully these notes help someone else to get WSPR running on a RPi with a current OS stack. I will keep playing but it is hard to think that I will spend this much time on again anytime soon.

73 de NG0R

Comments Off

Spindle Lock

After quiet a few distractions it is finished....

G0759 Mill with the new Spindle Lock

Ok... there is a back story. When the boys (Jacob, Ben, Joe) and I use the mill it feels like it takes 3 hands to change the R8 collet and accessories sometimes.  There is no "spindle brake" or "spindle lock" on this mill. After a bit of searching it appears that Grizzly and both sell after market spindle locks.

Screen capture from the LittleMachineShop.Com webpage

As much as I love to buy parts from Carl at I do get tired of sending out the money. I figured that since I am man that owns tools (Mill, Lathe, etc) I should be able to make one of these.

I am the proud owner of a 6lbs chunk of 6016 aluminum

I purchased a scrap piece of 6061 aluminum from a metal retailer in the Minneapolis area. It is 2.5"x5"x5" weighing in at 6 pounds.

My first project on the new lathe involves a 6 pound block in a four jaw chuck

Since I don't like to start small my first project in the new lathe is pretty complex. I have not even made chips on this lathe until now.  --As they say "Go Big or Go Home!"

Boring bar making chips

There was 5 gallon bucket full of chips once we the lathe work was complete

Two different ID sizes... pretty good for the first project

Mounted in the 3" vise on the mill

Added the 5" vise temporarily for this project

Using an indexable 1.25" face mill to remove some meat from the part

Ben (14) doing some of the milling

The finished part over being sanded down

That 6 pound block now ways about 1 pound. The total cost of parts for this project was about $18. There is probably 8 hours of labor in this project between setting up new machines and tools in addition to taking pictures and showing Ben how to setup the various operations.

It was a pretty cool project and I am very happy especially given the complexity and the number of operations. It works VERY well.

This mill is a G0759 which is the same as the G0704+DRO or a BF20 or a Super X3.