mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-01-06 16:08:28 -04:00
28 lines
658 B
C++
28 lines
658 B
C++
|
|
#ifndef __AP_HAL_LINUX_CONSOLE_H__
|
|
#define __AP_HAL_LINUX_CONSOLE_H__
|
|
|
|
#include <AP_HAL_Linux.h>
|
|
|
|
class Linux::LinuxConsoleDriver : public AP_HAL::ConsoleDriver {
|
|
public:
|
|
LinuxConsoleDriver(AP_HAL::BetterStream* delegate);
|
|
void init(void* machtnichts);
|
|
void backend_open();
|
|
void backend_close();
|
|
size_t backend_read(uint8_t *data, size_t len);
|
|
size_t backend_write(const uint8_t *data, size_t len);
|
|
|
|
int16_t available();
|
|
int16_t txspace();
|
|
int16_t read();
|
|
|
|
size_t write(uint8_t c);
|
|
size_t write(const uint8_t *buffer, size_t size);
|
|
|
|
private:
|
|
AP_HAL::BetterStream *_d;
|
|
};
|
|
|
|
#endif // __AP_HAL_LINUX_CONSOLE_H__
|