Skip to content

Commit 172ec43

Browse files
committed
IDF release/v4.4 1e1030e5ef
1 parent abc0133 commit 172ec43

File tree

87 files changed

+526
-442
lines changed

Some content is hidden

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

87 files changed

+526
-442
lines changed

platform.txt

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

tools/platformio-build-esp32.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -334,7 +334,7 @@
334334
"UNITY_INCLUDE_CONFIG_H",
335335
"WITH_POSIX",
336336
"_GNU_SOURCE",
337-
("IDF_VER", '\\"v4.4.7-92-g718cdd6c65-dirty\\"'),
337+
("IDF_VER", '\\"v4.4.7-95-g1e1030e5ef-dirty\\"'),
338338
"ESP_PLATFORM",
339339
"_POSIX_READER_WRITER_LOCKS",
340340
"ARDUINO_ARCH_ESP32",

tools/platformio-build-esp32c3.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -331,7 +331,7 @@
331331
"UNITY_INCLUDE_CONFIG_H",
332332
"WITH_POSIX",
333333
"_GNU_SOURCE",
334-
("IDF_VER", '\\"v4.4.7-92-g718cdd6c65-dirty\\"'),
334+
("IDF_VER", '\\"v4.4.7-95-g1e1030e5ef-dirty\\"'),
335335
"ESP_PLATFORM",
336336
"_POSIX_READER_WRITER_LOCKS",
337337
"ARDUINO_ARCH_ESP32",

tools/platformio-build-esp32s2.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -317,7 +317,7 @@
317317
"UNITY_INCLUDE_CONFIG_H",
318318
"WITH_POSIX",
319319
"_GNU_SOURCE",
320-
("IDF_VER", '\\"v4.4.7-92-g718cdd6c65-dirty\\"'),
320+
("IDF_VER", '\\"v4.4.7-95-g1e1030e5ef-dirty\\"'),
321321
"ESP_PLATFORM",
322322
"_POSIX_READER_WRITER_LOCKS",
323323
"ARDUINO_ARCH_ESP32",

tools/platformio-build-esp32s3.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -333,7 +333,7 @@
333333
"UNITY_INCLUDE_CONFIG_H",
334334
"WITH_POSIX",
335335
"_GNU_SOURCE",
336-
("IDF_VER", '\\"v4.4.7-92-g718cdd6c65-dirty\\"'),
336+
("IDF_VER", '\\"v4.4.7-95-g1e1030e5ef-dirty\\"'),
337337
"ESP_PLATFORM",
338338
"_POSIX_READER_WRITER_LOCKS",
339339
"ARDUINO_ARCH_ESP32",

tools/sdk/esp32/dio_qspi/include/sdkconfig.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -845,5 +845,5 @@
845845
#define CONFIG_ULP_COPROC_ENABLED CONFIG_ESP32_ULP_COPROC_ENABLED
846846
#define CONFIG_ULP_COPROC_RESERVE_MEM CONFIG_ESP32_ULP_COPROC_RESERVE_MEM
847847
#define CONFIG_WARN_WRITE_STRINGS CONFIG_COMPILER_WARN_WRITE_STRINGS
848-
#define CONFIG_ARDUINO_IDF_COMMIT "718cdd6c65"
848+
#define CONFIG_ARDUINO_IDF_COMMIT "1e1030e5ef"
849849
#define CONFIG_ARDUINO_IDF_BRANCH "release/v4.4"

tools/sdk/esp32/dout_qspi/include/sdkconfig.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -845,5 +845,5 @@
845845
#define CONFIG_ULP_COPROC_ENABLED CONFIG_ESP32_ULP_COPROC_ENABLED
846846
#define CONFIG_ULP_COPROC_RESERVE_MEM CONFIG_ESP32_ULP_COPROC_RESERVE_MEM
847847
#define CONFIG_WARN_WRITE_STRINGS CONFIG_COMPILER_WARN_WRITE_STRINGS
848-
#define CONFIG_ARDUINO_IDF_COMMIT "718cdd6c65"
848+
#define CONFIG_ARDUINO_IDF_COMMIT "1e1030e5ef"
849849
#define CONFIG_ARDUINO_IDF_BRANCH "release/v4.4"

tools/sdk/esp32/lib/libapp_update.a

0 Bytes
Binary file not shown.

tools/sdk/esp32/lib/libbt.a

0 Bytes
Binary file not shown.

tools/sdk/esp32/lib/libesp_system.a

0 Bytes
Binary file not shown.

tools/sdk/esp32/qio_qspi/include/sdkconfig.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -845,5 +845,5 @@
845845
#define CONFIG_ULP_COPROC_ENABLED CONFIG_ESP32_ULP_COPROC_ENABLED
846846
#define CONFIG_ULP_COPROC_RESERVE_MEM CONFIG_ESP32_ULP_COPROC_RESERVE_MEM
847847
#define CONFIG_WARN_WRITE_STRINGS CONFIG_COMPILER_WARN_WRITE_STRINGS
848-
#define CONFIG_ARDUINO_IDF_COMMIT "718cdd6c65"
848+
#define CONFIG_ARDUINO_IDF_COMMIT "1e1030e5ef"
849849
#define CONFIG_ARDUINO_IDF_BRANCH "release/v4.4"

tools/sdk/esp32/qout_qspi/include/sdkconfig.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -845,5 +845,5 @@
845845
#define CONFIG_ULP_COPROC_ENABLED CONFIG_ESP32_ULP_COPROC_ENABLED
846846
#define CONFIG_ULP_COPROC_RESERVE_MEM CONFIG_ESP32_ULP_COPROC_RESERVE_MEM
847847
#define CONFIG_WARN_WRITE_STRINGS CONFIG_COMPILER_WARN_WRITE_STRINGS
848-
#define CONFIG_ARDUINO_IDF_COMMIT "718cdd6c65"
848+
#define CONFIG_ARDUINO_IDF_COMMIT "1e1030e5ef"
849849
#define CONFIG_ARDUINO_IDF_BRANCH "release/v4.4"

tools/sdk/esp32c3/dio_qspi/include/sdkconfig.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -849,5 +849,5 @@
849849
#define CONFIG_TOOLPREFIX CONFIG_SDK_TOOLPREFIX
850850
#define CONFIG_UDP_RECVMBOX_SIZE CONFIG_LWIP_UDP_RECVMBOX_SIZE
851851
#define CONFIG_WARN_WRITE_STRINGS CONFIG_COMPILER_WARN_WRITE_STRINGS
852-
#define CONFIG_ARDUINO_IDF_COMMIT "718cdd6c65"
852+
#define CONFIG_ARDUINO_IDF_COMMIT "1e1030e5ef"
853853
#define CONFIG_ARDUINO_IDF_BRANCH "release/v4.4"

tools/sdk/esp32c3/dout_qspi/include/sdkconfig.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -849,5 +849,5 @@
849849
#define CONFIG_TOOLPREFIX CONFIG_SDK_TOOLPREFIX
850850
#define CONFIG_UDP_RECVMBOX_SIZE CONFIG_LWIP_UDP_RECVMBOX_SIZE
851851
#define CONFIG_WARN_WRITE_STRINGS CONFIG_COMPILER_WARN_WRITE_STRINGS
852-
#define CONFIG_ARDUINO_IDF_COMMIT "718cdd6c65"
852+
#define CONFIG_ARDUINO_IDF_COMMIT "1e1030e5ef"
853853
#define CONFIG_ARDUINO_IDF_BRANCH "release/v4.4"

tools/sdk/esp32c3/ld/sections.ld

+1-1
Original file line numberDiff line numberDiff line change
@@ -349,8 +349,8 @@ SECTIONS
349349
_bss_start = ABSOLUTE(.);
350350

351351
*(EXCLUDE_FILE(*libbt.a *libbtdm_app.a *libnimble.a) .bss EXCLUDE_FILE(*libbt.a *libbtdm_app.a *libnimble.a) .bss.*)
352-
*(.ext_ram.bss .ext_ram.bss.*)
353352
*(.dynbss .dynsbss .gnu.linkonce.b .gnu.linkonce.b.* .gnu.linkonce.sb .gnu.linkonce.sb.* .gnu.linkonce.sb2 .gnu.linkonce.sb2.* .sbss .sbss.* .sbss2 .sbss2.* .scommon .share.mem)
353+
*(.ext_ram.bss .ext_ram.bss.*)
354354
*(EXCLUDE_FILE(*libbt.a *libbtdm_app.a *libnimble.a) COMMON)
355355
. = ALIGN(4);
356356
_bt_bss_start = ABSOLUTE(.);

tools/sdk/esp32c3/lib/libapp_update.a

0 Bytes
Binary file not shown.

tools/sdk/esp32c3/lib/libbt.a

0 Bytes
Binary file not shown.

tools/sdk/esp32c3/lib/libesp_system.a

0 Bytes
Binary file not shown.

tools/sdk/esp32c3/qio_qspi/include/sdkconfig.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -849,5 +849,5 @@
849849
#define CONFIG_TOOLPREFIX CONFIG_SDK_TOOLPREFIX
850850
#define CONFIG_UDP_RECVMBOX_SIZE CONFIG_LWIP_UDP_RECVMBOX_SIZE
851851
#define CONFIG_WARN_WRITE_STRINGS CONFIG_COMPILER_WARN_WRITE_STRINGS
852-
#define CONFIG_ARDUINO_IDF_COMMIT "718cdd6c65"
852+
#define CONFIG_ARDUINO_IDF_COMMIT "1e1030e5ef"
853853
#define CONFIG_ARDUINO_IDF_BRANCH "release/v4.4"

tools/sdk/esp32c3/qout_qspi/include/sdkconfig.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -849,5 +849,5 @@
849849
#define CONFIG_TOOLPREFIX CONFIG_SDK_TOOLPREFIX
850850
#define CONFIG_UDP_RECVMBOX_SIZE CONFIG_LWIP_UDP_RECVMBOX_SIZE
851851
#define CONFIG_WARN_WRITE_STRINGS CONFIG_COMPILER_WARN_WRITE_STRINGS
852-
#define CONFIG_ARDUINO_IDF_COMMIT "718cdd6c65"
852+
#define CONFIG_ARDUINO_IDF_COMMIT "1e1030e5ef"
853853
#define CONFIG_ARDUINO_IDF_BRANCH "release/v4.4"

tools/sdk/esp32s2/dio_qspi/include/sdkconfig.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -717,5 +717,5 @@
717717
#define CONFIG_USB_MSC_BUFSIZE CONFIG_TINYUSB_MSC_BUFSIZE
718718
#define CONFIG_USB_MSC_ENABLED CONFIG_TINYUSB_MSC_ENABLED
719719
#define CONFIG_WARN_WRITE_STRINGS CONFIG_COMPILER_WARN_WRITE_STRINGS
720-
#define CONFIG_ARDUINO_IDF_COMMIT "718cdd6c65"
720+
#define CONFIG_ARDUINO_IDF_COMMIT "1e1030e5ef"
721721
#define CONFIG_ARDUINO_IDF_BRANCH "release/v4.4"

tools/sdk/esp32s2/dout_qspi/include/sdkconfig.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -717,5 +717,5 @@
717717
#define CONFIG_USB_MSC_BUFSIZE CONFIG_TINYUSB_MSC_BUFSIZE
718718
#define CONFIG_USB_MSC_ENABLED CONFIG_TINYUSB_MSC_ENABLED
719719
#define CONFIG_WARN_WRITE_STRINGS CONFIG_COMPILER_WARN_WRITE_STRINGS
720-
#define CONFIG_ARDUINO_IDF_COMMIT "718cdd6c65"
720+
#define CONFIG_ARDUINO_IDF_COMMIT "1e1030e5ef"
721721
#define CONFIG_ARDUINO_IDF_BRANCH "release/v4.4"

tools/sdk/esp32s2/include/arduino_tinyusb/tinyusb/src/class/cdc/cdc_host.h

+2-1
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,8 @@ TU_ATTR_WEAK extern void tuh_cdc_tx_complete_cb(uint8_t idx);
192192
//--------------------------------------------------------------------+
193193
// Internal Class Driver API
194194
//--------------------------------------------------------------------+
195-
void cdch_init (void);
195+
bool cdch_init (void);
196+
bool cdch_deinit (void);
196197
bool cdch_open (uint8_t rhport, uint8_t dev_addr, tusb_desc_interface_t const *itf_desc, uint16_t max_len);
197198
bool cdch_set_config (uint8_t dev_addr, uint8_t itf_num);
198199
bool cdch_xfer_cb (uint8_t dev_addr, uint8_t ep_addr, xfer_result_t event, uint32_t xferred_bytes);

tools/sdk/esp32s2/include/arduino_tinyusb/tinyusb/src/class/hid/hid_host.h

+2-1
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,8 @@ TU_ATTR_WEAK void tuh_hid_set_protocol_complete_cb(uint8_t dev_addr, uint8_t idx
163163
//--------------------------------------------------------------------+
164164
// Internal Class Driver API
165165
//--------------------------------------------------------------------+
166-
void hidh_init(void);
166+
bool hidh_init(void);
167+
bool hidh_deinit(void);
167168
bool hidh_open(uint8_t rhport, uint8_t dev_addr, tusb_desc_interface_t const* desc_itf, uint16_t max_len);
168169
bool hidh_set_config(uint8_t dev_addr, uint8_t itf_num);
169170
bool hidh_xfer_cb(uint8_t dev_addr, uint8_t ep_addr, xfer_result_t result, uint32_t xferred_bytes);

tools/sdk/esp32s2/include/arduino_tinyusb/tinyusb/src/class/msc/msc_host.h

+2-1
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,8 @@ TU_ATTR_WEAK void tuh_msc_umount_cb(uint8_t dev_addr);
113113
// Internal Class Driver API
114114
//--------------------------------------------------------------------+
115115

116-
void msch_init (void);
116+
bool msch_init (void);
117+
bool msch_deinit (void);
117118
bool msch_open (uint8_t rhport, uint8_t dev_addr, tusb_desc_interface_t const *desc_itf, uint16_t max_len);
118119
bool msch_set_config (uint8_t dev_addr, uint8_t itf_num);
119120
void msch_close (uint8_t dev_addr);

tools/sdk/esp32s2/include/arduino_tinyusb/tinyusb/src/class/video/video.h

+12-11
Original file line numberDiff line numberDiff line change
@@ -160,22 +160,23 @@ typedef enum {
160160
/* A.9.1 VideoControl Interface Control Selectors */
161161
typedef enum {
162162
VIDEO_VC_CTL_UNDEFINED = 0x00,
163-
VIDEO_VC_CTL_VIDEO_POWER_MODE,
164-
VIDEO_VC_CTL_REQUEST_ERROR_CODE,
163+
VIDEO_VC_CTL_VIDEO_POWER_MODE, // 0x01
164+
VIDEO_VC_CTL_REQUEST_ERROR_CODE, // 0x02
165165
} video_interface_control_selector_t;
166166

167167
/* A.9.8 VideoStreaming Interface Control Selectors */
168168
typedef enum {
169169
VIDEO_VS_CTL_UNDEFINED = 0x00,
170-
VIDEO_VS_CTL_PROBE,
171-
VIDEO_VS_CTL_COMMIT,
172-
VIDEO_VS_CTL_STILL_PROBE,
173-
VIDEO_VS_CTL_STILL_COMMIT,
174-
VIDEO_VS_CTL_STILL_IMAGE_TRIGGER,
175-
VIDEO_VS_CTL_STREAM_ERROR_CODE,
176-
VIDEO_VS_CTL_GENERATE_KEY_FRAME,
177-
VIDEO_VS_CTL_UPDATE_FRAME_SEGMENT,
178-
VIDEO_VS_CTL_SYNCH_DELAY_CONTROL,
170+
VIDEO_VS_CTL_PROBE, // 0x01
171+
VIDEO_VS_CTL_COMMIT, // 0x02
172+
VIDEO_VS_CTL_STILL_PROBE, // 0x03
173+
VIDEO_VS_CTL_STILL_COMMIT, // 0x04
174+
VIDEO_VS_CTL_STILL_IMAGE_TRIGGER, // 0x05
175+
VIDEO_VS_CTL_STREAM_ERROR_CODE, // 0x06
176+
VIDEO_VS_CTL_GENERATE_KEY_FRAME, // 0x07
177+
VIDEO_VS_CTL_UPDATE_FRAME_SEGMENT, // 0x08
178+
VIDEO_VS_CTL_SYNCH_DELAY_CONTROL, // 0x09
179+
179180
} video_interface_streaming_selector_t;
180181

181182
/* B. Terminal Types */

tools/sdk/esp32s2/include/arduino_tinyusb/tinyusb/src/common/tusb_fifo.h

+10-21
Original file line numberDiff line numberDiff line change
@@ -102,10 +102,8 @@ extern "C" {
102102
* |
103103
* -------------------------
104104
* | R | 1 | 2 | W | 4 | 5 |
105-
106105
*/
107-
typedef struct
108-
{
106+
typedef struct {
109107
uint8_t* buffer ; // buffer pointer
110108
uint16_t depth ; // max items
111109

@@ -124,16 +122,14 @@ typedef struct
124122

125123
} tu_fifo_t;
126124

127-
typedef struct
128-
{
125+
typedef struct {
129126
uint16_t len_lin ; ///< linear length in item size
130127
uint16_t len_wrap ; ///< wrapped length in item size
131128
void * ptr_lin ; ///< linear part start pointer
132129
void * ptr_wrap ; ///< wrapped part start pointer
133130
} tu_fifo_buffer_info_t;
134131

135-
#define TU_FIFO_INIT(_buffer, _depth, _type, _overwritable) \
136-
{ \
132+
#define TU_FIFO_INIT(_buffer, _depth, _type, _overwritable){\
137133
.buffer = _buffer, \
138134
.depth = _depth, \
139135
.item_size = sizeof(_type), \
@@ -144,23 +140,18 @@ typedef struct
144140
uint8_t _name##_buf[_depth*sizeof(_type)]; \
145141
tu_fifo_t _name = TU_FIFO_INIT(_name##_buf, _depth, _type, _overwritable)
146142

147-
148143
bool tu_fifo_set_overwritable(tu_fifo_t *f, bool overwritable);
149144
bool tu_fifo_clear(tu_fifo_t *f);
150145
bool tu_fifo_config(tu_fifo_t *f, void* buffer, uint16_t depth, uint16_t item_size, bool overwritable);
151146

152147
#if OSAL_MUTEX_REQUIRED
153-
TU_ATTR_ALWAYS_INLINE static inline
154-
void tu_fifo_config_mutex(tu_fifo_t *f, osal_mutex_t wr_mutex, osal_mutex_t rd_mutex)
155-
{
156-
f->mutex_wr = wr_mutex;
157-
f->mutex_rd = rd_mutex;
158-
}
159-
148+
TU_ATTR_ALWAYS_INLINE static inline
149+
void tu_fifo_config_mutex(tu_fifo_t *f, osal_mutex_t wr_mutex, osal_mutex_t rd_mutex) {
150+
f->mutex_wr = wr_mutex;
151+
f->mutex_rd = rd_mutex;
152+
}
160153
#else
161-
162-
#define tu_fifo_config_mutex(_f, _wr_mutex, _rd_mutex)
163-
154+
#define tu_fifo_config_mutex(_f, _wr_mutex, _rd_mutex)
164155
#endif
165156

166157
bool tu_fifo_write (tu_fifo_t* f, void const * p_data);
@@ -182,8 +173,7 @@ bool tu_fifo_overflowed (tu_fifo_t* f);
182173
void tu_fifo_correct_read_pointer (tu_fifo_t* f);
183174

184175
TU_ATTR_ALWAYS_INLINE static inline
185-
uint16_t tu_fifo_depth(tu_fifo_t* f)
186-
{
176+
uint16_t tu_fifo_depth(tu_fifo_t* f) {
187177
return f->depth;
188178
}
189179

@@ -198,7 +188,6 @@ void tu_fifo_advance_read_pointer (tu_fifo_t *f, uint16_t n);
198188
void tu_fifo_get_read_info (tu_fifo_t *f, tu_fifo_buffer_info_t *info);
199189
void tu_fifo_get_write_info(tu_fifo_t *f, tu_fifo_buffer_info_t *info);
200190

201-
202191
#ifdef __cplusplus
203192
}
204193
#endif

tools/sdk/esp32s2/include/arduino_tinyusb/tinyusb/src/common/tusb_private.h

+9-10
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ typedef struct {
6060
tu_fifo_t ff;
6161

6262
// mutex: read if ep rx, write if e tx
63-
OSAL_MUTEX_DEF(ff_mutex);
63+
OSAL_MUTEX_DEF(ff_mutexdef);
6464

6565
}tu_edpt_stream_t;
6666

@@ -87,32 +87,32 @@ bool tu_edpt_release(tu_edpt_state_t* ep_state, osal_mutex_t mutex);
8787
// Endpoint Stream
8888
//--------------------------------------------------------------------+
8989

90-
// Init an stream, should only be called once
90+
// Init an endpoint stream
9191
bool tu_edpt_stream_init(tu_edpt_stream_t* s, bool is_host, bool is_tx, bool overwritable,
9292
void* ff_buf, uint16_t ff_bufsize, uint8_t* ep_buf, uint16_t ep_bufsize);
9393

94+
// Deinit an endpoint stream
95+
bool tu_edpt_stream_deinit(tu_edpt_stream_t* s);
96+
9497
// Open an stream for an endpoint
9598
// hwid is either device address (host mode) or rhport (device mode)
9699
TU_ATTR_ALWAYS_INLINE static inline
97-
void tu_edpt_stream_open(tu_edpt_stream_t* s, uint8_t hwid, tusb_desc_endpoint_t const *desc_ep)
98-
{
100+
void tu_edpt_stream_open(tu_edpt_stream_t* s, uint8_t hwid, tusb_desc_endpoint_t const *desc_ep) {
99101
tu_fifo_clear(&s->ff);
100102
s->hwid = hwid;
101103
s->ep_addr = desc_ep->bEndpointAddress;
102104
s->ep_packetsize = tu_edpt_packet_size(desc_ep);
103105
}
104106

105107
TU_ATTR_ALWAYS_INLINE static inline
106-
void tu_edpt_stream_close(tu_edpt_stream_t* s)
107-
{
108+
void tu_edpt_stream_close(tu_edpt_stream_t* s) {
108109
s->hwid = 0;
109110
s->ep_addr = 0;
110111
}
111112

112113
// Clear fifo
113114
TU_ATTR_ALWAYS_INLINE static inline
114-
bool tu_edpt_stream_clear(tu_edpt_stream_t* s)
115-
{
115+
bool tu_edpt_stream_clear(tu_edpt_stream_t* s) {
116116
return tu_fifo_clear(&s->ff);
117117
}
118118

@@ -131,8 +131,7 @@ bool tu_edpt_stream_write_zlp_if_needed(tu_edpt_stream_t* s, uint32_t last_xferr
131131

132132
// Get the number of bytes available for writing
133133
TU_ATTR_ALWAYS_INLINE static inline
134-
uint32_t tu_edpt_stream_write_available(tu_edpt_stream_t* s)
135-
{
134+
uint32_t tu_edpt_stream_write_available(tu_edpt_stream_t* s) {
136135
return (uint32_t) tu_fifo_remaining(&s->ff);
137136
}
138137

tools/sdk/esp32s2/include/arduino_tinyusb/tinyusb/src/device/usbd.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -421,7 +421,7 @@ TU_ATTR_WEAK bool tud_vendor_control_xfer_cb(uint8_t rhport, uint8_t stage, tusb
421421
/* Standard AS Isochronous Feedback Endpoint Descriptor(4.10.2.1) */
422422
#define TUD_AUDIO_DESC_STD_AS_ISO_FB_EP_LEN 7
423423
#define TUD_AUDIO_DESC_STD_AS_ISO_FB_EP(_ep, _interval) \
424-
TUD_AUDIO_DESC_STD_AS_ISO_FB_EP_LEN, TUSB_DESC_ENDPOINT, _ep, (uint8_t) (TUSB_XFER_ISOCHRONOUS | TUSB_ISO_EP_ATT_NO_SYNC | TUSB_ISO_EP_ATT_EXPLICIT_FB), U16_TO_U8S_LE(4), _interval
424+
TUD_AUDIO_DESC_STD_AS_ISO_FB_EP_LEN, TUSB_DESC_ENDPOINT, _ep, (uint8_t) ((uint8_t)TUSB_XFER_ISOCHRONOUS | (uint8_t)TUSB_ISO_EP_ATT_NO_SYNC | (uint8_t)TUSB_ISO_EP_ATT_EXPLICIT_FB), U16_TO_U8S_LE(4), _interval
425425

426426
// AUDIO simple descriptor (UAC2) for 1 microphone input
427427
// - 1 Input Terminal, 1 Feature Unit (Mute and Volume Control), 1 Output Terminal, 1 Clock Source

tools/sdk/esp32s2/include/arduino_tinyusb/tinyusb/src/host/hcd.h

+3
Original file line numberDiff line numberDiff line change
@@ -130,6 +130,9 @@ bool hcd_configure(uint8_t rhport, uint32_t cfg_id, const void* cfg_param) TU_AT
130130
// Initialize controller to host mode
131131
bool hcd_init(uint8_t rhport);
132132

133+
// De-initialize controller
134+
bool hcd_deinit(uint8_t rhport);
135+
133136
// Interrupt Handler
134137
void hcd_int_handler(uint8_t rhport, bool in_isr);
135138

tools/sdk/esp32s2/include/arduino_tinyusb/tinyusb/src/host/hub.h

+6-7
Original file line numberDiff line numberDiff line change
@@ -187,24 +187,23 @@ bool hub_port_get_status (uint8_t hub_addr, uint8_t hub_port, void* resp,
187187
bool hub_edpt_status_xfer(uint8_t dev_addr);
188188

189189
// Reset a port
190-
static inline bool hub_port_reset(uint8_t hub_addr, uint8_t hub_port,
191-
tuh_xfer_cb_t complete_cb, uintptr_t user_data)
192-
{
190+
TU_ATTR_ALWAYS_INLINE static inline
191+
bool hub_port_reset(uint8_t hub_addr, uint8_t hub_port, tuh_xfer_cb_t complete_cb, uintptr_t user_data) {
193192
return hub_port_set_feature(hub_addr, hub_port, HUB_FEATURE_PORT_RESET, complete_cb, user_data);
194193
}
195194

196195
// Clear Reset Change
197-
static inline bool hub_port_clear_reset_change(uint8_t hub_addr, uint8_t hub_port,
198-
tuh_xfer_cb_t complete_cb, uintptr_t user_data)
199-
{
196+
TU_ATTR_ALWAYS_INLINE static inline
197+
bool hub_port_clear_reset_change(uint8_t hub_addr, uint8_t hub_port, tuh_xfer_cb_t complete_cb, uintptr_t user_data) {
200198
return hub_port_clear_feature(hub_addr, hub_port, HUB_FEATURE_PORT_RESET_CHANGE, complete_cb, user_data);
201199
}
202200

203201

204202
//--------------------------------------------------------------------+
205203
// Internal Class Driver API
206204
//--------------------------------------------------------------------+
207-
void hub_init (void);
205+
bool hub_init (void);
206+
bool hub_deinit (void);
208207
bool hub_open (uint8_t rhport, uint8_t dev_addr, tusb_desc_interface_t const *itf_desc, uint16_t max_len);
209208
bool hub_set_config (uint8_t dev_addr, uint8_t itf_num);
210209
bool hub_xfer_cb (uint8_t dev_addr, uint8_t ep_addr, xfer_result_t event, uint32_t xferred_bytes);

tools/sdk/esp32s2/include/arduino_tinyusb/tinyusb/src/host/usbh.h

+4
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,11 @@ bool tuh_configure(uint8_t rhport, uint32_t cfg_id, const void* cfg_param);
109109
// Init host stack
110110
bool tuh_init(uint8_t rhport);
111111

112+
// Deinit host stack on rhport
113+
bool tuh_deinit(uint8_t rhport);
114+
112115
// Check if host stack is already initialized with any roothub ports
116+
// To check if an rhport is initialized, use tuh_rhport_is_active()
113117
bool tuh_inited(void);
114118

115119
// Task function should be called in main/rtos loop, extended version of tuh_task()

tools/sdk/esp32s2/include/arduino_tinyusb/tinyusb/src/host/usbh_pvt.h

+2-4
Original file line numberDiff line numberDiff line change
@@ -50,11 +50,9 @@ enum {
5050
//--------------------------------------------------------------------+
5151

5252
typedef struct {
53-
#if CFG_TUSB_DEBUG >= CFG_TUH_LOG_LEVEL
5453
char const* name;
55-
#endif
56-
57-
void (* const init )(void);
54+
bool (* const init )(void);
55+
bool (* const deinit )(void);
5856
bool (* const open )(uint8_t rhport, uint8_t dev_addr, tusb_desc_interface_t const * itf_desc, uint16_t max_len);
5957
bool (* const set_config )(uint8_t dev_addr, uint8_t itf_num);
6058
bool (* const xfer_cb )(uint8_t dev_addr, uint8_t ep_addr, xfer_result_t result, uint32_t xferred_bytes);

0 commit comments

Comments
 (0)