фикс ошибок применения rx/tx параметров
This commit is contained in:
parent
df4b990316
commit
90b1f221ea
@ -554,8 +554,8 @@ void api_driver::ApiDriver::setRxTxSettings(boost::property_tree::ptree &pt) {
|
||||
|
||||
// демодулятор
|
||||
tmp = pt.get<std::string>(json_path("rx.gainMode", '/'));
|
||||
if (tmp == "normal") { demod.is_aru_on = true; }
|
||||
else if (tmp == "test") { demod.is_aru_on = false; }
|
||||
if (tmp == "auto") { demod.is_aru_on = true; }
|
||||
else if (tmp == "manual") { demod.is_aru_on = false; }
|
||||
else { throw std::runtime_error("api_driver::ApiDriver::setRxTxSettings(): Wrong gain mode: " + tmp); }
|
||||
demod.gain = pt.get<double>(json_path("rx.manualGain", '/'));
|
||||
demod.baudrate = pt.get<uint32_t>(json_path("rx.cymRate", '/'));
|
||||
@ -570,9 +570,9 @@ void api_driver::ApiDriver::setRxTxSettings(boost::property_tree::ptree &pt) {
|
||||
acm.snr_treashold_acm = pt.get<double>(json_path("dvbs2.snrReserve", '/')); // запас ОСШ
|
||||
acm.period_pack = pt.get<uint32_t>(json_path("dvbs2.servicePacketPeriod", '/'));
|
||||
acm.enable_auto_atten = pt.get<bool>(json_path("acm.en", '/'));
|
||||
acm.max_attenuation = pt.get<double>(json_path("dvbs2.maxAttenuation", '/'));
|
||||
acm.min_attenuation = pt.get<double>(json_path("dvbs2.minAttenuation", '/'));
|
||||
acm.snr_treashold = pt.get<double>(json_path("dvbs2.requiredSnr", '/')); // требуемый ОСШ
|
||||
acm.max_attenuation = pt.get<double>(json_path("acm.maxAttenuation", '/'));
|
||||
acm.min_attenuation = pt.get<double>(json_path("acm.minAttenuation", '/'));
|
||||
acm.snr_treashold = pt.get<double>(json_path("acm.requiredSnr", '/')); // требуемый ОСШ
|
||||
|
||||
daemon->setSettingsRxTx(mod, demod, acm);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user