Improving documentation

git-svn-id: https://svn.code.sf.net/p/gnss-sdr/code/trunk@102 64b25241-fba3-4117-9849-534c7e92360d
This commit is contained in:
Carles Fernandez 2011-12-28 03:05:37 +00:00
parent 0cee2be18f
commit 48719c3075
48 changed files with 261 additions and 324 deletions

View File

@ -31,17 +31,18 @@
#ifndef GPS_L1_CA_PVT_H_
#define GPS_L1_CA_PVT_H_
#ifndef GNSS_SDR_GPS_L1_CA_PVT_H_
#define GNSS_SDR_GPS_L1_CA_PVT_H_
#include "pvt_interface.h"
#include "gps_l1_ca_pvt_cc.h"
#include <gnuradio/gr_msg_queue.h>
class ConfigurationInterface;
/*!
* \brief This class implements a PVT interface for GPS L1 C/A
*/
class GpsL1CaPvt : public PvtInterface
{

View File

@ -1,6 +1,6 @@
/*!
* \file gps_l1_ca_pvt_cc.cc
* \brief Position Velocity and Time computation for GPS L1 C/A using Least Squares algorithm
* \brief Position Velocity and Time computation for GPS L1 C/A
* \author Javier Arribas, 2011. jarribas(at)cttc.es
* -------------------------------------------------------------------------
*
@ -33,23 +33,17 @@
#include <map>
#include <algorithm>
#include <bitset>
#include <cmath>
#include "math.h"
#include "gps_l1_ca_pvt_cc.h"
#include "control_message_factory.h"
#include <gnuradio/gr_io_signature.h>
#include <glog/log_severity.h>
#include <glog/logging.h>
#include "gps_l1_ca_pvt_cc.h"
#include "control_message_factory.h"
using google::LogMessage;
using namespace std;
gps_l1_ca_pvt_cc_sptr
gps_l1_ca_make_pvt_cc(unsigned int nchannels, gr_msg_queue_sptr queue, bool dump, std::string dump_filename, int averaging_depth, bool flag_averaging) {
@ -91,7 +85,7 @@ gps_l1_ca_pvt_cc::~gps_l1_ca_pvt_cc() {
delete d_ls_pvt;
}
bool pseudoranges_pairCompare_min( pair<int,gnss_pseudorange> a, pair<int,gnss_pseudorange> b)
bool pseudoranges_pairCompare_min( std::pair<int,gnss_pseudorange> a, std::pair<int,gnss_pseudorange> b)
{
return (a.second.pseudorange_m) < (b.second.pseudorange_m);
}
@ -101,8 +95,8 @@ int gps_l1_ca_pvt_cc::general_work (int noutput_items, gr_vector_int &ninput_ite
d_sample_counter++;
map<int,gnss_pseudorange> gnss_pseudoranges_map;
map<int,gnss_pseudorange>::iterator gnss_pseudoranges_iter;
std::map<int,gnss_pseudorange> gnss_pseudoranges_map;
std::map<int,gnss_pseudorange>::iterator gnss_pseudoranges_iter;
gnss_pseudorange **in = (gnss_pseudorange **) &input_items[0]; //Get the input pointer
@ -110,28 +104,28 @@ int gps_l1_ca_pvt_cc::general_work (int noutput_items, gr_vector_int &ninput_ite
{
if (in[i][0].valid==true)
{
gnss_pseudoranges_map.insert(pair<int,gnss_pseudorange>(in[i][0].SV_ID,in[i][0])); //record the valid psudorrange in a map
gnss_pseudoranges_map.insert(std::pair<int,gnss_pseudorange>(in[i][0].SV_ID,in[i][0])); //record the valid pseudorange in a map
}
}
//debug print
cout << setprecision(16);
std::cout << std::setprecision(16);
for(gnss_pseudoranges_iter = gnss_pseudoranges_map.begin();
gnss_pseudoranges_iter != gnss_pseudoranges_map.end();
gnss_pseudoranges_iter++)
{
cout<<"Pseudoranges(SV ID,pseudorange [m]) =("<<gnss_pseudoranges_iter->first<<","<<gnss_pseudoranges_iter->second.pseudorange_m<<")"<<endl;
std::cout<<"Pseudoranges(SV ID,pseudorange [m]) =("<<gnss_pseudoranges_iter->first<<","<<gnss_pseudoranges_iter->second.pseudorange_m<<")"<<std::endl;
}
// ############ 1. READ EPHEMERIS FROM QUEUE ######################
// find the minimum index (nearest satellite, will be the reference)
gnss_pseudoranges_iter=min_element(gnss_pseudoranges_map.begin(),gnss_pseudoranges_map.end(),pseudoranges_pairCompare_min);
gnss_pseudoranges_iter=std::min_element(gnss_pseudoranges_map.begin(),gnss_pseudoranges_map.end(),pseudoranges_pairCompare_min);
gps_navigation_message nav_msg;
while (d_nav_queue->try_pop(nav_msg)==true)
{
cout<<"New ephemeris record has arrived from SAT ID "<<nav_msg.d_satellite_PRN<<endl;
std::cout<<"New ephemeris record has arrived from SAT ID "<<nav_msg.d_satellite_PRN<<std::endl;
d_last_nav_msg=nav_msg;
d_ls_pvt->d_ephemeris[nav_msg.d_channel_ID]=nav_msg;
// **** update pseudoranges clock ****

View File

@ -1,6 +1,6 @@
/*!
* \file gps_l1_ca_pvt_cc.h
* \brief Position Velocity and Time computation for GPS L1 C/A using Least Squares algorithm
* \brief Position Velocity and Time computation for GPS L1 C/A
* \author Javier Arribas, 2011. jarribas(at)cttc.es
* -------------------------------------------------------------------------
*
@ -27,26 +27,20 @@
* -------------------------------------------------------------------------
*/
#ifndef GPS_L1_CA_PVT_CC_H
#define GPS_L1_CA_PVT_CC_H
#ifndef GNSS_SDR_GPS_L1_CA_PVT_CC_H
#define GNSS_SDR_GPS_L1_CA_PVT_CC_H
#include <fstream>
#include <gnuradio/gr_block.h>
#include <gnuradio/gr_msg_queue.h>
#include <queue>
#include <boost/thread/mutex.hpp>
#include <boost/thread/thread.hpp>
#include "concurrent_queue.h"
#include "gps_navigation_message.h"
#include "kml_printer.h"
#include "rinex_2_1_printer.h"
#include "gps_l1_ca_ls_pvt.h"
#include "GPS_L1_CA.h"
class gps_l1_ca_pvt_cc;
@ -54,7 +48,9 @@ typedef boost::shared_ptr<gps_l1_ca_pvt_cc> gps_l1_ca_pvt_cc_sptr;
gps_l1_ca_pvt_cc_sptr
gps_l1_ca_make_pvt_cc(unsigned int n_channels, gr_msg_queue_sptr queue, bool dump, std::string dump_filename, int averaging_depth, bool flag_averaging);
/*!
* \brief This class implements a block that computes the PVT solution
*/
class gps_l1_ca_pvt_cc : public gr_block {
private:

View File

@ -27,24 +27,10 @@
*
* -------------------------------------------------------------------------
*/
/*!
* Using ITPP
*/
//#include <itpp/itbase.h>
//#include <itpp/stat/misc_stat.h>
//#include <itpp/base/matfunc.h>
//using namespace itpp;
/*!
* Using armadillo
*/
#include "armadillo"
//using namespace arma;
#include "gps_l1_ca_ls_pvt.h"
#include "GPS_L1_CA.h"
gps_l1_ca_ls_pvt::gps_l1_ca_ls_pvt(int nchannels,std::string dump_filename, bool flag_dump_to_file)
@ -87,24 +73,22 @@ gps_l1_ca_ls_pvt::~gps_l1_ca_ls_pvt()
arma::vec gps_l1_ca_ls_pvt::e_r_corr(double traveltime, arma::vec X_sat) {
/*
%E_R_CORR Returns rotated satellite ECEF coordinates due to Earth
%rotation during signal travel time
%
%X_sat_rot = e_r_corr(traveltime, X_sat);
%
% Inputs:
% travelTime - signal travel time
% X_sat - satellite's ECEF coordinates
%
% Outputs:
% X_sat_rot - rotated satellite's coordinates (ECEF)
* Returns rotated satellite ECEF coordinates due to Earth
* rotation during signal travel time
*
* Inputs:
* travelTime - signal travel time
* X_sat - satellite's ECEF coordinates
*
* Returns:
* X_sat_rot - rotated satellite's coordinates (ECEF)
*/
double Omegae_dot = 7.292115147e-5; // rad/sec
//const double Omegae_dot = 7.292115147e-5; // rad/sec
//--- Find rotation angle --------------------------------------------------
double omegatau;
omegatau = Omegae_dot * traveltime;
omegatau = OMEGA_EARTH_DOT * traveltime;
//--- Make a rotation matrix -----------------------------------------------
arma::mat R3=arma::zeros(3,3);
@ -124,24 +108,17 @@ arma::vec gps_l1_ca_ls_pvt::e_r_corr(double traveltime, arma::vec X_sat) {
}
arma::vec gps_l1_ca_ls_pvt::leastSquarePos(arma::mat satpos, arma::vec obs, arma::mat w) {
//Function calculates the Least Square Solution.
//pos= leastSquarePos(satpos, obs, w);
// Inputs:
// satpos - Satellites positions (in ECEF system: [X; Y; Z;]
// obs - Observations - the pseudorange measurements to each
// satellite
// w - weigths vector
// Outputs:
// pos - receiver position and receiver clock error
// (in ECEF system: [X, Y, Z, dt])
//////////////////////////////////////////////////////////////////////////
// el - Satellites elevation angles (degrees)
// az - Satellites azimuth angles (degrees)
// dop - Dilutions Of Precision ([GDOP PDOP HDOP VDOP TDOP])
/*Function calculates the Least Square Solution.
* Inputs:
* satpos - Satellites positions in ECEF system: [X; Y; Z;]
* obs - Observations - the pseudorange measurements to each
* satellite
* w - weigths vector
*
* Returns:
* pos - receiver position and receiver clock error
* (in ECEF system: [X, Y, Z, dt])
*/
//=== Initialization =======================================================
int nmbOfIterations = 10; // TODO: include in config
@ -150,7 +127,6 @@ arma::vec gps_l1_ca_ls_pvt::leastSquarePos(arma::mat satpos, arma::vec obs, arma
int nmbOfSatellites;
//nmbOfSatellites = satpos.cols(); //ITPP
nmbOfSatellites = satpos.n_cols; //Armadillo
arma::vec pos = "0.0 0.0 0.0 0.0";
arma::mat A;
@ -183,7 +159,6 @@ arma::vec gps_l1_ca_ls_pvt::leastSquarePos(arma::mat satpos, arma::vec obs, arma
for (int i = 0; i < nmbOfSatellites; i++) {
if (iter == 0) {
//--- Initialize variables at the first iteration --------------
//Rot_X=X.get_col(i); //ITPP
Rot_X=X.col(i); //Armadillo
trop = 0.0;
} else {
@ -191,22 +166,16 @@ arma::vec gps_l1_ca_ls_pvt::leastSquarePos(arma::mat satpos, arma::vec obs, arma
rho2 = (X(0, i) - pos(0))*(X(0, i) - pos(0)) + (X(1, i) - pos(1))*(X(1, i) - pos(1))+ (X(2,i) - pos(2))*(X(2,i) - pos(2));
traveltime = sqrt(rho2) / GPS_C_m_s;
//--- Correct satellite position (do to earth rotation) --------
//Rot_X = e_r_corr(traveltime, X.get_col(i)); //ITPP
Rot_X = e_r_corr(traveltime, X.col(i)); //armadillo
//--- Find the elevation angel of the satellite ----------------
//[az(i), el(i), dist] = topocent(pos(1:3, :), Rot_X - pos(1:3, :));
}
//--- Apply the corrections ----------------------------------------
//omc(i) = (obs(i) - norm(Rot_X - pos(3)) - pos(4) - trop); //ITPP
omc(i) = (obs(i) - norm(Rot_X - pos.subvec(0,2),2) - pos(3) - trop); // Armadillo
//--- Construct the A matrix ---------------------------------------
//ITPP
//A.set(i, 0, (-(Rot_X(0) - pos(0))) / obs(i));
//A.set(i, 1, (-(Rot_X(1) - pos(1))) / obs(i));
//A.set(i, 2, (-(Rot_X(2) - pos(2))) / obs(i));
//A.set(i, 3, 1.0);
//--- Construct the A matrix ---------------------------------------
//Armadillo
A(i,0)=(-(Rot_X(0) - pos(0))) / obs(i);
A(i,1)=(-(Rot_X(1) - pos(1))) / obs(i);
@ -222,7 +191,6 @@ arma::vec gps_l1_ca_ls_pvt::leastSquarePos(arma::mat satpos, arma::vec obs, arma
//}
//--- Find position update ---------------------------------------------
// x = ls_solve_od(w*A,w*omc); // ITPP
x = arma::solve(w*A,w*omc); // Armadillo
//--- Apply position update --------------------------------------------
@ -235,12 +203,7 @@ arma::vec gps_l1_ca_ls_pvt::leastSquarePos(arma::mat satpos, arma::vec obs, arma
bool gps_l1_ca_ls_pvt::get_PVT(std::map<int,gnss_pseudorange> gnss_pseudoranges_map,double GPS_current_time,bool flag_averaging)
{
std::map<int,gnss_pseudorange>::iterator gnss_pseudoranges_iter;
//ITPP
//mat W=eye(d_nchannels); //channels weights matrix
//vec obs=zeros(d_nchannels); // pseudoranges observation vector
//mat satpos=zeros(3,d_nchannels); //satellite positions matrix
// Armadillo
arma::mat W=arma::eye(d_nchannels,d_nchannels); //channels weights matrix
arma::vec obs=arma::zeros(d_nchannels); // pseudoranges observation vector
arma::mat satpos=arma::zeros(3,d_nchannels); //satellite positions matrix
@ -288,7 +251,7 @@ bool gps_l1_ca_ls_pvt::get_PVT(std::map<int,gnss_pseudorange> gnss_pseudoranges_
mypos=leastSquarePos(satpos,obs,W);
std::cout << "Position at TOW="<<GPS_current_time<<" is ECEF (X,Y,Z) = " << mypos << std::endl;
cart2geo(mypos(0), mypos(1), mypos(2), 4);
std::cout << "Position at TOW="<<GPS_current_time<<" is Lat = " << d_latitude_d << " [º] Long ="<< d_longitude_d <<" [º] Height="<<d_height_m<<" [m]\r\n";
std::cout << "Position at TOW="<<GPS_current_time<<" is Lat = " << d_latitude_d << " [¼] Long = "<< d_longitude_d <<" [¼] Height= "<<d_height_m<<" [m]" <<std::endl;
// ######## LOG FILE #########
if(d_flag_dump_enabled==true) {
// MULTIPLEXED FILE RECORDING - Record results to file
@ -385,21 +348,19 @@ bool gps_l1_ca_ls_pvt::get_PVT(std::map<int,gnss_pseudorange> gnss_pseudoranges_
}
void gps_l1_ca_ls_pvt::cart2geo(double X, double Y, double Z, int elipsoid_selection)
{
//function [phi, lambda, h] = cart2geo(X, Y, Z, i)
//CART2GEO Conversion of Cartesian coordinates (X,Y,Z) to geographical
//coordinates (phi, lambda, h) on a selected reference ellipsoid.
// Conversion of Cartesian coordinates (X,Y,Z) to geographical
// coordinates (latitude, longitude, h) on a selected reference ellipsoid.
//
//[phi, lambda, h] = cart2geo(X, Y, Z, i);
//
// Choices i of Reference Ellipsoid for Geographical Coordinates
// Choices of Reference Ellipsoid for Geographical Coordinates
// 0. International Ellipsoid 1924
// 1. International Ellipsoid 1967
// 2. World Geodetic System 1972
// 3. Geodetic Reference System 1980
// 4. World Geodetic System 1984
double a[5] = {6378388, 6378160, 6378135, 6378137, 6378137};
double f[5] = {1/297, 1/298.247, 1/298.26, 1/298.257222101, 1/298.257223563};
const double a[5] = {6378388, 6378160, 6378135, 6378137, 6378137};
const double f[5] = {1/297, 1/298.247, 1/298.26, 1/298.257222101, 1/298.257223563};
double lambda;
lambda = atan2(Y,X);

View File

@ -27,8 +27,8 @@
*
* -------------------------------------------------------------------------
*/
#ifndef GPS_L1_CA_LS_PVT_H_
#define GPS_L1_CA_LS_PVT_H_
#ifndef GNSS_SDR_GPS_L1_CA_LS_PVT_H_
#define GNSS_SDR_GPS_L1_CA_LS_PVT_H_
#include <fstream>
#include <string>
@ -43,17 +43,11 @@
#include <algorithm>
#include "gps_navigation_message.h"
#include "GPS_L1_CA.h"
//#include <itpp/itbase.h>
//#include <itpp/stat/misc_stat.h>
//#include <itpp/base/matfunc.h>
#include "armadillo"
//using namespace arma;
//using namespace itpp;
/*!
* \brief This class implements a simple PVT Least Squares solution
*/
class gps_l1_ca_ls_pvt
{
private:
@ -62,21 +56,21 @@ private:
//void cart2geo();
//void topocent();
public:
int d_nchannels;
int d_nchannels; //! Number of available channels for positioning
gps_navigation_message* d_ephemeris;
double d_pseudoranges_time_ms;
double d_latitude_d;
double d_longitude_d;
double d_height_m;
double d_latitude_d; //! Latitude in degrees
double d_longitude_d; //! Longitude in degrees
double d_height_m; //! Height [m]
//averaging
std::deque<double> d_hist_latitude_d;
std::deque<double> d_hist_longitude_d;
std::deque<double> d_hist_height_m;
int d_averaging_depth;
int d_averaging_depth; //! Length of averaging window
double d_avg_latitude_d;
double d_avg_longitude_d;
double d_avg_height_m;
double d_avg_latitude_d; //! Averaged latitude in degrees
double d_avg_longitude_d; //! Averaged longitude in degrees
double d_avg_height_m; //! Averaged height [m]
double d_x_m;
double d_y_m;
@ -92,6 +86,22 @@ public:
~gps_l1_ca_ls_pvt();
bool get_PVT(std::map<int,gnss_pseudorange> pseudoranges,double GPS_current_time,bool flag_averaging);
/*!
* \brief Conversion of Cartesian coordinates (X,Y,Z) to geographical
* coordinates (d_latitude_d, d_longitude_d, d_height_m) on a selected reference ellipsoid.
*
* \param[in] X [m] Cartesian coordinate
* \param[in] Y [m] Cartesian coordinate
* \param[in] Z [m] Cartesian coordinate
* \param[in] elipsoid_selection Choices of Reference Ellipsoid for Geographical Coordinates
* 0 - International Ellipsoid 1924
* 1 - International Ellipsoid 1967
* 2 - World Geodetic System 1972
* 3 - Geodetic Reference System 1980
* 4 - World Geodetic System 1984
*
*/
void cart2geo(double X, double Y, double Z, int elipsoid_selection);
};

View File

@ -30,14 +30,16 @@
*/
#ifndef KML_PRINTER_H_
#define KML_PRINTER_H_
#ifndef GNSS_SDR_KML_PRINTER_H_
#define GNSS_SDR_KML_PRINTER_H_
#include <iostream>
#include <fstream>
#include "gps_l1_ca_ls_pvt.h"
/*!
* \brief Prints PVT information to a GoogleEarth .kml file
*/
class kml_printer
{
private:

View File

@ -29,14 +29,12 @@
* -------------------------------------------------------------------------
*/
#ifndef GNSS_SDR_ACQUISITION_H_
#define GNSS_SDR_ACQUISITION_H_
#ifndef GNSS_SDR_GPS_L1_CA_GPS_SDR_ACQUISITION_H_
#define GNSS_SDR_GPS_L1_CA_GPS_SDR_ACQUISITION_H_
#include "acquisition_interface.h"
#include "gps_l1_ca_gps_sdr_acquisition_cc.h"
#include "gps_l1_ca_gps_sdr_acquisition_ss.h"
#include <gnuradio/gr_msg_queue.h>
class ConfigurationInterface;

View File

@ -31,13 +31,11 @@
* -------------------------------------------------------------------------
*/
#ifndef GPS_L1_CA_PCPS_ACQUISITION_H_
#define GPS_L1_CA_PCPS_ACQUISITION_H_
#ifndef GNSS_SDR_GPS_L1_CA_PCPS_ACQUISITION_H_
#define GNSS_SDR_GPS_L1_CA_PCPS_ACQUISITION_H_
#include "acquisition_interface.h"
#include "gps_l1_ca_pcps_acquisition_cc.h"
#include <gnuradio/gr_msg_queue.h>
class ConfigurationInterface;
@ -114,4 +112,4 @@ private:
};
#endif /* GPS_L1_CA_PCPS_ACQUISITION_H_ */
#endif /* GNSS_SDR_GPS_L1_CA_PCPS_ACQUISITION_H_ */

View File

@ -30,13 +30,11 @@
* -------------------------------------------------------------------------
*/
#ifndef GPS_L1_CA_TONG_PCPS_ACQUISITION_H_
#define GPS_L1_CA_TONG_PCPS_ACQUISITION_H_
#ifndef GNSS_SDR_L1_CA_TONG_PCPS_ACQUISITION_H_
#define GNSS_SDR_L1_CA_TONG_PCPS_ACQUISITION_H_
#include "acquisition_interface.h"
#include "gps_l1_ca_tong_pcps_acquisition_cc.h"
#include <gnuradio/gr_msg_queue.h>
class ConfigurationInterface;
@ -72,10 +70,7 @@ public:
void set_satellite(unsigned int satellite);
void set_channel(unsigned int channel);
void set_threshold(float threshold)
{
}
;
void set_threshold(float threshold){};
void set_doppler_max(unsigned int doppler_max);
void set_doppler_step(unsigned int doppler_step);
void set_channel_queue(concurrent_queue<int> *channel_internal_queue);
@ -116,4 +111,4 @@ private:
};
#endif /* GPS_L1_CA_TONG_PCPS_ACQUISITION_H_ */
#endif /* GNSS_SDR_L1_CA_TONG_PCPS_ACQUISITION_H_ */

View File

@ -31,16 +31,14 @@
* -------------------------------------------------------------------------
*/
#ifndef INCLUDED_GPS_L1_CA_GPS_SDR_ACQUISITION_CC_H
#define INCLUDED_GPS_L1_CA_GPS_SDR_ACQUISITION_CC_H
#ifndef GNSS_SDR_GPS_L1_CA_GPS_SDR_ACQUISITION_CC_H
#define GNSS_SDR_GPS_L1_CA_GPS_SDR_ACQUISITION_CC_H
#include <fstream>
#include <gnuradio/gr_block.h>
#include <gnuradio/gr_msg_queue.h>
#include <gnuradio/gr_complex.h>
#include <gnuradio/gri_fft.h>
#include <queue>
#include <boost/thread/mutex.hpp>
#include <boost/thread/thread.hpp>
@ -163,4 +161,4 @@ public:
gr_vector_void_star &output_items);
};
#endif /* INCLUDED_GPS_L1_CA_GPS_SDR_ACQUISITION_CC_H */
#endif /* GNSS_SDR_GPS_L1_CA_GPS_SDR_ACQUISITION_CC_H */

View File

@ -180,7 +180,7 @@ int gps_l1_ca_gps_sdr_acquisition_ss::general_work(int noutput_items,
<< " bytes into buffer (" << d_fft_size << " samples)";
memcpy(d_baseband_signal, in, d_fft_size * sizeof(CPX));
#ifdef NO_SIMD
x86_cmulsc(d_baseband_signal, d_sine_250,
x86_cmulsc(d_baseband_signal, d_sine_250,
&d_baseband_signal[d_fft_size], d_fft_size, 14);
x86_cmulsc(d_baseband_signal, d_sine_500, &d_baseband_signal[2
* d_fft_size], d_fft_size, 14);
@ -226,7 +226,7 @@ int gps_l1_ca_gps_sdr_acquisition_ss::general_work(int noutput_items,
+ 100 + i], d_fft_codes[d_satellite], buffer,
d_fft_size, 10);
#endif
d_piFFT->doiFFT(buffer, true);
d_piFFT->doiFFT(buffer, true);
x86_cmag(buffer, d_fft_size);
x86_max((unsigned int *)buffer, &indext, &magt, d_fft_size);

View File

@ -31,15 +31,13 @@
* -------------------------------------------------------------------------
*/
#ifndef INCLUDED_GPS_L1_CA_GPS_SDR_ACQUISITION_SS_H
#define INCLUDED_GPS_L1_CA_GPS_SDR_ACQUISITION_SS_H
#ifndef GNSS_SDR_GPS_L1_CA_GPS_SDR_ACQUISITION_SS_H
#define GNSS_SDR_GPS_L1_CA_GPS_SDR_ACQUISITION_SS_H
#include <fstream>
#include <gnuradio/gr_block.h>
#include <gnuradio/gr_msg_queue.h>
#include "gps_sdr_signal_processing.h"
#include <queue>
#include <boost/thread/mutex.hpp>
#include <boost/thread/thread.hpp>
@ -152,4 +150,4 @@ public:
gr_vector_void_star &output_items);
};
#endif /* INCLUDED_GPS_L1_CA_GPS_SDR_ACQUISITION_SS_H */
#endif /* GNSS_SDR_GPS_L1_CA_GPS_SDR_ACQUISITION_SS_H */

View File

@ -35,11 +35,8 @@
#include "gps_sdr_signal_processing.h"
#include "control_message_factory.h"
#include "gps_sdr_x86.h"
#include <gnuradio/gr_io_signature.h>
#include <sstream>
#include <glog/log_severity.h>
#include <glog/logging.h>

View File

@ -31,16 +31,14 @@
* -------------------------------------------------------------------------
*/
#ifndef GPS_L1_CA_PCPS_ACQUISITION_A_CC_H
#define GPS_L1_CA_PCPS_ACQUISITION_A_CC_H
#ifndef GNSS_SDR_GPS_L1_CA_PCPS_ACQUISITION_A_CC_H
#define GNSS_SDR_GPS_L1_CA_PCPS_ACQUISITION_A_CC_H
#include <fstream>
#include <gnuradio/gr_block.h>
#include <gnuradio/gr_msg_queue.h>
#include <gnuradio/gr_complex.h>
#include <gnuradio/gri_fft.h>
#include <queue>
#include <boost/thread/mutex.hpp>
#include <boost/thread/thread.hpp>
@ -54,6 +52,9 @@ gps_l1_ca_pcps_make_acquisition_cc(unsigned int sampled_ms,
unsigned int doppler_max, long freq, long fs_in, int samples_per_ms,
gr_msg_queue_sptr queue, bool dump, std::string dump_filename);
/*!
* \brief This class implements a PCPS acquisition block
*/
class gps_l1_ca_pcps_acquisition_cc: public gr_block
{
@ -160,4 +161,4 @@ public:
gr_vector_void_star &output_items);
};
#endif /* GPS_L1_CA_PCPS_ACQUISITION_CC_H*/
#endif /* GNSS_SDR_GPS_L1_CA_PCPS_ACQUISITION_CC_H*/

View File

@ -34,11 +34,8 @@
#include "gps_sdr_signal_processing.h"
#include "control_message_factory.h"
#include "gps_sdr_x86.h"
#include <gnuradio/gr_io_signature.h>
#include <sstream>
#include <glog/log_severity.h>
#include <glog/logging.h>

View File

@ -30,16 +30,14 @@
* -------------------------------------------------------------------------
*/
#ifndef GPS_L1_CA_TONG_PCPS_ACQUISITION_CC_H
#define GPS_L1_CA_TONG_PCPS_ACQUISITION_CC_H
#ifndef GNSS_SDR_GPS_L1_CA_TONG_PCPS_ACQUISITION_CC_H
#define GNSS_SDR_GPS_L1_CA_TONG_PCPS_ACQUISITION_CC_H
#include <fstream>
#include <gnuradio/gr_block.h>
#include <gnuradio/gr_msg_queue.h>
#include <gnuradio/gr_complex.h>
#include <gnuradio/gri_fft.h>
#include <queue>
#include <boost/thread/mutex.hpp>
#include <boost/thread/thread.hpp>
@ -183,4 +181,4 @@ public:
gr_vector_void_star &output_items);
};
#endif /* GPS_L1_CA_TONG_PCPS_ACQUISITION_CC_H*/
#endif /* GNSS_SDR_GPS_L1_CA_TONG_PCPS_ACQUISITION_CC_H*/

View File

@ -32,12 +32,11 @@
* -------------------------------------------------------------------------
*/
#ifndef CHANNEL_H_
#define CHANNEL_H_
#ifndef GNSS_SDR_CHANNEL_H_
#define GNSS_SDR_CHANNEL_H_
#include <gnuradio/gr_null_sink.h>
#include <gnuradio/gr_msg_queue.h>
#include "channel_interface.h"
#include "gps_l1_ca_channel_fsm.h"
#include "control_message_factory.h"
@ -118,4 +117,4 @@ private:
};
#endif /*CHANNEL_H_*/
#endif /*GNSS_SDR_CHANNEL_H_*/

View File

@ -1,6 +1,6 @@
/*!
* \file gps_l1_ca_channel_fsm.h
* \brief State Machine for channel using boost::statechart
* \brief Interface of the State Machine for channel using boost::statechart
* \author Luis Esteve, 2011. luis(at)epsilon-formacion.com
*
*
@ -41,12 +41,10 @@
#include <queue>
#include <boost/thread/mutex.hpp>
#include <boost/thread/thread.hpp>
#include "acquisition_interface.h"
#include "tracking_interface.h"
#include "telemetry_decoder_interface.h"
#include <gnuradio/gr_msg_queue.h>
#include <iostream>
#include <cstring>

View File

@ -30,11 +30,10 @@
* -------------------------------------------------------------------------
*/
#ifndef DIRECT_RESAMPLER_CONDITIONER_H_
#define DIRECT_RESAMPLER_CONDITIONER_H_
#ifndef GNSS_SDR_DIRECT_RESAMPLER_CONDITIONER_H_
#define GNSS_SDR_DIRECT_RESAMPLER_CONDITIONER_H_
#include <gnuradio/gr_hier_block2.h>
#include "gnss_block_interface.h"
class ConfigurationInterface;
@ -84,4 +83,4 @@ private:
gr_block_sptr file_sink_;
};
#endif /*DIRECT_RESAMPLER_CONDITIONER_H_*/
#endif /*GNSS_SDR_DIRECT_RESAMPLER_CONDITIONER_H_*/

View File

@ -5,16 +5,11 @@
* gr_complex input and gr_complex output
* \author Luis Esteve, 2011. luis(at)epsilon-formacion.com
*
* Detailed description of the file here if needed.
*
* This block takes in a signal stream and performs direct
* resampling.
*
* The theory behind this block can be found in Chapter 7.5 of
* the following book.
*
* \param sample_freq_in (double) Specifies the sampling frequency of the input signal
* \param sample_freq_out (double) Specifies the sampling frequency of the output signal
*
* -------------------------------------------------------------------------
*
@ -41,8 +36,8 @@
* -------------------------------------------------------------------------
*/
#ifndef INCLUDED_DIRECT_RESAMPLER_CONDITIONER_CC_H
#define INCLUDED_DIRECT_RESAMPLER_CONDITIONER_CC_H
#ifndef GNSS_SDR_DIRECT_RESAMPLER_CONDITIONER_CC_H
#define GNSS_SDR_DIRECT_RESAMPLER_CONDITIONER_CC_H
#include <gnuradio/gr_block.h>
@ -53,6 +48,11 @@ direct_resampler_conditioner_cc_sptr
direct_resampler_make_conditioner_cc(double sample_freq_in,
double sample_freq_out);
/*!
* \brief This class implements a direct resampler conditioner for complex data
*
* Direct resampling without interpolation
*/
class direct_resampler_conditioner_cc: public gr_block
{
@ -62,8 +62,8 @@ private:
direct_resampler_make_conditioner_cc(double sample_freq_in,
double sample_freq_out);
double d_sample_freq_in;
double d_sample_freq_out;
double d_sample_freq_in; //! Specifies the sampling frequency of the input signal
double d_sample_freq_out; //! Specifies the sampling frequency of the output signal
unsigned int d_phase;
unsigned int d_lphase;
unsigned int d_phase_step;
@ -90,4 +90,4 @@ public:
gr_vector_void_star &output_items);
};
#endif /* INCLUDED_DIRECT_RESAMPLER_CONDITIONER_CC_H */
#endif /* GNSS_SDR_DIRECT_RESAMPLER_CONDITIONER_CC_H */

View File

@ -4,8 +4,6 @@
* short input and short output
* \author Luis Esteve, 2011. luis(at)epsilon-formacion.com
*
* Detailed description of the file here if needed.
*
* -------------------------------------------------------------------------
*
* Copyright (C) 2010-2011 (see AUTHORS file for a list of contributors)
@ -31,8 +29,8 @@
* -------------------------------------------------------------------------
*/
#ifndef INCLUDED_DIRECT_RESAMPLER_CONDITIONER_SS_H
#define INCLUDED_DIRECT_RESAMPLER_CONDITIONER_SS_H
#ifndef GNSS_SDR_DIRECT_RESAMPLER_CONDITIONER_SS_H
#define GNSS_SDR_DIRECT_RESAMPLER_CONDITIONER_SS_H
#include <gnuradio/gr_block.h>
@ -42,7 +40,11 @@ typedef boost::shared_ptr<direct_resampler_conditioner_ss>
direct_resampler_conditioner_ss_sptr
direct_resampler_make_conditioner_ss(double sample_freq_in,
double sample_freq_out);
/*!
* \brief This class implements a direct resampler conditioner for shorts
*
* Direct resampling without interpolation
*/
class direct_resampler_conditioner_ss: public gr_block
{
@ -80,4 +82,4 @@ public:
gr_vector_void_star &output_items);
};
#endif /* INCLUDED_DIRECT_RESAMPLER_CONDITIONER_SS_H */
#endif /* GNSS_SDR_DIRECT_RESAMPLER_CONDITIONER_SS_H */

View File

@ -122,7 +122,7 @@ typedef unsigned int uint32;
/* PVT Stuff */
/*----------------------------------------------------------------------------------------------*/
#define GRAVITY_CONSTANT (3.986005e14) //!< Earth's WGS-84 gravitational constant (m^3/s^2) as specified in IS-GPS-200D
#define WGS84OE (7.2921151467e-5) //!< Earth's WGS-84 rotation rate (rads/s) as specified in IS-GPS-200D
const double WGS84OE = 7.2921151467e-5; //!< Earth's WGS-84 rotation rate (rads/s) as specified in IS-GPS-200D
#define WGS84_MAJOR_AXIS (6378137.0) //!< Earth's WGS-84 ellipsoid's major axis
#define WGS84_MINOR_AXIS (6356752.314245) //!< Earth's WGS-84 ellipsoid's minor axis
#define SECONDS_IN_1024_WEEKS (619315200.0) //!< Number of seconds in 1024 weeks

View File

@ -31,13 +31,11 @@
*/
#ifndef GPS_L1_CA_OBSERVABLES_H_
#define GPS_L1_CA_OBSERVABLES_H_
#ifndef GNSS_SDR_GPS_L1_CA_OBSERVABLES_H_
#define GNSS_SDR_GPS_L1_CA_OBSERVABLES_H_
#include "observables_interface.h"
#include "gps_l1_ca_observables_cc.h"
#include <gnuradio/gr_msg_queue.h>
class ConfigurationInterface;

View File

@ -1,6 +1,6 @@
/*!
* \file gps_l1_ca_observables_cc.h
* \brief Pseudorange computation module for GPS L1 C/A
* \brief Interface of the pseudorange computation module for GPS L1 C/A
* \author Javier Arribas, 2011. jarribas(at)cttc.es
* -------------------------------------------------------------------------
*
@ -28,24 +28,18 @@
*/
#ifndef GPS_L1_CA_OBSERVABLES_CC_H
#define GPS_L1_CA_OBSERVABLES_CC_H
#ifndef GNSS_SDR_GPS_L1_CA_OBSERVABLES_CC_H
#define GNSS_SDR_GPS_L1_CA_OBSERVABLES_CC_H
#include <fstream>
#include <gnuradio/gr_block.h>
#include <gnuradio/gr_msg_queue.h>
#include <queue>
#include <boost/thread/mutex.hpp>
#include <boost/thread/thread.hpp>
#include "concurrent_queue.h"
#include "gps_navigation_message.h"
#include "rinex_2_1_printer.h"
#include "GPS_L1_CA.h"
class gps_l1_ca_observables_cc;
@ -53,7 +47,9 @@ typedef boost::shared_ptr<gps_l1_ca_observables_cc> gps_l1_ca_observables_cc_spt
gps_l1_ca_observables_cc_sptr
gps_l1_ca_make_observables_cc(unsigned int n_channels, gr_msg_queue_sptr queue, bool dump, std::string dump_filename, int output_rate_ms, bool flag_averaging);
/*!
* \brief This class implements a block that computes GPS L1 C/A observables
*/
class gps_l1_ca_observables_cc : public gr_block {
private:

View File

@ -37,7 +37,6 @@
#define GNSS_SDR_FILE_OUTPUT_FILTER_H_
#include "gnss_block_interface.h"
#include <gr_file_sink.h>
class ConfigurationInterface;

View File

@ -1,6 +1,6 @@
/*!
* \file null_sink_output_filter.h
* \brief Brief description of the file here
* \brief Interface of a null sink output filter
* \author Carlos Aviles, 2010. carlos.avilesr(at)googlemail.com
*
* This class represents an implementation of an output filter that
@ -33,15 +33,17 @@
#ifndef NULL_SINK_OUTPUT_FILTER_H_
#define NULL_SINK_OUTPUT_FILTER_H_
#ifndef GNSS_SDR_NULL_SINK_OUTPUT_FILTER_H_
#define GNSS_SDR_NULL_SINK_OUTPUT_FILTER_H_
#include "gnss_block_interface.h"
#include <gr_null_sink.h>
class ConfigurationInterface;
/*!
* \brief This class implements a null sink output filter
*/
class NullSinkOutputFilter : public GNSSBlockInterface
{
@ -87,4 +89,4 @@ private:
unsigned int out_streams_;
};
#endif /*NULL_SINK_OUTPUT_FILTER_H_*/
#endif /*GNSS_SDR_NULL_SINK_OUTPUT_FILTER_H_*/

View File

@ -1,6 +1,6 @@
/*!
* \file file_signal_source.h
* \brief Brief description of the file here
* \brief This class reads signals samples from a file
* \author Carlos Aviles, 2010. carlos.avilesr(at)googlemail.com
*
* This class represents a file signal source. Internally it uses a GNU Radio's gr_file_source
@ -31,11 +31,10 @@
* -------------------------------------------------------------------------
*/
#ifndef FILE_SIGNAL_SOURCE_H_
#define FILE_SIGNAL_SOURCE_H_
#ifndef GNSS_SDR_FILE_SIGNAL_SOURCE_H_
#define GNSS_SDR_FILE_SIGNAL_SOURCE_H_
#include "gnss_block_interface.h"
#include <gnuradio/gr_file_source.h>
#include <gnuradio/gr_file_sink.h>
#include <gnuradio/gr_throttle.h>
@ -44,6 +43,9 @@
class ConfigurationInterface;
/*!
* \brief This class reads samples from a file.
*/
class FileSignalSource: public GNSSBlockInterface
{
@ -120,4 +122,4 @@ private:
bool enable_throttle_control_;
};
#endif /*FILE_SIGNAL_SOURCE_H_*/
#endif /*GNSS_SDR_FILE_SIGNAL_SOURCE_H_*/

View File

@ -1,6 +1,6 @@
/*!
* \file gps_navigation.cc
* \brief Brief description of the file here
* \file gps_l1_ca_telemetry_decoder.cc
* \brief This class implements a NAV data decoder for GPS L1 C/A
* \author Javier Arribas, 2011. jarribas(at)cttc.es
*
* Detailed description of the file here if needed.
@ -33,15 +33,11 @@
#include "gps_l1_ca_telemetry_decoder.h"
#include "configuration_interface.h"
#include "gps_l1_ca_telemetry_decoder_cc.h"
#include <gnuradio/gr_io_signature.h>
#include <gnuradio/gr_stream_to_vector.h>
#include <gnuradio/gr_vector_to_stream.h>
#include <glog/log_severity.h>
#include <glog/logging.h>

View File

@ -1,10 +1,8 @@
/*!
* \file gps_navigation.h
* \brief Brief description of the file here
* \file gps_l1_ca_telemetry_decoder.h
* \brief This class implements a NAV data decoder for GPS L1 C/A
* \author Javier Arribas, 2011. jarribas(at)cttc.es
*
* Detailed description of the file here if needed.
*
* -------------------------------------------------------------------------
*
* Copyright (C) 2010-2011 (see AUTHORS file for a list of contributors)
@ -31,17 +29,18 @@
*/
#ifndef GPS_L1_CA_TELEMETRY_DECODER_H_
#define GPS_L1_CA_TELEMETRY_DECODER_H_
#ifndef GNSS_SDR_GPS_L1_CA_TELEMETRY_DECODER_H_
#define GNSS_SDR_GPS_L1_CA_TELEMETRY_DECODER_H_
#include "telemetry_decoder_interface.h"
#include "gps_l1_ca_telemetry_decoder_cc.h"
#include <gnuradio/gr_msg_queue.h>
class ConfigurationInterface;
/*!
* \brief This class implements a NAV data decoder for GPS L1 C/A
*/
class GpsL1CaTelemetryDecoder : public TelemetryDecoderInterface
{

View File

@ -29,20 +29,19 @@
*/
/*!
* \todo Clean this code and move the telemetri definitions to GPS_L1_CA system definitions file
* \todo Clean this code and move the telemetry definitions to GPS_L1_CA system definitions file
*/
#include "gps_l1_ca_telemetry_decoder_cc.h"
#include "control_message_factory.h"
#include <iostream>
#include <sstream>
#include <bitset>
#include <gnuradio/gr_io_signature.h>
#include <glog/log_severity.h>
#include <glog/logging.h>
#include "gps_l1_ca_telemetry_decoder_cc.h"
#include "control_message_factory.h"
using google::LogMessage;

View File

@ -26,30 +26,32 @@
*
* -------------------------------------------------------------------------
*/
#ifndef GPS_L1_CA_TELEMETRY_DECODER_CC_H
#define GPS_L1_CA_TELEMETRY_DECODER_CC_H
#ifndef GNSS_SDR_GPS_L1_CA_TELEMETRY_DECODER_CC_H
#define GNSS_SDR_GPS_L1_CA_TELEMETRY_DECODER_CC_H
#include <fstream>
#include <bitset>
#include <gnuradio/gr_block.h>
//#include <gnuradio/gr_sync_block.h>
#include <gnuradio/gr_msg_queue.h>
#include <bitset>
#include "GPS_L1_CA.h"
#include "gps_telemetry.h"
#include "gps_l1_ca_subframe_fsm.h"
#include "concurrent_queue.h"
class gps_l1_ca_telemetry_decoder_cc;
typedef boost::shared_ptr<gps_l1_ca_telemetry_decoder_cc> gps_l1_ca_telemetry_decoder_cc_sptr;
gps_l1_ca_telemetry_decoder_cc_sptr
gps_l1_ca_make_telemetry_decoder_cc(unsigned int satellite, long if_freq, long fs_in, unsigned
int vector_length, gr_msg_queue_sptr queue, bool dump);
/*!
* \brief This class implements a block that decodes the NAV data defined in IS-GPS-200E
*
*/
class gps_l1_ca_telemetry_decoder_cc : public gr_block {
private:

View File

@ -33,13 +33,11 @@
* -------------------------------------------------------------------------
*/
#ifndef GPS_L1_CA_DLL_FLL_PLL_TRACKING_H_
#define GPS_L1_CA_DLL_FLL_PLL_TRACKING_H_
#ifndef GNSS_SDR_GPS_L1_CA_DLL_FLL_PLL_TRACKING_H_
#define GNSS_SDR_GPS_L1_CA_DLL_FLL_PLL_TRACKING_H_
#include "tracking_interface.h"
#include "gps_l1_ca_dll_fll_pll_tracking_cc.h"
#include <gnuradio/gr_msg_queue.h>
class ConfigurationInterface;

View File

@ -33,18 +33,18 @@
* -------------------------------------------------------------------------
*/
#ifndef GPS_L1_CA_DLL_PLL_TRACKING_H_
#define GPS_L1_CA_DLL_PLL_TRACKING_H_
#ifndef GNSS_SDR_GPS_L1_CA_DLL_PLL_TRACKING_H_
#define GNSS_SDR_GPS_L1_CA_DLL_PLL_TRACKING_H_
#include "tracking_interface.h"
#include "gps_l1_ca_dll_pll_tracking_cc.h"
#include <gnuradio/gr_msg_queue.h>
class ConfigurationInterface;
/*!
* \brief This class implements a code DLL + carrier PLL tracking loop
*/
class GpsL1CaDllPllTracking : public TrackingInterface
{
@ -101,4 +101,4 @@ private:
concurrent_queue<int> *channel_internal_queue_;
};
#endif // GPS_L1_CA_DLL_PLL_TRACKING_H_
#endif // GNSS_SDR_GPS_L1_CA_DLL_PLL_TRACKING_H_

View File

@ -34,18 +34,15 @@
* -------------------------------------------------------------------------
*/
#ifndef GPS_L1_CA_DLL_FLL_PLL_TRACKING_CC_H
#define GPS_L1_CA_DLL_FLL_PLL_TRACKING_CC_H
#ifndef GNSS_SDR_GPS_L1_CA_DLL_FLL_PLL_TRACKING_CC_H
#define GNSS_SDR_GPS_L1_CA_DLL_FLL_PLL_TRACKING_CC_H
#include <fstream>
#include <gnuradio/gr_block.h>
#include <gnuradio/gr_msg_queue.h>
//#include <gnuradio/gr_sync_decimator.h>
#include "gps_sdr_signal_processing.h"
#include "tracking_FLL_PLL_filter.h"
#include <queue>
#include <boost/thread/mutex.hpp>
#include <boost/thread/thread.hpp>
@ -70,6 +67,10 @@ gps_l1_ca_dll_fll_pll_make_tracking_cc(unsigned int satellite,
float early_late_space_chips);
//class gps_l1_ca_dll_pll_tracking_cc: public gr_sync_decimator
/*!
* \brief This class implements a DLL and a FLL assisted PLL tracking loop block
*/
class gps_l1_ca_dll_fll_pll_tracking_cc: public gr_block
{
@ -204,4 +205,4 @@ public:
};
#endif //GPS_L1_CA_DLL_FLL_PLL_TRACKING_CC_H
#endif //GNSS_SDR_GPS_L1_CA_DLL_FLL_PLL_TRACKING_CC_H

View File

@ -47,9 +47,7 @@
#include <sstream>
#include <cmath>
#include "math.h"
#include <gnuradio/gr_io_signature.h>
#include <glog/log_severity.h>
#include <glog/logging.h>

View File

@ -32,19 +32,16 @@
*
* -------------------------------------------------------------------------
*/
#ifndef GPS_L1_CA_DLL_PLL_TRACKING_CC_H
#define GPS_L1_CA_DLL_PLL_TRACKING_CC_H
#ifndef GNSS_SDR_GPS_L1_CA_DLL_PLL_TRACKING_CC_H
#define GNSS_SDR_GPS_L1_CA_DLL_PLL_TRACKING_CC_H
#include <fstream>
#include <gnuradio/gr_block.h>
#include <gnuradio/gr_msg_queue.h>
//#include <gnuradio/gr_sync_decimator.h>
#include "gps_sdr_signal_processing.h"
#include "tracking_2nd_DLL_filter.h"
#include "tracking_2nd_PLL_filter.h"
#include <queue>
#include <boost/thread/mutex.hpp>
#include <boost/thread/thread.hpp>
@ -66,6 +63,10 @@ gps_l1_ca_dll_pll_make_tracking_cc(unsigned int satellite, long if_freq,
float early_late_space_chips);
//class gps_l1_ca_dll_pll_tracking_cc: public gr_sync_decimator
/*!
* \brief This class implements a DLL + PLL tracking loop block
*/
class gps_l1_ca_dll_pll_tracking_cc: public gr_block
{
@ -194,4 +195,4 @@ public:
};
#endif //GPS_L1_CA_DLL_PLL_TRACKING_CC_H
#endif //GNSS_SDR_GPS_L1_CA_DLL_PLL_TRACKING_CC_H

View File

@ -30,8 +30,8 @@
* -------------------------------------------------------------------------
*/
#ifndef CN_ESTIMATORS_H_
#define CN_ESTIMATORS_H_
#ifndef GNSS_SDR_CN_ESTIMATORS_H_
#define GNSS_SDR_CN_ESTIMATORS_H_
#include <gnuradio/gr_complex.h>

View File

@ -3,9 +3,8 @@
* \brief Class that implements 2 order DLL filter for code tracking loop.
* \author Javier Arribas, 2011. jarribas(at)cttc.es
*
* Class that implements 2 order PLL filter for code tracking loop. The algorithm is described in [1]
*
* [1] K.Borre, D.M.Akos, N.Bertelsen, P.Rinder, and S.~H.~Jensen, A Software-Defined GPS and Galileo Receiver. A Single-Frequency Approach,
* Class that implements 2 order PLL filter for code tracking loop. The algorithm is described in:
* K.Borre, D.M.Akos, N.Bertelsen, P.Rinder, and S. H. Jensen, A Software-Defined GPS and Galileo Receiver. A Single-Frequency Approach,
* Birkhauser, 2007, Applied and Numerical Harmonic Analysis.
*
* -------------------------------------------------------------------------
@ -33,9 +32,16 @@
* -------------------------------------------------------------------------
*/
#ifndef TRACKING_2ND_DLL_FILTER_H_
#define TRACKING_2ND_DLL_FILTER_H_
#ifndef GNSS_SDR_TRACKING_2ND_DLL_FILTER_H_
#define GNSS_SDR_TRACKING_2ND_DLL_FILTER_H_
/*!
* \brief This class implements a 2nd order DLL filter for code tracking loop.
*
* The algorithm is described in:
* K.Borre, D.M.Akos, N.Bertelsen, P.Rinder, and S. H. Jensen, A Software-Defined GPS and Galileo Receiver. A Single-Frequency Approach,
* Birkhauser, 2007, Applied and Numerical Harmonic Analysis.
*/
class tracking_2nd_DLL_filter
{
private:
@ -51,7 +57,7 @@ private:
void calculate_lopp_coef(float* tau1,float* tau2, float lbw, float zeta, float k);
public:
void set_DLL_BW(float dll_bw_hz);
void set_DLL_BW(float dll_bw_hz); //! Set DLL loop bandwidth [Hz]
void initialize(float d_acq_code_phase_samples);
float get_code_nco(float DLL_discriminator);
tracking_2nd_DLL_filter();

View File

@ -1,11 +1,10 @@
/*!
* \file tracking_2nd_PLL_filter.h
* \brief Class that implements 2 order PLL filter for tracking carrier loop
* \brief Class that implements 2 order PLL filter for carrier tracking loop
* \author Javier Arribas, 2011. jarribas(at)cttc.es
*
* Class that implements 2 order PLL filter for tracking carrier loop. The algorithm is described in [1]
*
* [1] K.Borre, D.M.Akos, N.Bertelsen, P.Rinder, and S.~H.~Jensen, A Software-Defined GPS and Galileo Receiver. A Single-Frequency Approach,
* Class that implements 2 order PLL filter for tracking carrier loop. The algorithm is described in
* K.Borre, D.M.Akos, N.Bertelsen, P.Rinder, and S.~H.~Jensen, A Software-Defined GPS and Galileo Receiver. A Single-Frequency Approach,
* Birkhauser, 2007, Applied and Numerical Harmonic Analysis.
*
* -------------------------------------------------------------------------
@ -33,9 +32,16 @@
* -------------------------------------------------------------------------
*/
#ifndef TRACKING_2ND_PLL_FILTER_H_
#define TRACKING_2ND_PLL_FILTER_H_
#ifndef GNSS_SDR_TRACKING_2ND_PLL_FILTER_H_
#define GNSS_SDR_TRACKING_2ND_PLL_FILTER_H_
/*!
* \brief This class implements a 2nd order PLL filter for carrier tracking loop.
*
* The algorithm is described in:
* K.Borre, D.M.Akos, N.Bertelsen, P.Rinder, and S. H. Jensen, A Software-Defined GPS and Galileo Receiver. A Single-Frequency Approach,
* Birkhauser, 2007, Applied and Numerical Harmonic Analysis.
*/
class tracking_2nd_PLL_filter
{
private:
@ -52,7 +58,7 @@ private:
void calculate_lopp_coef(float* tau1,float* tau2, float lbw, float zeta, float k);
public:
void set_PLL_BW(float pll_bw_hz);
void set_PLL_BW(float pll_bw_hz); //! Set PLL loop bandwidth [Hz]
void initialize(float d_acq_carrier_doppler_hz);
float get_carrier_nco(float PLL_discriminator);
tracking_2nd_PLL_filter();

View File

@ -30,9 +30,12 @@
* -------------------------------------------------------------------------
*/
#ifndef TRACKING_FLL_PLL_FILTER_H_
#define TRACKING_FLL_PLL_FILTER_H_
#ifndef GNSS_SDR_TRACKING_FLL_PLL_FILTER_H_
#define GNSS_SDR_TRACKING_FLL_PLL_FILTER_H_
/*!
* \brief This class implements a hybrid FLL and PLL filter for tracking carrier loop
*/
class tracking_FLL_PLL_filter
{
private:

View File

@ -30,8 +30,8 @@
* -------------------------------------------------------------------------
*/
#ifndef TRACKING_DISCRIMINATORS_H_
#define TRACKING_DISCRIMINATORS_H_
#ifndef GNSS_SDR_TRACKING_DISCRIMINATORS_H_
#define GNSS_SDR_TRACKING_DISCRIMINATORS_H_
#include <gnuradio/gr_complex.h>

View File

@ -33,16 +33,11 @@
*/
#include "control_thread.h"
#include <unistd.h>
#include <gnuradio/gr_message.h>
#include <gflags/gflags.h>
#include <glog/log_severity.h>
#include <glog/logging.h>
#include "gnss_flowgraph.h"
#include "file_configuration.h"
#include "control_message_factory.h"
@ -73,18 +68,18 @@ ControlThread::~ControlThread()
delete control_message_factory_;
}
/*
* Runs the control thread that manages the receiver control plane
*
* This is the main loop that reads and process the control messages
* 1- Connect the GNSS receiver flowgraph
* 2- Start the GNSS receiver flowgraph
* while (flowgraph_->running() && !stop)_{
* 3- Read control messages and process them }
*/
void ControlThread::run()
{
/* Runs the control thread
*
* This is the main loop that reads and process the control messages
*
* 1- Connect the GNSS receiver flowgraph
* 2- Start the GNSS receiver flowgraph
* while (flowgraph_->running() && !stop)_{
* 3- Read control messages and process them }
*/
flowgraph_->connect();
if (flowgraph_->connected())
{

View File

@ -38,7 +38,6 @@
#define GNSS_SDR_FILE_CONFIGURATION_H_
#include "configuration_interface.h"
#include <string>
class INIReader;

View File

@ -33,8 +33,8 @@
* -------------------------------------------------------------------------
*/
#ifndef GNSS_BLOCK_FACTORY_H_
#define GNSS_BLOCK_FACTORY_H_
#ifndef GNSS_SDR_BLOCK_FACTORY_H_
#define GNSS_SDR_BLOCK_FACTORY_H_
#include <vector>
#include <string>
@ -74,4 +74,4 @@ public:
};
#endif /*GNSS_BLOCK_FACTORY_H_*/
#endif /*GNSS_SDR_BLOCK_FACTORY_H_*/

View File

@ -32,15 +32,12 @@
*/
#include "gnss_flowgraph.h"
#include <exception>
#include "unistd.h"
#include <iostream>
#include <boost/lexical_cast.hpp>
#include <glog/log_severity.h>
#include <glog/logging.h>
#include "configuration_interface.h"
#include "gnss_block_interface.h"
#include "channel_interface.h"

View File

@ -38,7 +38,6 @@
#include <string>
#include <vector>
#include <queue>
#include <gnuradio/gr_top_block.h>
#include <gnuradio/gr_msg_queue.h>
@ -47,7 +46,7 @@ class ChannelInterface;
class ConfigurationInterface;
class GNSSBlockFactory;
/* \brief This class represents a GNSS flowgraph.
/*! \brief This class represents a GNSS flowgraph.
*
* It contains a signal source,
* a signal conditioner, a set of channels, a PVT and an output filter.
@ -67,10 +66,10 @@ public:
*/
virtual ~GNSSFlowgraph();
//! Start the flowgraph
//! \brief Start the flowgraph
void start();
//! Stop the flowgraph
//! \brief Stop the flowgraph
void stop();
/*!

View File

@ -38,12 +38,11 @@
#include <map>
#include <string>
#include "configuration_interface.h"
class StringConverter;
/*
/*!
* \brief This class is an implementation of the interface ConfigurationInterface.
*
* This implementation accepts configuration parameters upon instantiation and

View File

@ -27,8 +27,8 @@
*
* -------------------------------------------------------------------------
*/
#ifndef GPS_TELEMETRY_H_
#define GPS_TELEMETRY_H_
#ifndef GNSS_SDR_GPS_TELEMETRY_H_
#define GNSS_SDR_GPS_TELEMETRY_H_
#define _lrotl(X,N) ((X << N) ^ (X >> (32-N))) //!< Used in the parity check algorithm