active_receiver->agc_hang_threshold=(int)gtk_range_get_value(GTK_RANGE(widget));
if(active_receiver->agc==AGC_LONG || active_receiver->agc==AGC_SLOW) {
SetRXAAGCHangThreshold(active_receiver->id, (int)active_receiver->agc_hang_threshold);
+ //
+ // recalculate position of hang line for panadapter
+ //
+ GetRXAAGCHangLevel(active_receiver->id, &active_receiver->agc_hang);
}
}
SetRXAAGCHangThreshold(rx->id,100);
break;
}
+ //
+ // Determine the "panadapter" AGC line positions. These are re-calculated
+ // the first time the AGC slider is moved, but we need correct values
+ // until then.
+ //
+ GetRXAAGCHangLevel(rx->id, &rx->agc_hang);
+ GetRXAAGCThresh(rx->id, &rx->agc_thresh, 4096.0, (double)rx->sample_rate);
}
void set_offset(RECEIVER *rx,long long offset) {
return;
}
#endif
+ //
+ // re-calculate AGC line for panadapter since it depends on sample rate
+ //
+ GetRXAAGCThresh(rx->id, &rx->agc_thresh, 4096.0, (double)rx->sample_rate);
if (rx->audio_output_buffer != NULL) {
g_free(rx->audio_output_buffer);
}