CDC/HostDevice.h
Go to the documentation of this file.
Definition: Delegate.h:20
Implements CDC interface for a connected serial device.
Definition: CDC/HostDevice.h:31
virtual size_t setTxBufferSize(size_t size) override
Sets transmit buffer size.
Definition: CDC/HostDevice.h:38
bool isFinished() override
Check if all data has been read.
Definition: CDC/HostDevice.h:48
void clear(SerialMode mode=SERIAL_FULL) override
Clear the serial port transmit/receive buffers.
Definition: CDC/HostDevice.h:70
size_t setRxBufferSize(size_t size) override
Sets receiving buffer size.
Definition: CDC/HostDevice.h:33
int read() override
Read one character and moves the stream pointer.
Definition: CDC/HostDevice.h:53
int available() override
Return the total length of the stream.
Definition: CDC/HostDevice.h:43
size_t write(const uint8_t *buffer, size_t size) override
Write chars to stream.
int peek() override
Read a character without advancing the stream pointer.
Definition: CDC/HostDevice.h:64
size_t readBytes(char *buffer, size_t length) override
Read chars from stream into buffer.
Definition: CDC/HostDevice.h:59
@ TxOnly
@ RxOnly
Definition: Libraries/USB/src/USB/CDC/Device.h:26
void onUnmount(UnmountCallback callback)
Application should call this method to receive device disconnection notifications.
void onMount(MountCallback callback)
Application should call this method to receive device connection notifications.
uint8_t idx
Index or instance value specific to class.
Definition: HostInterface.h:37