Files
chenzhen 222dda1e43 1,新增“App_ThermalImageSystem”;
2,新增“Apps”;
3,新增“Common”;
4,新增“FileList”;
5,新增“MediaX”;
6,新增“OpenSource”;
7,新增“Samples”;
8,新增“SoftwareBusinessLines”.
2026-02-14 23:03:23 +08:00

52 lines
1.2 KiB
C++
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
#ifndef OBSTACLEAVOIDANCEMANAGER_H
#define OBSTACLEAVOIDANCEMANAGER_H
#include <QObject>
#include "protocol/CmdResponse.h"
#include "GDUDroneManager.h"
typedef std::function <void(CmdResponse *)> cmdComplete_t;
class ObstacleAvoidanceManager : public QObject
{
Q_OBJECT
public:
explicit ObstacleAvoidanceManager(QObject *parent = nullptr);
/**
* @brief openObstacleAvoidance 开启避障
* @param block 返回的结果
* @return 是否开启成功0x00 成功 0x01 失败
*/
void openObstacleAvoidance(cmdComplete_t block);
/**
* @brief closeObstacleAvoidance 关闭避障
* @param block 返回的结果
* @return 是否关闭成功0x00 成功 0x01 失败
*/
void closeObstacleAvoidance(cmdComplete_t block);
//避障开关
enum ObstacleAvoidanceSwitch{
OBSTACLE_AVOIDANCE_OPEN = 0X0000,
OBSTACLE_AVOIDANCE_CLOASE = 0X0001
};
//响应ACK帧
enum ObstacleAvoidanceACKResult
{
SUCCEED = 0X0000,
FAIL = 0X0001
};
private:
void _parseObstacle(CmdResponse *cmdResponse);
GDUDroneManager *_droneManager;
signals:
public slots:
};
#endif // OBSTACLEAVOIDANCEMANAGER_H