mirror of
https://github.com/intrepidcs/libicsneo.git
synced 2026-08-05 01:18:36 +02:00
Device: Add device binary export support
This commit is contained in:
@@ -0,0 +1,34 @@
|
||||
#ifndef __EXTENDEDDATAMESSAGE_H_
|
||||
#define __EXTENDEDDATAMESSAGE_H_
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
#include "icsneo/communication/message/message.h"
|
||||
#include "icsneo/communication/command.h"
|
||||
|
||||
|
||||
namespace icsneo {
|
||||
|
||||
class ExtendedDataMessage : public RawMessage {
|
||||
public:
|
||||
#pragma pack(push, 2)
|
||||
struct ExtendedDataHeader {
|
||||
ExtendedDataSubCommand subCommand;
|
||||
uint32_t userValue;
|
||||
uint32_t offset;
|
||||
uint32_t length;
|
||||
};
|
||||
#pragma pack(pop)
|
||||
|
||||
static constexpr size_t MaxExtendedDataBufferSize = 2048;
|
||||
const ExtendedDataHeader header;
|
||||
|
||||
ExtendedDataMessage(ExtendedDataHeader params) : RawMessage(Message::Type::RawMessage, Network::NetID::ExtendedData), header{params} {}
|
||||
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif // __cplusplus
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,22 @@
|
||||
#ifndef _EXTENDED_GENERIC_BINARY_STATUS_MESSAGE_H_
|
||||
#define _EXTENDED_GENERIC_BINARY_STATUS_MESSAGE_H_
|
||||
|
||||
#ifdef __cplusplus
|
||||
#include "icsneo/communication/message/extendedresponsemessage.h"
|
||||
|
||||
namespace icsneo {
|
||||
|
||||
class GenericBinaryStatusMessage : public Message {
|
||||
public:
|
||||
GenericBinaryStatusMessage() : Message(Message::Type::GenericBinaryStatus) {}
|
||||
|
||||
size_t binarySize;
|
||||
uint16_t binaryIndex;
|
||||
uint16_t binaryStatus;
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif // __cplusplus
|
||||
|
||||
#endif // _EXTENDED_GENERIC_BINARY_STATUS_RESPONSE_MESSAGE_H_
|
||||
@@ -36,6 +36,7 @@ public:
|
||||
ScriptStatus = 0x800b,
|
||||
ComponentVersions = 0x800c,
|
||||
SupportedFeatures = 0x800d,
|
||||
GenericBinaryStatus = 0x800e,
|
||||
};
|
||||
|
||||
Message(Type t) : type(t) {}
|
||||
|
||||
Reference in New Issue
Block a user