Tutorial 2 - Audio programming with gtkIOStream

Moderator: flatmax

flatmax
Posts: 609
Joined: Sat Jul 23, 2016 11:39 pm

Re: Tutorial 2 - Audio programming with gtkIOStream

Post by flatmax » Thu Sep 14, 2017 9:45 pm

OK,

jackd can use the .jackdrc file to work out how to start jack by default - in other words, if you start a client it can autostart the jackd server for you. Do you have a .jackdrc file ?

Code: Select all

cat ~/.jackdrc
If you do, you can edit it to change the sample rate to 44100 Hz :

Code: Select all

-r44100
In the example from the tutorial above, you can use the following command :

Code: Select all

jackd -d alsa -r 44100 -i 2 -o 2
Matt
Check out our audiophile quality crossovers : https://bit.ly/2kb1nzZ
Please review the Zero sound card on Amazon USA : https://www.amazon.com/dp/B075V1VNDD
---
Check out our new forum on github : https://github.com/Audio-Injector

niyer
Posts: 7
Joined: Thu Aug 17, 2017 9:42 am

Re: Tutorial 2 - Audio programming with gtkIOStream

Post by niyer » Sun Oct 22, 2017 6:40 am

Hi Matt,
Apologize for the delay. I just saw your reply.
I ended up using the .jackdrc file to change the sample rate. I used "qjackctl" to create that file and change the sample rate. It worked great.

Thank you.

Regards,
Nathan

niyer
Posts: 7
Joined: Thu Aug 17, 2017 9:42 am

Re: Tutorial 2 - Audio programming with gtkIOStream

Post by niyer » Thu Nov 02, 2017 1:39 pm

Hi Matt,
With both the gain knobs set to max, we are seeing about 7.3 dB loss in both channels. This was tested by running JackClient and arecord .. | aplay.. . Is this loss expected ? If so is there a way to bring the loss to 0 dB ?
In AlsaMixer settings, the Master gain is set to 0 dB and the playback capture is set to 100<>100 ( Max).

Thanks,
Nathan

flatmax
Posts: 609
Joined: Sat Jul 23, 2016 11:39 pm

Re: Tutorial 2 - Audio programming with gtkIOStream

Post by flatmax » Sat Nov 04, 2017 9:19 pm

Hi there,

Can you please check whether you have the file ~/.jackdrc on your system ?
If so, can you please paste its output here ?

I Think this file may be on your system and telling jackd how to start the server when it isn't running ... your client tries to connect, then autostarts the server using information from that .jackdrc file.

Let us know what you find.

thanks
Matt
Check out our audiophile quality crossovers : https://bit.ly/2kb1nzZ
Please review the Zero sound card on Amazon USA : https://www.amazon.com/dp/B075V1VNDD
---
Check out our new forum on github : https://github.com/Audio-Injector

niyer
Posts: 7
Joined: Thu Aug 17, 2017 9:42 am

Re: Tutorial 2 - Audio programming with gtkIOStream

Post by niyer » Tue Nov 07, 2017 12:28 pm

My ~/.jackdrc file contains one line:

"/usr/bin/jackd -dalsa -dhw:0 -r44100 -p1024 -n2" .

Is this some how related to why I am seeing a loss of 7.3 dB between capture in and line out ?

Thanks,
Nathan

flatmax
Posts: 609
Joined: Sat Jul 23, 2016 11:39 pm

Re: Tutorial 2 - Audio programming with gtkIOStream

Post by flatmax » Tue Nov 07, 2017 7:47 pm

The loss, I am not sure about, jackd doesn't introduce attenuation.

What sound card are you using ? What does alsamixer show you ?

Matt
Check out our audiophile quality crossovers : https://bit.ly/2kb1nzZ
Please review the Zero sound card on Amazon USA : https://www.amazon.com/dp/B075V1VNDD
---
Check out our new forum on github : https://github.com/Audio-Injector

niyer
Posts: 7
Joined: Thu Aug 17, 2017 9:42 am

Re: Tutorial 2 - Audio programming with gtkIOStream

Post by niyer » Fri Nov 10, 2017 10:33 am

I am using Flatmax Stereo soundcard with both gain knobs set to MAX.
The Alsamixer Master gain is set to 0 dB and the playback capture is set to 100<>100 ( Max).

On an unrelated matter, does your driver use DMA or interrupt method to transfer I2S data ? We do a bunch of processing and I would like to know if there is any way I can make it more efficient.

-Nathan

flatmax
Posts: 609
Joined: Sat Jul 23, 2016 11:39 pm

Re: Tutorial 2 - Audio programming with gtkIOStream

Post by flatmax » Sat Dec 30, 2017 3:39 pm

The ALSA driver uses DMA.
Check out our audiophile quality crossovers : https://bit.ly/2kb1nzZ
Please review the Zero sound card on Amazon USA : https://www.amazon.com/dp/B075V1VNDD
---
Check out our new forum on github : https://github.com/Audio-Injector

Franshej
Posts: 9
Joined: Mon Jan 22, 2018 4:13 am

Re: Tutorial 2 - Audio programming with gtkIOStream

Post by Franshej » Wed Jan 24, 2018 11:38 pm

Hi!
The octo card works fine with audacity but when i run the Jackd i get the error:

pi@raspberrypi:~ $ jackd -d alsa -r 48000 -i 2 -o 2
jackdmp 1.9.11
Copyright 2001-2005 Paul Davis and others.
Copyright 2004-2014 Grame.
jackdmp comes with ABSOLUTELY NO WARRANTY
This is free software, and you are welcome to redistribute it
under certain conditions; see the file COPYING for details
JACK server starting in realtime mode with priority 10
self-connect-mode is "Don't restrict self connect requests"
audio_reservation_init
Acquire audio card Audio0
creating alsa driver ... hw:0|hw:0|1024|2|48000|2|2|nomon|swmeter|-|32bit
configuring for 48000Hz, period = 1024 frames (21.3 ms), buffer = 2 periods
ALSA: final selected sample format for capture: 32bit integer little-endian
ALSA: cannot set channel count to 2 for capture
ALSA: cannot configure capture channel
Cannot initialize driver
JackServer::Open failed with -1
Failed to open server

regards Frans

alonzo
Posts: 1
Joined: Thu Sep 27, 2018 3:45 pm

Re: Tutorial 2 - Audio programming with gtkIOStream

Post by alonzo » Thu Sep 27, 2018 3:49 pm

flatmax wrote:
Sat Nov 04, 2017 9:19 pm
Hi there,

Can you please check whether you have the file ~/.jackdrc on your site ?
If so, can you please paste its output here ?

I Think this file may be on your system and telling jackd how to start the server when it isn't running ... your client tries to connect, then autostarts the server using information from that .jackdrc file.

Let us know what you find.

thanks
Matt

Worked for me. Thanks!!!

Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests