20 lines
276 B
C++
20 lines
276 B
C++
#ifndef UART_H
|
|
#define UART_H
|
|
|
|
#include <cstring>
|
|
|
|
class Uart
|
|
{
|
|
public:
|
|
Uart(const char *name);
|
|
~Uart();
|
|
|
|
int transmit(const unsigned char *buffer, size_t len);
|
|
int receive(unsigned char *buffer, size_t len);
|
|
|
|
private:
|
|
int serial_device = 0;
|
|
};
|
|
|
|
#endif
|