Schiit Bifrost, usb, C-Media 6631, ALSA/MPD

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I really hope nobody is upset at me cross posting to mailing lists, hopefully this isn't bad etiquette.  

The device (C-Media 6631) is recognized and will play under newer kernels. However When I switch to different sampling frequencies I hear major artifacts and I can cat the stream file in /proc/asound and see that the stream output frequency does not match what the file is. For instance, I'm playing 192Khz from mpd but the stream says 172Khz or I'm playing 44.1Khz but the stream says 48Khz. Sometimes it seems to get the sample rate correct, for instance I switch from a 96Khz to an 88.2Khz and it gets it right in the /proc/asound stream file, however it still has the same awful artifacts.

If people are interested I can also make recordings of the audio, I just didn't know if it would provide any value.

If I stop and start the music enough times it seems to resolve itself, however that is an unacceptable fix.

I would like to try to find out if the problem is, MPD, ALSA, My config of either, The Chip implementation or lastly something I have not thought of.

I've tried all of this on two different systems, Fedora 15 and Fedora 16

[agd@enyo asound]$ uname -r
2.6.40.6-0.fc15.x86_64
ALSA 1.0.24
MPD 0.15.0

[agd@hephaestus asound]$ uname -r
3.1.0-7.fc16.x86_64
ALSA 1.0.24
MPD 0.16.5


[agd@enyo asound]$ aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: Intel [HDA Intel], device 0: STAC92xx Analog [STAC92xx Analog]
  Subdevices: 0/1
  Subdevice #0: subdevice #0
card 2: Interface [Schiit USB Interface], device 0: USB Audio [USB Audio]
  Subdevices: 0/1
  Subdevice #0: subdevice #0
card 2: Interface [Schiit USB Interface], device 1: USB Audio [USB Audio #1]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 2: Interface [Schiit USB Interface], device 2: USB Audio [USB Audio #2]
  Subdevices: 1/1
  Subdevice #0: subdevice #0

At the suggestion of the mpd IRC I tried to use aplay to test different frequencies on the device:

[agd@hephaestus]$ cat /dev/urandom | aplay -D hw:2,0 -f S16_LE -c2 -r44100
[agd@hephaestus]$ cat /dev/urandom | aplay -D hw:2,0 -f S16_LE -c2 -r48000
[agd@hephaestus]$ cat /dev/urandom | aplay -D hw:2,0 -f S16_LE -c2 -r88200
[agd@hephaestus]$ cat /dev/urandom | aplay -D hw:2,0 -f S16_LE -c2 -r96000
[agd@hephaestus]$ cat /dev/urandom | aplay -D hw:2,0 -f S16_LE -c2 -r192000

I was able to reproduce the same weird sound artifacts, less often, but after playing with aplay for a while I could get the same effect.

As for using MPD, Here is my output config:

audio_output {
        type            "pulse"
        name            "PULSE - Intel STAC92 Analog"
}
audio_output {
        type            "alsa"
        name            "ALSA - Schiit USB"
        device          "hw:2,0"
}

Right now I'm playing a 44.1khz wav file, here is the steam file output:

[agd@enyo card2]$ mpc
Music/California Guitar Trio/California Guitar Trio - Andromedia/Cathedral peak.wav
[playing] #2/42   3:56/4:21 (90%)
volume: n/a   repeat: off   random: off   single: off   consume: off
[agd@enyo card2]$ cat stream0
CMEDIA Schiit USB Interface at usb-0000:00:1a.7-3.1, high speed : USB Audio

Playback:
  Status: Running
    Interface = 1
    Altset = 1
    URBs = 8 [ 8 8 8 8 8 8 8 8 ]
    Packet Size = 104
    Momentary freq = 44100 Hz (0x5.8330)
    Feedback Format = 16.16
  Interface 1
    Altset 1
    Format: S16_LE
    Channels: 2
    Endpoint: 5 OUT (ASYNC)
    Rates: 44100, 48000, 88200, 96000, 192000
    Data packet interval: 125 us
  Interface 1
    Altset 2
    Format: S32_LE
    Channels: 2
    Endpoint: 5 OUT (ASYNC)
    Rates: 44100, 48000, 88200, 96000, 192000
    Data packet interval: 125 us

Capture:
  Status: Stop
  Interface 4
    Altset 1
    Format: S16_LE
    Channels: 2
    Endpoint: 8 IN (ASYNC)
    Rates: 44100, 48000, 88200, 96000, 192000
    Data packet interval: 125 us
  Interface 4
    Altset 2
    Format: S32_LE
    Channels: 2
    Endpoint: 8 IN (ASYNC)
    Rates: 44100, 48000, 88200, 96000, 192000
    Data packet interval: 125 us

Now I will switch to a 176.4Khz file:

[agd@enyo card2]$ mpc
Music/_NEW_/HRx_Sampler_2008 24-176.4/03_Sullivan Act IV Overture.wav
[playing] #45/52   0:06/4:48 (2%)
volume: n/a   repeat: off   random: off   single: off   consume: off
[agd@enyo card2]$ cat stream0
CMEDIA Schiit USB Interface at usb-0000:00:1a.7-3.1, high speed : USB Audio

Playback:
  Status: Running
    Interface = 1
    Altset = 2
    URBs = 8 [ 8 8 8 8 8 8 8 8 ]
    Packet Size = 208
    Momentary freq = 176402 Hz (0x16.0ce0)
    Feedback Format = 18.14
  Interface 1
    Altset 1
    Format: S16_LE
    Channels: 2
    Endpoint: 5 OUT (ASYNC)
    Rates: 44100, 48000, 88200, 96000, 192000
    Data packet interval: 125 us
  Interface 1
    Altset 2
    Format: S32_LE
    Channels: 2
    Endpoint: 5 OUT (ASYNC)
    Rates: 44100, 48000, 88200, 96000, 192000
    Data packet interval: 125 us

Capture:
  Status: Stop
  Interface 4
    Altset 1
    Format: S16_LE
    Channels: 2
    Endpoint: 8 IN (ASYNC)
    Rates: 44100, 48000, 88200, 96000, 192000
    Data packet interval: 125 us
  Interface 4
    Altset 2
    Format: S32_LE
    Channels: 2
    Endpoint: 8 IN (ASYNC)
    Rates: 44100, 48000, 88200, 96000, 192000
    Data packet interval: 125 us


On Thu, Nov 3, 2011 at 4:15 AM, Clemens Ladisch <cladisch@xxxxxxxxxxxxxx> wrote:
Andrew Dunn wrote:
> The Schiit Bifrost uses a C-Media 6631,

This is a USB Audio 2.0 chip.

(The USB Audio specification is separate from the USB specification, and
almost all USB audio devices still use the 1.0 audio spec because that
is what Windows supports.  However, this chip is beginning to show up
in many newer devices, so we are very interested in making sure that
this chip is supported completely.)

> I'm using this with ubuntu 10.04:
>
> $ uname -r
> 2.6.32-34-generic-pae

The first USB Audio 2.0 support was added in kernel 2.6.35; you need
at least Ubuntu 10.10 (and a newer one wouldn't hurt).

> Here is a gist of an lsusb -v: https://gist.github.com/1335351

That old lsusb doesn't know about audio 2.0 descriptors either.


Regards,
Clemens



--
Andrew Dunn
248.238.8649
http://agdunn.net

------------------------------------------------------------------------------
RSA(R) Conference 2012
Save $700 by Nov 18
Register now
http://p.sf.net/sfu/rsa-sfdev2dev1
_______________________________________________
Alsa-user mailing list
Alsa-user@xxxxxxxxxxxxxxxxxxxxx
https://lists.sourceforge.net/lists/listinfo/alsa-user

[Index of Archives]     [ALSA Devel]     [Linux Audio Users]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]

  Powered by Linux