Skip to content

Commit b02f131

Browse files
committed
TinyUSB adjust
1 parent f40274a commit b02f131

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

74 files changed

+48
-20
lines changed

Diff for: tools/sdk/esp32s2/include/config/sdkconfig.h

+14-6
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,8 @@
2626
#define CONFIG_ESPTOOLPY_BAUD_OTHER_VAL 115200
2727
#define CONFIG_ESPTOOLPY_FLASHMODE_QIO 1
2828
#define CONFIG_ESPTOOLPY_FLASHMODE "dio"
29-
#define CONFIG_ESPTOOLPY_FLASHFREQ_80M 1
30-
#define CONFIG_ESPTOOLPY_FLASHFREQ "80m"
29+
#define CONFIG_ESPTOOLPY_FLASHFREQ_40M 1
30+
#define CONFIG_ESPTOOLPY_FLASHFREQ "40m"
3131
#define CONFIG_ESPTOOLPY_FLASHSIZE_4MB 1
3232
#define CONFIG_ESPTOOLPY_FLASHSIZE "4MB"
3333
#define CONFIG_ESPTOOLPY_FLASHSIZE_DETECT 1
@@ -353,21 +353,29 @@
353353
#define CONFIG_SPIFFS_META_LENGTH 4
354354
#define CONFIG_SPIFFS_USE_MTIME 1
355355
#define CONFIG_USB_ENABLED 1
356-
#define CONFIG_USB_MAX_POWER_USAGE 100
356+
#define CONFIG_USB_MAX_POWER_USAGE 500
357357
#define CONFIG_USB_CDC_ENABLED 1
358-
#define CONFIG_USB_CDC_RX_BUFSIZE 64
359-
#define CONFIG_USB_CDC_TX_BUFSIZE 64
358+
#define CONFIG_USB_CDC_RX_BUFSIZE 1024
359+
#define CONFIG_USB_CDC_TX_BUFSIZE 1024
360360
#define CONFIG_USB_MSC_ENABLED 1
361361
#define CONFIG_USB_MSC_BUFSIZE 512
362+
#define CONFIG_USB_HID_ENABLED 1
363+
#define CONFIG_USB_HID_BUFSIZE 16
364+
#define CONFIG_USB_MIDI_ENABLED 1
365+
#define CONFIG_USB_MIDI_RX_BUFSIZE 64
366+
#define CONFIG_USB_MIDI_TX_BUFSIZE 64
362367
#define CONFIG_USB_VENDOR_ENABLED 1
368+
#define CONFIG_USB_DFU_RT_ENABLED 1
363369
#define CONFIG_USB_DESC_USE_ESPRESSIF_VID 1
364370
#define CONFIG_USB_DESC_USE_DEFAULT_PID 1
365371
#define CONFIG_USB_DESC_BCDDEVICE 0x0100
366-
#define CONFIG_USB_DESC_MANUFACTURER_STRING "Espressif Systems"
372+
#define CONFIG_USB_DESC_MANUFACTURER_STRING "Espressif"
367373
#define CONFIG_USB_DESC_PRODUCT_STRING "Espressif Device"
368374
#define CONFIG_USB_DESC_SERIAL_STRING "123456"
369375
#define CONFIG_USB_DESC_CDC_STRING "Espressif CDC Device"
370376
#define CONFIG_USB_DESC_MSC_STRING "Espressif MSC Device"
377+
#define CONFIG_USB_DESC_MIDI_STRING "Espressif MIDI Device"
378+
#define CONFIG_USB_DESC_HID_STRING "Espressif HID Device"
371379
#define CONFIG_USB_DESC_VENDOR_STRING "Espressif VENDOR Device"
372380
#define CONFIG_UNITY_ENABLE_FLOAT 1
373381
#define CONFIG_UNITY_ENABLE_DOUBLE 1

Diff for: tools/sdk/esp32s2/include/tinyusb/port/common/include/descriptors_control.h

+4-3
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,10 @@
2424
* Auto ProductID layout's Bitmap:
2525
* [MSB] HID | MSC | CDC [LSB]
2626
*/
27-
#define EPNUM_MSC 0x03
28-
#define EPNUM_VENDOR 0x06
29-
#define EPNUM_MIDI 0x05
27+
#define EPNUM_MSC 0x01
28+
#define EPNUM_HID 0x02
29+
#define EPNUM_MIDI 0x04
30+
#define EPNUM_VENDOR 0x06
3031

3132
#ifdef __cplusplus
3233
extern "C" {

Diff for: tools/sdk/esp32s2/include/tinyusb/port/esp32s2/include/tusb_config.h

+10
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,14 @@ extern "C" {
8989
# define CONFIG_USB_CUSTOM_CLASS_ENABLED 0
9090
#endif
9191

92+
#ifndef CONFIG_USB_DFU_RT_ENABLED
93+
# define CONFIG_USB_DFU_RT_ENABLED 0
94+
#endif
95+
96+
#ifndef CONFIG_USB_NET_ENABLED
97+
# define CONFIG_USB_NET_ENABLED 0
98+
#endif
99+
92100
#ifndef CONFIG_USB_VENDOR_ENABLED
93101
# define CONFIG_USB_VENDOR_ENABLED 0
94102
#endif
@@ -97,6 +105,8 @@ extern "C" {
97105
#define CFG_TUD_CDC CONFIG_USB_CDC_ENABLED
98106
#define CFG_TUD_MSC CONFIG_USB_MSC_ENABLED
99107
#define CFG_TUD_HID CONFIG_USB_HID_ENABLED
108+
#define CFG_TUD_DFU_RT CONFIG_USB_DFU_RT_ENABLED
109+
#define CFG_TUD_NET CONFIG_USB_NET_ENABLED
100110

101111
#define CFG_TUD_MIDI CONFIG_USB_MIDI_ENABLED
102112
#define CFG_TUD_CUSTOM_CLASS CONFIG_USB_CUSTOM_CLASS_ENABLED

Diff for: tools/sdk/esp32s2/ld/esp32s2.project.ld

+2-2
Large diffs are not rendered by default.

Diff for: tools/sdk/esp32s2/lib/libapp_trace.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libapp_update.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libasio.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libbootloader_support.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libcbor.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libcoap.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libconsole.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libcxx.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libdriver.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libefuse.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libesp-tls.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libesp32s2.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libesp_common.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libesp_eth.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libesp_event.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libesp_gdbstub.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libesp_hid.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libesp_http_client.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libesp_http_server.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libesp_https_ota.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libesp_https_server.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libesp_local_ctrl.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libesp_netif.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libesp_ringbuf.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libesp_serial_slave_link.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libesp_system.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libesp_timer.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libesp_websocket_client.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libesp_wifi.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libespcoredump.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libexpat.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libfatfs.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libfb_gfx.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libfreemodbus.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libfreertos.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libheap.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libjsmn.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libjson.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/liblibsodium.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/liblog.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/liblwip.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libmbedcrypto.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libmbedtls.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libmbedx509.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libmdns.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libmqtt.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libnewlib.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libnghttp.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libnvs_flash.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libopenssl.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libperfmon.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libprotobuf-c.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libprotocomm.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libpthread.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libsdmmc.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libsoc.a

184 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libsoc_esp32s2.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libspi_flash.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libspiffs.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libtcp_transport.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libtcpip_adapter.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libtinyusb.a

146 KB
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libulp.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libunity.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libvfs.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libwear_levelling.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libwifi_provisioning.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libwpa_supplicant.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/lib/libxtensa.a

0 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32s2/sdkconfig

+18-9
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,7 @@ CONFIG_BOOTLOADER_LOG_LEVEL_NONE=y
4949
# CONFIG_BOOTLOADER_LOG_LEVEL_VERBOSE is not set
5050
CONFIG_BOOTLOADER_LOG_LEVEL=0
5151
CONFIG_BOOTLOADER_SPI_WP_PIN=7
52+
# CONFIG_BOOTLOADER_VDDSDIO_BOOST_1_8V is not set
5253
CONFIG_BOOTLOADER_VDDSDIO_BOOST_1_9V=y
5354
# CONFIG_BOOTLOADER_FACTORY_RESET is not set
5455
# CONFIG_BOOTLOADER_APP_TEST is not set
@@ -78,11 +79,11 @@ CONFIG_ESPTOOLPY_FLASHMODE_QIO=y
7879
# CONFIG_ESPTOOLPY_FLASHMODE_DIO is not set
7980
# CONFIG_ESPTOOLPY_FLASHMODE_DOUT is not set
8081
CONFIG_ESPTOOLPY_FLASHMODE="dio"
81-
CONFIG_ESPTOOLPY_FLASHFREQ_80M=y
82-
# CONFIG_ESPTOOLPY_FLASHFREQ_40M is not set
82+
# CONFIG_ESPTOOLPY_FLASHFREQ_80M is not set
83+
CONFIG_ESPTOOLPY_FLASHFREQ_40M=y
8384
# CONFIG_ESPTOOLPY_FLASHFREQ_26M is not set
8485
# CONFIG_ESPTOOLPY_FLASHFREQ_20M is not set
85-
CONFIG_ESPTOOLPY_FLASHFREQ="80m"
86+
CONFIG_ESPTOOLPY_FLASHFREQ="40m"
8687
# CONFIG_ESPTOOLPY_FLASHSIZE_1MB is not set
8788
# CONFIG_ESPTOOLPY_FLASHSIZE_2MB is not set
8889
CONFIG_ESPTOOLPY_FLASHSIZE_4MB=y
@@ -987,15 +988,21 @@ CONFIG_SPIFFS_USE_MTIME=y
987988
# TinyUSB
988989
#
989990
CONFIG_USB_ENABLED=y
990-
CONFIG_USB_MAX_POWER_USAGE=100
991+
CONFIG_USB_MAX_POWER_USAGE=500
992+
# CONFIG_USB_USE_BUILTIN_DESCRIPTORS is not set
991993
CONFIG_USB_CDC_ENABLED=y
992-
CONFIG_USB_CDC_RX_BUFSIZE=64
993-
CONFIG_USB_CDC_TX_BUFSIZE=64
994+
CONFIG_USB_CDC_RX_BUFSIZE=1024
995+
CONFIG_USB_CDC_TX_BUFSIZE=1024
994996
CONFIG_USB_MSC_ENABLED=y
995997
CONFIG_USB_MSC_BUFSIZE=512
996-
# CONFIG_USB_HID_ENABLED is not set
997-
# CONFIG_USB_MIDI_ENABLED is not set
998+
CONFIG_USB_HID_ENABLED=y
999+
CONFIG_USB_HID_BUFSIZE=16
1000+
CONFIG_USB_MIDI_ENABLED=y
1001+
CONFIG_USB_MIDI_RX_BUFSIZE=64
1002+
CONFIG_USB_MIDI_TX_BUFSIZE=64
9981003
CONFIG_USB_VENDOR_ENABLED=y
1004+
CONFIG_USB_DFU_RT_ENABLED=y
1005+
# CONFIG_USB_NET_ENABLED is not set
9991006
# CONFIG_USB_CUSTOM_CLASS_ENABLED is not set
10001007
# CONFIG_USB_DEBUG is not set
10011008

@@ -1005,11 +1012,13 @@ CONFIG_USB_VENDOR_ENABLED=y
10051012
CONFIG_USB_DESC_USE_ESPRESSIF_VID=y
10061013
CONFIG_USB_DESC_USE_DEFAULT_PID=y
10071014
CONFIG_USB_DESC_BCDDEVICE=0x0100
1008-
CONFIG_USB_DESC_MANUFACTURER_STRING="Espressif Systems"
1015+
CONFIG_USB_DESC_MANUFACTURER_STRING="Espressif"
10091016
CONFIG_USB_DESC_PRODUCT_STRING="Espressif Device"
10101017
CONFIG_USB_DESC_SERIAL_STRING="123456"
10111018
CONFIG_USB_DESC_CDC_STRING="Espressif CDC Device"
10121019
CONFIG_USB_DESC_MSC_STRING="Espressif MSC Device"
1020+
CONFIG_USB_DESC_MIDI_STRING="Espressif MIDI Device"
1021+
CONFIG_USB_DESC_HID_STRING="Espressif HID Device"
10131022
CONFIG_USB_DESC_VENDOR_STRING="Espressif VENDOR Device"
10141023
# end of Descriptor configuration
10151024
# end of TinyUSB

0 commit comments

Comments
 (0)