use alloc::string::String;
use serde::{Deserialize, Serialize};
#[cfg(feature = "schemars")]
use schemars::JsonSchema;
#[cfg_attr(feature = "schemars", derive(JsonSchema))]
#[derive(Serialize, Deserialize, Clone, Debug, PartialEq, Eq, Hash)]
pub struct SetNetworkConnectionConfig {
pub ssid: String,
pub password: String,
}
#[cfg_attr(feature = "schemars", derive(JsonSchema))]
#[derive(Serialize, Deserialize, Clone, Debug, PartialEq, Eq, Hash)]
pub struct SetUid {
pub uid: String,
}
#[cfg_attr(feature = "schemars", derive(JsonSchema))]
#[derive(Serialize, Deserialize, Clone, Debug, PartialEq)]
pub struct SetDriveBaseVelocity {
pub left_velocity_rad_per_s: f32,
pub right_velocity_rad_per_s: f32,
}
#[cfg_attr(feature = "schemars", derive(JsonSchema))]
#[derive(Serialize, Deserialize, Clone, Debug, PartialEq)]
#[non_exhaustive]
pub enum Message {
Ping,
Pong,
RequestNetworkScan,
SetNetworkConnectionConfig(SetNetworkConnectionConfig),
SetUid(SetUid),
SetDriveBaseVelocity(SetDriveBaseVelocity),
}