M5Unit-RS485 0.1.0 git rev:8a0af48
Loading...
Searching...
No Matches
rs485_component.hpp File Reference

Common base for RS-485 transceiver units in M5UnitUnified. More...

#include <M5UnitComponent.hpp>
#include <m5_utility/stl/byteswap.hpp>
#include <m5_utility/stl/endianness.hpp>
#include <cstring>
#include <memory>
#include <type_traits>

Go to the source code of this file.

Classes

class  m5::unit::RS485Component
 Non-instantiable base class for RS-485 transceiver units. More...
 
struct  m5::unit::RS485Component::config_t
 Settings for begin. More...
 
struct  m5::unit::RS485Component::byteswap_int_tag
 
struct  m5::unit::RS485Component::byteswap_float_tag
 
struct  m5::unit::RS485Component::byteswap_none_tag
 
struct  m5::unit::RS485Component::byteswap_tag_of< T >
 

Namespaces

namespace  m5
 Top level namespace of M5Stack.
 

Detailed Description

Common base for RS-485 transceiver units in M5UnitUnified.

Non-instantiable intermediate that holds the Arduino Serial-compatible API, the ISerial abstraction, endian-aware readValue / writeValue templates and the begin() flushRX policy shared between all RS-485 transceiver units in this library (UnitSP485, UnitSIT3088, ...). Chip-specific behavior is injected by overriding make_serial().

Note
The public API is framework-agnostic (no Arduino types leak through this header). Framework-specific bits (HardwareSerial, digitalWrite, ...) live in the derived classes' translation units.