GithubHelp home page GithubHelp logo

balena-io-experimental / sdr-spectrum-monitor Goto Github PK

View Code? Open in Web Editor NEW
22.0 5.0 13.0 46 KB

Running OpenWebRX on balena to monitor radio spectrum and stream audio.

Shell 8.11% Python 51.20% C 5.98% C++ 5.12% Makefile 29.59%

sdr-spectrum-monitor's Introduction

Run OpenWebRX on balena to remotely monitor local radio spectrum

Combine a Raspberry Pi and an inexpensive SDR (Software-Defined Radio) dongle to create a remote monitoring device that you can place anywhere in the world (with internet access) to view the surrounding radio spectrum and stream audio from some of the detected signals. See the full project tutorial on our blog!

To learn more about OpenWebRX visit the project site or check out their GitHub repository.

Hardware requirements

You’ll need the following hardware:

  • A Raspberry Pi, preferably a 3B+ or 4, but nothing less than a Raspberry Pi 2.
  • A 16GB microSD card or larger (We recommend using SanDisk Extreme Pro for best results)
  • An RTL-SDR based USB dongle. Good results have been obtained using the RTL-SDR.COM V3 but any dongle based on this chip will do. They range from $15 - $30 (beware of potentially poor performance from very cheap dongles!)
  • An antenna suitable for picking up signals in the frequency range you want to monitor with the appropriate connector for your SDR dongle. (Some of the dongle kits linked above include an antenna that reasonably covers many frequencies.)

Setting up

  • Log into your balenaCloud account and create a new application from the dashboard.
  • Add a device and download the balenaOS disk image from the dashboard. You can enter your WiFi details at this point if you wish so that your device can connect to the internet once it boots up.
  • Flash your SD card (we recommend using balenaEtcher) with the balenaOS image, insert it into your Raspberry Pi and power it up. After a minute or so, it should connect to the internet and show up on your balenaCloud dashboard.

Once the device is connected and showing on the dashboard, you can deploy the project code in this repository.

  • Download or clone this project to your local computer
  • Use the balenaCLI to push the application to your device

To access your spectrum monitor on your local network, enter the IP address (found on your device dashboard) followed by :8073 (the default port number.) If everything is running correctly you should see a waterfall display and a play button. Click on the play button to start monitoring the default spectrum centered at 144.25 MHz. (You can change the port and the center frequency using environment variables in the balenaCloud dashboard as described below.)

  • ORX_WEB_PORT - port for Openwebrx (defaults to 8073. If you set to 80, it will use a secure websocket and you should enable the balena public URL feature, granting access to anyone who you provide with the URL.)
  • ORX_SAMP_RATE - sampling rate (defaults to 2400000 which works well for RTL-SDR)
  • ORX_CENTER_FREQ - Center frequency (defaults to 144250000 which is 144.25MHz)
  • ORX_MAX_CLIENTS - Maximum number of clients that can connect at once (default is 20)
  • ORX_NAME - Name to display on your spectrum page
  • ORX_LOCATION - Location to display on your spectrum page
  • ORX_SDRHU_KEY - If you have registered on sdr.hu and have a key, you can set it here and your receiver will be shared.

The waterfall display shows any detected signals in a highlighted color. Click on a signal to listen to the audio, if available. You may need to try switching the type of demodulation (such as AM, FM, etc…) using the buttons on the lower right of the display to hear proper audio.

The RTL-SDR has a bandwidth of 2.4 MHz so that is the maximum amount of spectrum you can view at one time. You can set a “center frequency” which will be the mid point of the display with 1.2 MHz of spectrum viewable on either side. To change the center frequency, add or modify the device variable named ORX_CENTER_FREQ with a numeric value in Hz containing no commas or decimals. For instance, if you want a center frequency at 121.45 MHz you would enter 121450000 for the value.

sdr-spectrum-monitor's People

Contributors

alanb128 avatar chrisys avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

sdr-spectrum-monitor's Issues

mySDR

doesn't start because of "illegal instructions (core dumped)"

using a raspberry pi zero w

Dont work anymore

I've tried to install this project via balena.io cloud. But i always get an error when it's try to start at the device (Raspberry Pi 3B)

24.11.20 14:57:21 (+0100) main install.sh: Changing wss:// to ws://
24.11.20 14:57:21 (+0100) main sed: can't read openwebrx.py: No such file or directory
24.11.20 14:57:21 (+0100) main /usr/src/app/entry.sh: line 14: cd: htdocs: No such file or directory
24.11.20 14:57:21 (+0100) main sed: can't read openwebrx.js: No such file or directory
24.11.20 14:57:21 (+0100) main python: can't open file 'openwebrx.py': [Errno 2] No such file or directory
24.11.20 14:58:24 (+0100) main install.sh: Changing wss:// to ws://
24.11.20 14:58:24 (+0100) main sed: can't read openwebrx.py: No such file or directory
24.11.20 14:58:24 (+0100) main /usr/src/app/entry.sh: line 14: cd: htdocs: No such file or directory
24.11.20 14:58:24 (+0100) main sed: can't read openwebrx.js: No such file or directory
24.11.20 14:58:24 (+0100) main python: can't open file 'openwebrx.py': [Errno 2] No such file or directory
24.11.20 14:58:26 (+0100) Service exited 'main sha256:e972fe93c5909d40996a459fe6034a4de4eec91ceefa450fc6a47d3bda77c23a'

Build fails

Hi, I have followed all the instructions and the build fails with:

[Info] Starting build for RTL-SDR, user g_franz_sch_ning
[Info] Dashboard link: https://dashboard.balena-cloud.com/apps/1576877/devices
[Info] Building on arm01
[Info] Pulling previous images for caching purposes...
[Success] Successfully pulled cache images
[main] Step 1/15 : FROM balenalib/raspberry-pi2-python:2-build
[main] ---> fa02420d4e0a
[main] Step 2/15 : RUN apt-get update
[main] Using cache
[main] ---> 940a2b7cdc8e
[main] Step 3/15 : RUN apt-get -y install libfftw3-dev cmake libusb-1.0-0-dev
[main] Using cache
[main] ---> 68798bbbf3e5
[main] Step 4/15 : RUN apt install netcat
[main] Using cache
[main] ---> 64823f6da7da
[main] Step 5/15 : RUN mkdir -p /tmp
[main] Using cache
[main] ---> 69c260cd5eb7
[main] Step 6/15 : COPY fft_fftw.c /tmp/fft_fftw.c
[main] Using cache
[main] ---> 41c513730b49
[main] Step 7/15 : COPY fft_fftw.h /tmp/fft_fftw.h
[main] Using cache
[main] ---> 6f6ecc8aaad3
[main] Step 8/15 : COPY Makefile /tmp/Makefile
[main] Using cache
[main] ---> 86f0cdde9b1f
[main] Step 9/15 : COPY install.sh /usr/src/app/install.sh
[main] Using cache
[main] ---> 270d3ad7df35
[main] Step 10/15 : RUN ["chmod", "+x", "/usr/src/app/install.sh"]
[main] Using cache
[main] ---> 6d44b24a987a
[main] Step 11/15 : RUN ["/usr/src/app/install.sh"]
[main] ---> Running in 1091d640d3d6
[main] standard_init_linux.go:207: exec user process caused "no such file or directory"
[main]
[main] Removing intermediate container 1091d640d3d6
[main] The command '/usr/src/app/install.sh' returned a non-zero code: 1
[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: 1
[Info] Built on arm01
[Error] Not deploying release.
Remote build failed

Additional information may be available by setting a DEBUG=1 environment
variable: "set DEBUG=1" on a Windows command prompt, or "export DEBUG=1"
on Linux or macOS.

If you need help, don't hesitate in contacting our support forums at
https://forums.balena.io

For CLI bug reports or feature requests, have a look at the GitHub issues or
create a new one at: https://github.com/balena-io/balena-cli/issues/

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.