diff --git a/src/config.rs b/src/config.rs index c74621d..e9fda03 100644 --- a/src/config.rs +++ b/src/config.rs @@ -50,7 +50,6 @@ pub struct ControllerSettings { pub temperature_set_point_lower: f32, pub temperature_loop_mins: u64, pub sunlight_hours: u64, - pub soil_loop_hours: u64, pub watering_frequency_hours: u64, pub watering_amount_grams: u64, } @@ -116,7 +115,6 @@ impl Default for Configuration { temperature_set_point_upper: 35., temperature_set_point_lower: 28., temperature_loop_mins: 60, - soil_loop_hours: 12, sunlight_hours: 24, watering_frequency_hours: 30, watering_amount_grams: 200, diff --git a/src/control/data_logging.rs b/src/control/data_logging.rs index e4ccd30..2885dcb 100644 --- a/src/control/data_logging.rs +++ b/src/control/data_logging.rs @@ -24,16 +24,6 @@ pub struct DataRecords { const FILE_PATH: &str = "./growpi.datalog.csv"; impl DataRecords { - fn load() -> GenericResult { - let mut data = csv::ReaderBuilder::new() - .has_headers(true) - .from_path(FILE_PATH)?; - let mut result = Vec::new(); - for record in data.deserialize() { - result.push(record?); - } - Ok(DataRecords { records: result }) - } pub fn push(program_state: ProgramStateShared) -> GenericResult<()> { let program_state = lock_state(&program_state)?; let config = &program_state.config; diff --git a/src/main.rs b/src/main.rs index 3e636df..ab14f03 100644 --- a/src/main.rs +++ b/src/main.rs @@ -1,5 +1,4 @@ #![feature(duration_constructors)] -#![allow(dead_code)] use cli_mode::run_cli; use config::Configuration;