eive-obsw/linux/boardtest/UartTestClass.h
Robin Mueller 77c45c0de9
Some checks failed
EIVE/eive-obsw/pipeline/head Build queued...
EIVE/eive-obsw/pipeline/pr-develop There was a failure building this commit
applied formatting
2022-01-17 15:58:27 +01:00

28 lines
653 B
C++

#ifndef LINUX_BOARDTEST_UARTTESTCLASS_H_
#define LINUX_BOARDTEST_UARTTESTCLASS_H_
#include <termios.h> // Contains POSIX terminal control definitions
#include <array>
#include "lwgps/lwgps.h"
#include "test/testtasks/TestTask.h"
class UartTestClass : public TestTask {
public:
UartTestClass(object_id_t objectId);
ReturnValue_t initialize() override;
ReturnValue_t performOneShotAction() override;
ReturnValue_t performPeriodicAction() override;
private:
lwgps_t gpsData = {};
struct termios tty = {};
int serialPort = 0;
std::array<uint8_t, 512> recBuf;
uint8_t recvCnt = 0;
};
#endif /* LINUX_BOARDTEST_UARTTESTCLASS_H_ */