|
Open Model Railroad Network (OpenMRN)
|
#include "freertos_drivers/tinyusb/TinyUsbCdc.hxx"#include "freertos_drivers/common/DeviceBuffer.hxx"#include "os/OS.hxx"#include <fcntl.h>#include "tusb.h"Go to the source code of this file.
Macros | |
| #define | USBD_STACK_SIZE 768 |
| #define | USBD_TASK_PRIO 3 |
| #define | _PID_MAP(itf, n) ((CFG_TUD_##itf) << (n)) |
| #define | USB_PID |
| #define | USB_VID 0xCAFE |
| #define | USB_BCD 0x0200 |
| #define | EPNUM_CDC_NOTIF 0x81 |
| #define | EPNUM_CDC_OUT 0x02 |
| #define | EPNUM_CDC_IN 0x82 |
| #define | CONFIG_TOTAL_LEN (TUD_CONFIG_DESC_LEN + TUD_CDC_DESC_LEN) |
Enumerations | |
| enum | { ITF_NUM_CDC = 0 , ITF_NUM_CDC_DATA , ITF_NUM_TOTAL } |
Functions | |
| void | tud_cdc_rx_cb (uint8_t itf) |
| void | tud_cdc_tx_complete_cb (uint8_t itf) |
| uint8_t const * | tud_descriptor_device_cb (void) |
| uint8_t const * | tud_descriptor_configuration_cb (uint8_t index) |
| uint16_t const * | tud_descriptor_string_cb (uint8_t index, uint16_t langid) |
Variables | |
| uint8_t const | desc_fs_configuration [] |
| char const * | string_desc_arr [] |
| static uint16_t | _desc_str [32] |
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
Base class for implementing a CDC Device driver using the TinyUsb stack.
Definition in file TinyUsbCdcImpl.hxx.
| #define _PID_MAP | ( | itf, | |
| n | |||
| ) | ((CFG_TUD_##itf) << (n)) |
Definition at line 255 of file TinyUsbCdcImpl.hxx.
| #define CONFIG_TOTAL_LEN (TUD_CONFIG_DESC_LEN + TUD_CDC_DESC_LEN) |
Definition at line 305 of file TinyUsbCdcImpl.hxx.
| #define EPNUM_CDC_IN 0x82 |
Definition at line 303 of file TinyUsbCdcImpl.hxx.
| #define EPNUM_CDC_NOTIF 0x81 |
Definition at line 301 of file TinyUsbCdcImpl.hxx.
| #define EPNUM_CDC_OUT 0x02 |
Definition at line 302 of file TinyUsbCdcImpl.hxx.
| #define USB_BCD 0x0200 |
Definition at line 261 of file TinyUsbCdcImpl.hxx.
| #define USB_PID |
Definition at line 256 of file TinyUsbCdcImpl.hxx.
| #define USB_VID 0xCAFE |
Definition at line 260 of file TinyUsbCdcImpl.hxx.
| #define USBD_STACK_SIZE 768 |
Definition at line 48 of file TinyUsbCdcImpl.hxx.
| #define USBD_TASK_PRIO 3 |
Definition at line 52 of file TinyUsbCdcImpl.hxx.
| anonymous enum |
Definition at line 294 of file TinyUsbCdcImpl.hxx.
| void tud_cdc_rx_cb | ( | uint8_t | itf | ) |
Definition at line 232 of file TinyUsbCdcImpl.hxx.
| void tud_cdc_tx_complete_cb | ( | uint8_t | itf | ) |
Definition at line 240 of file TinyUsbCdcImpl.hxx.
| uint8_t const * tud_descriptor_configuration_cb | ( | uint8_t | index | ) |
Definition at line 389 of file TinyUsbCdcImpl.hxx.
| uint8_t const * tud_descriptor_device_cb | ( | void | ) |
Definition at line 265 of file TinyUsbCdcImpl.hxx.
| uint16_t const * tud_descriptor_string_cb | ( | uint8_t | index, |
| uint16_t | langid | ||
| ) |
Definition at line 416 of file TinyUsbCdcImpl.hxx.
|
static |
Definition at line 411 of file TinyUsbCdcImpl.hxx.
| uint8_t const desc_fs_configuration[] |
Definition at line 308 of file TinyUsbCdcImpl.hxx.
| char const* string_desc_arr[] |
Definition at line 403 of file TinyUsbCdcImpl.hxx.