mirror of
https://github.com/azaion/autopilot.git
synced 2026-04-23 00:26:33 +00:00
Refactored a8 codes and added remote testing app a8_remote.
This commit is contained in:
@@ -0,0 +1,40 @@
|
||||
#pragma once
|
||||
|
||||
#include "serialCommand.hpp"
|
||||
#include "serialPort.hpp"
|
||||
#include <cstdint>
|
||||
|
||||
class Config
|
||||
{
|
||||
public:
|
||||
static void setInitalValues(SerialPort *serial, SerialCommand *command);
|
||||
static void updateState(void);
|
||||
|
||||
static SerialPort *getSerial();
|
||||
static SerialCommand *getCommand(void);
|
||||
static uint16_t getResolutionWidth(void);
|
||||
static uint16_t getResolutionHeight(void);
|
||||
static float getMaxZoom(void);
|
||||
|
||||
static float getCurrentYaw(void);
|
||||
static float getCurrentPitch(void);
|
||||
static float getCurrentRoll(void);
|
||||
static float getCurrentZoom(void);
|
||||
|
||||
private:
|
||||
static void sanityCheck(void);
|
||||
|
||||
static SerialPort *mSerial;
|
||||
static SerialCommand *mCommand;
|
||||
|
||||
// Get these only once
|
||||
static uint16_t mResolutionX;
|
||||
static uint16_t mResolutionY;
|
||||
static float mMaxZoom;
|
||||
|
||||
// Update these before every command
|
||||
static float mCurrentYaw;
|
||||
static float mCurrentPitch;
|
||||
static float mCurrentRoll;
|
||||
static float mCurrentZoom;
|
||||
};
|
||||
Reference in New Issue
Block a user