Introduction: Raspberry Pi NOAA Weather Satellite Receiver

A new pile of parts means a new project is in the works.

I’m building a Raspberry Pi based NOAA weather satellite receiver. I’ve got some experience with receiving signals from NOAA satellites, but will be a little different, as all of the work is going to be done automatically on a Raspberry Pi. This will allow me to place the receiver right at the antenna, which is mounted in my attic. With a very short piece of coax, reducing feed-line loss.

I’ll be using the following list of parts:

  • Raspberry Pi 3 Model B
  • MicroUSB Power Supply
  • Generic Raspberry Pi 3 Case
  • 32 GB Micro SD Card
  • NooElec SDR Dongle
  • QFH Antenna

This project will require some basic Linux skills. If you are not comfortable navigating around the Linux command line, you may need to get some help if you want to follow along.

This instructable is going to focus on getting the Raspberry Pi working to receive images. Details around building a proper antenna can be found from other sources. I even made a video about it:

Step 1: Prepare the Raspberry Pi

The first step is getting the Raspberry Pi up and running. I’m using Raspbian (Jessie 2016-11-25).

There are plenty of tutorials on getting Raspbian set up and booting on the Raspberry Pi. You should have no difficulty in finding one:

Once you have the Raspbian image copied to your micro SD card, boot the Raspberry Pi. You'll need to get it on the network and enable SSH. You can certainly use either a wired Ethernet connection, or wireless. I'm using wireless, as I don't have a wired connection in my attic.

Enable SSH using the Raspberry Pi Configuration utility in the Preferences menu. You may want to set it to boot to CLI while you are in there. Since this is going to be a headless setup, there is no need to waste resources on a GUI.

Next we want to make sure the Raspberry Pi is fully up-to-date. Issue the following commands:

sudo apt-get update
sudo apt-get upgrade
sudo reboot

Step 2: Install the Necessary Software

The first thing we need is the USB drivers for the RTL dongle:

sudo apt-get install libusb-1.0

Since we need to build the latest version of rtl-sdr to actually make use of the RTL dongle, we'll need to install cmake:

sudo apt-get install cmake

We need to make sure the Raspberry Pi doesn't load any SDR kernel modules that will interfere with the rtl-sdr sofware.

Using your favorite text editor, create a new file named /etc/modprobe.d/no-rtl.conf and put the following text in the file. You need to run that text editor as sudo (i.e. 'sudo vi' or 'sudo nano' etc) to write to the modprobe.d directory:

blacklist dvb_usb_rtl28xxu
blacklist rtl2832
blacklist rtl2830

Install the most recent build of rtl-sdr:

cd ~
git clone
cd rtl-sdr/
mkdir build
cd build
sudo make install
sudo ldconfig
cd ~
sudo cp ./rtl-sdr/rtl-sdr.rules /etc/udev/rules.d/
sudo reboot

We'll need the sox audio toolkit in order to manipulate the received audio stream:

sudo apt-get install sox

We need a way to schedule the captures to happen as the satellites pass overhead. Install the at scheduler:

sudo apt-get install at

We need a way to know when the satellites will pass overhead. We'll use an application called predict:

sudo apt-get install predict

Finally, we'll need wxtoimg to convert the captured audio stream to an actual image:

cd ~
sudo dpkg -i wxtoimg-armhf-2.11.2-beta.deb

Step 3: Testing Things Out

Once all the software is installed, make sure your USB dongle is connected and run the following command:

sudo rtl_test

You should see the following output:

Found 1 device(s):
  0:  Realtek, RTL2838UHIDIR, SN: 00000001

Using device 0: Generic RTL2832U OEM
Found Rafael Micro R820T tuner
Supported gain values (29): 0.0 0.9 1.4 2.7 3.7 7.7 8.7 12.5 14.4 15.7 16.6 19.7 20.7 22.9 25.4 28.0 29.7 32.8 33.8 36.4 37.2 38.6 40.2 42.1 43.4 43.9 44.5 48.0 49.6 
Sampling at 2048000 S/s.

Info: This tool will continuously read from the device, and report if
samples get lost. If you observe no further output, everything is fine.

Reading samples in async mode...

If you receive any error messages, you'll need to troubleshoot them before continuing. If your RTL Dongle isn't working at this point, it won't do any good to continue.

You need to run predict one time to set your ground station location. To do that you'll need your latitude and longitude. You can get your latitude and longitude from google maps by searching for your address, the right clicking on the pointer and selecting "What's Here". One thing to note is that Google displays North as positive and East as positive numbers. Predict uses North as positive but WEST as positive. Make sure to adjust accordingly, or your predictions will be no good.

Run predict from the command line, and select option 'G'. Enter your ground station information and exit the program.:

                           --== PREDICT  v2.2.3 ==--         
                     Released by John A. Magliacane, KD2BD   
                                    May 2006                 

                            --==[ Main Menu ]==--

 [P]: Predict Satellite Passes          [I]: Program Information
 [V]: Predict Visible Passes            [G]: Edit Ground Station Information
 [S]: Solar Illumination Predictions    [D]: Display Satellite Orbital Data
 [L]: Lunar Predictions                 [U]: Update Sat Elements From File
 [O]: Solar Predictions                 [E]: Manually Edit Orbital Elements
 [T]: Single Satellite Tracking Mode    [B]: Edit Transponder Database
 [M]: Multi-Satellite Tracking Mode     [Q]: Exit PREDICT

                 *  Ground Station Location Editing Utility  *

                        Station Callsign  : W1AW
                        Station Latitude  : 41.7169 [DegN]
                        Station Longitude : 72.7271 [DegW]
                        Station Altitude  : 25 [m]

            Enter the callsign or identifier of your ground station

You need to run wxtoimg once to accept the terms and conditions.


You need to tell wxtoimg where your base station is at, so it can properly generate an overlay map. You do so by creating a file in your home directory named ~/.wxtoimgrc. In this file, North is positive, as with predict, however EAST is positive, which is the opposite of what predict uses. Make sure to adjust your values appropriately.

Using your favorite text editor, create a new file named ~/.wxtoimgrc and put the following text in the file, substituting your values:

Latitude: 41.7169
Longitude: -72.7271
Altitude: 25

Step 4: The Scripts

Now that you've got a working RTL dongle on your Raspberry Pi, it's time to actually make it receive some weather maps. Make sure your antenna is connected and located as best as possible. I've got mine mounted in my attic and it works fairly well from there. If you can mount it outside, that would be even better. Get it as high as possible.

We are going to need to create a few scripts to automate everything. This is where that Linux familiarity is going to come in.

First we'll create a couple directories to hold our files:

cd ~
mkdir weather
cd weather
mkdir predict
cd predict

Next we'll make the two scripts that kick off the scheduling. The first is ''. This script will be called nightly at midnight. It downloads satellite pass information from celestrak and creates a TLE file for predict to use. Then it removes all AT jobs from the system, so no passes get double scheduled. Finally, it calls the second script '' for each satellite we are interested in.

Using your favorite text editor, create a new file in ~/weather/predict named and put the following code in the file:


# Update Satellite Information

wget -qr -O /home/pi/weather/predict/weather.txt
grep "NOAA 15" /home/pi/weather/predict/weather.txt -A 2 > /home/pi/weather/predict/weather.tle
grep "NOAA 18" /home/pi/weather/predict/weather.txt -A 2 >> /home/pi/weather/predict/weather.tle
grep "NOAA 19" /home/pi/weather/predict/weather.txt -A 2 >> /home/pi/weather/predict/weather.tle
grep "METEOR-M 2" /home/pi/weather/predict/weather.txt -A 2 >> /home/pi/weather/predict/weather.tle

#Remove all AT jobs

for i in `atq | awk '{print $1}'`;do atrm $i;done

#Schedule Satellite Passes:

/home/pi/weather/predict/ "NOAA 19" 137.1000
/home/pi/weather/predict/ "NOAA 18" 137.9125
/home/pi/weather/predict/ "NOAA 15" 137.6200

The second script, '', recurses through each pass of the given satellite for the current day. It determines if the maximum elevation is 20 degrees or greater. If it is, then it calculates the length of the pass, and schedules the recording and processing of the pass. If the maximum elevation is less than 20 degrees, the pass is ignored, as it generally won't produce a decent image.

Using your favorite text editor, create a new file in ~/weather/predict named and put the following code in the file:

PREDICTION_START=`/usr/bin/predict -t /home/pi/weather/predict/weather.tle -p "${1}" | head -1`
PREDICTION_END=`/usr/bin/predict -t /home/pi/weather/predict/weather.tle -p "${1}" | tail -1`

var2=`echo $PREDICTION_END | cut -d " " -f 1`

MAXELEV=`/usr/bin/predict -t /home/pi/weather/predict/weather.tle -p "${1}" | awk -v max=0 '{if($5>max){max=$5}}END{print max}'`

while [ `date --date="TZ=\"UTC\" @${var2}" +%D` == `date +%D` ]; do

START_TIME=`echo $PREDICTION_START | cut -d " " -f 3-4`
var1=`echo $PREDICTION_START | cut -d " " -f 1`

var3=`echo $START_TIME | cut -d " " -f 2 | cut -d ":" -f 3`

TIMER=`expr $var2 - $var1 + $var3`

OUTDATE=`date --date="TZ=\"UTC\" $START_TIME" +%Y%m%d-%H%M%S`

if [ $MAXELEV -gt 19 ]
    echo ${1//" "}${OUTDATE} $MAXELEV

    echo "/home/pi/weather/predict/ \"${1}\" $2 /home/pi/weather/${1//" "}${OUTDATE} /home/pi/weather/predict/weather.tle $var1 $TIMER" | at `date --date="TZ=\"UTC\" $START_TIME" +"%H:%M %D"`


nextpredict=`expr $var2 + 60`

PREDICTION_START=`/usr/bin/predict -t /home/pi/weather/predict/weather.tle -p "${1}" $nextpredict | head -1`
PREDICTION_END=`/usr/bin/predict -t /home/pi/weather/predict/weather.tle -p "${1}"  $nextpredict | tail -1`

MAXELEV=`/usr/bin/predict -t /home/pi/weather/predict/weather.tle -p "${1}" $nextpredict | awk -v max=0 '{if($5>max){max=$5}}END{print max}'`

var2=`echo $PREDICTION_END | cut -d " " -f 1`


When the time comes for a give pass to be recorded and processed, at kicks off the final script ''. When this script is called, it uses rtl_fm to receive the audio from the satellite pass, and sends that audio to sox for processing. Sox saves the audio to a file. Once the pass is complete, wxmap is called to generate an overlay map for the image. Finally, wxtoimg is called to generate the actual image and place the overlay map on it.

Using your favorite text editor, create a new file in ~/weather/predict named and put the following code in the file:


# $1 = Satellite Name
# $2 = Frequency
# $3 = FileName base
# $4 = TLE File
# $5 = EPOC start time
# $6 = Time to capture

sudo timeout $6 rtl_fm -f ${2}M -s 60k -g 45 -p 55 -E wav -E deemp -F 9 - | sox -t wav - $3.wav rate 11025

PassStart=`expr $5 + 90`

if [ -e $3.wav ]
    /usr/local/bin/wxmap -T "${1}" -H $4 -p 0 -l 0 -o $PassStart ${3}-map.png

    /usr/local/bin/wxtoimg -m ${3}-map.png -e ZA $3.wav $3.png

Once all three scripts have been created, we need to make the executable, by issuing the following commands:

chmod +x
chmod +x
chmod +x

Now, the last step in automating the reception is to schedule the first script to run just after midnight. Run the following command:

crontab -e

It will open a text editor of your choice to edit the cron file. Simply add the following line to the bottom of this file and save:

1 0 * * * /home/pi/weather/predict/

Now, at 00:01 the schedule will start. (if you don't want to wait, simply run the following command once to kick the process off:)


Step 5: Check Things Out

To see upcoming satellite passes that are scheduled to be processed, run the following command:


Check the ~/weather directory for your results. Each pass will generate three files:

NOAA1820170105-181147-map.png  <-- Map overlay file
NOAA1820170105-181147.png      <-- The final image file
NOAA1820170105-181147.wav      <-- The raw audio file

The format of the file name is the satellite name, followed by the date (YYYYMMDD) and time (HHMMSS) of the start of the pass. There are several filters that wxtoimg can use when generating the image file. I've had different luck with different satellites and passes on each filter. Feel free to play around with wxtoimg on the original map and audio files and see what you come up with.

One thing to note, the receiver can only receive one satellite at a time. If two satellites are passing overhead at the same time, the first one to start recording will "win" and be recorded. The second recording will error out and stop.

Step 6: Some of My Results


TimA102 (author)2017-08-15

Thanks for the scripts OP! I found that for debugging you'll need to
install sendmail and perhaps alpine. Surprisingly sendmail is not part
of ubuntu server. It's also worth mentioning that the rtl_sdr included
in the repos is not compatible with these scripts.

sa7bnt (author)2017-08-09

Hallo @all,

i´am wondering why there is no map?? He make the map but did not merge it with the pic.

Has someone an idea??


rgabriana (author)2017-08-09

I can't wait to try this out. I just have one observation. I installed and tested all of the software listed in the instructions. And when I ran wxtoimg I received the following error:

wxtoimg: error while loading shared libraries: cannot open shared object file: No such file or directory

I installed the libxft2 package:

sudo apt-get install libxft2

and that fixed my problem

my setup is the following:

hardware=Raspberry PI 3



TorbjörnS1 made it! (author)2017-08-08


Great automated script!

Im somewhat frustrated here :/ Cannot get sox to work...

When the predicted pass is coming it runs rtl_fm and sox but sox fails...


sox FAIL formats: can't open input `-': WAVE: RIFF header not found


All help much appreciated!

TorbjörnS1 made it! (author)TorbjörnS12017-08-08

Aha, noted that it is rtl_fm that causes this problem. I did not use the keenerd fork of rtl-sdr but rather the "original". It seemse to lack support from RIFF / Wave(?) ..

Reinstalled my pi from scratch and got things going!

My Discone antenna (the roof installed attenuation ;) ) is doing a very poor job with circular polarized signals. Will build myself a better antenna!

Again, thanks for all the scripts! <3

hihelppls (author)2017-08-04

I got this error when I ran

pi@raspberrypi ~/weather/predict $ /home/pi/weather/predict/

date: invalid date ‘TZ="UTC" @’

/home/pi/weather/predict/ line 10: [: ==: unary operator expected

date: invalid date ‘TZ="UTC" @’

/home/pi/weather/predict/ line 10: [: ==: unary operator expected

date: invalid date ‘TZ="UTC" @’

/home/pi/weather/predict/ line 10: [: ==: unary operator expected

do you have any suggestions?

hihelppls (author)hihelppls2017-08-04

fixed, it was a glitch in wget, i used

curl -o /home/pi/weather/predict/weather.txt

in instead of the wget line

SJG1976 (author)2017-06-29

I'm not able to get an Schedule Recordings showing when i run the atq command.

When running the 1st Script no output is shown at all (unlike the example video where it seems to show an output of the passes)

If i then try and run the 2nd script I get

date: invalid date ‘TZ="UTC" @’

/home/pi/weather/predict/ line 10: [: ==: unary operator expected

Not sure where I've gone wrong?

Any pointers please the line in question reads as

while [ `date --date="TZ=\"UTC\" @${var2}" +%D` == `date +%D` ]; do


sleepy04 (author)SJG19762017-07-13

That script should be run in the full form like this one

/home/pi/weather/predict/ "NOAA 19" 137.1000

SJG1976 (author)sleepy042017-07-13

I've just left it to do it's thing, and it all appears to be working now.

Just need to get a better Antenna.

SJG1976 (author)2017-06-29

I'm having trouble with the atq command.

After running the command I see no scheduled passes.

How far ahead do these look? Or should it repsond with the next lot of passes?

JenniferL276 (author)2017-05-30

Hello, I have been seeing your work on APT capture. I am trying to receive the signal with a raspberry 3 and I haven't get a good signal yet. I had some problems with rtl_fm command .

I could probe that using a low bandwidth (with -s) and some gain values distort APT signal. It is so weird. Also, if I worked with sox and rtl_fm on the same line, I had problems. Finally, I installed the last version of rtl-sdr (keenerd) and I could use sox and rtl_fm on the same line. I had to update kernel of raspberry too.

This is the line with which I have gotten better results: timeout 900s rtl_fm -f 137.620M -s 40k -g 30 -p 47 -E wav -E deemp -F 9 - | sox -t wav - NOAA15_170530_083246.wav rate 11025.

However, I receive yet a signal with bad signal to noise rate. When I capture a satellite pass with SDR# and my PC on Windows, the results are perfect, so the antenna and connectors are ok. I don't know which is the problem on raspberrypi and rtl_fm of keernerd.

Any idea to try?? I have try a lot of things!

Thank you very much!

MichaelB738 (author)JenniferL2762017-06-15

I had similar challenges the first time I set this up. I was using Rpi2 at the time. I tried a few settings as you have and at one point was successful in adding the -M wbfm setting to the line in the script. At one point, however I started over with a clean image and walked through the setup just as shown in the video. I was able to run the script just as written. I believe the first time I tried this I had made a mistake in a script. My images from the initial setup are in the comments below. Now I'm running this on Rpi3 exactly as the scripts are written. The only change is that I added extra lines to process color images and I wrote in commands to delete map and wav files once processing is complete. Everything works perfectly and I have captured hundreds of images.

Lasse-1 (author)2017-06-04

Hi, I made it but a funny thing is that the ###-map.png is upside down..

Any tips ?

dunky77 (author)Lasse-12017-06-08


Are you sure about your location parameters you typed in predict tool ? step 3 above "Ground Station Location Editing Utility"

LiborL1 made it! (author)2017-04-30


Good work thanks!

dunky77 (author)LiborL12017-06-01


How did you do to get this false color images?



LiborL1 (author)dunky772017-06-01


change in

/usr/local/bin/wxtoimg -m ${3}-map.png -e ZA $3.wav $3.png


/usr/local/bin/wxtoimg -m ${3}-map.png -e NO $3.wav ${3}.NO.png
/usr/local/bin/wxtoimg -m ${3}-map.png -e MCIR $3.wav ${3}.MCIR.png
/usr/local/bin/wxtoimg -m ${3}-map.png -e MSA $3.wav ${3}.MSA.png

dunky77 (author)LiborL12017-06-01

Awesome, thank you LiborL1 (results below)

dunky77 made it! (author)2017-06-01

Thank you for this great tutorial. In attachment, my result.

Is it possible to get false colors instead of black and white images ?


LiborL1 (author)2017-02-24

Hello you can use RPI2? Thanks

dunky77 (author)LiborL12017-05-31

Yes, it also works with RPI2, without any change in the tutorial.

MichaelB738 made it! (author)2017-04-17

My son and I built the QFH antenna and then followed this process to get the rPi up and running. I did have to make a few tweaks to the way the audio was being captured. I assume this was due to the fact that my SDR was different. We used an rPi model 2 and once it was up and running we did not notice any issues. I'm working on moving this over to the latest model to see if there is any difference. I believe most of the challenge is just getting a solid audio signal during the pass. Thanks for posting this as it was a great home school science project for my son and I to work through together.

AlainV10 (author)2017-04-13

Hello ,

Work fine now , just a correct antenna to place .

have you an idee how to upload the images to a webside ?


Best regards.

haslettj (author)AlainV102017-04-13

It really would depend on what is available on your website you want to copy to. You could use FTP, SFTP, CURL, or something like that to transfer the files. I'm sure there are scripts available on the Internet to integrate to something like Wordpress to generate a post if that's what you are after.

Jimeno made it! (author)2017-04-08


Perfect tutorial. It works at the first attempt.

The antenna and the first map.


Ragards from Spain.

AlainV10 (author)2017-03-30

Hello ,

i try this and where can i found the image that i received , in wicht folder .

Many thanks.


MichaelB738 (author)AlainV102017-03-30

Here is the location to view received files. Check the ~/weather directory for your results. Each pass will generate three files:

NOAA1820170105-181147-map.png  <-- Map overlay file
NOAA1820170105-181147.png <-- The final image file
NOAA1820170105-181147.wav <-- The raw audio file
AlainV10 (author)MichaelB7382017-03-30

ok thanks for answer , i will check this .


tomatos666 (author)2017-02-14

Ok now it Work´s.

I have used the new image. And i have set all from the beginn like the video!


tomatos666 (author)2017-02-13

Screenshot with atq

tomatos666 (author)2017-02-13


thank´s for the great articel!

But i have a problem. I see on "atq" that are some recordings planned. But the are no files? I dont know where the error are... I hobe some one can help me.

dkulkarni (author)2017-02-05

Great to see the detailed & simple article to receive NOAA on Raspberry pi 3.

I am currently not getting the image from it the audio recorded in weather folder is just noise. I can receive pics on my laption but having troble here in Raspberry. Any help appriciated !

About This Instructable




Bio: I'm a ham, a tinker, a maker. I like interesting things. I'm a technophile, a wood turner, and a pen maker.
More by haslettj:Raspberry Pi NOAA Weather Satellite ReceiverAir Choke (Ugly Balun) for Ham RadioDrill Precise Holes for Mounting Electronics Controls and Boards
Add instructable to: