pub struct Soc {
pub total_voltage: f32,
pub current: f32,
pub soc_percent: f32,
}Expand description
Represents the State of Charge (SOC) and related battery metrics.
Fields§
§total_voltage: f32Total battery voltage in Volts.
current: f32Battery current in Amperes. Negative values indicate charging, positive values indicate discharging.
soc_percent: f32State of Charge percentage (0.0 - 100.0%).
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Soc
impl<'de> Deserialize<'de> for Soc
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for Soc
impl RefUnwindSafe for Soc
impl Send for Soc
impl Sync for Soc
impl Unpin for Soc
impl UnwindSafe for Soc
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more