radio_tool 0.2.1
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | List of all members
radio_tool::fw::SGLHeader Class Reference
Collaboration diagram for radio_tool::fw::SGLHeader:
Collaboration graph

Public Member Functions

 SGLHeader (const uint16_t &sgl_version, const uint32_t &len, const std::string &group, const std::string &model, const std::string &version, const std::string &key, const uint8_t &binary_offset, const uint16_t &header2_offset)
 
auto ToString () const -> std::string
 
auto Serialize (bool encrypt=true) const -> std::vector< uint8_t >
 
auto AsNew (const uint32_t &binary_len) const -> const SGLHeader
 
auto IsCompatible (const SGLHeader &other) const -> bool
 

Public Attributes

const uint16_t sgl_version
 
const uint32_t length
 
const uint8_t binary_offset
 
const uint16_t header2_offset
 
const std::string radio_group
 
const std::string radio_model
 
const std::string protocol_version
 
const std::string model_key
 

Detailed Description

Definition at line 34 of file tyt_fw_sgl.hpp.

Constructor & Destructor Documentation

◆ SGLHeader()

radio_tool::fw::SGLHeader::SGLHeader ( const uint16_t &  sgl_version,
const uint32_t &  len,
const std::string &  group,
const std::string &  model,
const std::string &  version,
const std::string &  key,
const uint8_t &  binary_offset,
const uint16_t &  header2_offset 
)
inline

Definition at line 37 of file tyt_fw_sgl.hpp.

Member Function Documentation

◆ AsNew()

auto SGLHeader::AsNew ( const uint32_t &  binary_len) const -> const SGLHeader

Genrate a new instance of this header with new secret values

Definition at line 265 of file tyt_fw_sgl.cpp.

◆ IsCompatible()

auto SGLHeader::IsCompatible ( const SGLHeader other) const -> bool

Check if this header is compatible with another (excluding secrets)

Definition at line 347 of file tyt_fw_sgl.cpp.

Here is the caller graph for this function:

◆ Serialize()

auto SGLHeader::Serialize ( bool  encrypt = true) const -> std::vector<uint8_t>

Definition at line 293 of file tyt_fw_sgl.cpp.

◆ ToString()

auto SGLHeader::ToString ( ) const -> std::string

Definition at line 250 of file tyt_fw_sgl.cpp.

Member Data Documentation

◆ binary_offset

const uint8_t radio_tool::fw::SGLHeader::binary_offset

Definition at line 82 of file tyt_fw_sgl.hpp.

◆ header2_offset

const uint16_t radio_tool::fw::SGLHeader::header2_offset

Definition at line 83 of file tyt_fw_sgl.hpp.

◆ length

const uint32_t radio_tool::fw::SGLHeader::length

Definition at line 81 of file tyt_fw_sgl.hpp.

◆ model_key

const std::string radio_tool::fw::SGLHeader::model_key

Definition at line 87 of file tyt_fw_sgl.hpp.

◆ protocol_version

const std::string radio_tool::fw::SGLHeader::protocol_version

Definition at line 86 of file tyt_fw_sgl.hpp.

◆ radio_group

const std::string radio_tool::fw::SGLHeader::radio_group

Definition at line 84 of file tyt_fw_sgl.hpp.

◆ radio_model

const std::string radio_tool::fw::SGLHeader::radio_model

Definition at line 85 of file tyt_fw_sgl.hpp.

◆ sgl_version

const uint16_t radio_tool::fw::SGLHeader::sgl_version

Definition at line 80 of file tyt_fw_sgl.hpp.


The documentation for this class was generated from the following files: