syrlinks hk handler complete

This commit is contained in:
2021-03-01 12:23:39 +01:00
parent f761789154
commit 22f8f370e4
7 changed files with 106 additions and 65 deletions

View File

@ -17,7 +17,8 @@ namespace SYRLINKS {
static const DeviceCommandId_t ACK_REPLY = 0x06;
static const DeviceCommandId_t READ_TX_STATUS = 0x07;
static const DeviceCommandId_t READ_TX_WAVEFORM = 0x08;
static const DeviceCommandId_t READ_TX_AGC_VALUE = 0x09;
static const DeviceCommandId_t READ_TX_AGC_VALUE_HIGH_BYTE = 0x09;
static const DeviceCommandId_t READ_TX_AGC_VALUE_LOW_BYTE = 0x0A;
/** Size of a simple transmission success response */
static const uint8_t ACK_SIZE = 11;
@ -26,12 +27,10 @@ namespace SYRLINKS {
static const uint8_t MESSAGE_HEADER_SIZE = 5;
/** Size of reply to an rx status registers request */
static const uint8_t RX_STATUS_REGISTERS_REPLY_SIZE = 49;
static const uint8_t READ_TX_STATUS_REPLY_SIZE = 13;
static const uint8_t READ_TX_WAVEFORM_REPLY_SIZE = 13;
static const uint8_t READ_TX_AGC_VALUE_REPLY_SIZE = 15;
static const uint8_t READ_ONE_REGISTER_REPLY_SIE = 13;
static const uint8_t RX_DATASET_ID = READ_RX_STATUS_REGISTERS;
static const uint8_t TX_DATASET_ID = READ_TX_STATUS;
static const uint8_t RX_DATASET_ID = 0x1;
static const uint8_t TX_DATASET_ID = 0x2;
static const size_t MAX_REPLY_SIZE = RX_STATUS_REGISTERS_REPLY_SIZE;
static const size_t MAX_COMMAND_SIZE = 15;
@ -39,7 +38,7 @@ namespace SYRLINKS {
static const size_t CRC_FIELD_SIZE = 4;
static const uint8_t RX_DATASET_SIZE = 8;
static const uint8_t TX_DATASET_SIZE = 1;
static const uint8_t TX_DATASET_SIZE = 3;
enum SyrlinksPoolIds: lp_id_t {
RX_STATUS,