GalFNavHealth.cpp
Go to the documentation of this file.
1 //==============================================================================
2 //
3 // This file is part of GNSSTk, the ARL:UT GNSS Toolkit.
4 //
5 // The GNSSTk is free software; you can redistribute it and/or modify
6 // it under the terms of the GNU Lesser General Public License as published
7 // by the Free Software Foundation; either version 3.0 of the License, or
8 // any later version.
9 //
10 // The GNSSTk is distributed in the hope that it will be useful,
11 // but WITHOUT ANY WARRANTY; without even the implied warranty of
12 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 // GNU Lesser General Public License for more details.
14 //
15 // You should have received a copy of the GNU Lesser General Public
16 // License along with GNSSTk; if not, write to the Free Software Foundation,
17 // Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110, USA
18 //
19 // This software was developed by Applied Research Laboratories at the
20 // University of Texas at Austin.
21 // Copyright 2004-2022, The Board of Regents of The University of Texas System
22 //
23 //==============================================================================
24 
25 
26 //==============================================================================
27 //
28 // This software was developed by Applied Research Laboratories at the
29 // University of Texas at Austin, under contract to an agency or agencies
30 // within the U.S. Department of Defense. The U.S. Government retains all
31 // rights to use, duplicate, distribute, disclose, or release this software.
32 //
33 // Pursuant to DoD Directive 523024
34 //
35 // DISTRIBUTION STATEMENT A: This software has been approved for public
36 // release, distribution is unlimited.
37 //
38 //==============================================================================
39 #include "GalFNavHealth.hpp"
40 #include "GalINavHealth.hpp"
41 
42 using namespace std;
43 
44 namespace gnsstk
45 {
46  GalFNavHealth ::
47  GalFNavHealth()
48  : sigHealthStatus(GalHealthStatus::Unknown),
49  dataValidityStatus(GalDataValid::Unknown),
50  sisaIndex(255)
51  {
55  weekFmt = "%4L(%4l)";
56  msgLenSec = 10.0;
57  }
58 
59 
60  void GalFNavHealth ::
61  dump(std::ostream& s, DumpDetail dl) const
62  {
63  const ios::fmtflags oldFlags = s.flags();
64  s.setf(ios::fixed, ios::floatfield);
65  s.setf(ios::right, ios::adjustfield);
66  s.setf(ios::uppercase);
67  s.precision(0);
68  s.fill(' ');
69  switch (dl)
70  {
72  NavData::dump(s,dl);
73  break;
74  case DumpDetail::Brief:
75  NavData::dump(s,dl);
76  s << " sigHealthStatus = "
77  << static_cast<unsigned>(sigHealthStatus)
79  << " dataValidityStatus = "
80  << static_cast<unsigned>(dataValidityStatus)
82  << endl
83  << " sigInSpaceAcc = " << static_cast<unsigned>(sisaIndex) <<endl
84  << " health = " << gnsstk::StringUtils::asString(getHealth())
85  << endl;
86  break;
87  case DumpDetail::Full:
88  // "header"
89  s << "*************************************************************"
90  << "***************" << endl
91  << "Satellite Health"
92  << endl
93  << endl
94  << getSignalString() << endl
95  << " TIMES OF INTEREST"
96  << endl << endl
97  << " " << getDumpTimeHdr(dl) << endl
98  << "Transmit: " << getDumpTime(dl, timeStamp) << endl
99  << endl
100  << " HEALTH DATA" << endl
101  << "SHS Bits 0x" << hex << setw(1)
102  << static_cast<unsigned>(sigHealthStatus) << dec << " ("
103  << StringUtils::asString(sigHealthStatus) << ")" << endl
104  << "DVS Bits 0x" << hex << setw(1)
105  << static_cast<unsigned>(dataValidityStatus) << dec << " ("
106  << StringUtils::asString(dataValidityStatus) << ")" << endl
107  << "SISA Index " << dec
108  << static_cast<unsigned>(sisaIndex) << endl
109  << "Status " << StringUtils::asString(getHealth())
110  << endl << endl;
111  break;
112  }
113  s.flags(oldFlags);
114  }
115 
116 
118  getHealth() const
119  {
121  sisaIndex);
122  }
123 }
gnsstk::NavData::getSignalString
std::string getSignalString() const
Definition: NavData.cpp:86
gnsstk::NavData::msgLenSec
double msgLenSec
Definition: NavData.hpp:199
gnsstk::GalDataValid
GalDataValid
Identify Galileo Data Validity Status (DVS) states.
Definition: GalDataValid.hpp:51
gnsstk::NavData::dump
virtual void dump(std::ostream &s, DumpDetail dl) const
Definition: NavData.cpp:79
gnsstk::GalFNavHealth::sigHealthStatus
GalHealthStatus sigHealthStatus
Signal health status (SHS)
Definition: GalFNavHealth.hpp:81
gnsstk::NavData::getDumpTime
std::string getDumpTime(DumpDetail dl, const CommonTime &t) const
Definition: NavData.cpp:145
GalFNavHealth.hpp
GalINavHealth.hpp
gnsstk::StringUtils::asString
std::string asString(IonexStoreStrategy e)
Convert a IonexStoreStrategy to a whitespace-free string name.
Definition: IonexStoreStrategy.cpp:46
gnsstk::NavData::getDumpTimeHdr
std::string getDumpTimeHdr(DumpDetail dl) const
Definition: NavData.cpp:127
gnsstk::SVHealth
SVHealth
Identify different types of SV health states.
Definition: SVHealth.hpp:52
gnsstk
For Sinex::InputHistory.
Definition: BasicFramework.cpp:50
gnsstk::IonexStoreStrategy::Unknown
@ Unknown
Unknown or uninitialized stategy value.
gnsstk::GalFNavHealth::sisaIndex
uint8_t sisaIndex
Signal in space accuracy index (OS-SIS-ICD tbl 76)
Definition: GalFNavHealth.hpp:85
gnsstk::NavData::timeStamp
CommonTime timeStamp
Definition: NavData.hpp:173
gnsstk::NavData::weekFmt
std::string weekFmt
Definition: NavData.hpp:193
gnsstk::GalFNavHealth::getHealth
SVHealth getHealth() const override
Definition: GalFNavHealth.cpp:118
gnsstk::DumpDetail::Full
@ Full
Include all detailed information.
gnsstk::DumpDetail
DumpDetail
Specify level of detail for dump output.
Definition: DumpDetail.hpp:51
gnsstk::DumpDetail::Brief
@ Brief
Limit output to <= 5 lines of minimal information.
std
Definition: Angle.hpp:142
gnsstk::GalFNavHealth::dataValidityStatus
GalDataValid dataValidityStatus
Data Validity Status (DVS)
Definition: GalFNavHealth.hpp:83
gnsstk::DumpDetail::OneLine
@ OneLine
Limit output to minimal information on a single line.
gnsstk::GalHealthStatus
GalHealthStatus
Identify different types of SV health states.
Definition: GalHealthStatus.hpp:51
gnsstk::GalFNavHealth::dump
void dump(std::ostream &s, DumpDetail dl) const override
Definition: GalFNavHealth.cpp:61
gnsstk::GalINavHealth::galHealth
static SVHealth galHealth(GalHealthStatus shs, GalDataValid dvs, uint8_t sisa)
Definition: GalINavHealth.cpp:124


gnsstk
Author(s):
autogenerated on Wed Oct 25 2023 02:40:39