Daily Archives: 1/17/2011

Getting data from APRS-IS using ncat…

I wanted to log a bunch of APRS-IS traffic for analysis, but didn’t really want to write any code (my brain hurts today), so I tried to figure out what the magic incantation is. It wasn’t necessary for me to inject any new info into the network, so it’s actually pretty easy.

Type:

ncat -C noam.aprs2.net 14580

This should connect you to a Tier 2 APRS server for North America. If you are in some other part of the world, google for “APRS Tier 2 Servers” and fine one for your local area. 14580 is the port number, and probably will be the same whatever server you choose.

Now, you need to login. Type:

user callsign pass -1 vers ncat 1.0 filter r/lat/lng/dist

Your callsign should be your amateur radio callsign. Specifying a password of -1 means that you are asking for a receive-only feed. The vers keyword introduces the software name and a software version, which is followed by a server command. In this case, we are following it by a “range filter”. If you insert a latitude and longitude, and a range expressed in km, the server will only return the information for sites within range of the specified latitude and longitude. There are other potential commands you can use, but I’ll leave that to another time. For instance, I entered:


user K6HX-15 pass -1 vers ncat 1.0 filter r/38/-122/1500

And then the necessary feed data started to spew:

# javAPRSSrvr 3.15b08
# logresp K6HX-15 unverified, server T2SJC, adjunct "filter r/38/-122/1500" OK - Filter definition updated
KC7FFI>APU25N,KINPRT*,WIDE3-2,qAR,KB7KSU:@170733z4254.31N/11235.35W_218/019g024t045r000p012P000b10100h74FWXNWS-POCATELLO {UIV32N}
K5MTS>APK102,WIDE2-2,qAR,W5AOX-10:=3500.04N/10620.91W_234/010g   t034r000p000P   h64b10182KDvs
WB6YTE>APU25N,WIDE1-1,qAR,KD6DCN-5:=3238.05N/11702.01W-Monitoring all local repeaters {UIV32N}
k2lca-14>APRS,TCPIP*,qAC,THIRD:@170737z3736.00N/12206.00W_340/013g020t023r000P000h64b10198
VA7MXA>BEACON,qAS,VA7TWM:>146.960T100 CAMPBELL RIVER VOICE REPEATER
SLIDE>APNU19,qAR,KB7PUX:!3918.76NS11953.03W#PHG7831/W3,NVn, WA6TLW, Slide Mtn., NV A=009700
K9AZZ-10>APS227,BRNSVL*,WIDE2-1,qAR,AB7FS:@170735z4408.72N/12235.25W_234/004g008t054r000P000p000h88b10245
KD6LAY>APW285,WA6YLB-5,WA6TK,WIDE2-2,qAR,W6MIN-15:_01170738c054s000g000t050r000p000P000h90b10174wU2K
KE6JDC>APRS,TCPIP*,qAC,T2TUS:@170737z3347.47N/11806.50W_360/002g...t052r...p...P000h87b10133.DsVP
VE7ZKI-10>APWW05,TCPIP*,qAC,T2VAN:>170737zAPRSISCE/32 Testing Status report
W7KZO-1>APRS,TCPIP*,qAC,MTAPRSNET:@170737z4528.87N/10942.87W_282/031g043t055r000p000P000h29b09997.DsVP
N7OKG>APU25N,TCPIP*,qAS,N7OKG-1:@170737z4805.12N/11725.93W_123/000g000t041r000p014P012h92b10047uLCrs
WA7ZVY-4>APRS,NEWPRT*,LINCON,qAR,W7KKE-6:@073702z4438.50N/12403.36W_214/009g019t052r006p448P047h00b10219.WxDG
KOPEAK>APN382,SOMTN,WIDE2*,qAo,WE7U-3:!4627.66NS12332.96W#PHG5660/W2,WAn,KOPEAK WA7RW
KC7HXC-9>APOTC1,W7PFR-1,WIDE1*,WIDE2-1,qAS,WW7CH:/170737z4725.71N/12206.70Wj263/004/A=000471 12.7V
NI6M-2>APNU3B,WIDE2-1,qAR,K6TJS:!3703.52NS11924.41W#PHG5360 Mile High, Ca 4690'
KD6RSQ-5>APRS,XE2K-1,KF6ILA-10*,WIDE3-1,qAR,N6EX-3:$ULTW005E00DC026600C027B7FFFC8B0F00010233000F058C00000039
KD6RSQ-5>APRS,XE2K-1,INDIO*,WIDE3-1,qAR,K6JV-11:$ULTW005E00DC026600C027B7FFFC8B0F00010233000F058C00000039  
DIAMON>APN391,BEAR*,WIDE2-1,qAR,CRVLS-1:!4314.44NS12206.59W#PHG5700/W7ZQD OR DIAMOND LAKE APRS
W0LTA>APRS,TCPIP*,qAC,T2BERN:@170737z4007.00N/10456.23W_178/004g006t038r000p000P000h66b10042.DsVP
XE2K-1>APN391,KF6ILA-10,WIDE2*,qAR,N6EX-3:!3238.88N/11530.04W#PHG73604/Mexicali B.C Digi @ XE2K's Station DM22fp www.xe2k.net
W8GWP-7>SV2PXP,WA6YLB-5*,WIDE2-1,qAR,K6MAR-10:`/CDl!>/`"4d}_#

And so on. The format of the individual lines is beyond the scope of this informational post, and is left as an exercise for those who like to read software specifications.

Addendum: Playing with this basic idea, I decided to limit output to just those stations reporting their symbol code as a balloon (APRS primary symbol “O”). I found out that station DL2FX-11 was reporting its position, with its status of “in der Luft” which even in my primitive knowledge of German I know to translate as “in the air”. So, I surfed over to aprs.fi to find out if the station was in fact a balloon, and it was. Apparently it was on its way down too, after reaching a height of 112K feet. Very neat.

Here’s the aprs.fi screen grab: