/workspaces/astro/sol3-sdk/cpp/sol3/camera_module/camera_msg_spec.h Source File

Space-ng SDK: /workspaces/astro/sol3-sdk/cpp/sol3/camera_module/camera_msg_spec.h Source File
Space-ng SDK
camera_msg_spec.h
Go to the documentation of this file.
1 // Copyright (c) Space-ng, inc. All rights reserved.
2 
3 #pragma once
4 #include "sol3/base_unit/msg/component_id.h"
5 #include "sol3/camera_module/msg/camera_control.h"
6 #include "sol3/camera_module/msg/camera_frame.h"
7 #include "sol3/camera_module/msg/camera_snapshot_control.h"
8 #include "sol3/camera_module/msg/camera_snapshot_telemetry.h"
9 #include "sol3/camera_module/msg/video_encoded_packet.h"
10 #include "sol3/core/message_spec.h"
11 
12 #include <cstdint>
13 
14 namespace sol3::camera_module {
19  using CameraControl =
21 
25  core::msg::InterfaceType_INPUT,
26  1>;
27 
28  using RawFrame =
30 
31  using YuvFrame =
33 
36 
37  using VideoEncodedPacket = core::
38  MessageSpec<msg::VideoEncodedPacket, core::msg::InterfaceType_OUTPUT, 4>;
39 
51 
55  core::msg::InterfaceType_OUTPUT,
56  6>;
57 
62  static char constexpr const* camera_endpoint = "/run/sol3/camera";
67  static char constexpr const* control_endpoint = "/run/sol3/camera_control";
68 
70  static char constexpr const* camera_server_config_path =
71  "/opt/sol3/etc/camera_server/camera_server_config.json";
72 };
73 
74 bool isCameraComponent(uint32_t component_id);
75 uint32_t getCameraComponentId(uint32_t cam_id);
76 uint32_t getCameraId(uint32_t component_id);
77 
78 } // namespace sol3::camera_module
table CameraSnapshotControl
Definition: camera_snapshot_control.fbs:8
root_type CameraSnapshotTelemetry
Definition: camera_snapshot_telemetry.fbs:26
Definition: camera_component.h:8
uint32_t getCameraId(uint32_t component_id)
uint32_t getCameraComponentId(uint32_t cam_id)
bool isCameraComponent(uint32_t component_id)
Message specifications and endpoints for the camera module.
Definition: camera_msg_spec.h:16
static constexpr char const * camera_endpoint
Definition: camera_msg_spec.h:62
static constexpr char const * camera_server_config_path
The default path the the camera server configuration file.
Definition: camera_msg_spec.h:70
static constexpr char const * control_endpoint
Definition: camera_msg_spec.h:67
Compile time message type and id specification.
Definition: message_spec.h:15