|| (onBoardRadioFreqI1 == stationFreq)) {
if (rec->allowTransmissions()) {
- if( fgGetBool( "/instrumentation/use-itm-attenuation", false ) ) {
- FGRadio* radio = new FGRadio();
+ if( fgGetBool( "/sim/radio/use-itm-attenuation", false ) ) {
+ //cerr << "Using ITM radio propagation" << endl;
+ FGRadioTransmission* radio = new FGRadioTransmission();
SGGeod sender_pos;
double sender_alt_ft, sender_alt;
if(ground_to_air) {
sender_pos= SGGeod::fromDegM( rec->getLongitude(),
rec->getLatitude(), sender_alt );
}
- radio->receiveText(sender_pos, stationFreq, text, ground_to_air);
+ double frequency = ((double)stationFreq) / 100;
+ radio->receiveATC(sender_pos, frequency, text, ground_to_air);
delete radio;
}
else {