Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AptX HD support #241

Closed
gpeter12 opened this issue Aug 28, 2019 · 7 comments
Closed

AptX HD support #241

gpeter12 opened this issue Aug 28, 2019 · 7 comments

Comments

@gpeter12
Copy link

gpeter12 commented Aug 28, 2019

Well guys I really really miss a void *io_thread_a2dp_sink_aptx(void *arg) function from io.c. I tried to work on that my phone recognize my RPi Zero W as an aptx-HD capable sink device in the last two days. Than I noticed in the source code that bluealsa isn't capable such thing. It can only receive sound through sbc and aac (as I can see). I'm wondering now: how hard can it be to fix that problem. Is it solvable? Or is it a "mission impossible" kind of problem? Am I completely wrong about that and this feature is already implemented?
Thanks for the help!

@arkq
Copy link
Owner

arkq commented Sep 3, 2019

Is it solvable? Or is it a "mission impossible" kind of problem?

Of course it is solvable. However, right now there is no official library from Qialcomm. There is reverse engineered support in ffmpeg, however, I'm not 100% convinced that the HD codec works correctly (I might be wrong, though). I've made some test with the library found on Android and ffmpeg and they produced different output... (or my test was incorrect). Anyway, I've got no real device with aptxHD support, so it is hard for me to test developed code. Hence, there is no aptxHD support. It will me in the future for sure :)

@arkq arkq changed the title I miss void *io_thread_a2dp_sink_aptx(void *arg) AptX HD support Sep 3, 2019
@powerpun
Copy link

how I could help on this, bought fiio btr3, claimed support aptx(hd)/ldac/hwa...

@gpeter12
Copy link
Author

gpeter12 commented Sep 12, 2019

@arkq This feature is implemented in the pulseaudio-modules-bt (https://github.com/EHfive/pulseaudio-modules-bt) repository. The aptxHD sink works perfectly on my laptop but there are serious issues on my RPi 3B and RPi Zero W. (details: EHfive/pulseaudio-modules-bt#78 (comment))

It is possible that I compiled the wrong way either pulseaudio or pulseaudio-modules-bt or the very same aptxHD decode function just can't run properly on armhf platform.

@powerpun
Copy link

@gpeter12 I got the same problem using common pulseaudio in RPi3 also with my own platform. I had to say bluezalsa provide a lot better quality than pulse while playing via A2DP mode(but pulseaudio default is SBC while bluealsa was using AAC) I hear the click during playing, no clue.

@t123yh
Copy link

t123yh commented Oct 1, 2019

Please have a try on #253.

@gpeter12
Copy link
Author

gpeter12 commented Oct 7, 2019

@t123yh Oh man It's working!!! Thank you very very much!
It has only one issue: I hear a crackling noise. It's a couple milliseconds long and It happens 1-2 times in 5 minutes. I guess it's caused by buffer underruns or damaged bluetooth packets.
I tested your code on a RPi 3B with Asus Zenfone 5Z. I will test it soon on another device (RPi Zero W) with a USB DAC.

@arkq
Copy link
Owner

arkq commented Jan 16, 2021

I'm closing this issue, because since commit b11cff0 apt-X / apt-X HD decoding support is available in the master branch.

@arkq arkq closed this as completed Jan 16, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants