/ bm_seapoint_turbidity_data_msg.h
bm_seapoint_turbidity_data_msg.h
 1  #pragma once
 2  #include "cbor.h"
 3  #include "sensor_header_msg.h"
 4  
 5  // For the Seapoint STM-S Turbidity Sensor
 6  
 7  namespace BmSeapointTurbidityDataMsg {
 8  
 9  constexpr uint32_t VERSION = 1;
10  constexpr size_t NUM_FIELDS = 2 + SensorHeaderMsg::NUM_FIELDS;
11  
12  struct Data {
13    SensorHeaderMsg::Data header;
14    double s_signal;
15    double r_signal;
16  };
17  
18  CborError encode(Data &d, uint8_t *cbor_buffer, size_t size,
19                   size_t *encoded_len);
20  
21  CborError decode(Data &d, const uint8_t *cbor_buffer, size_t size);
22  
23  } // namespace BmSeapointTurbidityDataMsg