USRP Hardware Driver and USRP Manual: uhd::uart_iface Class Reference

| USRP Hardware Driver and USRP Manual Version: 4.8.0.makepkg-0-g308126a4 UHD and USRP Manual |

Loading...
Searching...
No Matches
Public Types | Public Member Functions | List of all members
uhd::uart_iface Class Referenceabstract

`#include <uhd/types/serial.hpp>`

## Public Types
typedef std::shared_ptr< uart_iface > | sptr

## Public Member Functions
virtual | ~uart_iface (void)
virtual void | write_uart (const std::string &buf)=0
virtual std::string | read_uart (double timeout)=0

## Detailed Description

UART interface to write and read strings.

## Member Typedef Documentation

## ◆ sptr

typedef std::shared_ptr<uart_iface> uhd::uart_iface::sptr

## Constructor & Destructor Documentation

## ◆ ~uart_iface()

virtual uhd::uart_iface::~uart_iface | ( | void |  | ) |
| virtual

## Member Function Documentation

## ◆ read_uart()

virtual std::string uhd::uart_iface::read_uart | ( | double | timeout | ) |
| pure virtual

Read a line from a serial port.

Parameters

  timeout | the timeout in seconds

Returns
  the line or empty string upon timeout

## ◆ write_uart()

virtual void uhd::uart_iface::write_uart | ( | const std::string & | buf | ) |
| pure virtual

Write to a serial port.

Parameters

  buf | the data to write

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

- serial.hpp