th0masrad
Anmeldungsdatum: 19. August 2021
Beiträge: 14
|
Wie kann ich unter Linux/ubuntu die Abtastrate eines SPDIF-Signals erkennen? Ich habe ein Audiogerät, das ein SPDIF-Signal entweder mit 32, 44,1 oder 48 kHz Abtastrate ausgibt. Ich kann an dem Audiogerät nicht erkennen, welche Abtastrate es nutzt. Dafür ist leider keine Anzeige vorgesehen. Nun möchte ich gerne dieses Signal möglichst 1:1 - also ohne Abtastratenänderung - aufnehmen. Grundsätzlich ist das Aufnehmen, mit z. B. audacity möglich. in audacity kann ich den SPDIF-Eingang als Quelle auswählen und aufnehmen. Aber ich muss die Abtastrate in audacity einstellen und weiß natürlich nicht, welche Abtastrate das Audiogerät gewählt hat. (Äußerst vereinfacht ausgedrückt stelle ich mir vor, dass die Soundkarte das SPDIF-Signal dekodiert und das dekodierte - also beinahe wieder analog gewordene - Signal an audacity weiterreicht. In audacity kann es dann wieder mit verschiedenen Abtastraten kodiert werden.) Somit ergeben sich eigentlich drei Fragen:
Komme ich irgendwie direkt an das originale SPDIF-Signal heran? Wenn das nicht möglich ist, wie kann ich die Abtastrate des SPDIF-Signals erkennen, so dass wenigstens die Abtastratenkonvertierung wegfällt? Liege ich mit meinen Überlegungen möglicherweise völlig daneben? ☺
Danke! MfG
Thomas Rad
|
th0masrad
(Themenstarter)
Anmeldungsdatum: 19. August 2021
Beiträge: 14
|
Gerne hier zusätzliche Info: ChickenLipsRfun2eat schrieb: die Info über aplay -L , bzw. cat /proc/asound/devices (letzteres benennt das pcm-device für spdif) finden
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187 | $ aplay -L
default
Playback/recording through the PulseAudio sound server
surround21
2.1 Surround output to Front and Subwoofer speakers
surround40
4.0 Surround output to Front and Rear speakers
surround41
4.1 Surround output to Front, Rear and Subwoofer speakers
surround50
5.0 Surround output to Front, Center and Rear speakers
surround51
5.1 Surround output to Front, Center, Rear and Subwoofer speakers
surround71
7.1 Surround output to Front, Center, Side, Rear and Woofer speakers
null
Discard all samples (playback) or generate zero samples (capture)
samplerate
Rate Converter Plugin Using Samplerate Library
speexrate
Rate Converter Plugin Using Speex Resampler
jack
JACK Audio Connection Kit
oss
Open Sound System
pulse
PulseAudio Sound Server
upmix
Plugin for channel upmix (4,6,8)
vdownmix
Plugin for channel downmix (stereo) with a simple spacialization
sysdefault:CARD=PCH
HDA Intel PCH, ALC887-VD Analog
Default Audio Device
front:CARD=PCH,DEV=0
HDA Intel PCH, ALC887-VD Analog
Front speakers
surround21:CARD=PCH,DEV=0
HDA Intel PCH, ALC887-VD Analog
2.1 Surround output to Front and Subwoofer speakers
surround40:CARD=PCH,DEV=0
HDA Intel PCH, ALC887-VD Analog
4.0 Surround output to Front and Rear speakers
surround41:CARD=PCH,DEV=0
HDA Intel PCH, ALC887-VD Analog
4.1 Surround output to Front, Rear and Subwoofer speakers
surround50:CARD=PCH,DEV=0
HDA Intel PCH, ALC887-VD Analog
5.0 Surround output to Front, Center and Rear speakers
surround51:CARD=PCH,DEV=0
HDA Intel PCH, ALC887-VD Analog
5.1 Surround output to Front, Center, Rear and Subwoofer speakers
surround71:CARD=PCH,DEV=0
HDA Intel PCH, ALC887-VD Analog
7.1 Surround output to Front, Center, Side, Rear and Woofer speakers
hdmi:CARD=PCH,DEV=0
HDA Intel PCH, HDMI 0
HDMI Audio Output
hdmi:CARD=PCH,DEV=1
HDA Intel PCH, HDMI 1
HDMI Audio Output
hdmi:CARD=PCH,DEV=2
HDA Intel PCH, HDMI 2
HDMI Audio Output
hdmi:CARD=PCH,DEV=3
HDA Intel PCH, HDMI 3
HDMI Audio Output
hdmi:CARD=PCH,DEV=4
HDA Intel PCH, HDMI 4
HDMI Audio Output
dmix:CARD=PCH,DEV=0
HDA Intel PCH, ALC887-VD Analog
Direct sample mixing device
dmix:CARD=PCH,DEV=3
HDA Intel PCH, HDMI 0
Direct sample mixing device
dmix:CARD=PCH,DEV=7
HDA Intel PCH, HDMI 1
Direct sample mixing device
dmix:CARD=PCH,DEV=8
HDA Intel PCH, HDMI 2
Direct sample mixing device
dmix:CARD=PCH,DEV=9
HDA Intel PCH, HDMI 3
Direct sample mixing device
dmix:CARD=PCH,DEV=10
HDA Intel PCH, HDMI 4
Direct sample mixing device
dsnoop:CARD=PCH,DEV=0
HDA Intel PCH, ALC887-VD Analog
Direct sample snooping device
dsnoop:CARD=PCH,DEV=3
HDA Intel PCH, HDMI 0
Direct sample snooping device
dsnoop:CARD=PCH,DEV=7
HDA Intel PCH, HDMI 1
Direct sample snooping device
dsnoop:CARD=PCH,DEV=8
HDA Intel PCH, HDMI 2
Direct sample snooping device
dsnoop:CARD=PCH,DEV=9
HDA Intel PCH, HDMI 3
Direct sample snooping device
dsnoop:CARD=PCH,DEV=10
HDA Intel PCH, HDMI 4
Direct sample snooping device
hw:CARD=PCH,DEV=0
HDA Intel PCH, ALC887-VD Analog
Direct hardware device without any conversions
hw:CARD=PCH,DEV=3
HDA Intel PCH, HDMI 0
Direct hardware device without any conversions
hw:CARD=PCH,DEV=7
HDA Intel PCH, HDMI 1
Direct hardware device without any conversions
hw:CARD=PCH,DEV=8
HDA Intel PCH, HDMI 2
Direct hardware device without any conversions
hw:CARD=PCH,DEV=9
HDA Intel PCH, HDMI 3
Direct hardware device without any conversions
hw:CARD=PCH,DEV=10
HDA Intel PCH, HDMI 4
Direct hardware device without any conversions
plughw:CARD=PCH,DEV=0
HDA Intel PCH, ALC887-VD Analog
Hardware device with all software conversions
plughw:CARD=PCH,DEV=3
HDA Intel PCH, HDMI 0
Hardware device with all software conversions
plughw:CARD=PCH,DEV=7
HDA Intel PCH, HDMI 1
Hardware device with all software conversions
plughw:CARD=PCH,DEV=8
HDA Intel PCH, HDMI 2
Hardware device with all software conversions
plughw:CARD=PCH,DEV=9
HDA Intel PCH, HDMI 3
Hardware device with all software conversions
plughw:CARD=PCH,DEV=10
HDA Intel PCH, HDMI 4
Hardware device with all software conversions
usbstream:CARD=PCH
HDA Intel PCH
USB Stream Output
sysdefault:CARD=Device
USB Sound Device, USB Audio
Default Audio Device
front:CARD=Device,DEV=0
USB Sound Device, USB Audio
Front speakers
surround21:CARD=Device,DEV=0
USB Sound Device, USB Audio
2.1 Surround output to Front and Subwoofer speakers
surround40:CARD=Device,DEV=0
USB Sound Device, USB Audio
4.0 Surround output to Front and Rear speakers
surround41:CARD=Device,DEV=0
USB Sound Device, USB Audio
4.1 Surround output to Front, Rear and Subwoofer speakers
surround50:CARD=Device,DEV=0
USB Sound Device, USB Audio
5.0 Surround output to Front, Center and Rear speakers
surround51:CARD=Device,DEV=0
USB Sound Device, USB Audio
5.1 Surround output to Front, Center, Rear and Subwoofer speakers
surround71:CARD=Device,DEV=0
USB Sound Device, USB Audio
7.1 Surround output to Front, Center, Side, Rear and Woofer speakers
iec958:CARD=Device,DEV=0
USB Sound Device, USB Audio
IEC958 (S/PDIF) Digital Audio Output
dmix:CARD=Device,DEV=0
USB Sound Device, USB Audio
Direct sample mixing device
dsnoop:CARD=Device,DEV=0
USB Sound Device, USB Audio
Direct sample snooping device
hw:CARD=Device,DEV=0
USB Sound Device, USB Audio
Direct hardware device without any conversions
plughw:CARD=Device,DEV=0
USB Sound Device, USB Audio
Hardware device with all software conversions
usbstream:CARD=Device
USB Sound Device
USB Stream Output
|
Das Device an sich (Zeile 170) ist nicht das Problem… Aufnehmen kann ich ja…
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17 | $ cat /proc/asound/devices
1: : sequencer
2: [ 1- 0]: digital audio playback
3: [ 1- 0]: digital audio capture
4: [ 1] : control
5: [ 0- 0]: digital audio playback
6: [ 0- 0]: digital audio capture
7: [ 0- 2]: digital audio capture
8: [ 0- 3]: digital audio playback
9: [ 0- 7]: digital audio playback
10: [ 0- 8]: digital audio playback
11: [ 0- 9]: digital audio playback
12: [ 0-10]: digital audio playback
13: [ 0- 0]: hardware dependent
14: [ 0- 2]: hardware dependent
15: [ 0] : control
33: : timer
|
Ich muss zugeben, dass ich mit dieser Ausgabe nichts anfangen kann. ☹ ChickenLipsRfun2eat schrieb: Zumindest wenn die Angabe „Ubuntu Server“ stimmt.
Begrenzt; es ist eine Server-Installation auf die ein Kubuntu draufgesetzt ist. ChickenLipsRfun2eat schrieb: Ansonsten kommt es darauf an, was du wirklich verwendest, weil dann noch PulseAudio und PipeWire mit reinspielen können. Daher wären die Ausgaben aus der Sound Problembehebung/Audio-Fehler-Beschreibung sicher für die Helfer wichtig.
Die folgen hier: Ausgeführt als "normaler" Benutzer; kein root und kein sudo:
| $ lsb_release -d
Description: Ubuntu 20.04.4 LTS
|
| $ uname -r
5.4.0-121-generic
|
| $ cat /proc/asound/cards
0 [PCH ]: HDA-Intel - HDA Intel PCH
HDA Intel PCH at 0xf7340000 irq 148
1 [Device ]: USB-Audio - USB Sound Device
USB Sound Device at usb-0000:00:14.0-13.2, full speed
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23 | $ aplay -l
**** Liste der Hardware-Geräte (PLAYBACK) ****
Karte 0: PCH [HDA Intel PCH], Gerät 0: ALC887-VD Analog [ALC887-VD Analog]
Sub-Geräte: 0/1
Sub-Gerät #0: subdevice #0
Karte 0: PCH [HDA Intel PCH], Gerät 3: HDMI 0 [HDMI 0]
Sub-Geräte: 1/1
Sub-Gerät #0: subdevice #0
Karte 0: PCH [HDA Intel PCH], Gerät 7: HDMI 1 [HDMI 1]
Sub-Geräte: 1/1
Sub-Gerät #0: subdevice #0
Karte 0: PCH [HDA Intel PCH], Gerät 8: HDMI 2 [HDMI 2]
Sub-Geräte: 1/1
Sub-Gerät #0: subdevice #0
Karte 0: PCH [HDA Intel PCH], Gerät 9: HDMI 3 [HDMI 3]
Sub-Geräte: 1/1
Sub-Gerät #0: subdevice #0
Karte 0: PCH [HDA Intel PCH], Gerät 10: HDMI 4 [HDMI 4]
Sub-Geräte: 1/1
Sub-Gerät #0: subdevice #0
Karte 1: Device [USB Sound Device], Gerät 0: USB Audio [USB Audio]
Sub-Geräte: 1/1
Sub-Gerät #0: subdevice #0
|
| $ aplay /usr/share/sounds/alsa/Noise.wav
Wiedergabe: WAVE '/usr/share/sounds/alsa/Noise.wav' : Signed 16 bit Little Endian, Rate: 48000 Hz, mono
|
| $ lspci -nnk | grep -iA2 audio
00:1f.3 Audio device [0403]: Intel Corporation 100 Series/C230 Series Chipset Family HD Audio Controller [8086:a170] (rev 31)
Subsystem: ASUSTeK Computer Inc. 100 Series/C230 Series Chipset Family HD Audio Controller [1043:86d4]
Kernel driver in use: snd_hda_intel
Kernel modules: snd_hda_intel
|
| $ ps -C esd
PID TTY TIME CMD
|
| $ ps -C arts
PID TTY TIME CMD
|
| $ ps -C pulseaudio
PID TTY TIME CMD
2176 ? 18:11:41 pulseaudio
|
| $ grep "^audio" /etc/group | grep "$USER" | wc -l
0
|
| $ dpkg -l | tr -s " " | grep " alsa-"
ii alsa-base 1.0.25+dfsg-0ubuntu5 all ALSA driver configuration files
ii alsa-topology-conf 1.2.2-1 all ALSA topology configuration files
ii alsa-ucm-conf 1.2.2-1ubuntu0.13 all ALSA Use Case Manager configuration files
ii alsa-utils 1.2.2-1ubuntu2.1 amd64 Utilities for configuring and using ALSA
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23 | $ lsmod | grep "snd"
snd_seq_dummy 16384 0
snd_hda_codec_hdmi 61440 1
snd_hda_codec_realtek 131072 1
snd_hda_codec_generic 81920 1 snd_hda_codec_realtek
ledtrig_audio 16384 2 snd_hda_codec_generic,snd_hda_codec_realtek
snd_hda_intel 53248 4
snd_intel_dspcfg 28672 1 snd_hda_intel
snd_hda_codec 139264 4 snd_hda_codec_generic,snd_hda_codec_hdmi,snd_hda_intel,snd_hda_codec_realtek
snd_usb_audio 270336 2
snd_hda_core 90112 5 snd_hda_codec_generic,snd_hda_codec_hdmi,snd_hda_intel,snd_hda_codec,snd_hda_codec_realtek
snd_usbmidi_lib 36864 1 snd_usb_audio
snd_hwdep 20480 2 snd_usb_audio,snd_hda_codec
snd_pcm 106496 6 snd_hda_codec_hdmi,snd_hda_intel,snd_usb_audio,snd_hda_codec,snd_hda_core
snd_seq_midi 20480 0
snd_seq_midi_event 16384 1 snd_seq_midi
snd_rawmidi 36864 2 snd_seq_midi,snd_usbmidi_lib
snd_seq 69632 3 snd_seq_midi,snd_seq_midi_event,snd_seq_dummy
snd_seq_device 16384 3 snd_seq,snd_seq_midi,snd_rawmidi
snd_timer 36864 2 snd_seq,snd_pcm
snd 90112 24 snd_hda_codec_generic,snd_seq,snd_seq_device,snd_hda_codec_hdmi,snd_hwdep,snd_hda_intel,snd_usb_audio,snd_usbmidi_lib,snd_hda_codec,snd_hda_codec_realtek,snd_timer,snd_pcm,snd_rawmidi
mc 53248 6 videodev,snd_usb_audio,dvb_usb_v2,videobuf2_v4l2,dvb_core,videobuf2_common
soundcore 16384 1 snd
|
| $ head -n 3 /proc/asound/card0/codec#0
Codec: Realtek ALC887-VD
Address: 0
AFG Function Id: 0x1 (unsol 1)
|
| $ head -n 3 /proc/asound/card0/codec97#0/ac97#0-0
head: '/proc/asound/card0/codec97#0/ac97#0-0' kann nicht zum Lesen geöffnet werden: Datei oder Verzeichnis nicht gefunden
|
| $ head -n 3 /proc/asound/card0/codec97#0/ac97#0-0+regs
head: '/proc/asound/card0/codec97#0/ac97#0-0+regs' kann nicht zum Lesen geöffnet werden: Datei oder Verzeichnis nicht gefunden
|
| $ cat ~/.asoundrc$ cat ~/.asoundrc
cat: /home/tom/.asoundrc: Datei oder Verzeichnis nicht gefunden
|
| $ cat ~/.asoundrc.asoundconf
cat: /home/tom/.asoundrc.asoundconf: Datei oder Verzeichnis nicht gefunden
|
| $ cat /etc/asound.conf
cat: /etc/asound.conf: Datei oder Verzeichnis nicht gefunden
|
Edit 1: "Veröffentlichen" statt "Vorschau" gedrückt"; die Knöpfe sind auch sehr nah beieinander… 😉 Edit 2: Gemerkt, dass kein SPDIF-Input-Device vorhanden ist. Edit 3: War verwirrt, dass es kein explizites SPDIF-Input-Device gibt; das Output-Device kann aber auch aufnehmen, so dass arecord -c 2 -r 44100 -D iec958:CARD=Device,DEV=0 text.wav funktioniert!
|
th0masrad
(Themenstarter)
Anmeldungsdatum: 19. August 2021
Beiträge: 14
|
Erst einmal Danke für die rege Teilnahme! Marant-- schrieb: Soll Das heissen, das das Teil Das "auswürfelt"? Was sagt die BA? Wie heißt das Teil?
Nein, Chemnitzsurfer liegt mit DAT beinahe richtig; es ist ein DCC 951. Info's, auch die Bedienungsanleitung, gibt es unter https://www.dccmuseum.com/collection/philips-dcc951/. Chemnitzsurfer schrieb: Longplay 32kHz, Standard im Consumerbereich meist 48 kHz und im semipro Bereich bzw, wenn man ne CD 1:1 kopiert hatte auch 44 KHz
Ja, auch hier! Man sieht es aber dem Band, dem Gerät und der Bedienungsanleitung nicht an, welche Abtastrate benutzt wurde. Gerüchte besagen, dass 32 kHz nie, 44,1 kHz bei eigenen Aufnahmen und CD-Kopien und 48 kHz bei vorbespielten kommerziellen Bändern benutzt wurden. Kann aber auch anders gewesen sein. Marant-- schrieb: Meinst Du Eingangs- oder Ausgangsseitig?
[…] Wer gibt Das aus? Kann Das anhand des Geposteten nicht erkennen. Viel geschrieben mit wenig konkretem Inhalt.
☹ Es gibt ja auch "wenig" Inhalt, da die Frage ist, ob unter Linux - durch die Soundkarte - auf das S/PDIF-Signal zugegriffen werden kann. Da ist es mMn. unerheblich, ob S/PDIF noch zeitgemäß (shinichi 😉 ) ist oder wie das Audiogerät heißt… Ich hätte vielleicht "Zuspieler" statt "Audiogerät" schreiben sollen. Im Nachhinein erscheint mir nämlich die Verwechselungsgefahr mit einer externen Soundkarte oä. gegeben. Marant-- schrieb: cat /proc/asound/card1/pcm0p/sub0/hw_params
| $ cat /proc/asound/card1/pcm0p/sub0/hw_params
closed
|
Marant-- schrieb: pactl info
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 | $ pactl info
Server-Zeichenkette: /run/user/1000001/pulse/native
Bibliotheks-Protokollversion: 33
Server-Protokollversion: 33
ist lokal: ja
Client-Index: 721
Tile-Größe: 65472
Name des Benutzers: tom
Rechnername: pc-tom
Name des Servers: pulseaudio
Version des Servers: 13.99.1
Standard-Abtastwert-Angabe: s16le 2ch 44100Hz
Standard-Kanal-Zuordnung: front-left,front-right
Standard-Ziel: alsa_output.pci-0000_00_1f.3.analog-stereo
Standard-Quelle: alsa_output.pci-0000_00_1f.3.analog-stereo.monitor
Cookie: e88d:5849
|
Und wie ich versucht habe zu schreiben: Das Aufnehmen "des Signals aus dem Zuspieler" "mit audacity oder arecord auf dem Linux-Computer" funktioniert. Nur muss ich halt bei beiden Programmen die Abtastrate angeben. Und die kenne ich nicht. Ich hoffe, zu mehr Klarheit beigetragen zu haben! ☺
|