mirror of
https://github.com/sle118/squeezelite-esp32.git
synced 2025-12-07 20:17:04 +03:00
sink name corrections
This commit is contained in:
@@ -39,8 +39,8 @@
|
||||
#define BT_RC_TG_TAG "RCTG"
|
||||
#define BT_RC_CT_TAG "RCCT"
|
||||
|
||||
#ifndef CONFIG_BT_SINK_NAME
|
||||
#define CONFIG_BT_SINK_NAME "default"
|
||||
#ifndef CONFIG_BT_NAME
|
||||
#define CONFIG_BT_NAME "ESP32-BT"
|
||||
#endif
|
||||
|
||||
extern char current_namespace[];
|
||||
@@ -468,11 +468,11 @@ static void bt_av_hdl_stack_evt(uint16_t event, void *p_param)
|
||||
case BT_APP_EVT_STACK_UP: {
|
||||
/* set up device name */
|
||||
nvs_handle nvs;
|
||||
char dev_name[32] = CONFIG_BT_SINK_NAME;
|
||||
char dev_name[32] = CONFIG_BT_NAME;
|
||||
|
||||
if (nvs_open(current_namespace, NVS_READONLY, &nvs) == ESP_OK) {
|
||||
size_t len = 31;
|
||||
nvs_get_str(nvs, "bt_sink_name", dev_name, &len);
|
||||
nvs_get_str(nvs, "bt_name", dev_name, &len);
|
||||
nvs_close(nvs);
|
||||
}
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
#include "trace.h"
|
||||
|
||||
#ifndef CONFIG_AIRPLAY_NAME
|
||||
#define CONFIG_AIRPLAY_NAME "disabled"
|
||||
#define CONFIG_AIRPLAY_NAME "ESP32-AirPlay"
|
||||
#endif
|
||||
|
||||
static const char * TAG = "platform";
|
||||
@@ -60,7 +60,7 @@ void raop_sink_init(raop_cmd_cb_t cmd_cb, raop_data_cb_t data_cb) {
|
||||
|
||||
if (nvs_open(current_namespace, NVS_READONLY, &nvs) == ESP_OK) {
|
||||
size_t len = sizeof(sink_name) - 1;
|
||||
nvs_get_str(nvs, "airplay_sink_name", sink_name, &len);
|
||||
nvs_get_str(nvs, "airplay_name", sink_name, &len);
|
||||
nvs_close(nvs);
|
||||
}
|
||||
|
||||
|
||||
@@ -226,7 +226,7 @@ menu "Squeezelite-ESP32"
|
||||
default y
|
||||
help
|
||||
Enable bluetooth sink (Note that you obviously can't at the same time be a Bluetooth receiver and transmitter)
|
||||
config BT_SINK_NAME
|
||||
config BT_NAME
|
||||
depends on BT_SINK
|
||||
string "Name of Bluetooth A2DP device"
|
||||
default "ESP32-BT"
|
||||
|
||||
Reference in New Issue
Block a user