refactor: create network module

- move NetworkMode and SntpMode enums
This commit is contained in:
2026-05-17 12:19:22 +02:00
parent 2cfb2607a9
commit cd4d0cc683
2 changed files with 33 additions and 27 deletions

View File

@@ -0,0 +1,19 @@
use alloc::string::String;
use chrono::{DateTime, Utc};
use serde::Serialize;
#[derive(Serialize, Debug, PartialEq)]
pub enum SntpMode {
OFFLINE,
SYNC { current: DateTime<Utc> },
}
#[derive(Serialize, Debug, PartialEq)]
pub enum NetworkMode {
WIFI {
sntp: SntpMode,
mqtt: bool,
ip_address: String,
},
OFFLINE,
}