At this point, we have verified that the GPS hardware and the link to the PC are working properly, and are ready to start using RTKLIB to collect the raw GPS data.
Start by downloading RTKLIB from Github. Choose either the main branch (126.96.36.199) which is the stable branch or 2.4.3 which is a beta branch (currently at revision b8).
[Update 8/22/18: Your other choice is my demo5 version of the code which has been optimized for low-cost receivers, especially the u-blox receivers. This is the code I would recommend now. The source code is available here and Windows executables are available here]
Recent check-ins have all been made on the beta branch, but most or all of the recent work appears to be unrelated to Ublox receivers or the kinematic mode normally used for low cost receivers, so the functionality of the code should be nearly identical regardless of which branch you choose. I am using 2.4.3 because I think it may be easier to merge in any future changes. The repository includes all the executables, so there is no need to build any code before running it.
There are actually two sets of executables built from the same codebase, a GUI set, and a CUI set. I am using a combination of the two. For collecting the raw data, and plotting the results, I use the GUI versions (STRSVR and RTKPLOT) for convenience. For converting the raw data to RTCM and processing the data, I use the CUI versions (CONVBIN and RTKPOST). This is for two reasons. First, because making any changes to the GUI versions requires an Embarcadero/Borland VCL compiler to re-build the code and this compiler is not available for free. The CUI versions can be rebuilt with the Microsoft Visual C++ compiler, which is free and one I am also much more familiar with. The second reason I use the CUIs is because I have found it easier to keep track of all the input and output files for each run when using the CUIs. I use simple Matlab wrappers to call the CUIs which save all the configuration, input, and output information to a separate folder. Python wrappers would probably work just as well and it is available for free, but I already have Matlab and again am more familiar with it.
Once RTKLIB is downloaded, and the GPS receiver is connected to your PC via USB, start the STRSVR program (strsvr.exe). It can be found in the rtklib\bin folder. Set the Input Stream to “Serial” and use the “Opt” button to set the port and baudrate to match your GPS receiver. If you’ve been communicating to the receiver with U-center or any other application, make sure you have disconnected them from the com ports to avoid any conflicts.
Next we need to configure the receiver to output the raw GPS signals, pseudorange, carrier phase, doppler, and SNR. For the Neo-M8N receiver this requires us to use the normally undocumented commands TRK-MEAS and TRK-SFRBX. First select the “Cmd” button for the input stream and copy the following commands into the “Commands at startup” window.
!UBX CFG-GNSS 0 32 32 1 0 10 32 0 1
!UBX CFG-GNSS 0 32 32 1 6 8 16 0 1
!UBX CFG-MSG 3 15 0 1 0 1 0 0
!UBX CFG-MSG 3 16 0 1 0 1 0 0
!UBX CFG-MSG 1 32 0 1 0 1 0 0
Make sure the “Commands at startup” box is selected, then click the “Save” button to save. STRSVR will send these commands to the receiver at startup. The third and fourth commands in this list enable the TRK-MEAS and TRK-SFRBX commands to the USB and UART ports. See pages 9-13 of this document for an explanation of exactly what these numbers do. The first and second commands are documented commands to configure how many channels the receiver should allocate to GPS and GLONASS. Details are explained in the M8 Receiver Description under the CFG-GNSS command. We could have configured these with the Ublox eval software in the last post, but I thought it was easier to do it all in one place, and also more consistent with other references.
Next, set Output (1) to “File” and use the “Opt” button to select a file name to save the data to. I use a “.ubx” extension for this raw binary data. Finally, click on “Start” to start collecting receiver data. If everything is working properly, it should look something like this:
In the next post we will use RTKLIB to convert this Ublox proprietary binary data to a more friendly text version.