Each day, at 01:00UTC and 11:00UTC a Vaisala RS92-SGP radiosonde is launched from Madrid-Barajas airport. This is a small electronics package tied to a helium balloon that ascends up to between 24 and 28km high before bursting and descending on parachute. It is designed to measure atmospheric parameters on its way up. It includes temperature, pressure and humidity sensors, as well as a GPS receiver. The launch on Wednesdays at 11:00UTC also includes a plug-in ozone sensor (which is a much larger and more expensive package). The data is transmitted at 403MHz using Manchester-encoded 4800bps GMSK and protected using Reed-Solomon. You can find more information about the RS92-SGP model in its technical datasheet and about the launches at Madrid-Barajas and other launches in Spain in the Spanish AIP Section 5.3 (other activities of a dangerous nature). Also, there is somebody who feeds the radiosonde data into the APRS network using SM2APRS, so you can track the launches by following OKER-11 on aprs.fi.
Usually, the Sondemonitor software is used to receive and plot the parameters measured by the radiosonde and track the GPS data. Of course, this program is very nice and complete, but it is shareware, costs 25€ and runs only in Windows. I wanted to try if it is possible to track the GPS data in Linux using free software.
There is German receiver software on Github that supports the RS92-SGP model, as well as several others. The software is very crude and comes without any licence statement. However, it works and I guess it is OK to use it (I could contact the author about the licence). There are some German users posting their experiences on some forum, but I find it hard to track down the useful information there, so I’ve got this up and running by myself.
The program that I will be using is
rs92/rs92gps.c. It can be compiled just by doing
gcc -O2 -lm -o rs92gps rs92gps.c
This programs needs the GPS almanac and ephemeris data, because it seems that the radiosonde doesn’t send the GPS coordinates but rather the GPS time-of-flight data (or something similar), so all GPS calculations have to be done on the receiver. The current SEM almanac can be downloaded from Celestrak. For the ephemeris, look here:
ftp://cddis.gsfc.nasa.gov/gnss/data/daily/YYYY/DDD/YYn/brdcDDD0.YYn.Z (updated) ftp://cddis.gsfc.nasa.gov/gnss/data/daily/YYYY/brdc/brdcDDD0.YYn.Z (final)
As you can see on this youtube video (RS92-SGP starts at 00:50), the program just plots line by line the GPS positions reports, using its own human readable format. My idea is to use a small python script to turn this data into NMEA sentences and feed those to gpsd. Then Viking (or any other GPS mapping software) can be used to track the data on a map.
The python script goes as follows:
To run everything we do:
mkfifo /tmp/gps sudo chmod 666 /tmp/gps sudo gpsd /tmp/gps rec -t wav -r 48000 - | stdbuf -i0 -o0 -e0 ./rs92gps -a almanac.sem.week0886.405504.txt -e brdc2290.16n.Z -i | ./gps.py > /tmp/gps
Here, you should substitute the current almanac an ephemeris files and use the parameter
-i or not depending on your receiver (this parameter inverts the FSK waveform).
Then, in Viking it is as easy as adding a GPS layer, then right-clicking it and selecting “Start Realtime Tracking” to get the GPS data. The commands
gpspipe -r and
gpsmon are useful to check if the receiver is working.
Below, you can see the map for today’s afternoon launch. You can note that there are lines extending out to bogus positions. The reason for this is that although the data is RS-encoded, the receiver software doesn’t do any kind of error checking or correction, so sometimes you’ll get incorrect data. However, the incorrect GPS positions are very easy to spot. The reception of the radiosonde has being done in the worst possible conditions: I’ve being using my fixed 6m and HF antennas, as this was easier to set up for me. The signal received with a 2m/70cm handheld radio just standing out in my garden is much better. Nevertheless, this setup has being enough to test the software, as the signal from the radiosonde is indeed quite strong.
It seems that newer versions of the receiver software already support direct NMEA output to viking, so part of the procedure described here is no longer necessary.
Actually, it’s very similar to your approach. Someone in the german forum mentioned Viking, so I tried it out and wrote a quick perl script to get NMEA data for gpsd.
Now I see you already did the same…
To minimize “bogus positions” I recommend using the –crc option that outputs only frames which have correct GPS CRC.
And if you use rinex-ephemerides, the position will not jump so much. The rinex data is much more accurate, however it is only good for a few hours. Almanac can be used for half a week, but the position can deviate several hundred meters. (Don’t use both rinex and almanac as args.)
By the way, rs92ecc.c does Reed-Solomon error correction, but you need the fec-library of ka9q for that.
Thanks for the info. I did this a while ago, and since then the software has changed much. Back then, Reed-Solomon decoding was not implemented (and not sure about CRC and rinex, but I don’t think they were available either).
I should take a look at the new features of the software and write some instructions which include the new functionality.
Actually, the python script above doesn’t work very well because it will crash when the input doesn’t have the expected format (which happens when rs92gps has problems decoding or something like that). I had to modify the script live during a hunt for an RS92-SGP to prevent it from crashing frequently.
Dear all, I am trying to receive RS92 beacons using rs92gps without success. I am using a Raspi 2 + SDR receiver. What am I doing wrong?. Command line:
rtl_fm -f 403.00M -p 76 -s 48k – | aplay -r 48k -f S16_LE -t wav – | stdbuf -i0 -o0 -e0 ./rs92gps -v –vel -e brdc1070.17n