This document provides a description of the work developed for GNSS-SDR during the Google Summer of Code (GSoC) 2018 program. The main objective of this project is to extend the capabilities of the GNSS-SDR software by providing an implementation of BeiDou B2a signals. Specifically, this project will be focusing on the telemetry decoding, and processing of observables and position, velocity, and time (PVT) components of the receiver, and will be merged with the acquisition and tracking portion of the receiver to provide a fully functional BeiDou B2a receiver.
|Dong Kyeong Lee||Developer|
|Antonio Ramos de Torres||Mentor|
The current GNSS-SDR platform is a software defined receiver that supports GPS, GLONASS, and GALILEO Global Navigation Satellite System (GNSS) signals. It also partially supports BeiDou signals, but this is limited to the BeiDou B1l signal. This project will expand the software receiver to accommodate acquisition and tracking of BeiDou B2a signals that would further expand the receiver's capabilities in facilitating research on multi-constellation and multi-frequency receivers working iwth real signals. In addition, the demodulation of the navigation messages will open the door to innovation in multi-constellation receivers, addressing topics such as integrity, reliability, robustness, enhanced coverage, and high-accuracy positioning. Furthermore, the integration of BeiDou B2a observables into the position, velocity, time (PVT) solutions will allow the achievement of the aforementioned diverse range of applications and components.
To be more specific, this project is the second stage of the GNSS receiver, which comes after the acquistion and tracking of BeiDou B2a satellite signals. This project will be mainly divided into:
- Telemetry Decoding
- Observables Processing
- PVT using RTKlib
In essence, this project will be demodulating the BeiDou B2a CNAV2 navigation message, and integrating the BeiDou B2a observables into the PVT position.
(Note: The acquisition and tracking for BeiDou B2a code was developed at the same time as this project by Sara Hrbek for GNSS-SDR Google Summer of Code 2018 as well. link )
Description of Work
Code developed during the summer will be integrated into GNSS-SDR as a single pull request. For the inspection of the code, the reader is referred to the development branch of the project called b2a_pvt. This branch is still under development until all the tasks in the to do list presented below is completed. The most significant commits in this project are highlighted below:
Below are some of the commits for this project
- 6858e36 First commit of GSoC program
- aba819e Added system parameters for telemetry decoding
- f2ae3fc Added the telemetry decoding unit conversions, and fixed bugs in the telemetry decoder
- 0c7c414 Added RTKlib and PVT parameters
- fcee003 Added CRC checks
- 7d91792 First successful build
- c25a468 Added CRC unit-test
- 6d77a42 Corrected user algorithms
- e64a818 Completed telemetry decoder unit tests
- e151f8c Added Rinex, PVT, RTKLib ephemeris conversion, and commented out bugs so that the system is operational, tests are working, and code builds properly. End of GSoC 2018 Coding.
BeiDou B2a Navigation Data
The reference used to develop the code was based on the BeiDou Navigation Satellite System Signal In Space Interface Control Document - Open Service Signal B2a - v1 The BeiDou B2a signal broadcasts the B-CNAV2 navigation message, so the message will be referred to as B-CNAV2 nav message for the remainder of this page.
Cyclic Redundancy Check (CRC)
For the CRC calculation, we use the PRN, MesType, SOW, and message data. (explained in the next section)
For the computation of the CRC computation, a ready-made code was used from another opensource project Global Positioning System Daemon - GPSD. The codes used were crc24q.c crc24q.h.
B-CNAV2 Navigation Message
The B-CNAV2 navigation message is broadcast on the B2a signal. More specifically, the B-CNAV2 message data are modulated on the B2a data component. The basic frame structure of B-CNAV2 is showned in the figure below. Each fram has a length of 600 symbols, and its symbol rate is 200 symbols per second, so the transmission of one frame lasts for 3 seconds.
The first 24 symbols of each frame is preamble with the value of 0xE24DE8 in hexadecimal (111000100100110111101000 in binary). The MSB is transmitted first.
Each frame before error correction encoding has a length of 288 bits, containing Pseudorandom Noise (PRN), Message Type (MesType), Seconds of Week (SOW), Message Data, and CRC check bits.
The entire message is encoded using a 64-ary LDPC (96,48) encoding for error correction, so the navigation message excluding the preamble has 576 symbols and 288 bits. If we are to ignore the error correction, the first 288 bits correspond to the uncorrected data.
In this project, the error correction was not added to the code, so this will be a future work.
There are a total of 8 Message Types. Message Type 10, 11, 30, 31, 32, 33, 34, and 40.
From looking at the MesType, we can determine which message type the navigation message belongs to.
Their bit locations are as follows
Navigation Message Parameters and Algorithms
The parameters can be broadly grouped into following subsections.
- Ranging Code Number: The identification of the satellites
- Message Types: The identification of which message type the messages belong to
- System Time Parameters: The time of the message
- Issue od Data: Indication of ephemeris or clock correction parameter updates and age
- Clock Correction Parameters: Clock corrections
- Group Delay Differential Parameters: Delay between the signal radiated and the output of the satellite's on-board source
- Ephemeris Parameters: Provides satellite orbit type parameters
- Ionospheric Delay Correction Model Parameters: Corrects the effects of the ionospheric delay for single frequency users
- Midi Almanac Parameters
- Reduced Almanac Parameters
- Earth Orientation Parameters
- BDT-UTC Time Offset Parameters: Relationship between BDT and UTC time
- BDT-GNSS Time Offset Parameters: Relationship between BDT and other GNSS time
- Satellite Integrity Status Flag: Provides integrity flag about data, signal and accuracy
- Signal In Space Accuracy Index: Accuracy of the orbital parameters and clock correction parameters
- Signal In Space Monitoring Accuracy Index: Variance of the estimated error of the signal in space accuracy
These have been assigned to 3 types (ephemeris, almanac, time) and processed for simplifcation.
For further details of these parameters, their conversion factors, and relevant user algorithms, please refer to the BeiDou B2a ICD.
To ensure that all the above parameters are decoded correctly, unit tests were implemented for the navigation data decoding
- CRC Testing
- Parameter Testing: test if data decoding and unit conversions of all parameters are correct In order to carry out these tests, the navigation data was first processed using a MATLAB implemented version of the GNSS-SDR, then tested to check if the processing with the GNSS-DR matches the results.
Running the Unit Tests
In order to run the unit tests, we use the following commands
$ cd gnss-sdr/build
$ cmake ..
$ cd ../install
$ ./run_tests --gtest_filter=*Beidou*
This allows us to run all the unit tests for Beidou.
If we would like to look at the specific tests, we can simply use the following command
$ ./run_tests --gtest_list_tests
Unit Test Results
5 Channels were added to the GNSS-SDR for the RTKLib
- 32: BeiDou B2a
- 33: GPS L1 C/A + BeiDou B2a
- 34: Galileo E1b + BeiDou B2a
- 35: GPS L2C + BeiDou B2a
- 36: GLONASS L1 C/A + BeiDou B2a
The RINEX output format is set as the RINEX v3
Unfortunately, due to the unavailability of BeiDou B2a data where there are more than 3 satellites outputted from the tracking loop, PVT performance of B2a satellites could not be confirmed. On the other hand, the other components were verified with unit tests, and the data decoding portion was successfully verified with actual B2a data.
After merging this code with the BeiDou B2a acquisition and tracking code, resolving remaining bugs, and following the future launch of BeiDou B2a satellites (There should be several more by the end of this year), the full performance of the code implemented in this project will be further analyzed.
- Debug issues with CRC checker (The CRC check has some bugs)
- Debug issues with RINEX printer (The RTCM printer has some bugs)
- Implement additional unit-tests for user algorithms
- Merge code with acquisition/tracking code for BeiDou B2a
- Eventually attain position solutions for assessment of the receiver
This was a fantastic experience to participate in the Google Summer of Code project. I was able to find out about, and contribute to an open source project, and develop a lot of coding skills by receiving a lot of guidance from my mentors. I plan to continue to work on this project even after the GSoC, so that the receiver will be fully functional for the public. Also, I will be interested in participating in more open source projects in the future! It was a great opportunity to both learn and contribute. All this was achieved thanks to my mentors, GNSS-SDR, and GSoC 2018 program. Thank you Google for this project, and an opportunity to develop an insight into the opensource community!
BeiDou Navigation Satellite System Signal In Space Interface Control Document, Open Service Signal B2a (Version 1.0), China Satellite Navigation Office December, 2017