Commit Graph

46 Commits

Author SHA1 Message Date
Tomas Rezucha
cf59a8a2bd Merge branch 'feature/usb_v5_qol' into 'master'
usb: USB IDF v5 update

Closes IDF-4690 and IDF-5767

See merge request espressif/esp-idf!19875
2022-09-08 19:50:22 +08:00
Tomas Rezucha
fac9579d95 usb_host: Use MSC driver from component registry 2022-09-05 20:14:57 +02:00
Tomas Rezucha
d95ba21328 usb_host: Use CDC driver from component registry 2022-09-05 20:14:56 +02:00
Martin Valik
3bcd9ceefe USB: Add usb uvc example
Closes https://github.com/espressif/esp-idf/issues/6493
2022-08-29 10:44:39 +02:00
Tomas Rezucha
d777b790d0 tinyusb: Add TinyUSB example tests 2022-08-10 14:51:18 +02:00
Ivan Grokhotkov
e596c84d49 build system: re-add -Wno-format as private flag for some example components 2022-08-03 16:42:47 +04:00
Tomas Rezucha
45e8115dc6 usb: Add HID device example
Closes https://github.com/espressif/esp-idf/issues/6839
Closes https://github.com/espressif/esp-idf/issues/7700
2022-07-27 05:31:09 +00:00
David Cermak
5c383d7b73 esp_netif/lwip: Fix deps cycles to "lwip -> esp_netif -> phy-drivers"
Fix dependency tree so that lwip doesn't depend on any specific network
interface component.
Network interface drivers shall depend on esp_netif.
esp_netif shall depend on lwip (but not on any specific interface
driver) -- it optionally depends on vfs and esp_eth (need ethernet
header for L2/bridge mode)
2022-07-20 14:59:07 +02:00
jiangguangming
e0d9220a6e example: peripherals/usb: fix typo naming of local variables 2022-07-20 09:36:24 +08:00
Adam Múdry
2dfaec3106 usb: Added MIDI example + fixed TinyUSB MIDI config
Closes https://github.com/espressif/esp-idf/issues/8541
2022-06-29 14:02:00 +00:00
Tomas Rezucha
5d202aa401 usb: Clean-up TinyUSB unnecessary code 2022-06-09 10:56:39 +02:00
Djordje Nedic
facab8c5a7 tools: Increase the minimal supported CMake version to 3.16
This updates the minimal supported version of CMake to 3.16, which in turn enables us to use more CMake features and have a cleaner build system.
This is the version that provides most new features and also the one we use in our latest docker image for CI.
2022-06-01 06:35:02 +00:00
Martin Valik
be452efd4a msc example made hot plugable
Closes https://github.com/espressif/esp-idf/issues/8386
2022-05-10 18:48:37 +02:00
Tomas Rezucha
7fc0c14f4d usb_host: Add Virtual COM Port CDC example
This example implements usual UART/USB convertor driver.
Closes https://github.com/espressif/esp-idf/issues/8645
2022-04-22 09:50:46 +02:00
Tomas Rezucha
880b5a4bef usb_host: Unify CDC event callbacks
And return error code from C++ close method.
2022-04-22 09:50:46 +02:00
Tomas Rezucha
0428efa4ad usb_host: Propagate new device connection to user
Closes https://github.com/espressif/esp-idf/issues/8762
2022-04-22 09:50:39 +02:00
Tomas Rezucha
0ab17ec695 usb_host: Enable custom CDC commands
This new API allows further extension for vendor specific commands
2022-04-22 09:50:38 +02:00
Tomas Rezucha
7c2cf30109 usb_host: Update MSC test for fatfs 0.14b 2022-03-21 18:34:25 +01:00
Tomas Rezucha
3abeee00d0 usb_host: Pin test task to core 0
When we try to uninstall usb_host library on multi-core SoC (ESP32S3)
the USB interrupt can be triggered even after it was disabled on one CPU
2022-03-21 18:34:25 +01:00
Tomas Rezucha
9049230e4a usb_host: Rename symbols that conflict with TinyUSB 2022-03-21 18:34:25 +01:00
Tomas Rezucha
e3ba980d11 usb_host: Use USB_Host library calls for desc printing 2022-03-21 18:34:25 +01:00
Tomas Rezucha
3074981dcb usb_host: Update MSC tests for running in CI 2022-03-21 18:34:25 +01:00
Tomas Rezucha
6206302787 ci: Add USB Host CDC and MSC pytests to pipeline 2022-03-21 18:34:24 +01:00
Tomas Rezucha
7d950a63cc usb_host: Add Mock device to CDC tests 2022-03-21 18:34:24 +01:00
Tomas Rezucha
913d53384f usb_host: Update CDC tests for latest USB Host 2022-03-21 18:34:24 +01:00
Tomas Rezucha
f5f865df07 Merge branch 'fix/usb_host/cdc_build' into 'master'
usb_host: Don't build CDC host driver for unsupported targets

See merge request espressif/esp-idf!17517
2022-03-18 16:37:38 +08:00
Tomas Rezucha
c8fc4d226a usb_host: Don't build CDC host driver for unsupported targets 2022-03-17 13:10:29 +01:00
Anton Maklakov
4c865baae4 managed components: fix version references to allow implicit updates according to semver
Syntax details: https://devhints.io/semver
2022-03-11 13:49:26 +07:00
Adam Múdry
bb8587a139 fatfs: Update to version 0.14b
Updated FATFS to 0.14b from 0.13c and patched for ESP32
2022-02-21 14:54:55 +01:00
Martin Valik
68ff1b8c07 Bugfix: omit MSC reset during initialization 2022-01-27 10:03:40 +01:00
Darian
d95b15c557 Merge branch 'feature/usb_host_cleanup' into 'master'
USB: Host stack cleanup and QOL update

Closes IDFGH-6120, IDF-2747, IDFGH-4592, and IDFGH-6402

See merge request espressif/esp-idf!16349
2022-01-06 12:18:47 +00:00
Darian Leung
630a6b54c2 usb: Add USB Host Library Example
The commit adds a basic example for the USB Host Library
2022-01-06 15:15:15 +08:00
Darian Leung
b6dfadb168 usb: Update USB Host Library
This commit updates the USB Host Library as follows:

- usb_helpers.h
    - Removed dependency on USB Host Library API
    - Added function to print string descriptors
- usbh
    - Fixed bug where an interface/endpoint could be claimed/allocated multiple times
    - Removed redundant device ref_count change
- Added unit test for USB Host Library API usage
2022-01-06 15:14:10 +08:00
Darian Leung
1aad12468a usb: Hub Driver Update and Refactor
Hub Driver is refactored as follows:

This commit update and refactors the Hub Driver as follows:

- Refactored enumeration state machine and stage functions
    - Enumeration stage is now incremented
    - Combined transfer stages of enumeration into common functions
- Comments updated
- Fixed usbh_hal_disable_debounce_lock() that would cause root_port_handle_events()
    to fail the HCD_PORT_CMD_RESET call because the previous port connection interrupt
    was not cleared.

The following features were added to the Hub Driver

- Enumeration config descriptor is now fetched in two separate stages
    - Header is fetched first to determine the wTotalLength of the descriptor
    - Fetching the full descriptor will request exactly wTotalLength bytes
    - This works around some non-compliant devices that will babble/return zero
        when requesting a length > wTotalLength
    - Closes https://github.com/espressif/esp-idf/issues/7799
- Enumeration now stores string descriptors
    - The Manufacturer, Product, and Serial Number string descriptors are
        now read and stored during enumeration
    - String descriptors are now part of usb_device_info_t
- Added unit test to test enumeration
2022-01-06 15:11:13 +08:00
Darian Leung
854127a57c usb: USB Host stack uses USB PHY driver
This commit updates the USB Host stack to use the USB PHY driver. The
USB PHY and the OTG Controller should now both be setup/deleted using
usb_new_phy() and usb_del_phy() respectively.

- The hcd_install() now expects the USB PHY and OTG Contorller to be
    already setup before it is called
- usb_host_install() now has an option to skip calling usb_del_phy() if
    the user wants to setup their own USB PHY (e.g., in the case of using
    and external PHY).
- CDC-ACM and MSC examples/test updated to use internal PHY

Closes https://github.com/espressif/esp-idf/issues/8061
2022-01-06 15:09:39 +08:00
Tomas Rezucha
6330d5d312 usb: Extend CDC device with second CDC channel
Closes https://github.com/espressif/esp-idf/issues/7020
Closes https://github.com/espressif/esp-idf/pull/8011
2022-01-05 08:18:03 +01:00
Martin Valik
73dce765d5 USB: added MSC Host Driver with VFS support
Closes https://github.com/espressif/esp-idf/issues/6401
2021-12-20 12:39:45 +01:00
Tomas Rezucha
dd1b698075 usb: Add USB host CDC-ACM class driver 2021-12-09 10:28:46 +01:00
Marius Vikhammer
49eb42928a docs: fix broken link in usb example readme 2021-07-28 12:44:40 +08:00
morris
81448dcae8 tiny_usb: rename Kconfig name
1. Renamed Kconfig file of tinyusb (distinguish tinyusb stack from usb
   peripheral)
2. bugfix/typofix/doc update of tinyusb
2021-07-22 10:43:10 +08:00
Andrei Gramakov
1d1896d409 tinyusb: Add fix for tinyusb reading
Closes IDF-2029
2021-01-08 14:21:26 +00:00
Angus Gratton
66fb5a29bb Whitespace: Automated whitespace fixes (large commit)
Apply the pre-commit hook whitespace fixes to all files in the repo.

(Line endings, blank lines at end of file, trailing whitespace)
2020-11-11 07:36:35 +00:00
Andrei Gramakov
84aa1c0cc3 usb: cdc support, streams redirection; ci, examples upd
tusb: cdc, tasks encapsulation, callbacks api, multiple interfaces
examples: added serial interface and usb console
ci: reimplemented cmake/make test in python with ignore lists

IDF-578
2020-08-06 15:26:08 +02:00
Ivan Grokhotkov
e0177eb252 examples/tusb_sample_descriptor: default to esp32s2 target 2020-04-29 10:04:13 +02:00
Fu Hanxi
5b2fa1a5ad build_app: make multi target support readable 2020-04-09 16:40:57 +08:00
Andrei Gramakov
9d059be165 usb: added a tinyusb component; ci; soc.
ci: ignore s2-only projects from the cmake-make test
soc: refactored the usb part
2020-03-09 07:55:06 +01:00