|
QGroundControl
Ground Control Station for MAVLink Drones
|
Classes | |
| class | MessageHandler |
Typedefs | |
| using | MessageCallback = std::function< bool(const ulog_cpp::TypedDataView &sample)> |
Functions | |
| bool | isValidHeader (const char *data, qint64 size) |
| int | getVersion (const char *data, qint64 size) |
| uint64_t | getHeaderTimestamp (const char *data, qint64 size) |
| bool | iterateMessages (const char *data, qint64 size, const std::string &messageName, const MessageCallback &callback, QString &errorMessage) |
Variables | |
| constexpr char | kMagicBytes [] = {'U', 'L', 'o', 'g'} |
| ULog file magic bytes: "ULog" followed by 0x01 (version 1) followed by 0x12 (file compat) | |
| constexpr int | kMagicSize = 4 |
| constexpr int | kHeaderSize = 16 |
| using ULogUtility::MessageCallback = typedef std::function<bool(const ulog_cpp::TypedDataView &sample)> |
Callback for processing ULog messages
| sample | The typed data view for the message |
Definition at line 59 of file ULogUtility.h.
| uint64_t ULogUtility::getHeaderTimestamp | ( | const char * | data, |
| qint64 | size | ||
| ) |
Get the ULog header timestamp (microseconds since epoch)
| data | Pointer to data (must be at least kHeaderSize bytes) |
| size | Size of available data |
Definition at line 36 of file ULogUtility.cc.
References getHeaderTimestamp(), and kHeaderSize.
Referenced by getHeaderTimestamp().
| int ULogUtility::getVersion | ( | const char * | data, |
| qint64 | size | ||
| ) |
Get the ULog format version from header
| data | Pointer to data (must be at least 5 bytes) |
| size | Size of available data |
Definition at line 25 of file ULogUtility.cc.
References getVersion().
Referenced by getVersion().
| bool ULogUtility::isValidHeader | ( | const char * | data, |
| qint64 | size | ||
| ) |
Check if data starts with a valid ULog header magic
| data | Pointer to data |
| size | Size of available data |
Definition at line 17 of file ULogUtility.cc.
References kMagicBytes, and kMagicSize.
| bool ULogUtility::iterateMessages | ( | const char * | data, |
| qint64 | size, | ||
| const std::string & | messageName, | ||
| const MessageCallback & | callback, | ||
| QString & | errorMessage | ||
| ) |
Parse a ULog file and call callback for each matching message
| data | Pointer to the ULog data |
| size | Size of the data in bytes |
| messageName | Name of the message to filter for |
| callback | Function called for each matching message |
| errorMessage | Output error message if parsing fails |
Definition at line 129 of file ULogUtility.cc.
Referenced by ULogParser::getTagsFromLog().
|
constexpr |
Definition at line 28 of file ULogUtility.h.
Referenced by getHeaderTimestamp().
|
constexpr |
ULog file magic bytes: "ULog" followed by 0x01 (version 1) followed by 0x12 (file compat)
Definition at line 26 of file ULogUtility.h.
Referenced by isValidHeader().
|
constexpr |
Definition at line 27 of file ULogUtility.h.
Referenced by isValidHeader().