Announcement

Collapse
No announcement yet.

ANNOUNCE: Squeezelite-ESP32 (dedicated thread)

Collapse
X
 
  • Time
  • Show
Clear All
new posts

  • Originally posted by CJS
    Good to hear that it works, and that you can now play the FLAC files with empty seektable!

    Do I understand correctly that the first time you flashed the squeezelite.bin from the SqueezeAMP firmware zip, and the second time the squeezelite.bin from from the generic I2S firmware zip? I suggested to use the generic I2S firmware, since the SqueezeAMP firmware overrules some NVS settings, including the dac_config setting. In fact the I2S firmware (16-bit or 32-bit) can be used for all devices, provided that the correct NVS configuration settings are entered. For more info see the squeezelite-ESP32 README.

    I do not really understand why the DAC32 works OK with empty dac_config line. This seems to indicate that the PCM5122 DAC in the DAC32 works OK with default I2S settings, and does not require additional configuration via I2C.
    I used the same squeezelite.bin file both times. Not sure why I wasn't getting audio output the first time, but I did the second time. Very strange indeed! I followed your instructions in Post #1879. Both times, I used the same squeezelite.bin that I extracted from that zip.

    I've uploaded my config below, in case there's a clue as to why it works with the dac_config line empty. Might also help others with the DAC32 that are interested in moving away from the PolyVection firmware in order to receive ongoing updates/support.

    Code:
    {
      "a2dp_ctmt": "1000",
      "a2dp_ctrld": "500",
      "a2dp_dev_name": "DAC32-Office",
      "a2dp_sink_name": "SMSL BT4.2",
      "a2dp_spin": "0000",
      "actrls_config": "",
      "airplay_name": "DAC32-Office",
      "airplay_port": "5000",
      "ap_channel": "1",
      "ap_ip_address": "192.168.4.1",
      "ap_ip_gateway": "192.168.4.1",
      "ap_ip_netmask": "255.255.255.0",
      "ap_pwd": "squeezelite",
      "ap_ssid": "DAC32-Office",
      "autoexec": "1",
      "autoexec1": "squeezelite -b 500:2000 -d all=info -C 30 -W -n \"DAC32-Office\" -o I2S",
      "bat_config": "",
      "bt_name": "DAC32-Office",
      "bt_sink_pin": "1234",
      "bt_sink_volume": "127",
      "bypass_wm": "0",
      "cspot_config": "{\t\"deviceName\":\t\"DAC32-Office\",\t\"bitrate\":\t160}",
      "dac_config": "",
      "dac_controlset": "",
      "dhcp_tmout": "8",
      "display_config": "",
      "enable_airplay": "1",
      "enable_bt_sink": "1",
      "enable_cspot": "1",
      "equalizer": "0,0,0,0,0,0,0,0,0,0",
      "eth_config": "",
      "ethtmout": "8",
      "gpio_exp_config": "",
      "host_name": "DAC32-Office",
      "i2c_config": "",
      "jack_mutes_amp": "n",
      "led_brightness": "",
      "lms_ctrls_raw": "n",
      "metadata_config": "",
      "model_config": "",
      "ota_erase_blk": "249856",
      "ota_prio": "6",
      "ota_stack": "10240",
      "pollmin": "15",
      "pollmx": "600",
      "rel_api": "https://api.github.com/repos/sle118/squeezelite-esp32/releases",
      "release_url": "https://github.com/sle118/squeezelite-esp32/releases",
      "rotary_config": "",
      "set_GPIO": "",
      "spdif_config": "",
      "spi_config": "",
      "stats": "n",
      "target": "",
      "telnet_block": "500",
      "telnet_buffer": "40000",
      "telnet_enable": "",
      "wifi_smode": "f"
    }
    ​
    Thanks again CJS for your sleuthing work in figuring out the issue!

    Any suggestions as to tweaks I can try to improve the configuration are appreciated. I'm currently connecting the DAC32 to a Bose 2.1 speaker system, so definitely not hifi, but not horrible sound quality either.

    Cheers,
    Brawny

    Comment


    • Originally posted by brawny
      Any suggestions as to tweaks I can try to improve the configuration are appreciated.
      Hi,
      there are some more things to tweak, please see my previous comment (https://forums.slimdevices.com/forum...48#post1487948):
      Code:
      "autoexec1": "squeezelite -b 500:2000 -d all=info -C 30 -W -n \"DAC32\" -o I2S -r 44100-96000",
      "dac_config": "model=TAS57xx,bck=33,ws=25,do=32,mute=14:0,sda=27,scl=26",
      "set_GPIO": "12=green:0,13=red:0",
      The first line will limit the sample rate to appropriate values, the second line provides the DAC config (if required), the last enables the LED's. You can also directly compare your setting with the configuration from the original firmware: https://gitlab.com/polyvection/sw/es...onfig.defaults
      Daniel
      Transporter, Squeezelite-esp32 (SSD1322+IR+Cirrus CS43198), DAC32, 2x SB Radio, 2x SB3, Touch, PiCorePlayer8 (Audiophonics RASPTOUCH i-Sabre+IR)

      Comment


      • brawny, in addition to the remarks of df77, I can tell that I have compared schematics of SqueezeAMP and DAC32. It appears that the DAC32 uses the exact same IO pins of the ESP32 module for I2S (digital audio interface, signals bck, ws and do), I2C (digital control bus, signals scl and sda) and mute. The DAC32 does not use the same DAC as SqueezeAMP, but both DACs are from Texas instruments, and both have the same I2C address.

        An explanation why the DAC32 appears to work with empty dac_config in NVS when using the generic I2S firmware might be that squeeze-esp32 was in first instance developed for SqueezeAMP. So it may be that the I2S firmware uses the dac_config parameters of SqueezeAMP (that also work for DAC32), when no dac_config definition is found in NVS. This is speculation on my part, and I think that philippe_44 is the only person who could confirm this (or maybe somebody else by scrutinizing the source code).

        Anyway, since you are using the generic I2S firmware, I think it is a good idea to enter the dac_config parameters as indicated by df77 (and earlier by Rasputin_GY) in NVS. So you would need to enter the following in the dac_config field in NVS (copied from https://gitlab.com/polyvection/sw/es...onfig.defaults):
        Code:
        model=TAS57xx,bck=33,ws=25,do=32,sda=27,scl=26,mute=14:0
        Entering these parameters in NVS gives extra assurance that the DAC in the DAC32 is configured correctly.​
        Last edited by CJS; 2023-04-06, 11:06.
        | LMS 8.3.2 on Linux Mint 21.2 | Squeezebox Boom | RPi0W + pCP 8.2.0 + HiFiBerry DAC Zero | ESP Muse Luxe |

        Comment


        • Minor issue. A DAC32 board revision changed the LED. Not sure what happens with generic squeeze-esp32 - status Red/Green may be swapped. https://forums.slimdevices.com/forum...56#post1521456

          The board revision can be identifed by power connector - barrel vs usb-c.

          Comment


          • Regarding the discussion about dac_config, here is how it works

            - the generic I2S binary is fully vanilla, it does assume any specific pinout connections.
            - using the different config in NVS, the I2S binary will be *exactly* as the SqueezeAMP (exactly), there is no SqueezeAMP hardcoded items in the code
            - the GPIOs used for i2s in the generic binary are not set, so unless we have an issue in the online build of the generic I2S firmware, it cannot work
            - most DAC don't need an i2c connection to work
            - the DAC32 might be using one of these, hence it can work, or (most probably), you ran it with a proper DAC32 firmware, it set the key DAC parameters and then you flashed it with I2S generic binary *but* the DAC remained initialized, hence it played. It will likely stop at next power cycle (not reset).

            LMS 8.2 on Odroid-C4 - SqueezeAMP!, 5xRadio, 5xBoom, 2xDuet, 1xTouch, 1xSB3. Sonos PLAY:3, PLAY:5, Marantz NR1603, Foobar2000, ShairPortW, 2xChromecast Audio, Chromecast v1 and v2, Squeezelite on Pi, Yamaha WX-010, AppleTV 4, Airport Express, GGMM E5, RivaArena 1 & 3

            Comment


            • I also uploaded a version that fixes large artwork problem for Opus and Vorbis. It forced me to do a lot of changes including getting rid of the simplification layers above Opus and Vorbis and go directly to the Ogg packetizer... not fun. So more test(ers) will be needed.
              Last edited by philippe_44; 2023-04-07, 19:51.
              LMS 8.2 on Odroid-C4 - SqueezeAMP!, 5xRadio, 5xBoom, 2xDuet, 1xTouch, 1xSB3. Sonos PLAY:3, PLAY:5, Marantz NR1603, Foobar2000, ShairPortW, 2xChromecast Audio, Chromecast v1 and v2, Squeezelite on Pi, Yamaha WX-010, AppleTV 4, Airport Express, GGMM E5, RivaArena 1 & 3

              Comment


              • Originally posted by philippe_44
                Regarding the discussion about dac_config, here is how it works
                Thank you philippe for this explanation. It is clear now that for reliable operation of his DAC32 with generic I2S firmware brawny must enter the dac_config parameters in NVS.
                | LMS 8.3.2 on Linux Mint 21.2 | Squeezebox Boom | RPi0W + pCP 8.2.0 + HiFiBerry DAC Zero | ESP Muse Luxe |

                Comment


                • Originally posted by Rasputin_GY
                  I haven't found any issues yet, except that I can't connect to the spotify connect endpoint, cspot advertises within the spotify app.
                  Just for information, as far as I know you need Spotify Premium to be able to use the Spotify Connect feature. Today I subscribed for a Spotify Premium account with 1 month trial period, and in the Spotify app I can now select my ESP Muse as Spotify Connect endpoint, and it does play music. This is with the latest firmware version v2.1288, that was released 20 minutes ago . I am using the 16-bit build, but I suppose that cspot also works with 32-bit firmware.
                  | LMS 8.3.2 on Linux Mint 21.2 | Squeezebox Boom | RPi0W + pCP 8.2.0 + HiFiBerry DAC Zero | ESP Muse Luxe |

                  Comment


                  • Question about cspot_config NVS setting

                    This is probably a question for philippe_44. My cspot_config setting in NVS is now:
                    Code:
                    {"deviceName":"ESP Muse","bitrate":320,"volume":9018}
                    Is the volume setting an initial volume setting, or is it a gain setting? What is the range of this setting?
                    Reason for asking is that the first time that I used the spotify connect feature the initial audio volume was quite high. And when adjusting the audio volume in the Spotify App on my Android phone, only the lower half of the volume range is useful. I wonder if there is a way to lower the audio gain when using my Muse in cspot mode.
                    | LMS 8.3.2 on Linux Mint 21.2 | Squeezebox Boom | RPi0W + pCP 8.2.0 + HiFiBerry DAC Zero | ESP Muse Luxe |

                    Comment


                    • Originally posted by CJS
                      Question about cspot_config NVS setting

                      This is probably a question for philippe_44. My cspot_config setting in NVS is now:
                      Code:
                      {"deviceName":"ESP Muse","bitrate":320,"volume":9018}
                      Is the volume setting an initial volume setting, or is it a gain setting? What is the range of this setting?
                      Reason for asking is that the first time that I used the spotify connect feature the initial audio volume was quite high. And when adjusting the audio volume in the Spotify App on my Android phone, only the lower half of the volume range is useful. I wonder if there is a way to lower the audio gain when using my Muse in cspot mode.
                      It’s a volume that is provided to by Cspot, applying values are developers problem. I though I already placed them in the loudness war camp but maybe not enough. It’s a 16 bits value
                      LMS 8.2 on Odroid-C4 - SqueezeAMP!, 5xRadio, 5xBoom, 2xDuet, 1xTouch, 1xSB3. Sonos PLAY:3, PLAY:5, Marantz NR1603, Foobar2000, ShairPortW, 2xChromecast Audio, Chromecast v1 and v2, Squeezelite on Pi, Yamaha WX-010, AppleTV 4, Airport Express, GGMM E5, RivaArena 1 & 3

                      Comment


                      • Originally posted by philippe_44
                        It’s a volume that is provided to by Cspot, applying values are developers problem. I though I already placed them in the loudness war camp but maybe not enough.
                        Ok, thanks for the info. I will try a few different values and check the effect.

                        It’s a 16 bits value
                        So maximum is FFFF then. Should a hexadecimal value or a decimal value be entered for "volume"?
                        | LMS 8.3.2 on Linux Mint 21.2 | Squeezebox Boom | RPi0W + pCP 8.2.0 + HiFiBerry DAC Zero | ESP Muse Luxe |

                        Comment


                        • philippe_44, never mind. I just figured out that volume is a decimal value, and that the value in NVS changes after changing the volume in the spotify app. So the value represents the last volume that is set in the app?
                          EDIT: Apparently it is not that simple. The value in NVS changed from 9018 to 18234, but after changing the volume in the spotify app on my smartphone the value stays 18234. Anyway, it is not a big deal. The volume control is "fine" enough, even if I will not use the full range.
                          Last edited by CJS; 2023-04-08, 10:09.
                          | LMS 8.3.2 on Linux Mint 21.2 | Squeezebox Boom | RPi0W + pCP 8.2.0 + HiFiBerry DAC Zero | ESP Muse Luxe |

                          Comment


                          • Originally posted by CJS
                            philippe_44, never mind. I just figured out that volume is a decimal value, and that the value in NVS changes after changing the volume in the spotify app. So the value represents the last volume that is set in the app?
                            EDIT: Apparently it is not that simple. The value in NVS changed from 9018 to 18234, but after changing the volume in the spotify app on my smartphone the value stays 18234. Anyway, it is not a big deal. The volume control is "fine" enough, even if I will not use the full range.
                            The volume is memorized but it is saved in NVS only when the Spotify session ends, to avoid overusing the flash.
                            LMS 8.2 on Odroid-C4 - SqueezeAMP!, 5xRadio, 5xBoom, 2xDuet, 1xTouch, 1xSB3. Sonos PLAY:3, PLAY:5, Marantz NR1603, Foobar2000, ShairPortW, 2xChromecast Audio, Chromecast v1 and v2, Squeezelite on Pi, Yamaha WX-010, AppleTV 4, Airport Express, GGMM E5, RivaArena 1 & 3

                            Comment


                            • Originally posted by philippe_44
                              The volume is memorized but it is saved in NVS only when the Spotify session ends, to avoid overusing the flash.
                              Thanks Philippe, that makes perfect sense.
                              | LMS 8.3.2 on Linux Mint 21.2 | Squeezebox Boom | RPi0W + pCP 8.2.0 + HiFiBerry DAC Zero | ESP Muse Luxe |

                              Comment


                              • Hi, I'm trying to get spotify to work with PV DIGI32 I flashed with "I2S-4MFlash.32.2.1290.master-v4" (I have red that 32 version isn't recommended to use but unfortunately only the 32 version outputs music through SPDIF on that device).
                                Connecting the DIGI32 from the spotify app works fine and I can hear music for about 2 seconds through my speakers until it stops and the DIGI32 itself becomes unusable until power cycle.
                                I attach all information I could find, maybe someone has an idea or an advise.
                                DIGI32_serial.txt DIGI32_config.txt DIGI32_telnet.txt


                                Comment

                                Working...
                                X
                                😀
                                🥰
                                🤢
                                😎
                                😡
                                👍
                                👎