mirror of
https://github.com/mofeng-git/One-KVM.git
synced 2026-01-31 10:01:53 +08:00
refactoring
This commit is contained in:
@@ -25,9 +25,10 @@
|
||||
#include "driver.h"
|
||||
#include "stdint.h"
|
||||
|
||||
|
||||
namespace DRIVERS {
|
||||
typedef void(*DataHandler)(const uint8_t * data, size_t len);
|
||||
typedef void(*TimeoutHandler)();
|
||||
typedef void (*DataHandler)(const uint8_t *data, size_t size);
|
||||
typedef void (*TimeoutHandler)();
|
||||
|
||||
struct Connection : public Driver {
|
||||
using Driver::Driver;
|
||||
|
||||
@@ -21,12 +21,14 @@
|
||||
|
||||
|
||||
#pragma once
|
||||
|
||||
#ifdef CMD_SERIAL
|
||||
#include "connection.h"
|
||||
|
||||
|
||||
namespace DRIVERS {
|
||||
#ifdef Serial
|
||||
#undef Serial
|
||||
# undef Serial
|
||||
#endif
|
||||
struct Serial : public Connection {
|
||||
Serial() : Connection(CONNECTION) {}
|
||||
|
||||
Reference in New Issue
Block a user