Renamed settings to config
This commit is contained in:
@@ -1,18 +1,22 @@
|
||||
#pragma once
|
||||
|
||||
#include "settings.hpp"
|
||||
#include "config.hpp"
|
||||
|
||||
namespace uart {
|
||||
namespace detail {
|
||||
|
||||
template <class settings, const Mode mode>
|
||||
enum class Mode {
|
||||
ASYNCHRONOUS,
|
||||
ASYNCHRONOUS_2X,
|
||||
SYNCHRONOUS_MASTER,
|
||||
SYNCHRONOUS_SLAVE,
|
||||
SPI,
|
||||
};
|
||||
|
||||
template <const Mode mode, class config>
|
||||
class hardware0 {
|
||||
public:
|
||||
using data_t = typename settings::data_t;
|
||||
static constexpr auto BAUD_RATE = settings::BAUD_RATE;
|
||||
static constexpr auto DATA_BITS = settings::DATA_BITS;
|
||||
static constexpr auto PARITY = settings::PARITY;
|
||||
static constexpr auto STOP_BITS = settings::STOP_BITS;
|
||||
using data_t = typename config::data_t;
|
||||
static constexpr auto DATA_BITS = config::DATA_BITS;
|
||||
|
||||
static void init() {}
|
||||
|
||||
@@ -24,7 +28,11 @@ class hardware0 {
|
||||
static data_t rxByte() {}
|
||||
|
||||
static data_t peek() {}
|
||||
|
||||
private:
|
||||
static constexpr auto BAUD_RATE = config::BAUD_RATE;
|
||||
static constexpr auto PARITY = config::PARITY;
|
||||
static constexpr auto STOP_BITS = config::STOP_BITS;
|
||||
};
|
||||
|
||||
} // namespace detail
|
||||
} // namespace uart
|
||||
|
||||
Reference in New Issue
Block a user