Application of GPS15L module in MIS system

Application of GPS15L module in MIS system

Global Positioning System (Global PosiTIoning System-GPS) was developed by the US Department of Defense in the 1970s and developed on the basis of the Meridian Satellite Navigation System. The GPS system generally includes three parts. The first is the space part, that is, the GPS satellite constellation; the second is the ground control part, that is, the ground monitoring system; the third is the user equipment part, mainly referring to the GPS signal receiver.

The task of the GPS signal receiver is to capture the signals of the satellites under test selected by a certain satellite height cutoff angle, and track these satellites, and then transform, amplify and process the received GPS signals in order to measure the GPS signals from the satellite to the The propagation time of the receiver antenna, then interpret the navigation message sent by the GPS satellite, and finally calculate the three-dimensional position, position, even three-dimensional velocity and time of the station in real time. Because the navigation and positioning signals sent by GPS satellites are an information resource that can be shared by countless users, for the vast number of users in land, sea and space, as long as they have a receiving device that can receive, track, transform and measure GPS signals. That is, the GPS signal receiver can use GPS signals for navigation, positioning and measurement at any time.

1 GPS15L receiver module performance

The power consumption of GARMIN's GPS15L receiver is very small, and the data update rate is once per second. Its excellent performance can not only meet the sensitivity requirements of land navigation, but also meet the dynamic requirements of the aircraft. Both its hardware and software are very easy to use. Very suitable for system integration. The GPS receiver OEM board can save data such as satellite orbit parameters, last position, time and date in static memory. The GPS15L receiver has a backup battery to power the memory.

The technical indicators of GPS15L include physical indicators, electrical indicators, GPS indicators, interfaces, environmental characteristics, product configuration, etc.

(1) Physical indicators

◇ Size: 35.56mm × 45.85mm × 8.31mm;

â—‡ Weight: 14 grams.

(2) Electrical indicators

◇ Input voltage (DC): 3.3 ~ 5.4 V;

â—‡ Input current: peak value 100 mA, nominal value 85 mA;

◇ Backup battery charging voltage (DC): 2.8 ~ 3.4 V;

â—‡ Receiver sensitivity: The minimum can reach -165 dBW.

(3) GPS index

â—‡ Receiver channel: 12;

â—‡ Positioning time: Reacquisition time is less than 2 seconds, hot start is about 15 seconds (all data is known). Cold start is about 45 seconds (initial position, time and almanac are known, ephemeris is unknown), automatic positioning time is 5 minutes (almanac is known, initial position and time are unknown), search the sky (all data is unknown);

â—‡ Update rate: 1 second;

◇ Accuracy: positioning accuracy is less than 15 meters (95%), speed accuracy is 0.05 meters / second RMS (steady state), differential accuracy is less than 5 meters (95%), PPS accuracy is ± 1 microsecond;

â—‡ Dynamic performance: the upper limit of speed is 1850 kg / h, the upper limit of acceleration is 6 g, and the upper limit of height is 18000 m.

(4) Interface

â—‡ Interface characteristics: RS-232 output, the input can be RS-232 or TTL level with RS-232 polarity. Optional baud rates are 300, 600, 1200, 2400, 4800, 9600, 19200, 38400;

â—‡ Serial port 1 interface protocol: output NMEA0183 version 2.00 ASCII code sentences, including GPALM, GPGGA, GPGLL, GPGSA, GPGSV, GPRMC, GPVTG (NMEA standard sentences); PGRMB, PGRME, PGRMF, PGRMM, PGRMT, PGRMV (defined by GARMIN Statement). The serial port 1 can also be set to output binary data including GPS carrier phase data. Enter the initial position, time, second pulse status, differential mode, NMEA output interval and other setting information;

â—‡ Serial port 2 interface protocol: input artificial correction data (RTCM SC-104 information type 1, 2, 3, 7, 9);

◇ Second pulse PPS characteristics: 1Hz, pulse width adjustable, accuracy ± 1 microsecond.

(5) Environmental characteristics

◇ Temperature range: working temperature is -30 ℃ ~ + 80 ℃, storage temperature is -40 ℃ ~ + 90 ℃.

(6) Product configuration

â—‡ Standard configuration: GPS OEM board, cable, GAER-MIN OEM setting software, product manual;

Optional configuration: GPS antenna is G505, BNC interface; 30 cm extension cable, BNC to MCX.

The connection diagram of the serial port 1 of GPS15L and the serial port of PC is shown in Figure 1.


When in use, the serial port 1 of GPS15L and the serial port 2 of S3C2410A can be connected. Since the serial port provided by the ARM main control board is hole-shaped, the GPS15L needs to be connected to the needle-shaped serial port connector. When connecting, the two lines of the data outlet and the data inlet in Figure 1 can be swapped and connected to the needle respectively PIN3 (DATAOUT) and PIN2 (DATAIN) of the serial port connector.

2 Design of GPS data extraction program

2.1 Design of serial communication program

Because the GPS module communicates through the serial port 1 and the serial port 2 of the S3C2410 to communicate, therefore, this article designs the corresponding serial communication program under the Linux system.

In the entire operation process, only three functions are used for communication with the serial port, namely, opening, reading and closing the serial port.

(1) Open the serial port

Under Linux, all hardware devices are regarded as ordinary files. Each device in the system is represented by a special device-related file and stored in the / dev / directory. The serial port file is located under / dev, serial port one is / dev / ttvS0, serial port two is / dev / ttyS1, open the serial port can be operated by using standard file open function, as follows:



(2) Read serial port

Because in the entire communication process, all you need is to read data from the GPS module, so only the serial port reading program is used here, and its code is as follows:



(3) Close the serial port

Closing the serial port is actually closing the file. The code is as follows:

close (m_nFDGPSDevice);

2.2 GPS data extraction

Under normal circumstances, as long as the GPS receiver is in working state, it will continuously transmit the received information to the main control board through the serial port. Each of its NMEA sentences starts with "$" and ends with "\ n". The format of the received GPRMC statement is:



Among them, CR and LF respectively represent the ASCII characters "carriage return" and "line feed", hh represents the bitwise XOR value of all characters between "$" and "*" (excluding these two characters). Its meaning is listed in Table 1.



There may be two situations for the data obtained by reading the serial port. One situation is that each read data will have a complete GPRMC statement, and the other situation is that GPRMC is obtained in two times. After getting the complete sentence. Then determine whether the sentence is a GPRMC sentence (that is, whether the sentence starts with GPRMC). If it is a GPRMC sentence, then start to judge whether each data format is correct, including the UTC time format, positioning validity, and latitude format in Table 1. , Latitude Hemisphere Representation Method, Longitude Format, Longitude Hemisphere Representation Method, UTC Date Format Information, etc. Finally, all characters between "$" and "*" will be bitwise XORed (excluding these two characters) and calculated Checksum to see if it is a hh value (the value after "*").

The process of judging whether a sentence is a GPRMC sentence is shown in Figure 2.



Some of its key functions are as follows:

int Init (); initialization function, used to open the serial port, set the serial port (baud rate, data bit, parity bit), etc .;

void TIck (); function to read serial data;

void Cleanup (); close the serial port function;

void Decode (char * szData); judge GPRMC statement function;

bool VeriLine (char * szBuffer); determine whether the data format in the GPRMC statement is the correct function;

void DecodeLine (char * szBuffer); extract and print useful information in GPRMC statements, including time, latitude and longitude, and date.

The following are some related functions:

bool VeriLine (char * szBuffer); determine whether the data format in the GPRMC statement is the correct function;

bool VeriTImeForm (char * szBuffer2); judge the time format function;
bool VeriLonForm (char * szBuffer2); longitude format function;

bool VeriLatForm (char * szBuffer2); function for judging latitude format;

bool VeriDayForm (char * szBuffer2); judging date format function;

If the sentence is the correct GPRMC sentence, then you can extract the required information. The partial program for extracting time, latitude, longitude, and date information is as follows:

void PrintTIme (char * szBuffer2); print time function, here to convert UTC time to Beijing time;

void PrintLonLat (char * szBuffer2, int n); print latitude and longitude functions;

void PrintDay (char * szBuffer2); print date function, print in year / month / day format.

3 Conclusion

The global positioning system has the characteristics of good performance, high precision and wide application, and is the best navigation positioning system to date. With the continuous improvement of the global positioning system, as well as the continuous improvement of hardware and software, its application fields are constantly expanding. At present, GPS applications have begun to gradually penetrate into people's daily lives. The GPS receiver of GARMIN consumes very little power and the data is updated very quickly. Moreover, its excellent performance can meet the sensitivity requirements of land navigation and the dynamic requirements of the aircraft.


12-24W Solar Street Lights

12-24W Solar Street Lights,12W Solar Street Light,15W Solar Street Light,124W Solar Street Light

Yangzhou Bright Solar Solutions Co., Ltd. , https://www.solarlights.pl