Fang-Robotics-MCB
Fang Robotics Team Codebase
Loading...
Searching...
No Matches
tap::communication::serial::UartTerminalDevice Class Reference

#include <uart_terminal_device.hpp>

Inheritance diagram for tap::communication::serial::UartTerminalDevice:
Collaboration diagram for tap::communication::serial::UartTerminalDevice:

Public Member Functions

 UartTerminalDevice (Drivers *drivers)
 
 DISALLOW_COPY_AND_ASSIGN (UartTerminalDevice)
 
virtual ~UartTerminalDevice ()=default
 
void initialize ()
 
bool read (char &c) override
 
void write (char c) override
 
void flush () override
 

Detailed Description

A wrapper around UART3 used by the terminal handler. Allows for stream-based operations to be performed on data being sent/received by the UART line by using an instance of this class with a modm::IOStream.

Constructor & Destructor Documentation

◆ UartTerminalDevice()

tap::communication::serial::UartTerminalDevice::UartTerminalDevice ( Drivers drivers)

◆ ~UartTerminalDevice()

virtual tap::communication::serial::UartTerminalDevice::~UartTerminalDevice ( )
virtualdefault

Member Function Documentation

◆ DISALLOW_COPY_AND_ASSIGN()

tap::communication::serial::UartTerminalDevice::DISALLOW_COPY_AND_ASSIGN ( UartTerminalDevice  )

◆ flush()

void tap::communication::serial::UartTerminalDevice::flush ( )
override

Flushes the UART tx buffer.

◆ initialize()

void tap::communication::serial::UartTerminalDevice::initialize ( )

◆ read()

bool tap::communication::serial::UartTerminalDevice::read ( char &  c)
override

Reads a byte from the UART receive buffer and populates c with the value.

Parameters
[out]cThe byte that data will be read into.

◆ write()

void tap::communication::serial::UartTerminalDevice::write ( char  c)
override

Writes the character c into the UART buffer.

Parameters
[out]cThe byte to write to the buffer.

The documentation for this class was generated from the following files: