WiiM Mini: linux client - cannot play via bluetooth or airplay

vo-one

New member
Joined
Jan 27, 2024
Messages
4
Dear community,

Does any of you use linux clients with WiiM Mini?

I do not see Linux as a supported platform on a website, but I expected at least normal bluetooth to work.
Opened a support ticket, lets see what happens.


Bluetooth
Put my WiiM into bluetooth input via mobile app, made it discoverable by pressing "+" and "-" and attempted to pair and connect.
Pairing succeeds, but no audio device is registered, bluetoothd and pulseaudio segfaults, WiiM becomes unresponsive until I power-cycle it.

Code:
Jan 24 22:26:14 thinkpad bluetoothd[1171]: profiles/audio/avdtp.c:session_cb()
Jan 24 22:26:14 thinkpad bluetoothd[1171]: profiles/audio/avdtp.c:avdtp_parse_cmd() Received SUSPEND_CMD
Jan 24 22:26:14 thinkpad bluetoothd[1171]: profiles/audio/a2dp.c:suspend_ind() Sink 0x5861bc85e3a0: Suspend_Ind
Jan 24 22:26:14 thinkpad bluetoothd[1171]: profiles/audio/avdtp.c:avdtp_sep_set_state() stream state changed: STREAMING -> OPEN
Jan 24 22:26:14 thinkpad bluetoothd[1171]: profiles/audio/source.c:source_set_state() State changed /org/bluez/hci0/dev_B8_13_32_ED_F7_79: SOURCE_STATE_PLAYING -> SOURCE_STAT
E_CONNECTED
Jan 24 22:26:14 thinkpad bluetoothd[1171]: profiles/audio/transport.c:transport_update_playing() /org/bluez/hci0/dev_B8_13_32_ED_F7_79/fd1 State=TRANSPORT_STATE_ACTIVE Playin
g=0
Jan 24 22:26:14 thinkpad bluetoothd[1171]: profiles/audio/transport.c:media_transport_remove_owner() Transport /org/bluez/hci0/dev_B8_13_32_ED_F7_79/fd1 Owner :1.31
Jan 24 22:26:14 thinkpad bluetoothd[1171]: profiles/audio/transport.c:media_owner_free() Owner :1.31
Jan 24 22:26:14 thinkpad bluetoothd[1171]: profiles/audio/transport.c:media_transport_suspend() Transport /org/bluez/hci0/dev_B8_13_32_ED_F7_79/fd1 Owner
Jan 24 22:26:14 thinkpad bluetoothd[1171]: profiles/audio/transport.c:transport_set_state() State changed /org/bluez/hci0/dev_B8_13_32_ED_F7_79/fd1: TRANSPORT_STATE_ACTIVE ->
 TRANSPORT_STATE_IDLE
Jan 24 22:26:14 thinkpad bluetoothd[1171]: profiles/audio/a2dp.c:a2dp_sep_unlock() SEP 0x5861bc85e3a0 unlocked
Jan 24 22:26:15 thinkpad kernel: bluetoothd[1171]: segfault at 60 ip 00005861bc0d41cc sp 00007fff59bb7c70 error 4 in bluetoothd[5861bc0ae000+de000] likely on CPU 3 (core 3, s
ocket 0)
Jan 24 22:26:15 thinkpad kernel: Code: 00 00 c7 44 24 21 ff ff ff ff e8 ff 47 0b 00 e9 12 ff ff ff 66 2e 0f 1f 84 00 00 00 00 00 49 8b 56 20 41 0f b6 40 08 48 8b 12 <4c> 8b 6
2 60 49 8b 7c 24 60 3c 04 0f 87 51 02 00 00 48 8d 15 68 a8

Code:
Jan 24 22:26:15 thinkpad bluetoothd[1363]: Endpoint registered: sender=:1.31 path=/MediaEndpoint/A2DPSource/ldac_hq
Jan 24 22:26:15 thinkpad bluetoothd[1363]: Endpoint registered: sender=:1.31 path=/MediaEndpoint/A2DPSource/ldac_sq
Jan 24 22:26:15 thinkpad bluetoothd[1363]: Endpoint registered: sender=:1.31 path=/MediaEndpoint/A2DPSource/ldac_mq
Jan 24 22:26:15 thinkpad bluetoothd[1363]: Endpoint registered: sender=:1.31 path=/MediaEndpoint/A2DPSink/aptx_hd
Jan 24 22:26:15 thinkpad bluetoothd[1363]: Endpoint registered: sender=:1.31 path=/MediaEndpoint/A2DPSource/aptx_hd
Jan 24 22:26:15 thinkpad bluetoothd[1363]: Endpoint registered: sender=:1.31 path=/MediaEndpoint/A2DPSink/aptx
Jan 24 22:26:15 thinkpad bluetoothd[1363]: Endpoint registered: sender=:1.31 path=/MediaEndpoint/A2DPSource/aptx
Jan 24 22:26:15 thinkpad bluetoothd[1363]: Endpoint registered: sender=:1.31 path=/MediaEndpoint/A2DPSink/sbc
Jan 24 22:26:15 thinkpad bluetoothd[1363]: Endpoint registered: sender=:1.31 path=/MediaEndpoint/A2DPSource/sbc
Jan 24 22:26:15 thinkpad bluetoothd[1363]: Endpoint registered: sender=:1.31 path=/MediaEndpoint/A2DPSink/sbc_xq_453
Jan 24 22:26:15 thinkpad bluetoothd[1363]: Endpoint registered: sender=:1.31 path=/MediaEndpoint/A2DPSource/sbc_xq_453
Jan 24 22:26:15 thinkpad bluetoothd[1363]: Endpoint registered: sender=:1.31 path=/MediaEndpoint/A2DPSink/sbc_xq_512
Jan 24 22:26:15 thinkpad bluetoothd[1363]: Endpoint registered: sender=:1.31 path=/MediaEndpoint/A2DPSource/sbc_xq_512
Jan 24 22:26:15 thinkpad bluetoothd[1363]: Endpoint registered: sender=:1.31 path=/MediaEndpoint/A2DPSink/sbc_xq_552
Jan 24 22:26:15 thinkpad bluetoothd[1363]: Endpoint registered: sender=:1.31 path=/MediaEndpoint/A2DPSource/sbc_xq_552
Jan 24 22:26:15 thinkpad bluetoothd[1363]: Endpoint registered: sender=:1.31 path=/MediaEndpoint/A2DPSink/faststream
Jan 24 22:26:15 thinkpad bluetoothd[1363]: Endpoint registered: sender=:1.31 path=/MediaEndpoint/A2DPSource/faststream
Jan 24 22:26:15 thinkpad bluetoothd[1363]: src/device.c:set_wake_allowed_complete() Set device flags return status: Invalid Parameters
Jan 24 22:26:15 thinkpad kernel: Bluetooth: hci0: Bad flag given (0x1) vs supported (0x0)


Airplay
I was trying to use pulseaudio-raop, similar story: device is discoverable, but when I route audio to it, I get "RTSP/1.0 403 Forbidden"

Code:
Jan 27 09:17:12 thinkpad pulseaudio[699]: Unexpected/Unhandled response: Content-Length: 0
Jan 27 09:17:12 thinkpad pulseaudio[699]: Unexpected/Unhandled response: Server: AirTunes/366.0
Jan 27 09:17:12 thinkpad pulseaudio[699]: Unexpected/Unhandled response: CSeq: 2
Jan 27 09:17:12 thinkpad pulseaudio[699]: Unexpected/Unhandled response:
Jan 27 09:17:16 thinkpad pulseaudio[699]: Unexpected/Unhandled response: RTSP/1.0 403 Forbidden
Jan 27 09:17:16 thinkpad pulseaudio[699]: Unexpected/Unhandled response: Content-Length: 0
Jan 27 09:17:16 thinkpad pulseaudio[699]: Unexpected/Unhandled response: Server: AirTunes/366.0
Jan 27 09:17:16 thinkpad pulseaudio[699]: Unexpected/Unhandled response: CSeq: 3

Tried Bluetooth connectivity with two Linux distributions (my up-to-date Arch and live boot Ubuntu 23.10) with the same result :(


What works
- Spotify sharing protocol works on linux
- Same laptop works fine with WiiM over bluetooth on Windows
- other Android and iOS clients work fine with Bluetooth
- iOS clients work fine with AirPlay
 
Last edited:
I have the same problem with Wiim Pro Plus, neither bluetooth or Wi-Fi works with a linux laptop.

Wiim appears as a output device over Wi-Fi, but no sound is transmitted. Actually it appears twice on audio output device list:D

1711704134159.png
 
I never use Bluetooth on my WiiM devices, but have you made any progress on this, OP? I can try and test it later on if you're still having issues...

Unfortunately the best way to stream from Linux I tried was spotify/tidal connect. Now I don't have either, so I just use my android device and Wiim home app for qobuz...
 
> have you made any progress on this, OP?
No. Updated bluetooth stack, tried live-booting other distros, checking WiiM firmware upgrades weekly.

The best I can do from the linux laptop is Spotify streaming.

I've accepted the fact that linux users are not the target audience of this product.
Ticket #497020
Being Processed | 2 months ago
 
> have you made any progress on this, OP?
No. Updated bluetooth stack, tried live-booting other distros, checking WiiM firmware upgrades weekly.

The best I can do from the linux laptop is Spotify streaming.

I've accepted the fact that linux users are not the target audience of this product.
fair enough, but i'll still try test it from my server running zorin later...

out of interest - have you tried any of the external bluetooth dongles? like USB or something?? sometimes those seem to have better compatibility/driver support - this happened to me with an annoying bluetooth mouse once.
 
Thank you for the ideas, @bowsandarrows!

> out of interest - have you tried any of the external bluetooth dongles? like USB or something??
Today I've tried with USB Bluetooth dongle "TP-Link UB400" with the same result.

swyh-rs looks promising - it discovers WiiM, but something is wrong on ALSA end.
I will take a closer look and share my experience.
 
Have you tried pulseaudio-dlna?

I can confirm that pulseaudio-dlna works, however:
  • it downsamples your audio to 192 bps mp3 (at least with default settings i see `parec --format=s16le -d wiim_dlna.monitor | lame -b 192 -r -`)
  • the lag is significant and prevents you from watching movies.
Bluetooth problem is still there and the ticket is still in "Processing" state with zero responses from WiiM team after 3 months.
 
Last edited:
Well, I never play directly FROM Linux, but almost always control the WiiM from Linux, in a couple of ways.

First, my Allmusic Chrome browser extension, which allows me to use Allmusic.com to find albums, then pass them off to the WiiM to play on Tidal, Qobuz or Deezer. Just need the Chrome browser installed on your Linux box.

Second, I run a small Python script on an Inovato Quadra, with a browser UI that allows me to search Tidal for albums, then pass the selected album off to the WiiM. It also has a SQLite database to store reviews and bios that are missing from Tidal for completeness.

I'm pretty happy with these, but then I ALWAYS listen to full albums, and don't care at all for playlists, as a jazz nut. There's zero delay with either of these, as the play is always being done by the WiiM, only the search is done externally, then the albumId handed off to WiiM to play.
 

Attachments

  • IMG_2083.jpeg
    IMG_2083.jpeg
    149.6 KB · Views: 2
  • 1712789196850.png
    1712789196850.png
    854.1 KB · Views: 2
I'm not sure why neither of those is working for you. I am using openSUSE Tumbleweed, and can set my computer to output audio via Bluetooth (AAC, SBC and SNC-XQ) and Airplay. The only thing I had to do was open up my firewall for Airplay, because the default settings are apparently too strict. I couldn't figure out how to get DLNA streaming to work, unfortunately, but Bluetooth and Airplay work well enough. Airplay has a lag of about 2 seconds as well, but the computer automatically resynchronises the audio and video streams, so you don't actually notice when watching a movie or a video on YouTube.

This is what pactl tells me about the Bluetooth output to the Wiim Mini (which I'm listening to right now):

Code:
Source #7004
    State: RUNNING
    Name: bluez_output.B8_13_32_1C_7D_1D.1.monitor
    Description: Monitor of WiiM Mini
    Driver: PipeWire
    Sample Specification: s16le 2ch 48000Hz
    Channel Map: front-left,front-right
    Owner Module: 4294967295
    Mute: no
    Volume: front-left: 65536 / 100% / 0,00 dB,   front-right: 65536 / 100% / 0,00 dB
            balance 0,00
    Base Volume: 65536 / 100% / 0,00 dB
    Monitor of Sink: bluez_output.B8_13_32_1C_7D_1D.1
    Latency: 0 usec, configured 0 usec
    Flags: HARDWARE DECIBEL_VOLUME LATENCY
    Properties:
        api.bluez5.address = "B8:13:32:1C:7D:1D"
        api.bluez5.codec = "sbc_xq"
        api.bluez5.profile = "a2dp-sink"
        api.bluez5.transport = ""
        bluez5.loopback = "false"
        card.profile.device = "1"
        device.id = "143"
        device.routes = "1"
        factory.name = "api.bluez5.a2dp.sink"
        device.description = "WiiM Mini"
        node.name = "bluez_output.B8_13_32_1C_7D_1D.1"
        node.pause-on-idle = "false"
        priority.driver = "1010"
        priority.session = "1010"
        factory.id = "11"
        clock.quantum-limit = "8192"
        device.api = "bluez5"
        media.class = "Audio/Sink"
        media.name = "WiiM Mini"
        node.driver = "true"
        factory.mode = "merge"
        audio.adapt.follower = ""
        library.name = "audioconvert/libspa-audioconvert"
        object.id = "152"
        object.serial = "7004"
        client.id = "53"
        api.bluez5.class = "0x2c0428"
        api.bluez5.connection = "disconnected"
        api.bluez5.device = ""
        api.bluez5.icon = "audio-card"
        api.bluez5.id = "93"
        api.bluez5.path = "/org/bluez/hci0/dev_B8_13_32_1C_7D_1D"
        bluez5.profile = "off"
        device.alias = "WiiM Mini"
        device.bus = "bluetooth"
        device.form_factor = "hifi"
        device.icon_name = "audio-card-bluetooth"
        device.name = "bluez_card.B8_13_32_1C_7D_1D"
        device.product.id = "0x0000"
        device.string = "B8:13:32:1C:7D:1D"
        device.vendor.id = "bluetooth:000f"
        device.class = "monitor"
    Ports:
        hifi-output: HiFi (type: HiFi, priority: 0, available)
    Active Port: hifi-output
    Formats:
        pcm

I see you're using Pulseaudio, whereas I'm using Pipewire. Maybe that's part of the explanation? Have you tried using Pipewire instead of Pulseaudio?

Bluetooth problem is still there and the ticket is still in "Processing" state with zero responses from WiiM team after 3 months.
@Brantome, could you check with WiiM if this ticket accidentally slipped through the net?
 
What's the ticket number?
Sorry, looks like I quoted the wrong post. Meant to quote this which includes the ticket number:
> have you made any progress on this, OP?
No. Updated bluetooth stack, tried live-booting other distros, checking WiiM firmware upgrades weekly.

The best I can do from the linux laptop is Spotify streaming.

I've accepted the fact that linux users are not the target audience of this product.

#497020
 
Back
Top