Introduction: Manual Access of GPS Ublox Neo 6M With Raspberry Pi B+

About: Electronics Component - PCB [Design, Printing, Inserting] - Electronic Programming

Raspberry Pi is a very compatible mini PC for various modules that are quite easy to use. Basically it's almost the same as PC but can be controlled with GPIO from Raspberry Pi. Raspberry Pi is also support with several lines of communication, one of which is the line of communication Serial / UART.

Here is tutorial about how to use Ublox Neo 6M GPS Module with Raspberry Pi with Serial / UART Communication.

Step 1: Materials You Need

You will need:

  • Raspberry Pi Module B+512MB RAM
  • Ublox Neo 6M for Arduino Raspberry
  • PL2303 USB to TTL
  • Female To Female Jumper Cable

Step 2: Using PL2303 (not GPIO)

  • Connect each components as the schematic above.
  • Check serial communication of PL2303 whether it has been detected by Raspberry Pi or not by giving commands on the terminal as follows:

ls /dev/ttyUSB*

the output of the command will provide information in which USB that PL2303 is detected

  • Install GPS Daemon client with commands as follows:
  • Check serial communication of PL2303 whether it has been detected by Raspberry Pi or not by giving commands on the terminal as follows:

sudo apt-get install gpsd gpsd-clients python-gps

  • Do a manual command to run GPSD Daemon Socket with command as follows:

sudo gpsd /dev/ttyUSB0 -F /var/run/gpsd.sock

ttyUSB0 can be changed according to port detected by Raspberry Pi

  • The command to view data from GPS, do the following command:

cgps -s

It will show results from longitude, latitude, zone, time etc. To exit the view, click CTRL + Z / C.

Step 3: Using GPIO Raspberry Pi

  • Connect each components as schematic above.
  • Enable Serial Pin on Start -> Preference -> Raspi Configuration -> Enable Serial Port
  • Edit cmdline.txt to enable serial port with command as follows:

$ sudo nano /boot/cmdline.txt

  • Remove "console = ttyAMA0,115200" then save (CTRL + X) and Y then ENTER.
  • Do a manual start of GPS Daemon with command as follows:

$ sudo killall gpsd

$ sudo gpsd /dev/ttyAMA0 -F /var/run/gpsd.sock

  • To see the gps data do the following command:

cgps -s

Raspberry Pi Contest 2017

Participated in the
Raspberry Pi Contest 2017