devoxx uk 2015 - decoding the air around you with java and $7 hardware

41
# JavaSDR @ bjschrijver Decoding the air around you with Java and $7 hardware Bert Jan Schrijver @bjschrijver [email protected]

Upload: bert-jan-schrijver

Post on 05-Aug-2015

134 views

Category:

Internet


0 download

TRANSCRIPT

Page 1: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

Decoding the air around you with Java and $7 hardware

Bert Jan Schrijver @bjschrijver [email protected]

Page 2: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

Let’s meet

Bert Jan Schrijver

Page 3: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

Outline• Background • Software Defined Radio • ADS-B • AIS • Decoding ADS-B & AIS • Demo • Q&A

Page 4: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

How it all started…

Page 5: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

Software Defined Radio• Radio communication system • Components implemented in software • Cheap DVB-T with RTL2832U chip ($7) • Hence: RTL-SDR • Details on www.rtl-sdr.com

Page 6: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

Software Defined Radio

Page 7: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

@YourTwitterHandle#JavaSDR @bjschrijver

Demo

Page 8: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

Amateur radio

Page 9: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

Vessel to shore

Page 10: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

POCSAG pager messages

Page 11: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

FLEX pager messages

Page 12: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

So how about Java?

Page 13: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

Java and RTL-SDRRTL_TCP: Provides socket for RTL-SDR device

Page 14: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

ADS-BAutomatic Dependent Surveillance Broadcast

Source: simflight.nl

Page 15: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

Java and ADS-B• Java connects to RTL_TCP socket • But now what? • No open source Java decoders available • No other option than to write own decoder…

…or is there?

Page 16: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

(insert legal notice here)

Page 17: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

How stuff works

Page 18: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

@YourTwitterHandle#JavaSDR @bjschrijver

Demo

Page 19: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

That’s cool, but…• In-house reception is sub-optimal • Always-on service would be nice • Laptop needed for work now and then

Page 20: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

Getting serious

Page 21: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

That’s cool, but…• Raw RTL_TCP stream is huge • Problematic over wifi • Would like to give AIS another try • Want to throw out horrible decompiled code

Page 22: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

Getting serious - v2.

Page 23: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

Getting serious - v2.

Page 24: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

AISAutomatic Identification System

Source: hollandmarinehardware.nl

Page 25: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

Decoding AIS

rtl_fm -g 9999 -f 161975000 -p 10 -s 48k -r 48k | aisdecoder -h 192.168.2.2 -p 1234 -a file -c mono -d -f /dev/stdin

Page 26: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

Decoding AIS

rtl_fm -g 9999 -f 161975000 -p 10 -s 48k -r 48k | aisdecoder -h 192.168.2.2 -p 1234 -a file -c mono -d -f /dev/stdin

Page 27: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

Getting serious - v3.

Page 28: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

@YourTwitterHandle#JavaSDR @bjschrijver

Demo

Page 29: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

We love data• Keep system running for a while • Nicely stocked MongoDB • Now what? • Visualise it!

Page 30: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

Antenna range: planes

Page 31: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

Antenna range: ships

Page 32: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

1 hour of data

Page 33: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

2 hours

Page 34: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

4 hours

Page 35: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

8 hours

Page 36: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

16 hours

Page 37: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

24 hours

Page 38: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

Summar

y

Page 39: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

Summary• Playing with Software Defined Radio can

be loads of fun! • You can get started for just a few bucks • Want details?

https://github.com/bertjan/sdr-java • Live demo on http://sdr.revolution.nl • More SDR info on http://www.rtl-sdr.com

Page 40: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

Q & A

Page 41: Devoxx UK 2015 - Decoding the air around you with java and $7 hardware

#JavaSDR @bjschrijver

Thanks for your time!

Please care about conference quality.