-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(examples): improve example configuration (#140)
* feat(examples): improve example configuration * Update all peripheral examples to use espp::I2c class for cleaner / more reusable code * Update all peripheral examples to have a Kconfig.projbuild file for configuring the i2c pins - with default hardware selecting relevant targets for the example as well as CUSTOM hardware config to configure your own i2c pins on your hardware * fix(i2c example): reduce scope of read_data variable * fix(bm8563 example): fix kconfig * fix(controller example): add missing component * fix(st25dv example): added back missing config for nfc wifi settings * doc: rebuild
- Loading branch information
Showing
144 changed files
with
1,295 additions
and
1,082 deletions.
There are no files selected for viewing
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
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,39 @@ | ||
menu "Example Configuration" | ||
|
||
choice EXAMPLE_HARDWARE | ||
prompt "Hardware" | ||
default EXAMPLE_HARDWARE_QTPYPICO | ||
help | ||
Select the hardware to run this example on. | ||
|
||
config EXAMPLE_HARDWARE_QTPYPICO | ||
depends on IDF_TARGET_ESP32 | ||
bool "Qt Py PICO" | ||
|
||
config EXAMPLE_HARDWARE_QTPYS3 | ||
depends on IDF_TARGET_ESP32S3 | ||
bool "Qt Py S3" | ||
|
||
config EXAMPLE_HARDWARE_CUSTOM | ||
bool "Custom" | ||
endchoice | ||
|
||
config EXAMPLE_I2C_SCL_GPIO | ||
int "SCL GPIO Num" | ||
range 0 50 | ||
default 19 if EXAMPLE_HARDWARE_QTPYPICO | ||
default 40 if EXAMPLE_HARDWARE_QTPYS3 | ||
default 19 if EXAMPLE_HARDWARE_CUSTOM | ||
help | ||
GPIO number for I2C Master clock line. | ||
|
||
config EXAMPLE_I2C_SDA_GPIO | ||
int "SDA GPIO Num" | ||
range 0 50 | ||
default 22 if EXAMPLE_HARDWARE_QTPYPICO | ||
default 41 if EXAMPLE_HARDWARE_QTPYS3 | ||
default 22 if EXAMPLE_HARDWARE_CUSTOM | ||
help | ||
GPIO number for I2C Master data line. | ||
|
||
endmenu |
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
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
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,46 @@ | ||
menu "Example Configuration" | ||
|
||
choice EXAMPLE_HARDWARE | ||
prompt "Hardware" | ||
default EXAMPLE_HARDWARE_QTPYS3 | ||
help | ||
Select the hardware to run this example on. | ||
|
||
config EXAMPLE_HARDWARE_QTPYPICO | ||
depends on IDF_TARGET_ESP32 | ||
bool "Qt Py PICO" | ||
|
||
config EXAMPLE_HARDWARE_QTPYS3 | ||
depends on IDF_TARGET_ESP32S3 | ||
bool "Qt Py S3" | ||
|
||
config EXAMPLE_HARDWARE_CUSTOM | ||
bool "Custom" | ||
endchoice | ||
|
||
config EXAMPLE_ALERT_GPIO | ||
int "Alert GPIO Num" | ||
range 0 50 | ||
default 18 | ||
help | ||
GPIO number for alert pin. | ||
|
||
config EXAMPLE_I2C_SCL_GPIO | ||
int "SCL GPIO Num" | ||
range 0 50 | ||
default 19 if EXAMPLE_HARDWARE_QTPYPICO | ||
default 40 if EXAMPLE_HARDWARE_QTPYS3 | ||
default 19 if EXAMPLE_HARDWARE_CUSTOM | ||
help | ||
GPIO number for I2C Master clock line. | ||
|
||
config EXAMPLE_I2C_SDA_GPIO | ||
int "SDA GPIO Num" | ||
range 0 50 | ||
default 22 if EXAMPLE_HARDWARE_QTPYPICO | ||
default 41 if EXAMPLE_HARDWARE_QTPYS3 | ||
default 22 if EXAMPLE_HARDWARE_CUSTOM | ||
help | ||
GPIO number for I2C Master data line. | ||
|
||
endmenu |
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
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
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,39 @@ | ||
menu "Example Configuration" | ||
|
||
choice EXAMPLE_HARDWARE | ||
prompt "Hardware" | ||
default EXAMPLE_HARDWARE_QTPYS3 | ||
help | ||
Select the hardware to run this example on. | ||
|
||
config EXAMPLE_HARDWARE_QTPYPICO | ||
depends on IDF_TARGET_ESP32 | ||
bool "Qt Py PICO" | ||
|
||
config EXAMPLE_HARDWARE_QTPYS3 | ||
depends on IDF_TARGET_ESP32S3 | ||
bool "Qt Py S3" | ||
|
||
config EXAMPLE_HARDWARE_CUSTOM | ||
bool "Custom" | ||
endchoice | ||
|
||
config EXAMPLE_I2C_SCL_GPIO | ||
int "SCL GPIO Num" | ||
range 0 50 | ||
default 19 if EXAMPLE_HARDWARE_QTPYPICO | ||
default 40 if EXAMPLE_HARDWARE_QTPYS3 | ||
default 19 if EXAMPLE_HARDWARE_CUSTOM | ||
help | ||
GPIO number for I2C Master clock line. | ||
|
||
config EXAMPLE_I2C_SDA_GPIO | ||
int "SDA GPIO Num" | ||
range 0 50 | ||
default 22 if EXAMPLE_HARDWARE_QTPYPICO | ||
default 41 if EXAMPLE_HARDWARE_QTPYS3 | ||
default 22 if EXAMPLE_HARDWARE_CUSTOM | ||
help | ||
GPIO number for I2C Master data line. | ||
|
||
endmenu |
Oops, something went wrong.