mirror of
https://github.com/azaion/autopilot.git
synced 2026-04-22 10:36:34 +00:00
db2652d979
Added functionality to capture camera frame from RTSP stream. Refactored code. Fixed some minor issues.
28 lines
596 B
C++
28 lines
596 B
C++
#pragma once
|
|
|
|
#include <QByteArray>
|
|
#include <QList>
|
|
#include <QString>
|
|
#include "defines.h"
|
|
|
|
struct Command {
|
|
COMMAND_ID id;
|
|
QByteArray command;
|
|
QString description;
|
|
};
|
|
|
|
class SerialCommand {
|
|
public:
|
|
SerialCommand();
|
|
~SerialCommand();
|
|
void printCommands(void);
|
|
QByteArray getCommandByID(COMMAND_ID commandId);
|
|
uint8_t getCommandCount();
|
|
|
|
private:
|
|
void setExtraValues(COMMAND_ID commandId);
|
|
QByteArray createByteArray(const std::initializer_list<int> &bytes);
|
|
int16_t getCommandIndex(COMMAND_ID commandId);
|
|
std::vector<Command> mSerialCommands;
|
|
};
|