mirror of
https://github.com/sle118/squeezelite-esp32.git
synced 2026-01-27 04:40:48 +03:00
full i2s fix & loudness limited log
This commit is contained in:
@@ -77,7 +77,7 @@ cspotPlayer::cspotPlayer(const char* name, httpd_handle_t server, int port, cspo
|
||||
|
||||
cJSON *item, *config = config_alloc_get_cjson("cspot_config");
|
||||
if ((item = cJSON_GetObjectItem(config, "volume")) != NULL) volume = item->valueint;
|
||||
if ((item = cJSON_GetObjectItem(config, "bitrate")) != NULL) bitrate = item->valueint;
|
||||
if ((item = cJSON_GetObjectItem(config, "bitrate")) != NULL) bitrate = item->valueint;
|
||||
if ((item = cJSON_GetObjectItem(config, "deviceName") ) != NULL) this->name = item->valuestring;
|
||||
else this->name = name;
|
||||
cJSON_Delete(config);
|
||||
@@ -306,8 +306,9 @@ void cspotPlayer::runTask() {
|
||||
// Register mdns service, for spotify to find us
|
||||
bell::MDNSService::registerService( blob->getDeviceName(), "_spotify-connect", "_tcp", "", serverPort,
|
||||
{ {"VERSION", "1.0"}, {"CPath", "/spotify_info"}, {"Stack", "SP"} });
|
||||
|
||||
CSPOT_LOG(info, "CSpot instance service name %s (id %s)", blob->getDeviceName().c_str(), blob->getDeviceId().c_str());
|
||||
|
||||
static int count = 0;
|
||||
// gone with the wind...
|
||||
while (1) {
|
||||
clientConnected.wait();
|
||||
|
||||
@@ -163,15 +163,11 @@ static bool cmd_handler(cspot_event_t event, ...) {
|
||||
*/
|
||||
static void cspot_sink_start(nm_state_t state_id, int sub_state) {
|
||||
const char *hostname;
|
||||
uint8_t mac[6];
|
||||
|
||||
cmd_handler_chain = cspot_cbs.cmd;
|
||||
network_get_hostname(&hostname);
|
||||
|
||||
esp_netif_get_mac(network_get_active_interface(), mac);
|
||||
for (int i = 0; i < 6; i++) sprintf(deviceId + 2*i, "%02x", mac[i]);
|
||||
|
||||
ESP_LOGI(TAG, "Starting Spotify (CSpot) servicename %s with id %s", hostname, deviceId);
|
||||
ESP_LOGI(TAG, "starting Spotify on host %s", hostname);
|
||||
|
||||
int port;
|
||||
httpd_handle_t server = http_get_server(&port);
|
||||
|
||||
Reference in New Issue
Block a user