ros2_interfaces_rolling/mavros_msgs/msg/
onboard_computer_status.rs

1use serde::{Deserialize, Serialize};
2
3#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4pub struct OnboardComputerStatus {
5    pub header: crate::std_msgs::msg::Header,
6    pub component: u8,
7    pub uptime: u32,
8    #[serde(rename = "type")]    pub type_: u8,
9    pub cpu_cores: [u8; 8],
10    pub cpu_combined: [u8; 10],
11    pub gpu_cores: [u8; 4],
12    pub gpu_combined: [u8; 10],
13    pub temperature_board: i8,
14    pub temperature_core: [i8; 8],
15    pub fan_speed: [i16; 4],
16    pub ram_usage: u32,
17    pub ram_total: u32,
18    pub storage_type: [u32; 4],
19    pub storage_usage: [u32; 4],
20    pub storage_total: [u32; 4],
21    pub link_type: [u32; 6],
22    pub link_tx_rate: [u32; 6],
23    pub link_rx_rate: [u32; 6],
24    pub link_tx_max: [u32; 6],
25    pub link_rx_max: [u32; 6],
26}
27
28impl Default for OnboardComputerStatus {
29    fn default() -> Self {
30        OnboardComputerStatus {
31            header: crate::std_msgs::msg::Header::default(),
32            component: 0,
33            uptime: 0,
34            type_: 0,
35            cpu_cores: [0; 8],
36            cpu_combined: [0; 10],
37            gpu_cores: [0; 4],
38            gpu_combined: [0; 10],
39            temperature_board: 0,
40            temperature_core: [0; 8],
41            fan_speed: [0; 4],
42            ram_usage: 0,
43            ram_total: 0,
44            storage_type: [0; 4],
45            storage_usage: [0; 4],
46            storage_total: [0; 4],
47            link_type: [0; 6],
48            link_tx_rate: [0; 6],
49            link_rx_rate: [0; 6],
50            link_tx_max: [0; 6],
51            link_rx_max: [0; 6],
52        }
53    }
54}
55
56impl ros2_client::Message for OnboardComputerStatus {}