Date: Mon, 26 Nov 2018 13:43:30 -0600 From: Karl Denninger <karl@denninger.net> To: freebsd-arm@freebsd.org Subject: Re: Raspberry PI 2B/3 and USB audio Message-ID: <1418f261-9f56-7931-d23f-85059fdda077@denninger.net> In-Reply-To: <87lg5fhcgz.wl-herbert@gojira.at> References: <87ftw96uq0.wl-herbert@gojira.at> <6beca923-ba25-3814-6bb2-f4cc2d7360d3@selasky.org> <875zx2hyey.wl-herbert@gojira.at> <87lg5fhcgz.wl-herbert@gojira.at>
index | next in thread | previous in thread | raw e-mail
[-- Attachment #1 --] This one works fine on my Pi2.... (and it was dirt cheap too) uaudio0 on uhub1 uaudio0: <C-Media Electronics Inc. USB Audio Device, class 0/0, rev 1.10/1.00, addr 6> on usbus0 uaudio0: Play: 48000 Hz, 2 ch, 16-bit S-LE PCM format, 2x8ms buffer. uaudio0: Play: 44100 Hz, 2 ch, 16-bit S-LE PCM format, 2x8ms buffer. uaudio0: Record: 48000 Hz, 1 ch, 16-bit S-LE PCM format, 2x8ms buffer. uaudio0: Record: 44100 Hz, 1 ch, 16-bit S-LE PCM format, 2x8ms buffer. uaudio0: No MIDI sequencer. pcm1: <USB audio> on uaudio0 uaudio0: HID volume keys found. It was a no-name, and is a "full speed".... ugen0.6: <C-Media Electronics Inc. USB Audio Device> at usbus0, cfg=0 md=HOST spd=FULL (12Mbps) pwr=ON (100mA) FreeBSD 11.0-STABLE #1 r313159M: Wed Feb 15 13:36:01 CST 2017 freebsd@NewFS.denninger.net:/pics/Crochet-work/obj/arm.armv6/pics/CrossBuild/src/sys/RPI2 Older kernel and OS, but working fine. I use it to play synthesized voice and MP3s. On 11/26/2018 13:21, Herbert J. Skuhra wrote: > On Mon, 12 Nov 2018 20:46:13 +0100, "Herbert J. Skuhra" wrote: >> On Sun, 11 Nov 2018 13:52:14 +0100, Hans Petter Selasky wrote: >>> On 11/10/18 12:24 PM, Herbert J. Skuhra wrote: >>>> Hi, >>>> >>>> if you use an USB sound card on your Raspberry PI 2B/3, can you please >>>> answer the following questions: >>>> >>>> - which USB sound card? >>>> - do you have bad audio on current or stable/12 after r339388? >>>> >>>> My "Creative Technology Ltd Sound Blaster Play 2" device sounds very >>>> bad. Meanwhile more changes were commited but they don't fix audio >>>> completly. >>>> >>> Hi, >>> >>> Some background: >>> >>> The USB controller in Raspberry PI is running HIGH-speed USB. Many USB >>> audio device are FULL-speed USB. In order for a FULL-speed USB device >>> to work in a HIGH-speed USB environment all data transfers need to go >>> through a so-called transaction translator. This transaction >>> translator operate on chunks of data, 171 bytes maximum. That means if >>> a USB audio stream generates 1000 packets per second, then suddenly a >>> bunch of smaller packets will be needed. This puts some stress on the >>> DWC OTG driver and there might be some room for improvement in this >>> area too, but the basic sympthom is that the DWC OTG driver in FreeBSD >>> is not always able to keep up with the timing required for these >>> so-called split transactions. One idea is to move all DWC OTG IRQ >>> handling away from CPU-0. I'm not sure if cpuset supports this yet on >>> armv7 // arm64. Might have to be done in the driver. >>> >>> Further some audio device use non-adaptive clocks, which means the >>> recording channel must be active along with the playback channel else >>> jitter will occur. >>> >>> The recommendation for RPI is a HIGH-speed USB audio device (should be >>> clearly marked in the specification). Using a HIGH-speed USB audio >>> device will reduce the number of interrupts significantly. >> Well, the sound card worked perfectly fine so far... both on FreeBSD >> and Arch Linux ARM... no luck with NetBSD. Never mind! I am obviously >> the only user affected by this "fix" (r339388). > Unfortunally I've purchased another full-speed usb audio device: > > uaudio0 on uhub1 > uaudio0: <Creative Technology Ltd Sound Blaster Play 3, class 0/0, rev 2.00/1.06, addr 4> on usbus0 > uaudio0: Play: 96000 Hz, 2 ch, 24-bit S-LE PCM format, 2x8ms buffer. > uaudio0: Play: 88200 Hz, 2 ch, 24-bit S-LE PCM format, 2x8ms buffer. > uaudio0: Play: 48000 Hz, 2 ch, 24-bit S-LE PCM format, 2x8ms buffer. > uaudio0: Play: 44100 Hz, 2 ch, 24-bit S-LE PCM format, 2x8ms buffer. > uaudio0: Record: 48000 Hz, 2 ch, 24-bit S-LE PCM format, 2x8ms buffer. > uaudio0: Record: 44100 Hz, 2 ch, 24-bit S-LE PCM format, 2x8ms buffer. > uaudio0: No MIDI sequencer. > pcm0: <USB audio> on uaudio0 > uaudio0: HID volume keys found. > > While it works fine under Linux (pulse), MacOS and Windows, it > produces only bad noise under FreeBSD (Raspberry PI3B)! :-( > > How can I get it working? Can anyone recommend an USB audio device for > FreeBSD? Should DACs from Pro-Ject work? > > Thanks. > > -- > Herbert > _______________________________________________ > freebsd-arm@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-arm > To unsubscribe, send any mail to "freebsd-arm-unsubscribe@freebsd.org" -- Karl Denninger karl@denninger.net <mailto:karl@denninger.net> /The Market Ticker/ /[S/MIME encrypted email preferred]/ [-- Attachment #2 --] 0 *H 010 `He 0 *H 00 H^Ōc!5 H0 *H 010 UUS10UFlorida10U Niceville10U Cuda Systems LLC10UCuda Systems CA1!0UCuda Systems LLC 2017 CA0 170817164217Z 270815164217Z0{10 UUS10UFlorida10U Cuda Systems LLC10UCuda Systems CA1%0#UCuda Systems LLC 2017 Int CA0"0 *H 0 h-5B>[;olӴ0~͎O9}9Ye*$g!ukvʶLzN`jL>MD'7U 45CB+kY`bd~b*c3Ny-78ju]9HeuέsӬDؽmgwER?&UURj'}9nWD i`XcbGz \gG=u%\Oi13ߝ4 K44pYQr]Ie/r0+eEޝݖ0C15Mݚ@JSZ(zȏ NTa(25DD5.l<g[[ZarQQ%Buȴ~~`IohRbʳڟu2MS8EdFUClCMaѳ !}ș+2k/bųE,n当ꖛ\(8WV8 d]b yXw ܊:I39 00U]^§Q\ӎ0U#0T039N0b010 UUS10UFlorida10U Niceville10U Cuda Systems LLC10UCuda Systems CA1!0UCuda Systems LLC 2017 CA @Ui0U0 0U0 *H :P U!>vJnio-#ן]WyujǑR̀Q nƇ!GѦFg\yLxgw=OPycehf[}ܷ['4ڝ\[p 6\o.B&JF"ZC{;*o*mcCcLY߾` t*S!(`]DHP5A~/NPp6=mhk밣'doA$86hm5ӚS@jެEgl )0JG`%k35PaC?σ ׳HEt}!P㏏%*BxbQwaKG$6h¦Mve;[o-Iی& I,Tcߎ#t wPA@l0P+KXBպT zGv;NcI3&JĬUPNa?/%W6G۟N000 k#Xd\=0 *H 0{10 UUS10UFlorida10U Cuda Systems LLC10UCuda Systems CA1%0#UCuda Systems LLC 2017 Int CA0 170817212120Z 220816212120Z0W10 UUS10UFlorida10U Cuda Systems LLC10Ukarl@denninger.net0"0 *H 0 T[I-ΆϏ dn;Å@שy.us~_ZG%<MYd\gvfnsa1'6Egyjs"C [{~_K Pn+<*pv#Q+H/7[-vqDV^U>f%GX)H.|l`M(Cr>е͇6#odc"YljҦln8@5SA0&ۖ"OGj?UDWZ5 dDB7k-)9Izs-JAv J6L$Ն1SmY.Lqw*SH;EF'DĦH]MOgQQ|Mٙג2Z9y@y]}6ٽeY9Y2xˆ$T=eCǺǵbn֛{j|@LLt1[Dk5:$= ` M 00<+00.0,+0 http://ocsp.cudasystems.net:88880 U0 0 `HB0U0U%0++03 `HB &$OpenSSL Generated Client Certificate0U%՞V=;bzQ0U#0]^§Q\ӎϡ010 UUS10UFlorida10U Niceville10U Cuda Systems LLC10UCuda Systems CA1!0UCuda Systems LLC 2017 CA H^Ōc!5 H0U0karl@denninger.net0 *H ۠A0-j%--$%g2#ޡ1^>{K+uGEv1ş7Af&b&O;.;A5*U)ND2bF|\=]<sˋL!wrw٧>YMÄ3\mWR hSv!_zvl? 3_ xU%\^#O*Gk̍YI_&Fꊛ@&1n } ͬ:{hTP3B.;bU8:Z=^Gw8!k-@xE@i,+'Iᐚ:fhztX7/(hY` O.1}a`%RW^akǂpCAufgDix UTЩ/7}%=jnVZvcF<M= 2^GKH5魉 _O4ެByʈySkw=5@h.0z> W1000{10 UUS10UFlorida10U Cuda Systems LLC10UCuda Systems CA1%0#UCuda Systems LLC 2017 Int CA k#Xd\=0 `He E0 *H 1 *H 0 *H 1 181126194330Z0O *H 1B@q P([URt8t+)se7 x33y&Z2`Z4a\0l *H 1_0]0 `He*0 `He0 *H 0*H 0 *H @0+0 *H (0 +7100{10 UUS10UFlorida10U Cuda Systems LLC10UCuda Systems CA1%0#UCuda Systems LLC 2017 Int CA k#Xd\=0*H 10{10 UUS10UFlorida10U Cuda Systems LLC10UCuda Systems CA1%0#UCuda Systems LLC 2017 Int CA k#Xd\=0 *H 1K&5s=xv}{<!K8Ta c$l V1C ]"a DS+#<JYS&7B 5:QEU#z\ ~beLNM*[M5>NP op:̲uX O6eU]yvEHkr3mbq3UcţP:ҖF>Σ0:@w̓%X#/'r;<FНqƾ{nZE#{ n{rUhVwpOS|<Hԝ[Kr.>Z>AY`xn!E\u]ycVIa2=Kna,'yz*-lNP=tj4n #)lжp;V</!S bsg]_ bQrLaAO&u.IJ$k rMJDU(C$ϩG%9u_RKF4?ޒ%#.OvcVfhelp
Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1418f261-9f56-7931-d23f-85059fdda077>
