mirror of
https://github.com/AlexandreRouma/SDRPlusPlus.git
synced 2025-06-26 12:27:51 +02:00
@ -95,7 +95,7 @@ public:
|
||||
|
||||
refresh();
|
||||
|
||||
config.aquire();
|
||||
config.acquire();
|
||||
std::string confSerial = config.conf["device"];
|
||||
config.release();
|
||||
selectBySerial(confSerial);
|
||||
@ -151,7 +151,7 @@ public:
|
||||
}
|
||||
|
||||
bool created = false;
|
||||
config.aquire();
|
||||
config.acquire();
|
||||
if (!config.conf["devices"].contains(serial)) {
|
||||
config.conf["devices"][serial]["sampleRate"] = 2000000;
|
||||
config.conf["devices"][serial]["biasT"] = false;
|
||||
@ -280,7 +280,7 @@ private:
|
||||
ImGui::SetNextItemWidth(menuWidth);
|
||||
if (ImGui::Combo(CONCAT("##_hackrf_dev_sel_", _this->name), &_this->devId, _this->devListTxt.c_str())) {
|
||||
_this->selectedSerial = _this->devList[_this->devId];
|
||||
config.aquire();
|
||||
config.acquire();
|
||||
config.conf["device"] = _this->selectedSerial;
|
||||
config.release(true);
|
||||
}
|
||||
@ -288,7 +288,7 @@ private:
|
||||
if (ImGui::Combo(CONCAT("##_hackrf_sr_sel_", _this->name), &_this->srId, sampleRatesTxt)) {
|
||||
_this->sampleRate = sampleRates[_this->srId];
|
||||
core::setInputSampleRate(_this->sampleRate);
|
||||
config.aquire();
|
||||
config.acquire();
|
||||
config.conf["devices"][_this->selectedSerial]["sampleRate"] = _this->sampleRate;
|
||||
config.release(true);
|
||||
}
|
||||
@ -309,7 +309,7 @@ private:
|
||||
if (_this->running) {
|
||||
hackrf_set_baseband_filter_bandwidth(_this->openDev, _this->bandwidthIdToBw(_this->bwId));
|
||||
}
|
||||
config.aquire();
|
||||
config.acquire();
|
||||
config.conf["devices"][_this->selectedSerial]["bandwidth"] = _this->bwId;
|
||||
config.release(true);
|
||||
}
|
||||
@ -318,7 +318,7 @@ private:
|
||||
if (_this->running) {
|
||||
hackrf_set_antenna_enable(_this->openDev, _this->biasT);
|
||||
}
|
||||
config.aquire();
|
||||
config.acquire();
|
||||
config.conf["devices"][_this->selectedSerial]["biasT"] = _this->biasT;
|
||||
config.release(true);
|
||||
}
|
||||
@ -327,7 +327,7 @@ private:
|
||||
if (_this->running) {
|
||||
hackrf_set_amp_enable(_this->openDev, _this->amp);
|
||||
}
|
||||
config.aquire();
|
||||
config.acquire();
|
||||
config.conf["devices"][_this->selectedSerial]["amp"] = _this->amp;
|
||||
config.release(true);
|
||||
}
|
||||
@ -339,7 +339,7 @@ private:
|
||||
if (_this->running) {
|
||||
hackrf_set_lna_gain(_this->openDev, _this->lna);
|
||||
}
|
||||
config.aquire();
|
||||
config.acquire();
|
||||
config.conf["devices"][_this->selectedSerial]["lnaGain"] = (int)_this->lna;
|
||||
config.release(true);
|
||||
}
|
||||
@ -351,7 +351,7 @@ private:
|
||||
if (_this->running) {
|
||||
hackrf_set_vga_gain(_this->openDev, _this->vga);
|
||||
}
|
||||
config.aquire();
|
||||
config.acquire();
|
||||
config.conf["devices"][_this->selectedSerial]["vgaGain"] = (int)_this->vga;
|
||||
config.release(true);
|
||||
}
|
||||
|
Reference in New Issue
Block a user