Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

spresense: Pass the correct USB bus speed after restart #4245

Merged
merged 5 commits into from
Feb 25, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion lib/tinyusb
Submodule tinyusb updated 183 files
10 changes: 0 additions & 10 deletions ports/atmel-samd/boards/qtpy_m0_haxpress/mpconfigboard.mk
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,4 @@ CIRCUITPY_I2CPERIPHERAL = 0
CIRCUITPY_MSGPACK = 0

SUPEROPT_GC = 0

CFLAGS_BOARD = --param max-inline-insns-auto=15
ifeq ($(TRANSLATION), zh_Latn_pinyin)
RELEASE_NEEDS_CLEAN_BUILD = 1
CFLAGS_INLINE_LIMIT = 35
endif
ifeq ($(TRANSLATION), de_DE)
RELEASE_NEEDS_CLEAN_BUILD = 1
CFLAGS_INLINE_LIMIT = 35
SUPEROPT_VM = 0
endif
2 changes: 1 addition & 1 deletion ports/cxd56/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ LDFLAGS = \
--end-group \
-L$(BUILD) \

CFLAGS += -DCFG_TUSB_MCU=OPT_MCU_CXD56 -DCFG_TUD_MIDI_RX_BUFSIZE=512 -DCFG_TUD_CDC_RX_BUFSIZE=512 -DCFG_TUD_MIDI_TX_BUFSIZE=512 -DCFG_TUD_CDC_TX_BUFSIZE=512 -DCFG_TUD_MSC_BUFSIZE=512 $(CFLAGS_MOD)
CFLAGS += -DCFG_TUSB_MCU=OPT_MCU_CXD56 -DCFG_TUD_MIDI_RX_BUFSIZE=512 -DCFG_TUD_CDC_RX_BUFSIZE=1024 -DCFG_TUD_MIDI_TX_BUFSIZE=512 -DCFG_TUD_CDC_TX_BUFSIZE=1024 -DCFG_TUD_MSC_BUFSIZE=512 $(CFLAGS_MOD)

SRC_COMMON_HAL_EXPANDED = $(addprefix shared-bindings/, $(SRC_COMMON_HAL)) \
$(addprefix shared-bindings/, $(SRC_BINDINGS_ENUMS)) \
Expand Down
6 changes: 4 additions & 2 deletions shared-module/usb_hid/Device.c
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,8 @@ static usb_hid_device_obj_t* get_hid_device(uint8_t report_id) {
}

// Callbacks invoked when receive Get_Report request through control endpoint
uint16_t tud_hid_get_report_cb(uint8_t report_id, hid_report_type_t report_type, uint8_t* buffer, uint16_t reqlen) {
uint16_t tud_hid_get_report_cb(uint8_t itf, uint8_t report_id, hid_report_type_t report_type, uint8_t* buffer, uint16_t reqlen) {
(void) itf;
// only support Input Report
if ( report_type != HID_REPORT_TYPE_INPUT ) return 0;

Expand All @@ -83,7 +84,8 @@ uint16_t tud_hid_get_report_cb(uint8_t report_id, hid_report_type_t report_type,
}

// Callbacks invoked when receive Set_Report request through control endpoint
void tud_hid_set_report_cb(uint8_t report_id, hid_report_type_t report_type, uint8_t const* buffer, uint16_t bufsize) {
void tud_hid_set_report_cb(uint8_t itf, uint8_t report_id, hid_report_type_t report_type, uint8_t const* buffer, uint16_t bufsize) {
(void) itf;
if (report_type == HID_REPORT_TYPE_INVALID) {
report_id = buffer[0];
buffer++;
Expand Down
5 changes: 3 additions & 2 deletions supervisor/shared/usb/usb_desc.c
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,9 @@ uint8_t const * tud_descriptor_configuration_cb(uint8_t index) {
// Invoked when received GET HID REPORT DESCRIPTOR
// Application return pointer to descriptor
// Descriptor contents must exist long enough for transfer to complete
uint8_t const * tud_hid_descriptor_report_cb(void) {
return hid_report_descriptor;
uint8_t const * tud_hid_descriptor_report_cb(uint8_t itf) {
(void) itf;
return hid_report_descriptor;
}
#endif

Expand Down