make targets "loadable"

This commit is contained in:
Philippe G
2022-01-20 17:30:36 -08:00
parent 964b94fa1e
commit dbdd0739db
10 changed files with 72 additions and 30 deletions

View File

@@ -21,6 +21,9 @@ menu "Squeezelite-ESP32"
help
Set logging level info|debug|sdebug
endmenu
config TARGET_LOCKED
bool
default n
config AMP_LOCKED
bool
config JACK_LOCKED
@@ -38,9 +41,6 @@ menu "Squeezelite-ESP32"
config MUTE_GPIO_LEVEL
int
default 0
config WELL_KNOWN
bool
default n
menu "Target"
choice OUTPUT_TYPE
prompt "Main system"
@@ -54,20 +54,20 @@ menu "Squeezelite-ESP32"
select I2C_LOCKED
select LED_LOCKED
select SPKFAULT_LOCKED
select WELL_KNOWN
select TARGET_LOCKED
config MUSE
bool "Muse"
select JACK_LOCKED
select BAT_LOCKED
select I2C_LOCKED
select AMP_LOCKED
select WELL_KNOWN
select TARGET_LOCKED
config BASIC_I2C_BT
bool "Generic I2S & Bluetooth"
config TWATCH2020
bool "T-WATCH2020 by LilyGo"
select I2C_LOCKED
select WELL_KNOWN
select TARGET_LOCKED
endchoice
config RELEASE_API
string "Software update URL"
@@ -131,9 +131,14 @@ menu "Squeezelite-ESP32"
default "[{\"gpio\":32, \"pull\":true, \"debounce\":10, \"normal\":{\"pressed\":\"ACTRLS_VOLDOWN\"}}, {\"gpio\":19, \"pull\":true, \"debounce\":40, \"normal\":{\"pressed\":\"ACTRLS_VOLUP\"}}, {\"gpio\":12, \"pull\":true, \"debounce\":40, \"longpress\":1000, \"normal\":{\"pressed\":\"ACTRLS_TOGGLE\"},\"longpress\":{\"pressed\":\"ACTRLS_POWER\"}}]" if MUSE
default ""
config BAT_CONFIG
string
default "channel=7,scale=20.24,atten=0" if SQUEEZEAMP
default "channel=5,scale=1,atten=3,cells=1" if MUSE
default ""
config TARGET
string
default "muse" if MUSE
default ""
endmenu
menu "Audio settings"
@@ -325,7 +330,7 @@ menu "Squeezelite-ESP32"
endmenu
menu "LED configuration"
visible if !WELL_KNOWN
visible if !TARGET_LOCKED
config LED_GREEN_GPIO
int "Green led GPIO"
default 12 if SQUEEZEAMP
@@ -352,7 +357,7 @@ menu "Squeezelite-ESP32"
endmenu
menu "Audio JACK"
visible if !WELL_KNOWN
visible if !TARGET_LOCKED
config JACK_GPIO
int "Jack insertion GPIO"
default 34 if SQUEEZEAMP || MUSE
@@ -366,7 +371,7 @@ menu "Squeezelite-ESP32"
endmenu
menu "Amplifier"
visible if !WELL_KNOWN
visible if !TARGET_LOCKED
config AMP_GPIO
int "Amplifier GPIO"
default 21 if MUSE
@@ -380,7 +385,7 @@ menu "Squeezelite-ESP32"
endmenu
menu "Speaker Fault"
visible if !WELL_KNOWN
visible if !TARGET_LOCKED
config SPKFAULT_GPIO
int "Speaker fault GPIO"
default 2 if SQUEEZEAMP
@@ -394,7 +399,7 @@ menu "Squeezelite-ESP32"
endmenu
menu "Battery measure"
visible if !WELL_KNOWN
visible if !TARGET_LOCKED
config BAT_CONFIG
string "Battery acquisitiong configuration"
help