Skip to content

Commit

Permalink
Fix Formating
Browse files Browse the repository at this point in the history
  • Loading branch information
leskowicz committed Oct 24, 2024
1 parent 86b797b commit dfa84d8
Showing 1 changed file with 23 additions and 27 deletions.
50 changes: 23 additions & 27 deletions src/point_one/fusion_engine/messages/uart_to_st5635.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,48 +37,44 @@ namespace messages {
* MessageType::COMMAND_RESPONSE, version 1.0).
* @ingroup device_control
*/
struct P1_ALIGNAS(4) SpiCmdResponse : public MessagePayload {
static constexpr MessageType MESSAGE_TYPE = MessageType::SPI_CMD_RESPONSE;
static constexpr uint8_t MESSAGE_VERSION = 0;

int64_t system_time_ns = 0;
uint8_t data_0 = 0;
uint8_t data_1 = 0;
uint8_t data_2 = 0;
uint8_t data_3 = 0;
};
struct P1_ALIGNAS(4) SpiCmdResponse : public MessagePayload {
static constexpr MessageType MESSAGE_TYPE = MessageType::SPI_CMD_RESPONSE;
static constexpr uint8_t MESSAGE_VERSION = 0;

int64_t system_time_ns = 0;
uint8_t data_0 = 0;
uint8_t data_1 = 0;
uint8_t data_2 = 0;
uint8_t data_3 = 0;
};

/**
* @brief SPI Command to be sent to ST5635 (@ref
* MessageType::SPI_CMD, version 1.0).
* @ingroup device_control
*/
struct P1_ALIGNAS(4) SpiCmd : public MessagePayload {
static constexpr MessageType MESSAGE_TYPE = MessageType::SPI_CMD;
static constexpr uint8_t MESSAGE_VERSION = 0;

uint8_t cmd = 0;
uint8_t address = 0;
uint8_t val1 = 0;
uint8_t val2 = 0;
};
struct P1_ALIGNAS(4) SpiCmd : public MessagePayload {
static constexpr MessageType MESSAGE_TYPE = MessageType::SPI_CMD;
static constexpr uint8_t MESSAGE_VERSION = 0;

uint8_t cmd = 0;
uint8_t address = 0;
uint8_t val1 = 0;
uint8_t val2 = 0;
};

/**
* @brief L-band frame contents from ST5635 (@ref
* MessageType::SPI_LBAND_PACKET, version 1.0).
* @ingroup device_control
*/
struct P1_ALIGNAS(4) SpiLbandPacket : public MessagePayload {
static constexpr MessageType MESSAGE_TYPE = MessageType::SPI_LBAND_PACKET;
static constexpr uint8_t MESSAGE_VERSION = 0;
uint32_t msg_counter;
uint8_t packet[260];
};


struct P1_ALIGNAS(4) SpiLbandPacket : public MessagePayload {
static constexpr MessageType MESSAGE_TYPE = MessageType::SPI_LBAND_PACKET;
static constexpr uint8_t MESSAGE_VERSION = 0;
uint32_t msg_counter;
uint8_t packet[260];
};

#pragma pack(pop)

Expand Down

0 comments on commit dfa84d8

Please sign in to comment.