mirror of
https://github.com/f4exb/sdrangel.git
synced 2026-06-06 16:05:13 -04:00
Settings.
This commit is contained in:
@@ -95,7 +95,7 @@ bool V4LGui::handleMessage(Message* message)
|
||||
void V4LGui::displaySettings()
|
||||
{
|
||||
ui->centerFrequency->setValue(m_generalSettings.m_centerFrequency / 1000);
|
||||
ui->decimation->setValue(m_settings.m_decimation);
|
||||
ui->samplerate->setValue(m_settings.m_samplerate);
|
||||
|
||||
if(m_gains.size() > 0) {
|
||||
int dist = abs(m_settings.m_gain - m_gains[0]);
|
||||
@@ -139,10 +139,12 @@ void V4LGui::on_gain_valueChanged(int value)
|
||||
sendSettings();
|
||||
}
|
||||
|
||||
void V4LGui::on_decimation_valueChanged(int value)
|
||||
void V4LGui::on_samplerate_valueChanged(int value)
|
||||
{
|
||||
ui->decimationText->setText(tr("1:%1").arg(1 << value));
|
||||
m_settings.m_decimation = value;
|
||||
int Rates[] = { 2500, 1536, 3072, 288, 1000, 0};
|
||||
int newrate = Rates[value];
|
||||
ui->samplerateText->setText(tr("%1kHz").arg(newrate));
|
||||
m_settings.m_samplerate = 1000 * newrate;
|
||||
sendSettings();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user