ZITA-AJBRIDGE(1)

πŸ“¦
version 0.8.4 Β· 2 versions
, in debian bookworm, debian trixie, ubuntu jammy, ubuntu noble, ubuntu questing, ubuntu resolute, ubuntu stonking

ZITA-AJBRIDGE(1) πŸ’–

okay bestie, this is a page from the General Commands Manual, and it's about two lil programs: zita-a2j and zita-j2a. get comfy 🫢


✨ NAME ✨

zita-a2j, zita-j2a β€” use an ALSA device as a Jack client, with resampling. πŸ’…


🌸 SYNOPSIS 🌸

zita-a2j [options]
zita-j2a [options]

πŸ¦‹ DESCRIPTION πŸ¦‹

so these two programs let you use an ALSA device as a Jack client, which gives you extra capture channels (zita-a2j) or extra playback channels (zita-j2a). functionally they do exactly what alsa_in and alsa_out (the ones that ship with Jack) do β€” but the audio quality is so much better. not me being dramatic, it's literally in the manual. πŸ’€

the resampling ratio will typically be stable within a few parts per million and only change very smoothly. delay stays stable too, even in worse case conditions β€” like when the Jack client is running near the end of the cycle. iconic behavior honestly. ✨

the ALSA device should be a hw: one, i.e. direct access to a soundcard, NOT an ALSA plug device. also, a well-working Jack system is assumed, running in real-time mode. no pressure bestie πŸŽ€

the sample rate can be the same as Jack's, or different. you get minimum delay by running the ALSA device at a lower period size than Jack. this is safe to do because the ALSA thread runs at a higher priority, and apart from copying to an internal buffer, no work is done there. and listen β€” there are no restrictions on the product of period_size and number_of_periods, unlike with alsa_in and alsa_out. slay.

resampling is done using the zita-resampler library. the -Q option sets the resampling quality. that parameter value is half the length (i.e. the delay) of the multiphase filter used for resampling, expressed in samples at the lower of the two sample rates. it mainly affects the shape of the frequency response near the Nyquist frequency. normally you don't even need this option, because an optimum value depending on both sample rates is chosen automatically. the available range is 16..96.

the -S option disables resampling. but bestie, this requires that the device is synced via word-clock to the one used by Jack.

the -L option forces the ALSA interface to 2 channels and 16-bit sample format. you might need this when a2j or j2a is used with ALSA's loop device, if the other end doesn't accept more than 2 channels or floating point samples.

⚠️ This option must not be used otherwise. like, periodt. don't do it.

both programs will optionally print some info four times per second. here's the tea:

  • the first number is the average loop error over the last quarter second, in samples. it should settle down to small random values close to zero after 15 seconds or so.
  • the second number is the dynamic correction factor of the nominal resampling ratio. this should converge to a value close to one and not move much.

small variations in these numbers show up when Jack apps are started or stopped. this is normal. anything else isn't β€” please report it! πŸ™ˆ

when starting, and in case of major trouble, the Starting synchronisation message gets printed. a restart can happen if there's a timeout on the Jack server, e.g. when a client crashed or terminated in a dirty way. 😭

Jack1 will skip one or more cycles when new apps are started, or when a large number of port connections is done in a short time. this may interrupt the audio signal, but should otherwise have no ill consequences and not require a restart.

both zita-a2j and zita-j2a will suspend operation while Jack is in freewheeling mode.


πŸ’… OPTIONS πŸ’…

  • -h β€” print command line and options summary. the lil help me please button πŸ₯Ί
  • -j <name> β€” Jack client name [default: zita-a2j or zita-j2a].
  • -d <device> β€” ALSA device [default: none].
  • -r <rate> β€” sample rate [default: 48000].
  • -p <period> β€” period size [default: 256].
  • -n <nfrags> β€” number of fragments [default: 2].
  • -c <nchannels> β€” number of channels [default: 2].
  • -Q <quality> β€” resampling quality [default: auto].
  • -S β€” word clock sync, disable resampling.
  • -I <samples> [0] β€” (zita-a2j only) latency correction. the value is added to the latency property set on the Jack ports.
  • -O <samples> [0] β€” (zita-j2a only) latency correction. the value is added to the latency property set on the Jack ports.
  • -L β€” force 2 channels and 16-bit sample format.
  • -v β€” print tracing information.

πŸ‘‘ AUTHOR πŸ‘‘

the zita-a2j and zita-j2a programs were written by Fons Adriaensen <fons@linuxaudio.org>. this manual page was written by Robin Gareus <robin@gareus.org> and Fons Adriaensen. legends, both of them 🫢


and that's the whole page bestie, Sept 2013, from the General Commands Manual crew (source/version: ZITA-AJBRIDGE(1)). go make some beautiful audio, ily πŸ’–βœ¨πŸŽ€