From owner-freebsd-multimedia@FreeBSD.ORG Sat May 18 07:22:44 2013 Return-Path: Delivered-To: freebsd-multimedia@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id BA36E867; Sat, 18 May 2013 07:22:44 +0000 (UTC) (envelope-from smithi@nimnet.asn.au) Received: from sola.nimnet.asn.au (paqi.nimnet.asn.au [115.70.110.159]) by mx1.freebsd.org (Postfix) with ESMTP id 0C9335E9; Sat, 18 May 2013 07:22:43 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by sola.nimnet.asn.au (8.14.2/8.14.2) with ESMTP id r4I72qwQ060654; Sat, 18 May 2013 17:02:53 +1000 (EST) (envelope-from smithi@nimnet.asn.au) Date: Sat, 18 May 2013 17:02:52 +1000 (EST) From: Ian Smith To: sbruno@freebsd.org Subject: Re: jackd In-Reply-To: <1368803054.1374.8.camel@localhost> Message-ID: <20130518154752.W86776@sola.nimnet.asn.au> References: <1368803054.1374.8.camel@localhost> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Cc: freebsd-multimedia@freebsd.org X-BeenThere: freebsd-multimedia@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Multimedia discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 18 May 2013 07:22:44 -0000 On Fri, 17 May 2013 08:04:14 -0700, Sean Bruno wrote: > I'm working on a port of IDJC, which requires jackd. > > At this point, I'm stuck on two jackd related issues. > > 1. How do I configure freebsd+jackd for realtime audio? Currently I > have to configure my .jackdrc to disable realtime audio, e.g. > /usr/local/bin/jackd -r -T -d oss Just wondering what problems are evident running it without rtprio? I gather -r with no value gives 48000, how many consumers? Just that even on an old 2GHz P4 on debian 4, we found no real issues running without -R that tuning buffer sizes etc wouldn't fix; FM pre-transmitter feeding an audio logging task (darkice to mp3 VBR -q0 @ ~210kbps) and our stream feed (patched edcast_jack to mp3 VBR -q2 @ ~192kbps) ALSA, though. That said, we wound up using -R anyway (both consumers running as root) but it made no noticeable difference with that load: /etc/default/jackd OPTIONS="-R -m -d alsa -d hw:0 -C hw:0 -r 44100 -n 3 -p 4096" PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND 16483 root 15 0 41252 3456 1580 S 8.2 0.7 173:15.30 edcast_jack 3032 root 15 0 25752 3576 1940 S 7.4 0.7 2583:03 darklogger 3002 root 22 0 37740 3612 3312 S 0.2 0.7 44:29.66 jackd 1491 root 25 10 2232 1140 864 R 0.2 0.2 0:00.96 top Re what Diane said, that seems also to be the case on linux, though I know nothing about our jackd port or what can be done here on FreeBSD. -R, --realtime Use realtime scheduling. This is needed for reliable low-latency performance. On most systems, it requires jackd to run with special scheduler and memory allocation privileges, which may be obtained in several ways. The simplest, and least-secure method is to run jackd with root privileges. This means that all JACK clients must also run as root. With a Linux 2.6 kernel, ordinary users can run jackd and its clients using options of the realtime LSM. Linux 2.4 kernels need "POSIX draft capabilities" enabled (see the include file). Using that method, ordinary users who invoke the daemon using jackstart, can later launch JACK clients without running them as root. See http://jackit.sourceforge.net/docs/faq.php#a52 for more information. > 2. Any clues on getting the microphone working with jackd? My > microphones work fine under audacity, but I don't seem to be able to get > any audio from microphones. > > Sean No idea sorry, and while interested, sadly no time to play with these: > http://people.freebsd.org/~sbruno/idjc/ > http://people.freebsd.org/~sbruno/shoud-idjc/ 404. http://people.freebsd.org/~sbruno/shout-idjc/ works :) cheers, Ian