GlobalSat EM 406 GPS Module

This is the GlobalSat EM-406 GPS module with serial interface.

/media/uploads/simon/gpsproduct.jpg

Hello World!

main.cpp

#include "mbed.h"
#include "GPS.h"

Serial pc(USBTX, USBRX);
GPS gps(p9, p10);

int main() {
    while(1) {
        if(gps.sample()) {
            pc.printf("I'm at %f, %f\n", gps.longitude, gps.latitude);
        } else {
            pc.printf("Oh Dear! No lock :(\n");
        }
    }
}

Library

Reference


Discussion topics

Nothing here yet!

Questions