2016-02-17 21:25:23 -04:00
|
|
|
#pragma once
|
2012-12-14 21:55:38 -04:00
|
|
|
|
2015-08-11 03:28:43 -03:00
|
|
|
#include "AP_HAL_Empty.h"
|
2012-12-14 21:55:38 -04:00
|
|
|
|
2015-12-07 14:53:55 -04:00
|
|
|
class Empty::UARTDriver : public AP_HAL::UARTDriver {
|
2012-12-14 21:55:38 -04:00
|
|
|
public:
|
2015-12-07 14:53:55 -04:00
|
|
|
UARTDriver();
|
2012-12-14 21:55:38 -04:00
|
|
|
/* Empty implementations of UARTDriver virtual methods */
|
2018-11-07 06:59:10 -04:00
|
|
|
void begin(uint32_t b) override;
|
|
|
|
void begin(uint32_t b, uint16_t rxS, uint16_t txS) override;
|
|
|
|
void end() override;
|
|
|
|
void flush() override;
|
|
|
|
bool is_initialized() override;
|
|
|
|
void set_blocking_writes(bool blocking) override;
|
|
|
|
bool tx_pending() override;
|
2012-12-14 21:55:38 -04:00
|
|
|
|
|
|
|
/* Empty implementations of Stream virtual methods */
|
2016-08-02 10:42:50 -03:00
|
|
|
uint32_t available() override;
|
|
|
|
uint32_t txspace() override;
|
|
|
|
int16_t read() override;
|
2020-05-22 21:22:28 -03:00
|
|
|
bool discard_input() override;
|
2012-12-14 21:55:38 -04:00
|
|
|
|
|
|
|
/* Empty implementations of Print virtual methods */
|
2018-11-07 06:59:10 -04:00
|
|
|
size_t write(uint8_t c) override;
|
|
|
|
size_t write(const uint8_t *buffer, size_t size) override;
|
2021-06-05 00:50:28 -03:00
|
|
|
|
|
|
|
// request information on uart I/O for one uart
|
|
|
|
void uart_info(ExpandingString &str) override;
|
2012-12-14 21:55:38 -04:00
|
|
|
};
|