Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases now! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Raspberry Pi for Secret Agents - Second Edition

You're reading from   Raspberry Pi for Secret Agents - Second Edition Turn your Raspberry Pi into your very own secret agent toolbox with this set of exciting projects

Arrow left icon
Product type Paperback
Published in Jan 2015
Publisher
ISBN-13 9781784397906
Length 206 pages
Edition 2nd Edition
Languages
Arrow right icon
Author (1):
Arrow left icon
Stefan Sjogelid Stefan Sjogelid
Author Profile Icon Stefan Sjogelid
Stefan Sjogelid
Arrow right icon
View More author details
Toc

Table of Contents (7) Chapters Close

Preface 1. Getting Up to No Good FREE CHAPTER 2. Audio Antics 3. Webcam and Video Wizardry 4. Wi-Fi Pranks – Exploring Your Network 5. Taking Your Pi Off-road Index

Tracking the Pi's whereabouts using GPS


Go right ahead and connect your GPS gadget to the USB port. Most GPS units appear to Linux as serial ports with device names starting with tty then commonly followed by ACM0 or USB0. Type in the following command and focus on the last line:

pi@raspberrypi ~ $ dmesg -T | grep tty

USB GPS receiver identifying as ttyACM0

The first couple of lines talk about the serial port built into the Pi (ttyAMA0). On the last line, however, a USB device is identified, which is most likely our GPS unit and will be accessible as /dev/ttyACM0. We can confirm that it's a GPS by trying to read from it using the following command, where [XXXX] should be replaced by the name of your device:

pi@raspberrypi ~ $ cat /dev/tty[XXXX]

A GPS conforming to the NMEA standard will start flooding your screen with sentences beginning with a code such as $GPGGA followed by comma-separated data (see http://aprs.gids.nl/nmea/ if you're curious about those messages). Even if your GPS outputs...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at €18.99/month. Cancel anytime