Line |
Branch |
Exec |
Source |
1 |
|
|
// This file is part of INSTINCT, the INS Toolkit for Integrated |
2 |
|
|
// Navigation Concepts and Training by the Institute of Navigation of |
3 |
|
|
// the University of Stuttgart, Germany. |
4 |
|
|
// |
5 |
|
|
// This Source Code Form is subject to the terms of the Mozilla Public |
6 |
|
|
// License, v. 2.0. If a copy of the MPL was not distributed with this |
7 |
|
|
// file, You can obtain one at https://mozilla.org/MPL/2.0/. |
8 |
|
|
|
9 |
|
|
/// @file Clock.hpp |
10 |
|
|
/// @brief Abstract satellite clock information |
11 |
|
|
/// @author T. Topp (topp@ins.uni-stuttgart.de) |
12 |
|
|
/// @date 2022-12-02 |
13 |
|
|
|
14 |
|
|
#pragma once |
15 |
|
|
|
16 |
|
|
#include "Navigation/Time/InsTime.hpp" |
17 |
|
|
#include "Navigation/GNSS/Core/Frequency.hpp" |
18 |
|
|
|
19 |
|
|
namespace NAV |
20 |
|
|
{ |
21 |
|
|
|
22 |
|
|
/// @brief Abstract satellite clock information |
23 |
|
|
class Clock |
24 |
|
|
{ |
25 |
|
|
public: |
26 |
|
|
/// Satellite clock corrections |
27 |
|
|
struct Corrections |
28 |
|
|
{ |
29 |
|
|
InsTime transmitTime; ///< Transmit time of the signal |
30 |
|
|
double bias{}; ///< Satellite clock bias [s] |
31 |
|
|
double drift{}; ///< Satellite clock drift [s/s] |
32 |
|
|
}; |
33 |
|
|
|
34 |
|
|
/// @brief Default Constructor |
35 |
|
41371 |
Clock() = default; |
36 |
|
|
/// @brief Destructor |
37 |
|
82742 |
virtual ~Clock() = default; |
38 |
|
|
/// @brief Copy constructor |
39 |
|
|
Clock(const Clock&) = default; |
40 |
|
|
/// @brief Move constructor |
41 |
|
|
Clock(Clock&&) = default; |
42 |
|
|
/// @brief Copy assignment operator |
43 |
|
|
Clock& operator=(const Clock&) = delete; |
44 |
|
|
/// @brief Move assignment operator |
45 |
|
|
Clock& operator=(Clock&&) = delete; |
46 |
|
|
|
47 |
|
|
/// @brief Calculates clock bias and drift of the satellite |
48 |
|
|
/// @param[in] recvTime Receiver time to calculate the satellite position for |
49 |
|
|
/// @param[in] dist Distance between receiver and satellite (normally the pseudorange) [m] |
50 |
|
|
/// @param[in] freq Signal Frequency |
51 |
|
|
[[nodiscard]] virtual Corrections calcClockCorrections(const InsTime& recvTime, double dist, const Frequency& freq) const = 0; |
52 |
|
|
}; |
53 |
|
|
|
54 |
|
|
} // namespace NAV |
55 |
|
|
|