IQaudio configuration

Hi, I’m building a zynthian with an IQaudio DAC+ board. I had started with a Raspiaudio (not officially supported by Zynthian) that I had quite easily managed to get working and after replacing it with an IQaudio DAC+ (officially supported by Zynthian) I can’t get it to work. The UI starts and everything but the sound goes through the RPi headphone output instead of soundcard.

Here is what aplay returns:

root@zynthian://zynthian# aplay -l                                                                                    
**** List of PLAYBACK Hardware Devices ****                                                                           
card 1: Headphones [bcm2835 Headphones], device 0: bcm2835 Headphones [bcm2835 Headphones]                            
  Subdevices: 7/8                                                                                                     
  Subdevice #0: subdevice #0                                                                                          
  Subdevice #1: subdevice #1                                                                                          
  Subdevice #2: subdevice #2                                                                                          
  Subdevice #3: subdevice #3                                                                                          
  Subdevice #4: subdevice #4                                                                                          
  Subdevice #5: subdevice #5                                                                                          
  Subdevice #6: subdevice #6                                                                                          
  Subdevice #7: subdevice #7                                                                                          
card 3: IQaudIODAC [IQaudIODAC], device 0: IQaudIO DAC HiFi pcm512x-hifi-0 [IQaudIO DAC HiFi pcm512x-hifi-0]          
  Subdevices: 0/1                                                                                                     
  Subdevice #0: subdevice #0                                                                                          
root@zynthian://zynthian# 

I tried to follow some instructions found in this thread: DIY Zynthian UI issue RPI 4B, i.e. in the Zynthian default advanced config proposal for IQaudio DAC+, I replaced a “hw:0” argument with “hw:IQaudIODAC”, some my jackd option looks like this:
-P 70 -t 2000 -s -d alsa -d hw:IQaudIODAC -r 44100 -p 256 -n 2 -X raw

Config: dtoverlay=iqaudio-dacplus
Any hint? Thanks in advance

Hi @pat

It looks like the templates for audio devices have not all been updated. This should work if you select Iqaudio Dac then replace hw:0 with hw:IQaudIODAC in the Jackd Options field. Save and reboot. If that does not work then post the output of journalctl -ujack2.

I had already rebooted. Here is the output you asked for:

-- Logs begin at Thu 2019-02-14 10:11:58 GMT, end at Sun 2021-02-14 13:41:07 GMT. --                                  
Feb 14 10:17:58 zynthian systemd[1]: Started JACK2 Audio Server.                                                      
Feb 14 10:17:59 zynthian jackd[401]: jackdmp 1.9.14                                                                   
Feb 14 10:17:59 zynthian jackd[401]: Copyright 2001-2005 Paul Davis and others.                                       
Feb 14 10:17:59 zynthian jackd[401]: Copyright 2004-2016 Grame.                                                       
Feb 14 10:17:59 zynthian jackd[401]: Copyright 2016-2019 Filipe Coelho.                                               
Feb 14 10:17:59 zynthian jackd[401]: jackdmp comes with ABSOLUTELY NO WARRANTY                                        
Feb 14 10:17:59 zynthian jackd[401]: This is free software, and you are welcome to redistribute it                    
Feb 14 10:17:59 zynthian jackd[401]: under certain conditions; see the file COPYING for details                       
Feb 14 10:17:59 zynthian jackd[401]: JACK server starting in realtime mode with priority 70                           
Feb 14 10:17:59 zynthian jackd[401]: self-connect-mode is "Don't restrict self connect requests"                      
Feb 14 10:18:00 zynthian jackd[401]: creating alsa driver ... hw:IQaudIODAC|hw:IQaudIODAC|256|2|44100|0|0|nomon|swmete
Feb 14 10:18:00 zynthian jackd[401]: configuring for 44100Hz, period = 256 frames (5.8 ms), buffer = 2 periods        
Feb 14 10:18:00 zynthian jackd[401]: ALSA: final selected sample format for playback: 32bit integer little-endian     
Feb 14 10:18:00 zynthian jackd[401]: ALSA: use 2 periods for playback                                                 
Feb 14 10:18:00 zynthian jackd[401]: scan: added port hw:0,0,0 in-hw-0-0-0-f-midi                                     
Feb 14 10:18:00 zynthian jackd[401]: scan: added port hw:0,0,0 out-hw-0-0-0-f-midi                                    
Feb 14 10:18:00 zynthian jackd[401]: scan: opened port hw:0,0,0 in-hw-0-0-0-f-midi                                    
Feb 14 10:18:00 zynthian jackd[401]: scan: opened port hw:0,0,0 out-hw-0-0-0-f-midi                                   
Feb 14 13:39:23 zynthian jackd[401]: scan: added port hw:3,0,0 in-hw-3-0-0-S90-MIDI-1                                 

thanks for your help

Maybe have a look at alsamixer settings (using ssh, type alsamixer command and verify that the iqaudio is the default)

Sorry the dump was incomplete but I doubt it changes anything, the alsa init stuff seems at the beginning

root@zynthian://zynthian# journalctl -ujack2                                                                          
-- Logs begin at Thu 2019-02-14 10:11:58 GMT, end at Sun 2021-02-14 16:39:26 GMT. --                                  
Feb 14 10:17:58 zynthian systemd[1]: Started JACK2 Audio Server.                                                      
Feb 14 10:17:59 zynthian jackd[401]: jackdmp 1.9.14                                                                   
Feb 14 10:17:59 zynthian jackd[401]: Copyright 2001-2005 Paul Davis and others.                                       
Feb 14 10:17:59 zynthian jackd[401]: Copyright 2004-2016 Grame.                                                       
Feb 14 10:17:59 zynthian jackd[401]: Copyright 2016-2019 Filipe Coelho.                                               
Feb 14 10:17:59 zynthian jackd[401]: jackdmp comes with ABSOLUTELY NO WARRANTY                                        
Feb 14 10:17:59 zynthian jackd[401]: This is free software, and you are welcome to redistribute it                    
Feb 14 10:17:59 zynthian jackd[401]: under certain conditions; see the file COPYING for details                       
Feb 14 10:17:59 zynthian jackd[401]: JACK server starting in realtime mode with priority 70                           
Feb 14 10:17:59 zynthian jackd[401]: self-connect-mode is "Don't restrict self connect requests"                      
Feb 14 10:18:00 zynthian jackd[401]: creating alsa driver ... hw:IQaudIODAC|hw:IQaudIODAC|256|2|44100|0|0|nomon|swmete
Feb 14 10:18:00 zynthian jackd[401]: configuring for 44100Hz, period = 256 frames (5.8 ms), buffer = 2 periods        
Feb 14 10:18:00 zynthian jackd[401]: ALSA: final selected sample format for playback: 32bit integer little-endian     
Feb 14 10:18:00 zynthian jackd[401]: ALSA: use 2 periods for playback                                                 
Feb 14 10:18:00 zynthian jackd[401]: scan: added port hw:0,0,0 in-hw-0-0-0-f-midi                                     
Feb 14 10:18:00 zynthian jackd[401]: scan: added port hw:0,0,0 out-hw-0-0-0-f-midi                                    
Feb 14 10:18:00 zynthian jackd[401]: scan: opened port hw:0,0,0 in-hw-0-0-0-f-midi                                    
Feb 14 10:18:00 zynthian jackd[401]: scan: opened port hw:0,0,0 out-hw-0-0-0-f-midi                                   
Feb 14 13:39:23 zynthian jackd[401]: scan: added port hw:3,0,0 in-hw-3-0-0-S90-MIDI-1                                 
Feb 14 13:39:23 zynthian jackd[401]: scan: added port hw:3,0,1 in-hw-3-0-1-S90-MIDI-2                                 
Feb 14 13:39:23 zynthian jackd[401]: scan: added port hw:3,0,2 in-hw-3-0-2-S90-MIDI-3                                 
Feb 14 13:39:23 zynthian jackd[401]: scan: added port hw:3,0,0 out-hw-3-0-0-S90-MIDI-1                                
Feb 14 13:39:23 zynthian jackd[401]: scan: added port hw:3,0,1 out-hw-3-0-1-S90-MIDI-2                                
Feb 14 13:39:23 zynthian jackd[401]: scan: added port hw:3,0,2 out-hw-3-0-2-S90-MIDI-3                                
Feb 14 13:39:23 zynthian jackd[401]: scan: added port hw:3,0,3 out-hw-3-0-3-S90-MIDI-4                                
Feb 14 13:39:23 zynthian jackd[401]: scan: added port hw:3,0,4 out-hw-3-0-4-S90-MIDI-5                                
Feb 14 13:39:23 zynthian jackd[401]: scan: added port hw:3,0,5 out-hw-3-0-5-S90-MIDI-6  
Feb 14 13:39:23 zynthian jackd[401]: scan: added port hw:3,0,6 out-hw-3-0-6-S90-MIDI-7                                
Feb 14 13:39:23 zynthian jackd[401]: scan: added port hw:3,0,7 out-hw-3-0-7-S90-MIDI-8                                
Feb 14 13:39:23 zynthian jackd[401]: ALSA lib rawmidi_hw.c:233:(snd_rawmidi_hw_open) open /dev/snd/midiC3D0 failed: De
Feb 14 13:39:23 zynthian jackd[401]: ALSA lib rawmidi_hw.c:233:(snd_rawmidi_hw_open) open /dev/snd/midiC3D0 failed: De                              

Here is alsamixer output:

┌───────────────────────────────────────────────── AlsaMixer v1.1.8 ─────────────────────────────────────────────────┐
│ Card: f_midi                                                                               F1:  Help               │
│ Chip:                                                                                      F2:  System information │
│ View: F3: Playback  F4: Capture  F5: All                                                   F6:  Select sound card  │
│ Item:                                                                                      Esc: Exit               │
│                                                                                                                    │
│                                                                                                                    │
│                                                                                                                    │
│                                   This sound┌───── Sound Card ──────┐ controls.                                    │
│                                             │-  (default)           │                                              │
│                                             │0  f_midi              │                                              │
│                                             │1  bcm2835 Headphones  │                                              │
│                                             │2  IQaudIODAC          │                                              │
│                                             │3  S90                 │                                              │
│                                             │   enter device name...│                                              │
│                                             └───────────────────────┘                                              │
│                                                                                                                    │
│                                                                                                                    │

it says “this sound device has no controls”. I can then press F6 like shown above, and select IQaudioDAC and a bunch of controls appear, but then? doesn’t seem to make any difference

Choose in alsamixer the iqaudio sound card. Then, in the brunch of controls, maybe there’s one that mute the output.

I have never touched these controls before, so isn’t it unlikely that the output was muted by default? And also: I get (quite weak) sound from the raspberry pi board headphones output, so doesn’t it mean the wrong audio device is selected somewhere and it is just not going to the sound card? (unless the alsa mixer sends to more than one output device at a time?)

who knows ? Did you try to check this ?

As far as I understand, the “Select sound card” function in alsa mixer only selects which device to display parameters for, not which one is active: whatever device I select, sound always goes through rpi headphone out, and it doesn’t remember the selected device when you exit and restart alsamixer. By default it shows me device 0, if I select device 1 I can adjust the raspberry pi headphone output volume (and it indeed works, btw it was quite low, which explained why I founded it weak), and if I select device 2 I see the IQaudio settings. Analog output level is 0 dB, so it seems fine.

Hi, the log above shows that jackd sound server is up and running and that jackd it use the iqaudio interface. So you have to find why there is no sound output from that interface and some settings in alsamixer could solve this issue.
I can’t tell you more as I do not own an iqaudio.

OK in the meantime I saved again the hw audio settings in webconf then restarted the zynthian as requested an now I no longer have any audio out (neither from rpi nor from iqaudio), rebooted again and same result.

Here"s a screenshot of alsamixer


1st analogue is output level = 0dB, the second one is an “analogue playback boost” which is also set to 0dB (only takes 0 or +0.8 dB), then the “auto mute” stuff: don’t know what it is about but I don’t seem to be able to change its value anyway…

Yes, that’s what I had understood too, though the sound was actually going out through the RPi headphone out! (no longer does)

Please post the output of:

jack_lsp -c

so we can check the audio routing.

The “m” key toggles mute unmute switches

Here you go:

system:playback_1                                                                                                     
   LinuxSampler:CH0_1                                                                                                 
system:playback_2                                                                                                     
   LinuxSampler:CH0_2                                                                                                 
system:midi_capture_1                                                                                                 
   ZynMidiRouter:main_in                                                                                              
system:midi_playback_1                                                                                                
ttymidi:MIDI_in                                                                                                       
   ZynMidiRouter:main_in                                                                                              
ttymidi:MIDI_out                                                                                                      
   ZynMidiRouter:midi_out                                                                                             
a2j:Midi Through [14] (capture): Midi Through Port-0                                                                  
   ZynMidiRouter:main_in                                                                                              
a2j:Midi Through [14] (playback): Midi Through Port-0                                                                 
jackpeak:input_a                                                                                                      
   LinuxSampler:CH0_1                                                                                                 
jackpeak:input_b                                                                                                      
   LinuxSampler:CH0_2                                                                                                 
ZynMidiRouter:main_out                                                                                                
ZynMidiRouter:midi_out                                                                                                
   ttymidi:MIDI_out                                                                                                   
ZynMidiRouter:net_out                                                                                                
ZynMidiRouter:ctrl_out                                                                                                
ZynMidiRouter:step_out                                                                                                
   zynthstep:input                                                                                                    
ZynMidiRouter:ch0_out                                                                                                 
   LinuxSampler:midi_in_0                                                                                             
ZynMidiRouter:ch1_out                                                                                                 
ZynMidiRouter:ch2_out                                                                                                 
ZynMidiRouter:ch3_out                                                                                                 
ZynMidiRouter:ch4_out                                                                                                 
ZynMidiRouter:ch5_out                                                                                                 
ZynMidiRouter:ch6_out                                                                                                 
ZynMidiRouter:ch7_out                                                                                                 
ZynMidiRouter:ch8_out                                                                                                 
ZynMidiRouter:ch9_out                                                                                                 
ZynMidiRouter:ch10_out                                                                                                
ZynMidiRouter:ch11_out                                                                                                
ZynMidiRouter:ch12_out                                                                                                
ZynMidiRouter:ch13_out                                                                                                
ZynMidiRouter:ch14_out                                                                                                
ZynMidiRouter:ch15_out                                                                                                
ZynMidiRouter:main_in                                                                                                 
   system:midi_capture_1                                                                                              
   ttymidi:MIDI_in                                                                                                    
   a2j:Midi Through [14] (capture): Midi Through Port-0                                                               
   jack_midi_clock:mclk_out                                                                                           
   aubio:midi_out_1                                                                                                   
   a2j:S90 [28] (capture): S90 MIDI 1                                                                                 
   a2j:S90 [28] (capture): S90 MIDI 2                                                                                 
   a2j:S90 [28] (capture): S90 MIDI 3                                                                                 
ZynMidiRouter:net_in                                                                                                  
ZynMidiRouter:seq_in                                                                                                  
ZynMidiRouter:step_in                                                                                                 
   zynthstep:output                                                                                                   
ZynMidiRouter:ctrl_in                                                                                                 
Headphones:playback_1                                                                                                 
   LinuxSampler:CH0_1                                                                                                 
Headphones:playback_2                                                                                                 
   LinuxSampler:CH0_2                                                                                                 
zynthstep:input                                                                                                       
   ZynMidiRouter:step_out                                                                                             
zynthstep:output                                                                                                      
   ZynMidiRouter:step_in                                                                                              
LinuxSampler:CH0_1                                                                                                    
   system:playback_1                                                                                                  
   Headphones:playback_1                                                                                              
   jackpeak:input_a                                                                                                   
LinuxSampler:CH0_2                                                                                                    
   system:playback_2                                                                                                  
   Headphones:playback_2                                                                                              
   jackpeak:input_b                                                                                                   
LinuxSampler:CH1_1                                                                                                    
LinuxSampler:CH1_2                                                                                                    
LinuxSampler:CH2_1                                                                                                    
LinuxSampler:CH2_2                                                                                                    
LinuxSampler:CH3_1                                                                                                    
LinuxSampler:CH3_2                                                                                                    
LinuxSampler:CH4_1                                                                                                    
LinuxSampler:CH4_2                                                                                                    
LinuxSampler:CH5_1                                                                                                    
LinuxSampler:CH5_2                                                                                                     
LinuxSampler:CH6_1                                                                                                    
LinuxSampler:CH6_2                                                                                                    
LinuxSampler:CH7_1                                                                                                    
LinuxSampler:CH7_2                                                                                                    
LinuxSampler:midi_in_0                                                                                                
   ZynMidiRouter:ch0_out                                                                                              
jack_midi_clock:mclk_out                                                                                              
   ZynMidiRouter:main_in                                                                                              
aubio:out_1                                                                                                           
aubio:midi_out_1                                                                                                      
   ZynMidiRouter:main_in                                                                                              
aubio:in_1                                                                                                            
a2j:S90 [28] (capture): S90 MIDI 1                                                                                    
   ZynMidiRouter:main_in                                                                                              
a2j:S90 [28] (playback): S90 MIDI 1                                                                                   
a2j:S90 [28] (capture): S90 MIDI 2                                                                                    
   ZynMidiRouter:main_in                                                                                              
a2j:S90 [28] (playback): S90 MIDI 2                                                                                   
a2j:S90 [28] (capture): S90 MIDI 3                                                                                    
   ZynMidiRouter:main_in                                                                                              
a2j:S90 [28] (playback): S90 MIDI 3                                                                                   
a2j:S90 [28] (playback): S90 MIDI 4                                                                                   
a2j:S90 [28] (playback): S90 MIDI 5                                                                                   
a2j:S90 [28] (playback): S90 MIDI 5                                                                                   
a2j:S90 [28] (playback): S90 MIDI 6                                                                                   
a2j:S90 [28] (playback): S90 MIDI 7                                                                                   
a2j:S90 [28] (playback): S90 MIDI 8                                                                                   

Looks like you have linux sampler as a layer which is routed to main output, headphone output and peak meters.

Do you see any audio indication on your peak meters at top right of zynthian display?

Have you checked the volume controls within Linux Sampler layer?

(Sorry for asking such simple questions but sometimes a simple thing is the problem that we overlook!)

1 Like

I have a piano SFZ loaded and I can see it on the peak meters… and hear it on the RPi headphone outputs (for some reason, it had gone away during a couple of reboots and now it’s back)

As far as I remember it’s full scale but no need to double check I guess as I can hear it… but on the wrong output…

Have you checked the audio wiring from the Zynthian to your amplifier? What connections are you using? Have you tried a different audio source with the same cables?

The amplifier is connected through a RCA cable that I plug either on the IQaudio DAC+ line output or on a 3.5mm jack to RCA adapter inserted in the RPi headphones output. As I get some sound out of it when it’s plugged to the RPi out through the adapter, I’m positive that the cable works fine. I’ve also tried the IQaudio headphones output this way with no luck BTW. The only one that makes sound is the RPi out, whose volume I can control through alsamixer.

FYI I had first installed another board (raspiaudio hat) that isn’t officially supported by Zynthian but that worked and for which I had installed drivers, but I suppose that this should cause no conflict as soon as the card is no longer plugged.

I wonder if installation of drivers may have upset the device? It has been bitter experience that running any kind of installer or manual update changes the Zynthian and often breaks operation. You may need to restore back to a new image and start again :frowning_face: .