Helper class to trace LEO constellation mobility and/or antenna pointing. More...
Public Member Functions | |
| LeoConstellationTracer (Ptr< Node > groundNode, LeoMode mode, Ptr< ThreeGppPropagationLossModel > propagationLossModel, Vector groundNodePosGEO, Vector groundNodePosECEF, std::ostream *traceStream) | |
| Construct a LeoConstellationTracer. | |
| void | CourseChange (Ptr< const MobilityModel > mob) const |
| CourseChange callback that outputs trace data. | |
| Vector | GeneratePoint (const Vector &nodePosECEF, const double azimuth, const double inclination) const |
| Compute a point along a satellite's antenna pointing direction. | |
| void | UpdateAntennaOrientation (Ptr< Node > node, Time period) const |
| Periodically steer a satellite node's antenna toward the ground station. | |
Private Attributes | |
| Ptr< Node > | m_groundNode |
| Ground station node. | |
| Vector | m_groundNodePosECEF |
| Ground station ECEF position. | |
| Vector | m_groundNodePosGEO |
| Ground station geodetic position. | |
| LeoMode | m_mode |
| Simulation mode. | |
| Ptr< ThreeGppPropagationLossModel > | m_propagationLossModel |
| Propagation loss model. | |
| std::ostream * | m_traceStream |
| Output stream for trace data. | |
Helper class to trace LEO constellation mobility and/or antenna pointing.
This tracer periodically updates satellite antenna orientation toward a fixed ground station, optionally computes propagation loss, and outputs trace data including satellite position, antenna pointing vector endpoints, path loss, slant distance, and elevation angle.
Definition at line 95 of file leo-satellite-example.cc.
|
inline |
Construct a LeoConstellationTracer.
| groundNode | Pointer to the ground station node. |
| mode | The simulation mode. |
| propagationLossModel | The propagation loss model (can be null for non-channel modes). |
| groundNodePosGEO | Ground station geodetic position (lat/lon/alt). |
| groundNodePosECEF | Ground station ECEF position (x/y/z in meters). |
| traceStream | Output stream for trace data. |
Definition at line 108 of file leo-satellite-example.cc.
References m_groundNode, m_groundNodePosECEF, m_groundNodePosGEO, m_mode, m_propagationLossModel, m_traceStream, and propagationLossModel.
| void LeoConstellationTracer::CourseChange | ( | Ptr< const MobilityModel > | mob | ) | const |
CourseChange callback that outputs trace data.
The output columns depend on the mode:
| mob | the satellite mobility model that changed course. |
Definition at line 251 of file leo-satellite-example.cc.
References Antenna, ns3::GeographicPositions::CartesianToGeographicCoordinates(), Channel, ns3::ConstCast(), GeneratePoint(), ns3::GeographicPositions::GeographicToTopocentricCoordinates(), ns3::Angles::GetInclination(), groundStation, m_groundNode, m_mode, m_propagationLossModel, ns3::Simulator::Now(), Orbit, ns3::RadiansToDegrees(), and ns3::GeographicPositions::SPHERE.
| Vector LeoConstellationTracer::GeneratePoint | ( | const Vector & | nodePosECEF, |
| const double | azimuth, | ||
| const double | inclination ) const |
Compute a point along a satellite's antenna pointing direction.
Given a satellite position in ECEF and its antenna azimuth and inclination angles, this function returns a second ECEF point at the end of the antenna orientation vector (whose length equals the satellite-to-ground-station distance). The two points can be used to visualize the antenna pointing direction.
| nodePosECEF | the satellite node ECEF position. |
| azimuth | the antenna azimuth angle in radians. |
| inclination | the antenna inclination angle in radians. |
Definition at line 209 of file leo-satellite-example.cc.
References ns3::GeographicPositions::CartesianToGeographicCoordinates(), ns3::GeographicPositions::GeographicToCartesianCoordinates(), groundStation, ns3::GeographicPositions::SPHERE, and ns3::GeographicPositions::TopocentricToGeographicCoordinates().
Referenced by CourseChange().
Periodically steer a satellite node's antenna toward the ground station.
The antenna angles are computed from the relative position between the satellite and a fixed ground station, then applied to the node's uniform planar antenna array.
| node | the satellite node. |
| period | the interval at which to update the antenna angles (seconds). |
Definition at line 175 of file leo-satellite-example.cc.
References ns3::GeographicPositions::CartesianToGeographicCoordinates(), ns3::GeographicPositions::GeographicToTopocentricCoordinates(), ns3::Angles::GetAzimuth(), ns3::Angles::GetInclination(), groundStation, ns3::Simulator::Schedule(), ns3::UniformPlanarArray::SetAlpha(), ns3::GeographicPositions::SPHERE, and UpdateAntennaOrientation().
Referenced by UpdateAntennaOrientation().
Ground station node.
Definition at line 167 of file leo-satellite-example.cc.
Referenced by LeoConstellationTracer(), and CourseChange().
|
private |
Ground station ECEF position.
Definition at line 170 of file leo-satellite-example.cc.
Referenced by LeoConstellationTracer().
|
private |
Ground station geodetic position.
Definition at line 169 of file leo-satellite-example.cc.
Referenced by LeoConstellationTracer().
|
private |
Simulation mode.
Definition at line 166 of file leo-satellite-example.cc.
Referenced by LeoConstellationTracer(), and CourseChange().
|
private |
Propagation loss model.
Definition at line 168 of file leo-satellite-example.cc.
Referenced by LeoConstellationTracer(), and CourseChange().
|
private |
Output stream for trace data.
Definition at line 171 of file leo-satellite-example.cc.
Referenced by LeoConstellationTracer().