badaix/snapdroid

Snapdroid does not play any audio

Nuesel opened this issue · 4 comments

When playing some audio with Snapdroid 24.0.0 on my Android 10 (LineageOS), my phone keeps being quiet. The audio perfectly plays on my RaspberryPi with Snapclient.
I started playing while tracing the log of the app with:
adb shell pidof -s de.badaix.snapcast
adb logcat --pid=xxxxx
The Android app cannot successfully contact the Snapserver, although everything is properly configured (see below). After hitting the play button in Snapdroid, it changes to a stop button but nothing else happens.
Does anybody know, what might cause such a problem?
Many thanks!

Nuesel

--------- beginning of main
04-10 19:41:10.401 26506 26506 W main : type=1400 audit(0.0:35480): avc: denied { write } for name="tasks" dev="tmpfs" ino=6046 scontext=u:r:zygote:s0 tcontext=u:object_r:device:s0 tclass=file permissive=0 app=de.badaix.snapcast
04-10 19:41:10.401 26506 26506 W main : type=1300 audit(0.0:35480): arch=40000028 syscall=334 per=8 success=no exit=-13 a0=ffffff9c a1=e7043a40 a2=2 a3=0 items=0 ppid=3439 auid=4294967295 uid=0 gid=10145 euid=0 suid=0 fsuid=0 egid=10145 sgid=10145 fsgid=10145 ses=4294967295 tty=(none) exe="/system/bin/app_process32" subj=u:r:zygote:s0 key=(null) app=de.badaix.snapcast
04-10 19:41:10.510 26506 26506 I MultiDex: VM with version 2.1.0 has multidex support
04-10 19:41:10.510 26506 26506 I MultiDex: Installing application
04-10 19:41:10.510 26506 26506 I MultiDex: VM has multidex support, MultiDex support library is disabled.
04-10 19:41:22.789 26506 26506 W ActivityThread: handleWindowVisibility: no activity for token android.os.BinderProxy@2af5461
04-10 19:41:24.588 26506 26506 D GroupList: onCreateView: GroupListFragment{85c511a (f380fd66-9b78-42f0-8ea8-23a0564f7216) id=0x7f09008e}
04-10 19:41:24.593 26506 26506 D Main : Samplerate: 8000
04-10 19:41:24.597 26506 26506 D Main : Samplerate: 8000, buffer: 1408
04-10 19:41:24.597 26506 26506 D Main : Samplerate: 11025
04-10 19:41:24.597 26506 26506 D Main : Samplerate: 11025, buffer: 1920
04-10 19:41:24.597 26506 26506 D Main : Samplerate: 16000
04-10 19:41:24.597 26506 26506 D Main : Samplerate: 16000, buffer: 2816
04-10 19:41:24.597 26506 26506 D Main : Samplerate: 22050
04-10 19:41:24.598 26506 26506 D Main : Samplerate: 22050, buffer: 3840
04-10 19:41:24.598 26506 26506 D Main : Samplerate: 44100
04-10 19:41:24.598 26506 26506 D Main : Samplerate: 44100, buffer: 7552
04-10 19:41:24.598 26506 26506 D Main : Samplerate: 48000
04-10 19:41:24.598 26506 26506 D Main : Samplerate: 48000, buffer: 8192
04-10 19:41:24.599 26506 26506 D Main : Samplerate: 48000
04-10 19:41:24.613 26506 26630 D RC : onConnecting
04-10 19:41:24.694 26506 26626 D mali_winsys: EGLint new_window_surface(egl_winsys_display*, void*, EGLSurface, EGLConfig, egl_winsys_surface**, egl_color_buffer_format*, EGLBoolean) returns 0x3000, [1080x1920]-format:1
04-10 19:41:24.700 26506 26626 W Gralloc3: mapper 3.x is not supported
04-10 19:41:24.702 26506 26630 D TCP : Connecting to 192.168.84.20:1705
04-10 19:41:24.704 26506 26626 E ion : ioctl c0044901 failed with code -1: Invalid argument
04-10 19:41:24.708 26506 26630 D RC : onConnected
04-10 19:41:24.710 26506 26646 D TCP : Sending: {"jsonrpc":"2.0","method":"Server.GetStatus","id":0}
04-10 19:41:24.718 26506 26630 D TCP : Received Message: '{"id":0,"jsonrpc":"2.0","result":{"server":{"groups":[{"clients":[{"config":{"instance":1,"latency":0,"name":"","volume":{"muted":false,"percent":100}},"connected":false,"host":{"arch":"aarch64","ip":"192.168.84.149","mac":"e4:5f:01:87:46:59","name":"Musikbox","os":"Debian GNU/Linux 11 (bullseye)"},"id":"e4:5f:01:87:46:59","lastSeen":{"sec":1649612299,"usec":9058},"snapclient":{"name":"Snapclient","protocolVersion":2,"version":"0.26.0"}},{"config":{"instance":1,"latency":0,"name":"Ubuntu Laptop","volume":{"muted":false,"percent":100}},"connected":false,"host":{"arch":"x86_64","ip":"192.168.84.110","mac":"98:2c:bc:39:06:57","name":"ubuntu","os":"Linux Mint 20.3"},"id":"98:2c:bc:39:06:57","lastSeen":{"sec":1644178156,"usec":25267},"snapclient":{"name":"Snapclient","protocolVersion":2,"version":"0.26.0"}}],"id":"59bc600a-2ea4-c332-e1af-b0aa759174fe","muted":false,"name":"","stream_id":"default"}],"server":{"host":{"arch":"x86_64","ip":"","mac":"","name":"george","os":"Ubuntu 20.04.2 LTS"},"snapserver":{"controlProtocolVersion":1,"name":"Snapserver","protocolVersion":1,"version":"0.26.0"}},"streams":[{"id":"default","properties":{"canControl":false,"canGoNext":false,"canGoPrevious":false,"canPause":false,"canPlay":false,"canSeek":false},"status":"playing","uri":{"fragment":"","host":"","path":"/tmp/snapfifo","query":{"chunk_ms":"40","codec":"flac","name":"default","sampleformat":"48000:16:2"},"raw":"pipe:////tmp/snapfifo?chunk_ms=40&codec=flac&name=default&sampleformat=48000:16:2","scheme":"pipe"}}]}}}'
04-10 19:41:24.719 26506 26630 D RC : Response to: Server.GetStatus
04-10 19:41:24.737 26506 26506 D Main : updateStartStopMenuItem: ic_media_play
04-10 19:41:35.009 26506 26506 D Service : start host: 192.168.84.20, port: 1704
04-10 19:41:35.010 26506 26506 D Service : Running on a non-TV Device
04-10 19:41:35.021 26506 26506 D Service : startProcess
04-10 19:41:35.022 26506 26506 I Service : Configured engine: Auto, active engine: oboe, sampleformat: 48000:16:*
04-10 19:41:35.041 26506 26659 D Main : onPlayerStart
04-10 19:41:35.041 26506 26506 D Main : updateStartStopMenuItem: ic_media_stop

Maybe the error
Gralloc3: mapper 3.x is not supported
is related with this problem:
https://forum.qt.io/topic/123071/gralloc3-mapper-3-x-is-not-supported-error-with-chartview

I tried to compile Snapdroid on my own, but I got stuck with error message:

What went wrong:
Could not determine the dependencies of task ':Snapcast:stripReleaseDebugSymbols'.
Could not create task ':Snapcast:mergeReleaseNativeLibs'.
Gradle project cmake.path is /home/nuesel/snapdroid/Snapcast/src/main/cpp/snapcast/CMakeLists.txt but that file doesn't exist

Obviously I am missing a dependency, but what? Is there any howto on building Snapdroid?
Thanks for your help!

Did you check out the submodules: git submodule update --init --recursive. Snapcast is compiled with the NDK as native binary and the Snapclient source is linked as submodule.
Snapdroid is built by the Github actions CI: https://github.com/badaix/snapdroid/blob/develop/.github/workflows/ubuntu.yml, maybe this file can give more hints on what might went wrong.

Thanks for the hint. Checking out the Snapclient submodule solves the compilation issue.

The last build on Github works without problems:
https://github.com/badaix/snapdroid/actions/runs/1802461396
The same is true for my local build (master/head).

The current version 24.0.0 distributed on F-Droid shows the behavior described above. Maybe a new release would be reasonable?
Thanks for your help!