24 #if !defined(BOARD_ATTINY) 30 #ifndef COSA_RS485_BUFFER_MAX 31 # define COSA_RS485_BUFFER_MAX 64 47 static const uint8_t
SOT = 0x01;
81 UART(port, ibuf, obuf),
116 int send(
const void* buf,
size_t len, uint8_t
dest = MASTER);
126 __attribute__((always_inline))
128 return (
send(buf, len, BROADCAST));
141 int recv(
void* buf,
size_t len, uint32_t ms = 0L);
virtual void on_udre_interrupt()
virtual void on_transmit_completed()
virtual int putchar(char c)
const uint16_t PAYLOAD_MAX
int broadcast(const void *buf, size_t len)
int send(const void *buf, size_t len, uint8_t dest=MASTER)
static IOBuffer< UART::TX_BUFFER_MAX > obuf
static const uint8_t FRAME_MAX
static const uint16_t BUFFER_MAX
static const uint8_t MASTER
static const uint8_t BROADCAST
void address(uint8_t addr=MASTER)
#define COSA_RS485_BUFFER_MAX
int recv(void *buf, size_t len, uint32_t ms=0L)
virtual void on_tx_interrupt()
static IOBuffer< UART::RX_BUFFER_MAX > ibuf
RS485(uint8_t port, IOStream::Device *ibuf, IOStream::Device *obuf, uint16_t size, Board::DigitalPin de, uint8_t addr=MASTER)