lotus_extra/messages/
technical.rs

1use lotus_script::prelude::*;
2use serde::{Deserialize, Serialize};
3
4//===================================================================
5// Kehrwert vom Moment of Inertia (kgm²)
6//===================================================================
7
8/// Communication of the rotational inertia of mechanical components, typical
9/// example: Engine ==> Transmission
10/// Target is always the parent
11#[derive(Debug, Copy, Clone, Serialize, Deserialize, PartialEq)]
12pub struct InvMomentOfInertia(pub f32);
13
14message_type!(InvMomentOfInertia, "Technical", "InvMomentOfInertia");
15
16//===================================================================
17// Torque (Nm)
18//===================================================================
19
20/// Communication of the torque of mechanical components, typical
21/// example: Engine ==> Transmission
22/// Target is always the parent
23#[derive(Debug, Copy, Clone, Serialize, Deserialize, PartialEq)]
24pub struct Torque(pub f32);
25
26message_type!(Torque, "Technical", "Torque");
27
28//===================================================================
29// Rotation Speed (revolutions per minute)
30//===================================================================
31
32/// Communication of the rotational speed of mechanical components, typical
33/// example: Transmission ==> Engine
34/// Target is always the parent
35#[derive(Debug, Copy, Clone, Serialize, Deserialize, PartialEq)]
36pub struct RotationSpeed(pub f32);
37
38message_type!(RotationSpeed, "Technical", "RotationSpeed");