MRPT
1.9.9
|
Definition at line 40 of file linux/net_serial.h.
#include <rplidar/src/arch/linux/net_serial.h>
Public Types | |
enum | { SERIAL_RX_BUFFER_SIZE = 512, SERIAL_TX_BUFFER_SIZE = 128 } |
enum | { SERIAL_RX_BUFFER_SIZE = 512, SERIAL_TX_BUFFER_SIZE = 128 } |
enum | { SERIAL_RX_BUFFER_SIZE = 512, SERIAL_TX_BUFFER_SIZE = 128, SERIAL_RX_TIMEOUT = 2000, SERIAL_TX_TIMEOUT = 2000 } |
enum | { ANS_OK = 0, ANS_TIMEOUT = -1, ANS_DEV_ERR = -2 } |
Public Member Functions | |
raw_serial () | |
virtual | ~raw_serial () |
virtual bool | bind (const char *portname, uint32_t baudrate, uint32_t flags=0) |
virtual bool | open () |
virtual void | close () |
virtual void | flush (_u32 flags) |
virtual int | waitfordata (size_t data_count, _u32 timeout=-1, size_t *returned_size=nullptr) |
virtual int | senddata (const unsigned char *data, size_t size) |
virtual int | recvdata (unsigned char *data, size_t size) |
virtual int | waitforsent (_u32 timeout=-1, size_t *returned_size=nullptr) |
virtual int | waitforrecv (_u32 timeout=-1, size_t *returned_size=nullptr) |
virtual size_t | rxqueue_count () |
virtual void | setDTR () |
virtual void | clearDTR () |
_u32 | getTermBaudBitmap (_u32 baud) |
raw_serial () | |
virtual | ~raw_serial () |
virtual bool | bind (const char *portname, uint32_t baudrate, uint32_t flags=0) |
virtual bool | open () |
virtual void | close () |
virtual void | flush (_u32 flags) |
virtual int | waitfordata (_word_size_t data_count, _u32 timeout=-1, _word_size_t *returned_size=nullptr) |
virtual int | senddata (const unsigned char *data, _word_size_t size) |
virtual int | recvdata (unsigned char *data, _word_size_t size) |
virtual int | waitforsent (_u32 timeout=-1, _word_size_t *returned_size=nullptr) |
virtual int | waitforrecv (_u32 timeout=-1, _word_size_t *returned_size=nullptr) |
virtual size_t | rxqueue_count () |
virtual void | setDTR () |
virtual void | clearDTR () |
_u32 | getTermBaudBitmap (_u32 baud) |
raw_serial () | |
virtual | ~raw_serial () |
virtual bool | bind (const char *portname, _u32 baudrate, _u32 flags=0) |
virtual bool | open () |
virtual void | close () |
virtual void | flush (_u32 flags) |
virtual int | waitfordata (size_t data_count, _u32 timeout=-1, size_t *returned_size=nullptr) |
virtual int | senddata (const unsigned char *data, size_t size) |
virtual int | recvdata (unsigned char *data, size_t size) |
virtual int | waitforsent (_u32 timeout=-1, size_t *returned_size=nullptr) |
virtual int | waitforrecv (_u32 timeout=-1, size_t *returned_size=nullptr) |
virtual size_t | rxqueue_count () |
virtual void | setDTR () |
virtual void | clearDTR () |
virtual bool | isOpened () |
Static Public Member Functions | |
static serial_rxtx * | CreateRxTx () |
static void | ReleaseRxTx (serial_rxtx *) |
Protected Member Functions | |
bool | open (const char *portname, uint32_t baudrate, uint32_t flags=0) |
void | _init () |
bool | open (const char *portname, uint32_t baudrate, uint32_t flags=0) |
void | _init () |
bool | open (const char *portname, _u32 baudrate, _u32 flags) |
void | _init () |
Protected Attributes | |
char | _portName [200] |
uint32_t | _baudrate |
uint32_t | _flags |
int | serial_fd |
size_t | required_tx_cnt |
size_t | required_rx_cnt |
OVERLAPPED | _ro |
OVERLAPPED | _wo |
OVERLAPPED | _wait_o |
volatile HANDLE | _serial_handle |
DCB | _dcb |
COMMTIMEOUTS | _co |
volatile bool | _is_serial_opened |
anonymous enum |
Enumerator | |
---|---|
SERIAL_RX_BUFFER_SIZE | |
SERIAL_TX_BUFFER_SIZE |
Definition at line 43 of file linux/net_serial.h.
anonymous enum |
Enumerator | |
---|---|
SERIAL_RX_BUFFER_SIZE | |
SERIAL_TX_BUFFER_SIZE |
Definition at line 43 of file macOS/net_serial.h.
anonymous enum |
Enumerator | |
---|---|
SERIAL_RX_BUFFER_SIZE | |
SERIAL_TX_BUFFER_SIZE | |
SERIAL_RX_TIMEOUT | |
SERIAL_TX_TIMEOUT |
Definition at line 43 of file win32/net_serial.h.
|
inherited |
Enumerator | |
---|---|
ANS_OK | |
ANS_TIMEOUT | |
ANS_DEV_ERR |
Definition at line 43 of file abs_rxtx.h.
rp::arch::net::raw_serial::raw_serial | ( | ) |
Definition at line 45 of file linux/net_serial.cpp.
References _init().
|
virtual |
Definition at line 51 of file linux/net_serial.cpp.
References close().
rp::arch::net::raw_serial::raw_serial | ( | ) |
|
virtual |
rp::arch::net::raw_serial::raw_serial | ( | ) |
|
virtual |
|
protected |
|
protected |
Definition at line 275 of file linux/net_serial.cpp.
References _portName, required_rx_cnt, required_tx_cnt, and serial_fd.
Referenced by raw_serial().
|
protected |
|
virtual |
Implements rp::hal::serial_rxtx.
|
virtual |
Implements rp::hal::serial_rxtx.
Definition at line 53 of file linux/net_serial.cpp.
|
virtual |
Implements rp::hal::serial_rxtx.
|
virtual |
Implements rp::hal::serial_rxtx.
Definition at line 267 of file linux/net_serial.cpp.
References rp::hal::serial_rxtx::isOpened(), and serial_fd.
Referenced by open().
|
virtual |
Implements rp::hal::serial_rxtx.
|
virtual |
Implements rp::hal::serial_rxtx.
|
virtual |
Implements rp::hal::serial_rxtx.
|
virtual |
Implements rp::hal::serial_rxtx.
Definition at line 124 of file linux/net_serial.cpp.
References rp::hal::serial_rxtx::_is_serial_opened, and serial_fd.
Referenced by open(), and ~raw_serial().
|
virtual |
Implements rp::hal::serial_rxtx.
|
staticinherited |
Definition at line 319 of file linux/net_serial.cpp.
Referenced by rp::standalone::rplidar::RPlidarDriverSerialImpl::RPlidarDriverSerialImpl().
Implements rp::hal::serial_rxtx.
Definition at line 165 of file linux/net_serial.cpp.
References serial_fd.
Implements rp::hal::serial_rxtx.
Implements rp::hal::serial_rxtx.
|
inlinevirtualinherited |
Definition at line 78 of file abs_rxtx.h.
References rp::hal::serial_rxtx::_is_serial_opened.
Referenced by clearDTR(), open(), recvdata(), rxqueue_count(), senddata(), setDTR(), waitfordata(), and waitforrecv().
|
virtual |
Implements rp::hal::serial_rxtx.
Definition at line 52 of file linux/net_serial.cpp.
References _baudrate, _flags, and _portName.
Referenced by open().
|
virtual |
Implements rp::hal::serial_rxtx.
|
virtual |
Implements rp::hal::serial_rxtx.
|
protected |
Definition at line 61 of file linux/net_serial.cpp.
References rp::hal::serial_rxtx::_is_serial_opened, clearDTR(), close(), getTermBaudBitmap(), rp::hal::serial_rxtx::isOpened(), open(), and serial_fd.
|
protected |
|
virtual |
Implements rp::hal::serial_rxtx.
Definition at line 154 of file linux/net_serial.cpp.
References rp::hal::serial_rxtx::isOpened(), required_rx_cnt, and serial_fd.
|
virtual |
Implements rp::hal::serial_rxtx.
|
virtual |
Definition at line 155 of file macOS/net_serial.cpp.
|
staticinherited |
Definition at line 324 of file linux/net_serial.cpp.
Referenced by rp::standalone::rplidar::RPlidarDriverSerialImpl::~RPlidarDriverSerialImpl().
|
virtual |
Implements rp::hal::serial_rxtx.
Definition at line 250 of file linux/net_serial.cpp.
References rp::hal::serial_rxtx::isOpened(), and serial_fd.
|
virtual |
Implements rp::hal::serial_rxtx.
|
virtual |
Implements rp::hal::serial_rxtx.
|
virtual |
Implements rp::hal::serial_rxtx.
Definition at line 132 of file linux/net_serial.cpp.
References rp::hal::serial_rxtx::isOpened(), required_tx_cnt, and serial_fd.
|
virtual |
Definition at line 133 of file macOS/net_serial.cpp.
|
virtual |
Implements rp::hal::serial_rxtx.
|
virtual |
Implements rp::hal::serial_rxtx.
Definition at line 259 of file linux/net_serial.cpp.
References rp::hal::serial_rxtx::isOpened(), and serial_fd.
|
virtual |
Implements rp::hal::serial_rxtx.
|
virtual |
Implements rp::hal::serial_rxtx.
|
virtual |
Definition at line 181 of file macOS/net_serial.cpp.
|
virtual |
Implements rp::hal::serial_rxtx.
Definition at line 180 of file linux/net_serial.cpp.
References _baudrate, rp::hal::serial_rxtx::ANS_DEV_ERR, rp::hal::serial_rxtx::ANS_TIMEOUT, rp::hal::serial_rxtx::isOpened(), and serial_fd.
|
virtual |
Implements rp::hal::serial_rxtx.
|
virtual |
Implements rp::hal::serial_rxtx.
Definition at line 172 of file linux/net_serial.cpp.
References rp::hal::serial_rxtx::isOpened(), and required_rx_cnt.
|
virtual |
Implements rp::hal::serial_rxtx.
|
virtual |
Definition at line 173 of file macOS/net_serial.cpp.
|
virtual |
Implements rp::hal::serial_rxtx.
Definition at line 166 of file linux/net_serial.cpp.
References required_tx_cnt.
|
virtual |
Definition at line 167 of file macOS/net_serial.cpp.
|
virtual |
Implements rp::hal::serial_rxtx.
|
protected |
Definition at line 78 of file linux/net_serial.h.
Referenced by bind(), open(), and waitfordata().
|
protected |
Definition at line 84 of file win32/net_serial.h.
|
protected |
Definition at line 83 of file win32/net_serial.h.
|
protected |
Definition at line 79 of file linux/net_serial.h.
|
protectedinherited |
Definition at line 80 of file abs_rxtx.h.
Referenced by close(), rp::hal::serial_rxtx::isOpened(), and open().
|
protected |
Definition at line 77 of file linux/net_serial.h.
|
protected |
Definition at line 80 of file win32/net_serial.h.
|
protected |
Definition at line 82 of file win32/net_serial.h.
|
protected |
Definition at line 81 of file win32/net_serial.h.
|
protected |
Definition at line 80 of file win32/net_serial.h.
|
protected |
Definition at line 84 of file linux/net_serial.h.
Referenced by _init(), recvdata(), and waitforrecv().
|
protected |
Definition at line 83 of file linux/net_serial.h.
Referenced by _init(), senddata(), and waitforsent().
|
protected |
Definition at line 81 of file linux/net_serial.h.
Referenced by _init(), clearDTR(), close(), flush(), open(), recvdata(), rxqueue_count(), senddata(), setDTR(), and waitfordata().
Page generated by Doxygen 1.8.14 for MRPT 1.9.9 Git: 7d5e6d718 Fri Aug 24 01:51:28 2018 +0200 at lun nov 2 08:35:50 CET 2020 |