-
Notifications
You must be signed in to change notification settings - Fork 201
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
5f4e104
commit 1e50526
Showing
13 changed files
with
756 additions
and
27 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
File renamed without changes.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# USB CDC examples - Only ESP32S3 | ||
# Note: In order to try this you need to have a USB connected directly to MCU like in v7 hardware | ||
# ESP_USB+ to GPIO19, ESP_USB- to GPIO20 | ||
|
||
# Select only ONE app_source: | ||
|
||
# Dumb slow terminal example, type and write character in display | ||
#set(app_sources "serial-note.c") | ||
|
||
# Still in research "serial-receive-file.c" IDEA: To make a port of rz (zmodem serial receive protocol to transfer image via serial) | ||
|
||
set(app_sources "msc-sd/msc_main.c") | ||
|
||
set(requires epdiy esp_tinyusb fatfs console) | ||
|
||
if(CONFIG_EXAMPLE_STORAGE_MEDIA_SPIFLASH) | ||
list(APPEND requires wear_levelling) | ||
endif() | ||
|
||
idf_component_register( | ||
SRCS "${app_sources}" | ||
INCLUDE_DIRS . | ||
REQUIRES "${requires}" | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
menu "USB Dev MSC Example Configuration" | ||
|
||
choice EXAMPLE_STORAGE_MEDIA | ||
prompt "Storage Media Used" | ||
default EXAMPLE_STORAGE_MEDIA_SPIFLASH | ||
help | ||
Select the storage media that is exposed to USB host. | ||
|
||
config EXAMPLE_STORAGE_MEDIA_SPIFLASH | ||
bool "SPI FLASH" | ||
|
||
config EXAMPLE_STORAGE_MEDIA_SDMMCCARD | ||
bool "SDMMC CARD" | ||
depends on IDF_TARGET_ESP32S3 | ||
endchoice | ||
|
||
if EXAMPLE_STORAGE_MEDIA_SDMMCCARD | ||
|
||
choice EXAMPLE_SDMMC_BUS_WIDTH | ||
prompt "SD/MMC bus width" | ||
default EXAMPLE_SDMMC_BUS_WIDTH_4 | ||
help | ||
Select the bus width of SD or MMC interface. | ||
Note that even if 1 line mode is used, D3 pin of the SD card must | ||
have a pull-up resistor connected. Otherwise the card may enter | ||
SPI mode, the only way to recover from which is to cycle power to the card. | ||
|
||
config EXAMPLE_SDMMC_BUS_WIDTH_4 | ||
bool "4 lines (D0 - D3)" | ||
|
||
config EXAMPLE_SDMMC_BUS_WIDTH_1 | ||
bool "1 line (D0)" | ||
endchoice | ||
|
||
if SOC_SDMMC_USE_GPIO_MATRIX | ||
|
||
config EXAMPLE_PIN_CMD | ||
int "CMD GPIO number" | ||
default 35 if IDF_TARGET_ESP32S3 | ||
|
||
config EXAMPLE_PIN_CLK | ||
int "CLK GPIO number" | ||
default 36 if IDF_TARGET_ESP32S3 | ||
|
||
config EXAMPLE_PIN_D0 | ||
int "D0 GPIO number" | ||
default 37 if IDF_TARGET_ESP32S3 | ||
|
||
if EXAMPLE_SDMMC_BUS_WIDTH_4 | ||
|
||
config EXAMPLE_PIN_D1 | ||
int "D1 GPIO number" | ||
default 38 if IDF_TARGET_ESP32S3 | ||
|
||
config EXAMPLE_PIN_D2 | ||
int "D2 GPIO number" | ||
default 33 if IDF_TARGET_ESP32S3 | ||
|
||
config EXAMPLE_PIN_D3 | ||
int "D3 GPIO number" | ||
default 34 if IDF_TARGET_ESP32S3 | ||
|
||
endif # EXAMPLE_SDMMC_BUS_WIDTH_4 | ||
|
||
endif # SOC_SDMMC_USE_GPIO_MATRIX | ||
|
||
endif # EXAMPLE_STORAGE_MEDIA_SDMMCCARD | ||
|
||
endmenu |
File renamed without changes.
Oops, something went wrong.