FastArduino v1.10
C++ library to build fast but small Arduino/AVR projects
Loading...
Searching...
No Matches
serial Namespace Reference

Defines all API for UART features. More...

Namespaces

namespace  hard
 Defines API types used by hardware UART features.
 
namespace  soft
 Defines API types used by software UART features.
 

Classes

class  UARTErrors
 Holder of latest UART errors. More...
 

Enumerations

enum class  Parity : uint8_t {
  NONE = 0 ,
  EVEN = 1 ,
  ODD = 3
}
 Parity used for serial transmission. More...
 
enum class  StopBits : uint8_t {
  ONE = 1 ,
  TWO = 2
}
 Number of stop bits used for serial transmission. More...
 
enum class  BufferHandling : uint8_t {
  KEEP = 0x00 ,
  CLEAR = 0x01 ,
  FLUSH = 0x02
}
 How the TX/RX buffer should be handled when ending transmission (see end() methods) on UATX/UARX. More...
 

Detailed Description

Defines all API for UART features.

This namespace embeds two namespaces:

  • hard contains API for hardware UART (only for MCU that support it)
  • soft contains API for software-emulated UART (for all MCU)

Enumeration Type Documentation

◆ Parity

enum class serial::Parity : uint8_t
strong

Parity used for serial transmission.

Enumerator
NONE 

No parity bit.

EVEN 

Even parity bit.

ODD 

Odd parity bit.

Definition at line 37 of file uart_commons.h.

◆ StopBits

enum class serial::StopBits : uint8_t
strong

Number of stop bits used for serial transmission.

Enumerator
ONE 

One stop bit.

TWO 

Two stop bits.

Definition at line 50 of file uart_commons.h.

◆ BufferHandling

enum class serial::BufferHandling : uint8_t
strong

How the TX/RX buffer should be handled when ending transmission (see end() methods) on UATX/UARX.

Enumerator
KEEP 

Stop transmission immediately, keep buffer as-is.

CLEAR 

Stop transmission immediately, clear buffer.

FLUSH 

Flush buffer before stopping transmission (buffer will be empty after calling end()).

Definition at line 62 of file uart_commons.h.