GPS¶
1442 words Estimated reading time 6 minutes
Overview¶
Position data is sent by the GPS module every second over an serial bi-directional connection to the MCU. The MCU itself can send commands to the GPS, but does that only if needed (i.e. during initialization).
graph LR
G[GPS] <-->|Data| CPU
G[GPS] -->|1PPS| CPU
GPSANT([GPS Antenna]) --> G
GPS status¶
The status page of the web interface gives a detailed overview of the GPS status. The picture shows values from a station where where the GPS antenna has been placed inside the building under the roof during a sunny day. The signal strength is not perfect, but okay. In case of a weather change, however, the reception quality may decrease.
GPS chipset¶
Our systems have different chipsets installed. The controller firmware detects them automatically. It also requests the firmware versions of the GPS module. In case of problems firmware versions can be updated.
Satellite reception¶
Note
The count of tracked satellites shouldn’t fall below 6 too often. A value of four is the absolutely minimum! Higher values are always better.
Satellites in view gives the number of satellites, which could be tracked under perfect conditions (i.e. on a airplane). The number of tracked satellites should be close to the number of satellites in view. For example, when you have 15 satellites view and only 4 tracked, then you should search a better place for the antenna.
Please note that those values will change very often, because the GPS satellites are moving fast, weather and condition of the ionosphere can change quickly. You should see similar values every 24 hours, as the satellite constellation will be almost the same.
Using other GNSS¶
Note
Always have in mind, that we use GPS mainly for time synchronization and not for positioning!
In addition to GPS, there are other global navigation satellite systems (GNSS) with their own satellites, which are operated by various countries. At the time when the first Blitzortung.org TOA systems went online around 2008, however, there was only GPS globally available. Every GNSS uses its own time base, but they are synced in some way 1. For absolute timing precision we can only rely on the GPS time base. This is why we generally use the word GPS instead of GNSS. It is also not possible to deactivate GPS in the web interface settings.
That means that every additional satellite from different GNSS will improve position accuracy, but not necessarily the accuracy of the absolute time, as there might be an offset between the time GNSS time bases. In the worst case the GNSS module may decide to use another base when GPS coverage is not available.
Depending on the chipset not all GNSS constellations are supported. For example, the u-blox MAX M8 doesn't support GPS + Galileo + GLONASS, but does support GPS + Galileo + Beidou.
Galileo¶
Galileo is operated by the European Union. The time bases of GPS and Galileo is officially synced 2. If you want to use an additional GNSS besides GPS, Galileo should be your first choice.
Beidou and GLONASS¶
Beidou is the Chinese and GLONASS the Russian navigation satellite system. It's not 100% clear whether they are officially synced with the GPS time base. 3 So far we didn't experience any time offsets when enabling one or both of them.
Baud rate¶
The baud rate for the GPS connection is variable and can be set in the web-interface. However, you should avoid slow baud rates as it can take too long for the GPS to send the whole data before the next 1PPS-pulse. We recommend baud rates of 115200 and higher.
SBAS¶
In the GPS settings you have the option to enable SBAS. This is a service which can improve position accuracy and is provided for different regions of the world (i.e. EGNOS, WAAS). The accuracy will be improved due to additional information about current status of the ionosphere. The needed data is sent by satellites on geostationary positions. To receive their signals, your GPS antenna needs a good view to them. For the northern hemisphere that means there should be no buildings, trees etc. on the south side of the antenna.
On older chipsets SBAS might cause problems or even make time accuracy worse. If you are unsure, leave it disabled.
Position and Precision¶
Note
Using our lightning detector on a mobile vehicle is not supported. It must stay at a fixed position.
While the system is running the position will be smoothed. So you we get a very accurate 3D position.
PDOP stands for position dilution of precision. There are also values for vertical and horizontal position (VDOP, HDOP). The DOPs give the best estimation about the "GPS-quality". The lower the values, the better the position accuracy. Values below 1.0 are almost perfect and those below 3.0 are still far good enough for our purposes. The DOPs give a idea whether the constellation of tracked satellites is good. For example, even if you receive 8 satellites your PDOP could be bigger that 7 (very bad), because the GPS sees only satellites from a part of the sky and cannot calculate a good position.
Timing precision¶
For exact timing the GPS module sends a 1PPS pulse which the CPU compares with its internal 84MHz timer. The accuracy of 84MHz is 11ns. That's why the "current" PPS accuracy often shows 11ns or a multiple.
GPS tools¶
In the web interface under Tools -> GPS several commands can be send to the GPS module. They are mainly for testing and debugging in case the GPS module isn't working as expected. For u-blox modules it is possible to send UBX binary messages when entering strings like ubx06 8a 12 34 45
.
GPS direct connection¶
It is also possible to enable a pass through mode, which enables direct communication between you computer and the GPS module. When enabling the GPS to USB virtual COM passthrough the controller will continue to work. Usage of the serial debug port passthrough will stop normal operation, so you have to push the button first.
Known Problems¶
Solve Gmm-g3 wrong date bug¶
The Gmm-g3 has a bug and reports a wrong date since November 30th 2022 (week rollover bug, see this internal forum thread). The latest firmware ⧉ can detect this bug and will show a warning in the web interface.
Important
An update of the GPS module firmware is highly recommended! When the Gmm-g3 is not updated with the new module firmware, it will stop working after some days or weeks and you have to power cycle the controller to get it working again.
Firmware upgrade
The bug has been fixed in the Gmm-g3 firmware AXN3.8 and upwards. All needed files to upgrade the firmware can be downloaded here (password required):
- STM32 COM Port driver
- GlobalTop Flash Tool
- Firmware file AXN5.1.1_8525_3333_1152.1151100.1.bin
Info
If you experience problems during the upgrade procedure don't hesitate to contact us.
Follow these steps to upgrade the firmware:
- For PCB 19.1 and older: Close the solder bridge J3 on the bottom of the PCB.
- Download and install the STM32 COM Port driver.
- Connect the controller to your computer via USB-cable.
- In the web interface choose Tools -> GPS -> Pass-Through (USB) -> Send.
A new virtual COM port should appear on your computer.
The controller will beep once and it will operate as usual while in this mode (sending signals etc.). However, it can not send anything to the GNSS module and the controller just passively listens to the data from the GNSS module. - Download and extract GlobalTop Flash Tool.
- Start Powerflash.
- Choose the correct COM-Port from "ComPort" -> "COM"
- Click Download Agent and choose MTK_AllInOne_DA_MT3333_MP.BIN
- Click ROM and choose the downloaded firmware AXN5.1.1_8525_3333_1152.1151100.1.bin
- Click Connect (some weird blue bars appear)
- Click Download (this will download the firmware to thg module)
Wait until flashing has been done. It will take around one minute to complete. - Power cycle the controller (remove USB and attach again)
Some notes:
- In case of a problem, the GPS module may need a power cycle. So just try again at 3.
- Sometimes the COM port is not visible in the Powerflash tool. In this case you have to open the COM port with another tool, for example PuTTY. While PuTTY is running, the COM port should appear in the ComPort menu. Before using "Download" close PuTTY.
- You can also try to use the Sierra Wireless GNSSTool which is newer than GlobalTop Flash Tool
Other GlobalTop modules can be flashed the same way with the associated firmware:
A linux tool can be found here ⧉, but it hasn't been tested by us.