GNU Radio's SATNOGS Package
doppler_correction_cc.h
Go to the documentation of this file.
1 /* -*- c++ -*- */
2 /*
3  * gr-satnogs: SatNOGS GNU Radio Out-Of-Tree Module
4  *
5  * Copyright (C) 2016,2019 Libre Space Foundation <http://libre.space>
6  *
7  * This program is free software: you can redistribute it and/or modify
8  * it under the terms of the GNU General Public License as published by
9  * the Free Software Foundation, either version 3 of the License, or
10  * (at your option) any later version.
11  *
12  * This program is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with this program. If not, see <http://www.gnu.org/licenses/>.
19  */
20 
21 #ifndef INCLUDED_SATNOGS_DOPPLER_CORRECTION_CC_H
22 #define INCLUDED_SATNOGS_DOPPLER_CORRECTION_CC_H
23 
24 #include <satnogs/api.h>
25 #include <gnuradio/sync_block.h>
26 
27 namespace gr {
28 namespace satnogs {
29 
30 /*!
31  * \brief This block corrects the doppler effect between the ground
32  * station and the satellite. It takes the input stream in baseband
33  * and applies proper corrections to keep the carrier at the desired
34  * frequency. To achieve that it uses messages containing the absolute
35  * predicted frequency of the satellite from software like Gpredict.
36  *
37  * \ingroup satnogs
38  *
39  */
40 class SATNOGS_API doppler_correction_cc : virtual public gr::sync_block {
41 public:
42  typedef boost::shared_ptr<doppler_correction_cc> sptr;
43 
44  /*!
45  * The doppler correction block. The input is the complex signal at
46  * baseband as it comes from the SDR device. The message input \p freq
47  * received periodically messages containing the predicted absolute
48  * frequency of the satellite at that specific time.
49  * @param target_freq the absolute frequency of the satellite
50  * @param offset the frequency offset from the actual target frequency.
51  * This is very common on SDR receivers to avoid DC spikes at the center
52  * frequency. This block can automatically compensate this offset
53  * @param sampling_rate the sampling rate of the signal
54  * @param corrections_per_sec the number of the corrections every second
55  * that the block should perform
56  */
57  static sptr
58  make(double target_freq, double offset, double sampling_rate,
59  size_t corrections_per_sec = 1000);
60 };
61 
62 } // namespace satnogs
63 } // namespace gr
64 
65 #endif /* INCLUDED_SATNOGS_DOPPLER_CORRECTION_CC_H */
66 
Definition: amsat_duv_decoder.h:29
boost::shared_ptr< doppler_correction_cc > sptr
Definition: doppler_correction_cc.h:42
#define SATNOGS_API
Definition: api.h:30
This block corrects the doppler effect between the ground station and the satellite. It takes the input stream in baseband and applies proper corrections to keep the carrier at the desired frequency. To achieve that it uses messages containing the absolute predicted frequency of the satellite from software like Gpredict.
Definition: doppler_correction_cc.h:40