Distorted/garbled sound on high channel count USB audio interface (class compliant) at certain altsets

Đang mở
#529 1 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Đánh giá

Độ khó
5/5
Thời gian dự kiến
Hơn một tuần
Mức phù hợp với người mới
12/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
c, linux

Hướng nghiên cứu

The report describes corrupted audio on USB altset 3 of a 198-channel class-compliant interface, and the fault may sit in the kernel's snd-usb-audio driver rather than in this alsa-lib userspace repo. Start by reading the altset and packet-size data in the reporter's /proc/asound/card2/stream0 output and checking which altset selection code paths exist here. Done would mean identifying the layer responsible and reproducing the glitch with a test playback at 48 kHz on altset 3.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

kernel driver

I don't know if I'm in the right place to address this issue here. If not, please feel free to point me in the right direction.

I recently purchased an RME Madiface XT II, which is (among others) a class compliant USB audio interface with a channel count of up to 196 input and 198 output channels over three MADI connections plus Phones Out, one AES I/O and one Stereo Analog I/O. I'm on Debian based MX 25.3, running liquorix kernel 7.2.8. My digital audio workstation is Reaper, native Linux build, running on ALSA, as pipewire(-jack) currently doesn't support more than 128 channels.

The interface offers 3 different altsets to ALSA for each set of sample rates.

At 44.1/48kHz: setting Reaper to the device's native channel count (I: 196/O: 198) it switches to altset 3, on I: 100/O: 102 to altset 2 and on I: 52/O: 54 to altset 1. Altsets 1 and 2 work fine but as soon as altset 3 is active, the audio is heavily distorted and sounds like a bitcrushed, modulated, glitchy mess. This is what /proc/asound/card2/stream0 looks like when Reaper is running:

RME MADIface XT (xxxxxxxx) at usb-0000:00:14.0-1, super speed : USB Audio

Playback:
  Status: Running
    Interface = 1
    Altset = 3
    Packet Size = 4096
    Momentary freq = 48000 Hz (0x6.0000)
  Interface 1
    Altset 1
    Format: S32_LE
    Channels: 54
    Endpoint: 0x02 (2 OUT) (ASYNC)
    Rates: 44100, 48000, 88200, 96000, 176400, 192000
    Data packet interval: 125 us
    Bits: 24
    Sync Endpoint: 0x82 (2 IN)
    Sync EP Interface: 1
    Sync EP Altset: 1
    Implicit Feedback Mode: No
  Interface 1
    Altset 2
    Format: S32_LE
    Channels: 102
    Endpoint: 0x02 (2 OUT) (ASYNC)
    Rates: 44100, 48000, 88200, 96000, 176400, 192000
    Data packet interval: 125 us
    Bits: 24
    Sync Endpoint: 0x82 (2 IN)
    Sync EP Interface: 1
    Sync EP Altset: 2
    Implicit Feedback Mode: No
  Interface 1
    Altset 3
    Format: S32_LE
    Channels: 198
    Endpoint: 0x02 (2 OUT) (ASYNC)
    Rates: 44100, 48000, 88200, 96000, 176400, 192000
    Data packet interval: 125 us
    Bits: 24
    Sync Endpoint: 0x82 (2 IN)
    Sync EP Interface: 1
    Sync EP Altset: 3
    Implicit Feedback Mode: No

Capture:
  Status: Running
    Interface = 2
    Altset = 3
    Packet Size = 4096
    Momentary freq = 48000 Hz (0x6.0000)
  Interface 2
    Altset 1
    Format: S32_LE
    Channels: 52
    Endpoint: 0x81 (1 IN) (ASYNC)
    Rates: 44100, 48000, 88200, 96000, 176400, 192000
    Data packet interval: 125 us
    Bits: 24
  Interface 2
    Altset 2
    Format: S32_LE
    Channels: 100
    Endpoint: 0x81 (1 IN) (ASYNC)
    Rates: 44100, 48000, 88200, 96000, 176400, 192000
    Data packet interval: 125 us
    Bits: 24
  Interface 2
    Altset 3
    Format: S32_LE
    Channels: 196
    Endpoint: 0x81 (1 IN) (ASYNC)
    Rates: 44100, 48000, 88200, 96000, 176400, 192000
    Data packet interval: 125 us
    Bits: 24

At higher sample rates, only altset 1 works and obviously the channel count is further reduced.

According to the hardware developer, the device is confirmed to be working fine in class compliant mode on all three altsets on MacOS (although it also has native Mac drivers), so everything points to some incompatibility/bug with ALSA.

There are several topics on RME's Linux sub forum about this, if more info is needed.
https://forum.rme-audio.de/viewtopic.php?id=41751
On the following thread, the relevant part starts at post no. 12: https://forum.rme-audio.de/viewtopic.php?id=31000

Ngôn ngữ chính
C
Star
501
Fork
227
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Chuẩn bị môi trường

Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của alsa-project/alsa-lib

Tất cả issue của alsa-project/alsa-lib

Issue tương tự

Thêm issue về C

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.