class FGATCController NOTE: this class serves as an abstraction layer for all sorts of ATC controllers.
More...
#include <ATCController.hxx>
Inherited by EnRouteController, FGApproachController, FGGroundController, FGStartupController, and FGTowerController.
|
enum | AtcMsgId {
MSG_ANNOUNCE_ENGINE_START
, MSG_REQUEST_ENGINE_START
, MSG_PERMIT_ENGINE_START
, MSG_DENY_ENGINE_START
,
MSG_ACKNOWLEDGE_ENGINE_START
, MSG_REQUEST_PUSHBACK_CLEARANCE
, MSG_PERMIT_PUSHBACK_CLEARANCE
, MSG_HOLD_PUSHBACK_CLEARANCE
,
MSG_ACKNOWLEDGE_SWITCH_GROUND_FREQUENCY
, MSG_INITIATE_CONTACT
, MSG_ACKNOWLEDGE_INITIATE_CONTACT
, MSG_REQUEST_TAXI_CLEARANCE
,
MSG_ISSUE_TAXI_CLEARANCE
, MSG_ACKNOWLEDGE_TAXI_CLEARANCE
, MSG_HOLD_POSITION
, MSG_ACKNOWLEDGE_HOLD_POSITION
,
MSG_RESUME_TAXI
, MSG_ACKNOWLEDGE_RESUME_TAXI
, MSG_REPORT_RUNWAY_HOLD_SHORT
, MSG_ACKNOWLEDGE_REPORT_RUNWAY_HOLD_SHORT
,
MSG_CLEARED_FOR_TAKEOFF
, MSG_ACKNOWLEDGE_CLEARED_FOR_TAKEOFF
, MSG_SWITCH_TOWER_FREQUENCY
, MSG_ACKNOWLEDGE_SWITCH_TOWER_FREQUENCY
,
MSG_ARRIVAL
, MSG_ACKNOWLEDGE_ARRIVAL
, MSG_HOLD
, MSG_ACKNOWLEDGE_HOLD
,
MSG_CLEARED_TO_LAND
, MSG_ACKNOWLEDGE_CLEARED_TO_LAND
, MSG_TAXI_PARK
, MSG_ACKNOWLEDGE_TAXI_PARK
} |
|
enum | AtcMsgDir { ATC_AIR_TO_GROUND
, ATC_GROUND_TO_AIR
} |
|
|
| FGATCController () |
|
virtual | ~FGATCController () |
|
void | init () |
|
void | setAirportGroundRadar (SGSharedPtr< AirportGroundRadar > groundRadar) |
|
virtual void | announcePosition (int id, FGAIFlightPlan *intendedRoute, int currentRoute, double lat, double lon, double hdg, double spd, double alt, double radius, int leg, FGAIAircraft *aircraft)=0 |
|
virtual void | updateAircraftInformation (int id, SGGeod geod, double heading, double speed, double alt, double dt)=0 |
|
bool | checkTransmissionState (int minState, int MaxState, TrafficVectorIterator i, time_t now, AtcMsgId msgId, AtcMsgDir msgDir) |
|
SGSharedPtr< FGTrafficRecord > | getRecord (int id) const |
|
virtual void | handover (SGSharedPtr< FGTrafficRecord > aiObject, int leg) |
| We share the traffic record much like real life.
|
|
virtual void | signOff (int id) |
| Sign off the aircraft with the id from this controller.
|
|
bool | hasInstruction (int id) |
|
FGATCInstruction | getInstruction (int id) |
|
bool | hasActiveTraffic () |
|
TrafficVector & | getActiveTraffic () |
|
double | getDt () |
|
void | setDt (double dt) |
|
void | transmit (FGTrafficRecord *rec, FGAirportDynamics *parent, AtcMsgId msgId, AtcMsgDir msgDir, bool audible) |
|
std::string | getGateName (FGAIAircraft *aircraft) |
|
virtual void | render (bool)=0 |
|
virtual std::string | getName () const =0 |
|
virtual void | update (double)=0 |
|
class FGATCController NOTE: this class serves as an abstraction layer for all sorts of ATC controllers.
Definition at line 71 of file ATCController.hxx.
◆ AtcMsgDir
◆ AtcMsgId
Enumerator |
---|
MSG_ANNOUNCE_ENGINE_START | |
MSG_REQUEST_ENGINE_START | |
MSG_PERMIT_ENGINE_START | |
MSG_DENY_ENGINE_START | |
MSG_ACKNOWLEDGE_ENGINE_START | |
MSG_REQUEST_PUSHBACK_CLEARANCE | |
MSG_PERMIT_PUSHBACK_CLEARANCE | |
MSG_HOLD_PUSHBACK_CLEARANCE | |
MSG_ACKNOWLEDGE_SWITCH_GROUND_FREQUENCY | |
MSG_INITIATE_CONTACT | |
MSG_ACKNOWLEDGE_INITIATE_CONTACT | |
MSG_REQUEST_TAXI_CLEARANCE | |
MSG_ISSUE_TAXI_CLEARANCE | |
MSG_ACKNOWLEDGE_TAXI_CLEARANCE | |
MSG_HOLD_POSITION | |
MSG_ACKNOWLEDGE_HOLD_POSITION | |
MSG_RESUME_TAXI | |
MSG_ACKNOWLEDGE_RESUME_TAXI | |
MSG_REPORT_RUNWAY_HOLD_SHORT | |
MSG_ACKNOWLEDGE_REPORT_RUNWAY_HOLD_SHORT | |
MSG_CLEARED_FOR_TAKEOFF | |
MSG_ACKNOWLEDGE_CLEARED_FOR_TAKEOFF | |
MSG_SWITCH_TOWER_FREQUENCY | |
MSG_ACKNOWLEDGE_SWITCH_TOWER_FREQUENCY | |
MSG_ARRIVAL | |
MSG_ACKNOWLEDGE_ARRIVAL | |
MSG_HOLD | |
MSG_ACKNOWLEDGE_HOLD | |
MSG_CLEARED_TO_LAND | |
MSG_ACKNOWLEDGE_CLEARED_TO_LAND | |
MSG_TAXI_PARK | |
MSG_ACKNOWLEDGE_TAXI_PARK | |
Definition at line 100 of file ATCController.hxx.
◆ FGATCController()
FGATCController::FGATCController |
( |
| ) |
|
◆ ~FGATCController()
FGATCController::~FGATCController |
( |
| ) |
|
|
virtual |
◆ announcePosition()
virtual void FGATCController::announcePosition |
( |
int | id, |
|
|
FGAIFlightPlan * | intendedRoute, |
|
|
int | currentRoute, |
|
|
double | lat, |
|
|
double | lon, |
|
|
double | hdg, |
|
|
double | spd, |
|
|
double | alt, |
|
|
double | radius, |
|
|
int | leg, |
|
|
FGAIAircraft * | aircraft ) |
|
pure virtual |
◆ checkTransmissionState()
◆ clearTrafficControllers()
void FGATCController::clearTrafficControllers |
( |
| ) |
|
|
protected |
◆ eraseDeadTraffic()
void FGATCController::eraseDeadTraffic |
( |
| ) |
|
|
protected |
◆ formatATCFrequency3_2()
string FGATCController::formatATCFrequency3_2 |
( |
int | freq | ) |
|
|
protected |
◆ genTransponderCode()
string FGATCController::genTransponderCode |
( |
const std::string & | fltRules | ) |
|
|
protected |
◆ getActiveTraffic()
◆ getDt()
double FGATCController::getDt |
( |
| ) |
|
|
inline |
◆ getFrequency()
virtual int FGATCController::getFrequency |
( |
| ) |
|
|
protectedpure virtual |
◆ getGateName()
string FGATCController::getGateName |
( |
FGAIAircraft * | aircraft | ) |
|
◆ getInstruction()
◆ getName()
virtual std::string FGATCController::getName |
( |
| ) |
const |
|
pure virtual |
◆ getRecord()
◆ handover()
void FGATCController::handover |
( |
SGSharedPtr< FGTrafficRecord > | aiObject, |
|
|
int | leg ) |
|
virtual |
We share the traffic record much like real life.
It gets handed from one controller to the next.
- Parameters
-
Reimplemented in FGGroundController.
Definition at line 443 of file ATCController.cxx.
◆ hasActiveTraffic()
bool FGATCController::hasActiveTraffic |
( |
| ) |
|
|
inline |
◆ hasInstruction()
bool FGATCController::hasInstruction |
( |
int | id | ) |
|
◆ init()
void FGATCController::init |
( |
| ) |
|
◆ isUserAircraft()
◆ render()
virtual void FGATCController::render |
( |
bool | | ) |
|
|
pure virtual |
◆ searchActiveTraffic()
Search activeTraffic vector to find matching id.
- Parameters
-
id | integer to search for in the vector |
- Returns
- the matching item OR activeTraffic.end()
Definition at line 582 of file ATCController.cxx.
◆ setAirportGroundRadar()
void FGATCController::setAirportGroundRadar |
( |
SGSharedPtr< AirportGroundRadar > | groundRadar | ) |
|
◆ setDt()
void FGATCController::setDt |
( |
double | dt | ) |
|
|
inline |
◆ signOff()
void FGATCController::signOff |
( |
int | id | ) |
|
|
virtual |
◆ transmit()
◆ update()
virtual void FGATCController::update |
( |
double | | ) |
|
|
pure virtual |
◆ updateAircraftInformation()
virtual void FGATCController::updateAircraftInformation |
( |
int | id, |
|
|
SGGeod | geod, |
|
|
double | heading, |
|
|
double | speed, |
|
|
double | alt, |
|
|
double | dt ) |
|
pure virtual |
◆ _isDestroying
bool FGATCController::_isDestroying = false |
|
protected |
◆ activeTraffic
◆ airportGroundRadar
◆ available
bool FGATCController::available |
|
protected |
◆ dt_count
double FGATCController::dt_count |
|
protected |
◆ generator
std::default_random_engine FGATCController::generator |
|
protected |
◆ group
osg::Group* FGATCController::group |
|
protected |
◆ initialized
bool FGATCController::initialized |
|
protected |
◆ lastTransmission
time_t FGATCController::lastTransmission |
|
protected |
◆ parent
The documentation for this class was generated from the following files: