upsampling 44.1kHz music to 48kHz

  • I'm running version 7.0.2.006 on a MQX-Pro-4K (S905 Chipset). It runs perfectly, so many thanks for the great work to kszaq!

    The only problem I have, is that music with a 44.1kHz bitrate is upsampled to 48k on the SPDIF output (I guess also on HDMI, but I can’t test). It’s independent of the Kodi audio settings (I tried nearly everything: 44.1 fixed and best mach (German 'beste übereinstimmung), with and without passthrough, all audio drivers for output, HDMI port connected and disconnected, ...).

    I’m I doing something wrong or is this a general problem?

    Edited once, last by kszaq (September 22, 2016 at 2:21 PM).


  • I'm running version 7.0.2.006 on a MQX-Pro-4K (S905 Chipset). It runs perfectly, so many thanks for the great work to kszaq!

    The only problem I have, is that music with a 44.1kHz bitrate is upsampled to 48k on the SPDIF output (I guess also on HDMI, but I can’t test). It’s independent of the Kodi audio settings (I tried nearly everything: 44.1 fixed and best mach (German 'beste übereinstimmung), with and without passthrough, all audio drivers for output, HDMI port connected and disconnected, ...).

    I’m I doing something wrong or is this a general problem?

    I try with mini mx and hdmi output.
    It worked for me with flac source, switch to correct sample rate. I try with 44.1,48,88.2,96,192kHz.
    Only I have trouble with multichannel 5.1 flac, that's not played, stay silent. And DSD isn't played too good q. It's noisy

    Edited once, last by envagyok (September 6, 2016 at 4:11 AM).

  • I've tested it. Flac and also WAV (both in 44.1) are also upsampled to 48k – the same result as it is with my mp3.
    It seems, that is has something to do with my MQX-Pro-4K. It's amazing; I thought it has the same Chipset than the mini mx.

    PS: The sound quality from the upsampled 48k output is not bad, but the upsampling reduce the sound quality (not massive but you can hear it after a while).


  • I've tested it. Flac and also WAV (both in 44.1) are also upsampled to 48k – the same result as it is with my mp3.
    It seems, that is has something to do with my MQX-Pro-4K. It's amazing; I thought it has the same Chipset than the mini mx.

    PS: The sound quality from the upsampled 48k output is not bad, but the upsampling reduce the sound quality (not massive but you can hear it after a while).

    With what av receiver use it?

  • It is a Rotel RSX 1065. The Reciever shows the sampling frequncy in it's display.
    It works fine with a Google Chromecast and with my very old Popcorn Hour A110. Both don't have the upsampling problem, so I don't thing it's a Reciever problem.

  • I've checked, but this entry is not there. See Details:

    MXQ-Pro:/ # find | grep advancedsettings.xml
    ./usr/share/kodi/system/advancedsettings.xml

    MXQ-Pro:/ # cat ./usr/share/kodi/system/advancedsettings.xml
    <?xml version="1.0" encoding="UTF-8"?>
    <advancedsettings>
    <showexitbutton>false</showexitbutton>

    <samba>
    <clienttimeout>30</clienttimeout>
    </samba>

    <network>
    <readbufferfactor>4.0</readbufferfactor>
    </network>

    <pvr>
    <minvideocachelevel>5</minvideocachelevel>
    <minaudiocachelevel>20</minaudiocachelevel>
    </pvr>
    </advancedsettings>

  • Could also be a HDMI handshaking problem, you could try another cable.

    I have the problem the other way around. I have a Pioneer receiver which can not come into agreement with my Beebox. The Pioneer works fine with an ION 3D, but when connected to the Beebox, it is incapable of playing 44.1kHz. This is why I knew the setting :)

  • I've checked several HDMI-cables and I've checked without any HDMI connection (only SPDIF directly connected to the reciever and played music via DLNA). Always the same result: 44.1 music is still upsampled to 48k.

  • Yes I've tried the 7.0.2.007 with the latest device tree this weekend. Same result: 44.1 music is upsampled to 48k (using the SPDIF, independent if HDMI is connected or not).

    I tried to set the audio rate to fixed with different rates and I played 44.1 material : setting 44.1 and 48 -> 48k output, setting 88.2 and 96 -> 96k output, 192 is not supported from my receiver.
    Audio set to optimized or best match (sorry I use the German frontend, so my translation might be not exactly) result in a 48k output.

    Were it helpful, if I make some specific tests and produce some (which) logfiles?

  • kszaq Sorry for late answering, I have seen your commet too late.

    I tried the command echo "44.1k" > /sys/class/amhdmitx/amhdmitx0/aud_mode
    but it seems, that the file file aud_mode is not accessalbe from the shell. The file is empty before and after I typed the command. It's also not accessable with vi (can't read 'aud_mode').

    In the directory are several files:
    -r--r--r-- 1 root root 4096 Sep 29 23:09 aud_cap
    -rw-rw-r-- 1 root root 4096 Sep 29 23:09 aud_ch
    -rw-r--r-- 1 root root 4096 Sep 29 23:10 aud_mode
    -rw-rw-r-- 1 root root 4096 Sep 29 23:09 aud_output_chs
    ...
    All files have the timestamp from last reboot of the box, but the file aud_mode has the timestamp from the moment, when I type the echo... command.

    cat aud_cap
    CodingType MaxChannels SamplingFreq SampleSize
    PCM, 2 ch, 32/44.1/48/88.2/96 kHz, 16/20/24 bit
    AC-3, 6 ch, 32/44.1/48 kHz, bit

    cat aud_ch
    hdmi_channel = 2 ch

    aud_mode and aud_output_chs are empty. I haven't ckecked the other files in the directory.

    Doe's this information help?

  • I've tried it
    1) typed the command and then started playing music. -> 48k
    2) typed the command while playing music. -> 48k

    Meanwhile, I have a second box (a Nexbox A95). The box is also running version 7.0.2.007 with the device tree for A95X from version 7.0.2.006. This box has exactly the same behaviour.


  • I've tried it
    1) typed the command and then started playing music. -> 48k
    2) typed the command while playing music. -> 48k

    Meanwhile, I have a second box (a Nexbox A95). The box is also running version 7.0.2.007 with the device tree for A95X from version 7.0.2.006. This box has exactly the same behaviour.

    The at yours setup other problem present.
    What is your setup?

  • The at yours setup other problem present.
    What is your setup?

    I don't have any other problems with my MXQ-Pro 4k.
    The Nextbox A95 works also fine, beside that the toothpick is not working and that it can only turned on by connecting the powersupply (not via remote).

    What in detail do you like to know about "my setup"?

  • This is only to write my experience. I don't know if t's related to this topic, but I think is interesting.

    At this moment I have 3 cheap chinese boxes running LE (thanks a lot o kszaq): one is a S805 (a MXQ clone), and the others are S905 (a M18 and a T95N).
    All 3 are connected via HDMI to an Onkyo receiver. Watching movies with AC3/DTS, with audio passthrough activated, I can't notice any difference between them.
    But listening mp3 files (or AVI files with mp3 sound) things become a little funny. The sound from the S805 box is nearly perfect, but the sound from the S905 boxes is not so good. There's a little distortion, that's especially noticeable with very bass tones: if you listen to John Lennon's 'Imagine', with the piano notes at the beginning, there's a clear distortion (it's like using very cheap speakers). That distortion doesn't exists at all with the S805 box.

    When I read this post I thought that maybe I'm having that problem of resampling, but my Onkyo says it's always receiving 44.1 signals.

    The other day I made a test using Android's SPMC on the M18 box. Surprisingly, even with occasional gitches (Android Kodi it's not very good with audio), I found that the sound had not the LE's Kodi distortion. So I think maybe is a software problem.