Remote Spectrum Monitoring with OpenWebRX, RTL-SDR and the Balena Cloud Service

Thanks to Alan Boris of Balena.io for submitting their new blog post titled "Running OpenWebRX on balena to remotely monitor local radio spectrum". Balena.io is an IoT cloud service that is used for "building, deploying, and managing fleets of connected Linux devices".

In the blog post, they show how it's possible to use a RTL-SDR and Raspberry Pi running OpenWebRX to remotely monitor the radio spectrum over the internet. This of course has been done many times before, however, the novel thing here is the use of the Balena cloud platform which makes installing and managing the Raspberry Pi running OpenWebRX much easier.

Balena has a has a special balenaOS image that is first burned on the Raspberry Pi's SD card. The OS image is pre-generated with your home WiFi details, so upon boot it automatically connects to the internet and can be accessed on the balenaCloud dashboard. At that point you can easily remotely push the pre-made Balena "sdr-spectrum-monitor" docker image to the Pi from the Balena online dashboard. This docker image has OpenWebRX and the RTL-SDR drivers already installed on it. It's then a simple matter of connecting to OpenWebRX via the local IP address as you would normally.

This is quite a nice system as it avoids needing to perform the "fiddly" steps of setting up WiFi, connecting to the Pi, determining the Pi's IP address, and installing the RTL-SDR drivers and OpenWebRX software manually.

Balena also has a very simple way to make the OpenWebRX server accessible from outside your network. The only steps required are to set a port variable in the Balena cloud dashboard, and enable the "public device URL" option. No need to fiddle around with unblocking ports or dynamic DNS services.

Balena.io appears to be free for personal use, allowing you to add and manage up to 10 devices before needing to pay.

RTL-SDR & OpenWebRX Installed and Managed via Balena Cloud.
RTL-SDR & OpenWebRX Installed and Managed via Balena Cloud.
Subscribe
Notify of
guest

6 Comments
Inline Feedbacks
View all comments
Sdoros

Can my RTL-SDR be listed in sdr.hu with balena?
I can see it outside my network using DYNDNS, I believe I have place everything correcy in congiguration. Is something else I shoud run?

Jeff

I would like to have the RTL-SDR dongle work with Direct sampling on Balena Cloud.
The -D switch is not allowed in the build, apparently a keenerd’s fork of RTL-SDR, as it has the -D switch although I’m not clear on how to get this working on Balena Cloud. The VHF/UHF monitoring works well on the cloud, just cannot set direct sampling for the RTL-SDR dongle.

start_rtl_command=”rtl_sdr -D1 -s {samp_rate} -f {center_freq} -p {ppm}

ploink

For a long time I’m searching for a way to share my airspy and controle it remote on my phone. I now use a raspberry in combination with spyserver It works fine but there is not mobile webpage or app that i can use. Really curious if there is a OpenwebRX page that will work (together with this solution)

SGilmour

Spent all night playing with it. I couldn’t get it to work on the 64-bit image (it is marked beta) for the Raspberry pi 3+, but the 32-bit version works fine. I don’t really like the control of openwebrx interface, but that has nothing to do with this project.
For those new to balena (I certainly was), when it says “Use the balenaCLI to push the application to your device”, that just means you cd into the git folder you downloaded in the previous step, then run balena push foobar where foobar is the name of your raspberry pi. If you eventually see a unicorn, things are good. You wait a few minutes for the service to start, and it does.

Martin Ehrenfried

Tried it with a Raspi 4 64bit OS – no luck after running balena push – too many errors to mention.

If anyone does get it to work on a Raspi4 please tell us ‘step by step’ how you did it, and don’t assume we are all Linux Gurus 🙂

Martin Ehrenfried

[main] — Set runtime path of “/usr/local/bin/rtl_biast” to “”
[main] ***** finished building rtl-sdr *****
[main] ***** disabling DVB-T driver *****
[main] rmmod: ERROR: ../libkmod/libkmod.c:514 lookup_builtin_file() could not open builtin file ‘/lib/modules/4.15.0-45-generic/modules.builtin.bin’
[main] rmmod: ERROR: Module dvb_usb_rtl28xxu is not currently loaded
[main]
[main] Cloning into ‘openwebrx’…
[main]
[main] Cloning into ‘csdr’…
[main]
[main] ***** compiling libcsdr *****
[main] NOTE: you may have to manually edit Makefile to optimize for your CPU (especially if you compile on ARM, please edit PARAMS_NEON).
[main] Auto-detected optimization parameters: -mfloat-abi=hard -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mvectorize-with-neon-quad -funsafe-math-optimizations -Wformat=0 -DNEON_OPTS -DCSDR_DISABLE_FFTW_MEASURE
[main] rm -f dumpvect*.vect
[main] gcc -std=gnu99 -O3 -ffast-math -fdump-tree-vect-details -dumpbase dumpvect -mfloat-abi=hard -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mvectorize-with-neon-quad -funsafe-math-optimizations -Wformat=0 -DNEON_OPTS -DCSDR_DISABLE_FFTW_MEASURE fft_fftw.c libcsdr_wrapper.c -g -lm -lrt -lfftw3f -DUSE_FFTW -DLIBCSDR_GPL -DUSE_IMA_ADPCM -Wno-unused-result -fpic -shared -Wl,-soname,libcsdr.so.0.15 -o libcsdr.so.0.15
[main] gcc: error: unrecognized command line option ‘-mfloat-abi=hard’
[main]
[main] gcc: error: unrecognized command line option ‘-mfpu=neon’
[main]
[main] gcc: error: unrecognized command line option ‘-mvectorize-with-neon-quad’
[main]
[main] make: *** [Makefile:57: libcsdr.so] Error 1
[main]
[main] NOTE: you may have to manually edit Makefile to optimize for your CPU (especially if you compile on ARM, please edit PARAMS_NEON).
[main] Auto-detected optimization parameters: -mfloat-abi=hard -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mvectorize-with-neon-quad -funsafe-math-optimizations -Wformat=0 -DNEON_OPTS -DCSDR_DISABLE_FFTW_MEASURE
[main] rm -f dumpvect*.vect
[main] gcc -std=gnu99 -O3 -ffast-math -fdump-tree-vect-details -dumpbase dumpvect -mfloat-abi=hard -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mvectorize-with-neon-quad -funsafe-math-optimizations -Wformat=0 -DNEON_OPTS -DCSDR_DISABLE_FFTW_MEASURE fft_fftw.c libcsdr_wrapper.c -g -lm -lrt -lfftw3f -DUSE_FFTW -DLIBCSDR_GPL -DUSE_IMA_ADPCM -Wno-unused-result -fpic -shared -Wl,-soname,libcsdr.so.0.15 -o libcsdr.so.0.15
[main] gcc: error: unrecognized command line option ‘-mfloat-abi=hard’
[main]
[main] gcc: error: unrecognized command line option ‘-mfpu=neon’
[main]
[main] gcc: error: unrecognized command line option ‘-mvectorize-with-neon-quad’
[main]
[main] make: *** [Makefile:57: libcsdr.so] Error 1
[main]
[main] Removing intermediate container c00cf4fee22a
[main] The command ‘/usr/src/app/install.sh’ returned a non-zero code: 2
[Info] Uploading images
[Success] Successfully uploaded images
[Error] Some services failed to build:
[Error] Service: main
[Error] Error: The command ‘/usr/src/app/install.sh’ returned a non-zero code: 2
[Info] Built on arm01
[Error] Not deploying release.
Remote build failed