Skip to content
Snippets Groups Projects
Commit 49a1bf00 authored by David Maul's avatar David Maul :crab:
Browse files

fix: replace c++ enum definition with c enum definition

parent 215aa909
Branches
No related tags found
No related merge requests found
......@@ -11,13 +11,13 @@
typedef s32 int32_t;
typedef s64 int64_t;
#else
#include <stdint.h>
#include <stddef.h>
#include <stdint.h>
#endif
#define MAX_MESSAGE_DATA_SIZE 4096
typedef enum message_data_type : uint32_t {
enum message_data_type {
INT8,
UINT8,
INT16,
......@@ -28,13 +28,18 @@ typedef enum message_data_type : uint32_t {
UINT64,
FLOAT32,
FLOAT64
} message_data_type_t;
};
typedef uint32_t message_data_type_t;
/**
* typedef message_t - Structure to hold a message with a measurement.
* @measurement_id: The id of the measurement. Every sender should have a unique id.
* @daemon_measurement_datatype: Datatype of the data. All values in `data` must be of this type.
* @length: How many types of `datatype` are in `data`. Must not exceed (`length` * daemon_measurement_datatype_size(`datatype`)) > MAX_DAEMON_PACKET_DATA_SIZE.
* @measurement_id: The id of the measurement. Every sender should have a unique
* id.
* @daemon_measurement_datatype: Datatype of the data. All values in `data` must
* be of this type.
* @length: How many types of `datatype` are in `data`. Must not exceed
* (`length` * daemon_measurement_datatype_size(`datatype`)) >
* MAX_DAEMON_PACKET_DATA_SIZE.
* @data: The measurement data.
*/
typedef struct message {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment