Do soundcards in laptops/AIO PCs lie about supporting rates higher than 48KHz?
Linux - Laptop and NetbookHaving a problem installing or configuring Linux on your laptop? Need help running Linux on your netbook? This forum is for you. This forum is for any topics relating to Linux and either traditional laptops or netbooks (such as the Asus EEE PC, Everex CloudBook or MSI Wind).
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Do soundcards in laptops/AIO PCs lie about supporting rates higher than 48KHz?
I have Manjaro Linux installed on a 27" iMac and pipewire came preinstalled. In /proc/asound/card0/codec#0 it says pretty much all commonly used sampling rates and depths are supported:
Code:
codec: Cirrus Logic CS4206
Address: 0
AFG Function Id: 0x1 (unsol 0)
Vendor Id: 0x10134206
Subsystem Id: 0x106b2000
Revision Id: 0x100302
No Modem Function Group found
Default PCM:
rates [0x7f0]: 32000 44100 48000 88200 96000 176400 192000
bits [0x1e]: 16 20 24 32
formats [0x3]: PCM FLOAT
.
.
.
However, when I play any "HD" audio files obtained from eclassical.com and nativedsd.com (96KHz/24bit, 192KHz/24bit) they're resampled to 48KHz. This is with nothing in ~/.config/pipewire/pipewire.conf.d and I checked that there was nothing in /etc/pipwire/pipewire.conf.d either.
I am determining the sampling rate during playback from looking at /proc/asound/card0/pcmp0/sub0/hw_params while sound is playing: it always says 48KHz.
If I make a file ~/.config/pipewire/pipewire.conf.d/10-rates.conf per the pipewire documentation:
Code:
# Adds more common rates
context.properties = {
default.clock.allowed-rates = [ 44100 48000 88200 96000 192000 ]
}
and restart the pipewire service, sound players seem to work without error but there is no sound at all for files 48KHz and above. CD rips (44100/16bit) play fine and are not resampled to 48KHz. /proc/asound/card0/pcmp0/sub0/hw_params says the correct rate for 96 and 192kHz files but there is no sound while the player thinks its playing. I tried VLC, mpv, and pw-play players and all behave the same way.
I have also examined the FLAC files using spek (it's in AUR, but really ought to be included in the distro) to make sure they are really 96KHz/24bit and 192KHz/24bit.
I'm beginning to suspect CS4206 does not really support rates higher than 48KHz, pipewire has a bug, or there is a problem with the kernel sound drivers. I mean, almost no one likes classical music or jazz--what is typically recorded at these higher rates--so maybe no one bothered to check whether these rates actually work?
Last edited by slackmensch; 02-23-2024 at 08:12 AM.
To me, there'd be a question of software, and hardware. You need to know that the original ISA bus ran at 7.86(?)MHz and through some labyrinthine and convoluted reasoning involving sample rates 44100khz was chosen as the max sample rate.
A lot of stuff got set up around that, and it kept downloads small. I would chase data on the chip, that "Cirrus Logic CS4206." What sampling rates does that handle?
IME, most internal devices in PCs have 44 or 48 khz sample rates, although usb sound cards go much higher (192khz). I can't talk definitely about Macs. It could be that the software will do 192khz, but the hardware won't.
Well, it appears Cirrus Logic doesn't really make a 4206?! The closest match is 4207 and the rumormill says 4206 is 4207 but somehow customized for Apple. I give up. Plugging in my USB DAC....
BTW, a lower number strongly implies lesser features, not more. So a CS4207 modified for Apple might be CS4207<letters>. Is there a CS4205? It's most likely to be a testing thing if the rumour mill is right. E.g. lower sampling rate.
You see this most often with CPUs. I have a Ryzen 5 5600. There is a Ryzen 5 5600X with 100MHz extra frequency and 300MHz extra on turbo, which sells for €100 extra. But many parts that fail the 5600X spec actually pass the 5600 spec. So they are sold as 5600s.
You can read the specs (pronounced "marketing info") at Cirrus Logic; it appears to support 44.1 to 192kHz with depths 16,32 bits.
I'm thinking maybe 4206 in iMac is just 48kHz. Or that's all the generic kernel sound drivers support? Anyway, I really have given up on this: the reward is too little for way too much wading into the ever-shifting sands of ~/.config.
It's curious that pipewire has so many debugging tools: pw-cat, pw-cli, pw-top, pw-dump etc.... Bet it "just working" properly is a rare thing.
In a fit of disgust with the ongoing Linux Sound Server mess, I decided to try FreeBSD on this system. (FreeBSD still uses ye olde OSS.) Unfortunately, it works, but the sound quality is horrible and no one knows why. iMac 2011 with CS4206 has been discussed on several BSD forums (not just by me begging for help) with no conclusion reached. Maybe Apple broke 4207 in some secret way so it only works 100 percent properly with Mac OS. No, I'm not installing whatever last bloaty, horrible old version OS X worked on iMac 2011 just to test, LOL.
Apple have a policy of not being give-ish about hardware details or software. They don't ever want competition.
That said, most things do quite well on 44khz/48khz When you consider that the highest note any soprano can sing is about 9khz that puts things in perspective. 'A' above middle C is 440Hz. One octave up is 880hz; another octave up 'A' is 1,760Hz. What you want to hear is actually well covered.
The Hi-Fi cards that do 192khz will have higher quality throughout, and produce lower THD, TID, etc distortion rates. Speakers often contribute significantly to the total distortion. So do capacitors.
If your 13 year old iMac sounds lousy on everybody's software, consider hardware problems.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.