fix high cpu load
This commit is contained in:
parent
667ae76821
commit
a3875721a2
1 changed files with 4 additions and 1 deletions
|
@ -24,7 +24,10 @@ fn main() {
|
||||||
let radio_data_new = match flrig::get_radio_data(&settings.flrig.host, &settings.flrig.port)
|
let radio_data_new = match flrig::get_radio_data(&settings.flrig.host, &settings.flrig.port)
|
||||||
{
|
{
|
||||||
Ok(res) => res,
|
Ok(res) => res,
|
||||||
Err(_) => continue,
|
Err(_) => {
|
||||||
|
thread::sleep(Duration::from_secs(3));
|
||||||
|
continue;
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
if radio_data_current.frequency != radio_data_new.frequency
|
if radio_data_current.frequency != radio_data_new.frequency
|
||||||
|
|
Loading…
Reference in a new issue