cargo fmt
This commit is contained in:
@@ -2,10 +2,7 @@ use chrono::{DateTime, TimeDelta, Utc};
|
||||
use chrono_tz::Tz;
|
||||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
config::PlantConfig,
|
||||
in_time_range, plant_hal,
|
||||
};
|
||||
use crate::{config::PlantConfig, in_time_range, plant_hal};
|
||||
|
||||
const MOIST_SENSOR_MAX_FREQUENCY: f32 = 6500.; // 60kHz (500Hz margin)
|
||||
const MOIST_SENSOR_MIN_FREQUENCY: f32 = 150.; // this is really, really dry, think like cactus levels
|
||||
@@ -239,9 +236,7 @@ impl PlantState {
|
||||
false
|
||||
}
|
||||
}
|
||||
PlantWateringMode::TimerOnly => {
|
||||
!self.pump_in_timeout(plant_conf, current_time)
|
||||
}
|
||||
PlantWateringMode::TimerOnly => !self.pump_in_timeout(plant_conf, current_time),
|
||||
}
|
||||
}
|
||||
|
||||
@@ -308,4 +303,4 @@ pub struct PlantInfo<'a> {
|
||||
last_pump: Option<DateTime<Tz>>,
|
||||
/// next time when pump should activate
|
||||
next_pump: Option<DateTime<Tz>>,
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user