The GPS Signal can be obtained and used via different ways:
The Webinterface gives you access to the GPS Data. This can be suitable to have a quick look on the current status of a vehicle.
Via Status→GNSS you will see this Overview
Via Interfaces→GNSS you will see this Map
source: http://freenmea.net/docs
NMEA-0183 prefixes (Talker IDs) NMEA protocol can be sent by different equipment. It can be identified by so called Talker Id. Most known one is, of course $GP_ - GPS.
We use version 3.9 of gpsd as a GPS via IP Daemon
We support the following modes:
// get JSON ?WATCH={'enable':true,'json':true} // get NMEA ?WATCH={'enable':true,'json':false} ?WATCH={'enable':true,'nmea':true} ?WATCH={'enable':true}
For more information on the new JSON interface see http://www.catb.org/gpsd/client-howto.html
Linux clients are cgps
, gpsmon
and gpspipe.
You can install them via apt-get install gpsd-clients
To see the NMEA Data you can also use any telnet emulator of your choice: putty
, hyperterminal
etc.
The Command Line Interface can be used via telnet, ssh or serial terminal access.
With the command “cli status gnss” you will seethe current gps data.
To have it in the right format for using inside of scripts (bash, python etc.) you can use the parameter “-s”
Within the SDK you can reach the gps data by requesting the status parameter as in the cli example or you can retrieve the data from the gps over IP daemon to distribute it further.
Cli data can be retrieved as follows:
status=nb_status("gnss"); dump(status);
Result:
struct(15): { .GNSS1_MODULE_TYPE = string[5]: "me909" .GNSS1_MODULE_INFO = string[126]: "Manufacturer: Huawei Technologies Co., Ltd. Model: ME909u-521 Revision: 11.235.07.00.00 IMEI: 860461024127634 +GCAP: +CGSM" .GNSS1_LONGITUDE = string[8]: "8.572821" .GNSS1_HDOP = string[4]: "6.00" .GNNS1_SYSTEM = string[3]: "GPS" .GNSS1_VDOP = string[4]: "0.90" .GNSS1_LATITUDE = string[9]: "50.134294" .GNNS1_LAST_FIX = string[19]: "2016-05-08 03:42:16" .GNSS1_ALTITUDE = string[6]: "146.90" .GNSS1_PDOP = string[4]: "6.00" .GNSS1_SATELLITES_USED = string[1]: "4" .GNSS1_VERTICAL_SPEED = string[5]: "0.000" .GNSS1_SATELLITES_INVIEW = string[2]: "12" .GNSS1_SIGNAL = string[7]: "present" .GNSS1_HORIZONTAL_SPEED = string[5]: "0.000" }
It's possible to poll the postition via SNMP. You will find the entries “gnssLat” latitude and “gnssLon” longitude in the private MIB. Please be aware that the update interval will be 3s.