diff --git a/src/config.rs b/src/config.rs index ceedee1..6886844 100644 --- a/src/config.rs +++ b/src/config.rs @@ -36,7 +36,7 @@ pub struct Config { short = 'i', long, action = ArgAction::Set, - default_value = "1000", + default_value = "2000", help = "Update interval", long_help = "Set the duration of the interval between two updates (milliseconds)" )] diff --git a/src/main.rs b/src/main.rs index db28fe3..f97ff13 100644 --- a/src/main.rs +++ b/src/main.rs @@ -23,9 +23,9 @@ use crate::config::Config; use crate::errors::WavelogHamlibError; use crate::wavelog::Update; use clap::Parser; +use hamlib_client::adif::Mode; use hamlib_client::RigCtlClient; use std::time::Duration; -use hamlib_client::adif::Mode; use tokio::time::sleep; #[tokio::main] @@ -104,6 +104,6 @@ async fn program(configuration: &Config) -> Result<(), WavelogHamlibError> { } log::debug!("Sleeping"); - sleep(Duration::from_millis(1000)).await; + sleep(Duration::from_millis(configuration.interval)).await; } }