How to connect USB guitar pedal or any USB music instrument and configure JACK to play and record on Ubuntu Linux

By Detector | 25 November 2008



If you are a musician or hobbyist player and if you have USB music gear, you can use your Ubuntu computer for playing, practicing or recording. This first tutorial is how to connect your USB music gear on Ubuntu:

Note: Alsa configuration is necessary for your sound card, because many USB instruments use the driver “snd-usb-audio” of ALSA. Go to System/Preferences/Sounds and configure sound capture same as on picture below:


First connect your music gear in computer USB (in this case I’m using guitar pedal zoom G2.1u) and connect the instrument to the gear.

Ubuntu will recognize the USB audio without any notifications so, to check that everything is OK, open your terminal and type this line:

cat /proc/asound/cards

and you will get something like on this picture:


We need this line for configuring Jack Audio Connection Kit. For installing Jack, open terminal and enter:

sudo apt-get install qjackctl jackd

Or you can install JACK with Package Manager:
Go to System/Administration/Synaptic Package Manager and in search field type “jack” without quotes. Find jackd and click and Mark for Installation. When installation is finished start Jack from Applications/Sound and Video/Jack Control and you will get something like next picture:


To configure jack click on setup and configure input devices (click > and choose USB audio codec) and output devices (usually hw:0) like the picture below (or set up higher sample rate if your system can support, but with this setup you can play normally too).


Next, in the main JACK window, click Start, and then click Connect. On Connections window select both input and output system by clicking on them and click connect, so that connection line must be shown as on picture!


Now your Jack server is on so you can play on your instrument. Many DAW applications like Ardour use Jack as main server for playing and recording, but for recording features and how to record instruments on Ubuntu read more on our next posts.

Tags | , , , ,

| |

9 Responses to “How to connect USB guitar pedal or any USB music instrument and configure JACK to play and record on Ubuntu Linux”

  1. Ular says:

    WOW! I do not know how to say THANKS!!!! 1 week looking for a way to play my guitar without latency in windows (when i use linux) and now this! it works perfectly! and in LINUX! Thanks a lot man! really thanks!

  2. Ular says:

    By the way, i’m using the Zoom g2.1u as you. last day I found a usefull site with lot of configurations (patches) for it:
    http://www.haax.se/manualsite/index.php?unit=G2

    I think your article is really good, and if you like to translate it at spanish, i can help you if you like (my englesh is not good but my Stanish yes :D ) i can translate it and send it to you by mail if you like.

    just an other thing. Too many people may be searching for this article but they use the wrong keys, like me (i was searching for: latency, usb, pc, sound driver, “how play the guitar in the computer speakers” and things like that)

    Please, feel free to edit this or delete if you want, i’m just traing to send you data because i can’t belive that I was the only one putting a post here, your article is very very usefull. thanks again. and count with me for helping.

  3. Ular,
    I’m really glad that we help you with our post, we are trying to simplify computer tips as much as is possible! You can translate it on Spanish and post it on the net but insert the link to the original article written by DetectorPRO.

    And also, you are invited to subscribe to get our great articles daily :)

    Viktor Ustijanoski
    DetectorPRO

  4. Ular says:

    I dont want to have my page, only colaborate so, here you have the traduction.

    Una traducción al castellano del articulo principal.

    Si son músicos o tocan por hobby, y además poseen una pedalera USB, ustedes pueden conectarla a Ubuntu y escuchar o grabar su instrumento atravez del mismo. Este primer tutorial explica como conectar la pedalera USB a Ubuntu:

    Nota: Es necesario que posean su placa de sonido configurada con ALSA, ya que muchos instrumentos USB usan el driver "snd-usb-audio" de ALSA. Vallan a Sistema/Preferencias/Sonido y configuren la captura de sonido tal como se muestra en la aquí:

    http://1.bp.blogspot.com/_Xy2g3N79xiI/SStW7Y0yvzI/AAAAAAAAARE/1VzMzRrUGvo/s1600-h/ALSA.jpg

    Primero conecten su pedalera USB a la computadora (en mi caso uso una pedalera de guitarra Zoom G2.1u) y conecten el instrumento a su pedalera.

    Ubuntu reconocera el dispositivo de audio USB sin notificarlo, de manera que para chequear que todo este bien, abran una terminal y digiten la siguiente linea:

    cat /proc/asound/cards

    y obtendrán algo parecido a lo que ven en esta figura:

    http://3.bp.blogspot.com/_Xy2g3N79xiI/SStChHThaUI/AAAAAAAAAQc/cPAivTp3ECU/s1600-h/terminalconnect.jpg

    Necesitamos esta linea para configurar el "Jack Audio Connection Kit". para instalarlo, abrimos una terminal y digitamos:

    sudo apt-get install qjackctl jackd

    O pueden instalar JACK con el manejador de paquetes:

    vallan a Sistemas/Administración/Gestor de Paquetes Synaptic , y en el área de búsqueda dimiten "jack" sin las comillas. En el resultado busquen la linea de jackd y márquenla para instalación. cuando la instalación este realizada ejecuten jack desde Aplicaciones/Sonido y Video/JACK Control , y obtendrán algo como lo de la imagen:

    http://4.bp.blogspot.com/_Xy2g3N79xiI/SStGBawpC7I/AAAAAAAAAQs/XxpooO52DyM/s1600-h/Jackstart.jpg

    Para configurarlo toquen el boton setup, y configuren los dispositivos de entrada ( toquen el botón ">" y seleccionen USB audio codec) y en dispositivos de salida (usualmente hw:0) como se muestra en la figura de abajo (o seleccionen un rate de muestreo superior si su sistema puede soportarlo, pero con estos seteos usted puede tocar normalmente también)

    http://4.bp.blogspot.com/_Xy2g3N79xiI/SStGdAFuPcI/AAAAAAAAAQ0/L7-N76IVV1A/s1600-h/Jacksetup.jpg

    Seguidamente, en la ventana principal de JACK, toquen el botón Start, y luego el Connect. En la ventana de conexiones que se abre, seleccionen ambos dispositivos de entrada y salida del sistema cliqueandolos y luego el botón connect. Esta linea de conexión sera mostrada como en la figura!

    http://4.bp.blogspot.com/_Xy2g3N79xiI/SStGtLbO-nI/AAAAAAAAAQ8/ZFY7ubCLU2c/s1600-h/jackconnection.jpg

    Ahora su servidor Jack esta activo de manera que usted puede tocar su instrumento. Algunas aplicaciones DAW como Ardour usan jack como server principal para reproducir y grabar, pero para grabar instrumentos en Ubuntu lea mas en nuestros próximos posts.

  5. hi,

    i am using ubuntu studio 9.10. i followed your instructions and found them very helpful.

    can you offer any advice on what the settings in 9.10 Sound Preference>Hardware,Input,Output tabs should be?

    it seems that sometimes there is to much gain but it could just be my old laptop does not have very good speakers.

    please advise.

  6. Alonzo, try increasing your Jack latency, set frames/period and periods/buffer to higher value, lower your sample rate, becouse if you are using old laptop maybe the problem is low latency = CPU intensive. If you connect your instrument with USB, I don think there is a input volume problem. Also connect your laptop with amplifier and bigger speakers and see if there is any difference. Have fun

  7. Pienso que estás en lo cierto. Tendré en cuenta tu blog!

  8. ollie brooks says:

    My sound preferences look completely different to yours! Im using ubuntu 10.10, how do i configure ALSA??
    Also when im running JACK and click connect it comes up with an error saying it cant connect to the JACK server?? What am i doing wrong?






Archives

Add to Technorati Favorites
website stats
TwitterCounter for @ukion