WSF
WsfCommComponentHW_Subsurface.hpp
Go to the documentation of this file.
1// ****************************************************************************
2// CUI
3//
4// The Advanced Framework for Simulation, Integration, and Modeling (AFSIM)
5//
6// Copyright 2017 Infoscitex, a DCS Company. All rights reserved.
7//
8// The use, dissemination or disclosure of data in this file is subject to
9// limitation or restriction. See accompanying README and LICENSE for details.
10// ****************************************************************************
11
12#ifndef WSFCOMMCOMPONENTHWSUBSURFACE_HPP
13#define WSFCOMMCOMPONENTHWSUBSURFACE_HPP
14
15#include "wsf_mil_export.h"
16
17#include <memory>
18
21
22// Forward declarations
23class WsfCommResult;
24class WsfGeoPoint;
25
26namespace wsf
27{
28namespace comm
29{
30
32class WSF_MIL_EXPORT ComponentHW_Subsurface : public ComponentHW
33{
34public:
35 static ComponentHW_Subsurface* Find(const wsf::comm::Comm& aParent);
37
39 ~ComponentHW_Subsurface() override = default;
40
42
43 WsfComponent* CloneComponent() const override;
44 WsfStringId GetComponentName() const override;
45 const int* GetComponentRoles() const override;
46 void* QueryInterface(int aRole) override;
48
50
51 bool ProcessInput(UtInput& aInput) override;
52
54
55 bool CanSendTo(double aSimTime, wsf::comm::Comm* aRcvrPtr, wsf::comm::Result& aResult) override;
56
57protected:
60
61 unsigned int SetSubmarineRadioValues(double aSimTime,
62 WsfGeoPoint& aLowPoint1,
63 WsfGeoPoint& aHighPoint2,
64 double& aSlantrange,
65 double& aWaterRange,
66 double& aAirRange,
67 double& aWaterLatDeg,
68 double& aWaterLongDeg,
69 double& aGrazingAngleRadians,
70 wsf::comm::Result& aResult);
71
72private:
73 // We are putting the mWaterAttenuation attribute on the radio here for our initial
74 // implementation in order to simplify the release and to check that this parameter
75 // will be truly useful. Other WSF attenuation methods are performed through the
76 // WsfEM_Attenuation class models which reside on the WsfEM_Xmtr class. These models do not
77 // assume the air-water boundary needed for this communication model. Overriding the transmitter
78 // type and the associated WsfEM_Attenuation methods and models can be a future development if this
79 // feature is needed for other radios. But if only for this radio, then we see extra work as an
80 // unnecessary complication.
81 double mWaterAttenuation; // unit is ratio using dB/meter
82
83 // Permits users to exclude comm signals based on angle to water.
84 // Angle is from horizon up to line for signal path--similar to a grazing angle.
85 // This angle is applied to the airborne side of the path.
86 // Later consider modeling to include better understanding of refraction and effects of
87 // reflection and absorption effects at watter boundary.
88 double mMinimumHorizonAngle;
89
90 // Defaults to false; Set true for modeled VLF. Later consider VLf behavior as separate class.
91 bool mIsVLFcomm;
92
93 // This is an error tolerance used to simplify horizon checks in the initial filtering process.
94 // Water transmission will generally be less than a few hundred meters. So we will set sub altitude
95 // to zero and won't constrain initial horizon/LOS checks when ranges fail by this small value.
96 double mAllowedWaterPathRange;
97
98 // Specifies the maximum depth at which a submerged platform is permitted to exchange communication
99 // events. In order to reduce user input issues, the absolute value of the numeric input is used,
100 // and the value is converted to be a negative altitude to represent the depth below the surface
101 // for the submerged platform.
102 double mMaxCommunicationDepth;
103};
104
105} // namespace comm
106} // namespace wsf
107
109
110#endif
#define WSF_DECLARE_COMPONENT_ROLE_TYPE(TYPE, ROLE)
Definition WsfComponentRoles.hpp:44
@ cWSF_COMPONENT_COMM_HW_SUBSURFACE
Definition WsfMilComponentRoles.hpp:33
UtStringId WsfStringId
WsfStringId – the same thing as UtStringId.
Definition WsfStringId.hpp:23
Definition WsfComponent.hpp:39
Definition WsfGeoPoint.hpp:29
Definition WsfComm.hpp:43
The hardware component that can be attached to all comm systems.
Definition WsfCommComponentHW_Subsurface.hpp:33
unsigned int SetSubmarineRadioValues(double aSimTime, WsfGeoPoint &aLowPoint1, WsfGeoPoint &aHighPoint2, double &aSlantrange, double &aWaterRange, double &aAirRange, double &aWaterLatDeg, double &aWaterLongDeg, double &aGrazingAngleRadians, wsf::comm::Result &aResult)
Definition WsfCommComponentHW_Subsurface.cpp:444
const int * GetComponentRoles() const override
Definition WsfCommComponentHW_Subsurface.cpp:102
bool CanSendTo(double aSimTime, wsf::comm::Comm *aRcvrPtr, wsf::comm::Result &aResult) override
Definition WsfCommComponentHW_Subsurface.cpp:191
static ComponentHW_Subsurface * FindOrCreate(wsf::comm::Comm &aParent)
Definition WsfCommComponentHW_Subsurface.cpp:46
WsfComponent * CloneComponent() const override
Definition WsfCommComponentHW_Subsurface.cpp:90
void * QueryInterface(int aRole) override
Definition WsfCommComponentHW_Subsurface.cpp:113
~ComponentHW_Subsurface() override=default
bool ProcessInput(UtInput &aInput) override
Definition WsfCommComponentHW_Subsurface.cpp:132
static ComponentHW_Subsurface * Find(const wsf::comm::Comm &aParent)
Find the instance of this component attached to the specified processor.
Definition WsfCommComponentHW_Subsurface.cpp:36
ComponentHW_Subsurface()
Definition WsfCommComponentHW_Subsurface.cpp:58
ComponentHW_Subsurface & operator=(const ComponentHW_Subsurface &aRhs)=delete
WsfStringId GetComponentName() const override
Definition WsfCommComponentHW_Subsurface.cpp:96
ComponentHW()
Definition WsfCommComponentHW.cpp:56
Definition WsfCommResult.hpp:34
Definition WsfComm.cpp:34
Function definitions for those who need run-time access to the version.
Definition WsfComm.cpp:32
Copyrights Multiple, All Rights Reserved