mirror of
https://github.com/sle118/squeezelite-esp32.git
synced 2026-01-27 12:50:49 +03:00
Merge branch 'master' into nvs_parameters
# Conflicts: # .cproject # Makefile # README.md # components/cmd_nvs/cmd_nvs.c # components/cmd_system/cmd_system.c # components/cmd_system/cmd_system.h # components/driver_bt/CMakeLists.txt # components/wifi-manager/CMakeLists.txt # components/wifi-manager/Kconfig.projbuild # components/wifi-manager/code.js # components/wifi-manager/component.mk # components/wifi-manager/dns_server.c # components/wifi-manager/dns_server.h # components/wifi-manager/http_server.c # components/wifi-manager/http_server.h # components/wifi-manager/index.html # components/wifi-manager/style.css # components/wifi-manager/wifi_manager.c # components/wifi-manager/wifi_manager.h # main/CMakeLists.txt # main/console.c # main/esp_app_main.c # sdkconfig.defaults
This commit is contained in:
@@ -31,11 +31,6 @@
|
||||
#ifdef CONFIG_FREERTOS_USE_STATS_FORMATTING_FUNCTIONS
|
||||
#define WITH_TASKS_INFO 1
|
||||
#endif
|
||||
#define LWS_MAGIC_REBOOT_TYPE_ADS 0x50001ffc
|
||||
#define LWS_MAGIC_REBOOT_TYPE_REQ_FACTORY 0xb00bcafe
|
||||
#define LWS_MAGIC_REBOOT_TYPE_FORCED_FACTORY 0xfaceb00b
|
||||
#define LWS_MAGIC_REBOOT_TYPE_FORCED_FACTORY_BUTTON 0xf0cedfac
|
||||
#define LWS_MAGIC_REBOOT_TYPE_REQ_FACTORY_ERASE_OTA 0xfac0eeee
|
||||
|
||||
|
||||
static const char * TAG = "platform_esp32";
|
||||
|
||||
@@ -88,12 +88,17 @@ void set_volume(unsigned left, unsigned right) {
|
||||
|
||||
bool test_open(const char *device, unsigned rates[], bool userdef_rates) {
|
||||
memset(rates, 0, MAX_SUPPORTED_SAMPLERATES * sizeof(unsigned));
|
||||
if (!strcmp(device, "BT")) {
|
||||
rates[0] = 44100;
|
||||
} else {
|
||||
unsigned _rates[] = { 192000, 176400, 96000, 88200, 48000, 44100, 32000, 24000, 22050, 16000, 12000, 11025, 8000, 0 };
|
||||
if (!strcasecmp(device, "I2S")) {
|
||||
unsigned _rates[] = { 192000, 176400, 96000, 88200, 48000,
|
||||
44100, 32000, 24000, 22050, 16000,
|
||||
12000, 11025, 8000, 0 };
|
||||
memcpy(rates, _rates, sizeof(_rates));
|
||||
}
|
||||
} else if (!strcasecmp(device, "SPDIF")) {
|
||||
unsigned _rates[] = { 48000, 44100, 0 };
|
||||
memcpy(rates, _rates, sizeof(_rates));
|
||||
} else {
|
||||
rates[0] = 44100;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user