STAR
Cal STAR — firmware, DAQ server, and engine design
Loading...
Searching...
No Matches
CalibratedPTMessage.hpp
Go to the documentation of this file.
1
#ifndef CALIBRATED_PT_MESSAGE_HPP
2
#define CALIBRATED_PT_MESSAGE_HPP
3
4
#include <array>
5
#include <cstdint>
6
7
#include "
../../CommsMessage.hpp
"
8
9
namespace
comms
{
10
namespace
messages
{
11
namespace
sensor
{
12
13
/**
14
* @brief Calibrated Pressure Transducer message for Elodin
15
*
16
* Contains both raw ADC counts and calibrated pressure in PSI.
17
* This message is published alongside RawPTMessage for calibrated sensors.
18
*
19
* Layout: uint64_t (8) + uint8_t (1) + padding[3] (3) + float (4) + uint32_t (4) + uint8_t (1) = 21
20
* bytes
21
*/
22
using
CalibratedPTMessage
=
23
CommsMessage
<uint64_t,
// (0) timestamp_ns - monotonic timestamp in nanoseconds
24
uint8_t,
// (1) channel_id - sensor channel identifier
25
std::array<uint8_t, 3>,
// (2) padding - 3 bytes to align float to 4-byte boundary
26
float,
// (3) calibrated_pressure_psi - calibrated pressure in PSI
27
uint32_t,
// (4) raw_adc_counts - raw ADC reading (for reference)
28
uint8_t
// (5) calibration_status - 0=uncalibrated, 1=calibrated
29
>;
30
31
}
// namespace sensor
32
}
// namespace messages
33
}
// namespace comms
34
35
#endif
// CALIBRATED_PT_MESSAGE_HPP
CommsMessage.hpp
comms::messages::sensor
Definition
CalibratedPTMessage.hpp:11
comms::messages::sensor::CalibratedPTMessage
CommsMessage< uint64_t, uint8_t, std::array< uint8_t, 3 >, float, uint32_t, uint8_t > CalibratedPTMessage
Calibrated Pressure Transducer message for Elodin.
Definition
CalibratedPTMessage.hpp:22
comms::messages
Definition
BoardHeartbeatMessage.hpp:9
comms
Central message header for all communication messages.
Definition
CommsMessage.hpp:11
comms::CommsMessage
CommsMessage - Template-based message serialization.
Definition
CommsMessage.hpp:24
daq-server
diablo_server
transport
include
comms
messages
sensor
CalibratedPTMessage.hpp
Generated by
1.15.0