Desktop HDMI screen, no encoders, only USB MIDI controls - what settings should I use?

I’m planning to build my RPi into a MIDI keyboard case and use the encoders/faders to access all Zynthian controls. I may end up building in a screen and adding hardware encorders eventually but for right now, how far will I be able to get with just a Raspberry Pi, an external MIDI controller and a cheap generic USB soundcard?? Should I change the ‘wiring’ settings to reflect the fact that I don’t have any?? And also, how can I then look at setting it up so that I can perform the tasks of the hardware encoders via the MIDI controls already present on my keyboard?

i m also interested in this to begin mt project!

the hdmi display setting will deal with an hdmi monitor and the width & height settings will allow you to deal with any aspect ratio issues. The UI ffont settings might need altering to fit the screen but it’s all preety obvious once you get going.

if you select dummies for the encoders that will solve that one but most settings work in any case.the audio is probably the setting that most affects the behaviour. get it wrong and the gui probably won’t start but luckily the webconf allows you to set the device up in spite of a non start of the gui and the generic USB will generally work. If it doesn’t you will need to play around with the USB alsa settings but I’d try it out then report the results if it doesn’t work. You can try cut and paste but understanding of the jackd start up settings is probably what’s required. It’s normally the hw: setting.

using midi driven encoders is a little bit more confusing, and that’s conceptual rather than technical. A midi controller is normally a pot or an encoder pretending to be a potentiometer. So it varies from 0 to 127. The problem with that is the zynth encoders work as proper encoders using up and down signals. To produce something that could control a list properly when you move to a specific screen after you’ve come from another page is rather complicated because most pots will simply send the maximum value but not repeat send if further turns are made. I’m sure it can be done but I suspect it will be a bit clunky…

and this is before we try to do the push button function of the encoder and bold presses and long presses don’t really map.

so it’s not quite the easy option it might appear at first glance.
You can send CUIA commands to drive the gui and that would allow you to drive the whole device from push buttons but it might be a lot of switches. Course some one will probably come up with a solution at some point and if you do get a screen then makes sure it’s a touchscreen as that will address most of the issues. And you really can do an awful lot with a mouse! I drive most of my differently abled zynth that way. Really easy if you get a wireless(not Bluetooth) one it’s really intuitive once you learn the trick to do the back button.1

Thanks Wyleu, that was very helpful info! So just by manually specifying my resolution width/height I was able to finally get an image on my monitor and control it with keyboard/mouse. I still can’t seem to get any audio, though; I changed from the USB audio to the Pi’s built-in output which helped me to get the menu screen to boot, but I don’t know why I wouldn’t be getting any audio. I’ll keep persevering and following the user guide. I don’t know much about changing the ALSA settings; are you saying these will need to be set for my specific hardware (it’s a Pi 3 B v1.2)

I understand what you mean about the MIDI encoders, being linear (0-127) instead of ‘endless’, so I will definitely think about adding GPIO controllers, as well as a touch screen! I just wanted to give it a test drive to see how much is possible first.

Glad it helped.
The audio settings for USB are really just passed to the jackd (the audio server) and if they don’t match then jackd won’t start hense no audio. The gui logging in the webconf will tell you if this is happening. A very good starting point if it’s not working is by logging onto the zynth and type a play - l this will tell you what alsa (the audio hardware handler) and these settings will contain details that need feeding into the jack settings. I set up a yeti USB microphone so if you search this forum for the word yeti you will probably find my all too copious notes on setting that up that might help. I’m on my android tablet at the moment which isn’t the most effective editing environment for the forum so I’ll let you find it. But post the logging results if you can’t get it working and I’m sure we can get you going.

Thanks I appreciate the help. So sticking with on-board audio (rather than over-complicating things with a USB audio card) I’m currently just using the suggested settings which look like this:

But even when I navigate to the ADMIN menu on my Pi and try to test the audio by playing the test MP3, I hear no output. I’m thinking I have to have some specific setting for the Rbpi On-board Audio to get anything to play out…?

Also, I found your post on the Yeti and typed the ‘aplay -l’ into SSH and here’s what I get with just the on-board audio:

**** List of PLAYBACK Hardware Devices ****
card 0: ALSA [bcm2835 ALSA], device 0: bcm2835 ALSA [bcm2835 ALSA]
Subdevices: 6/7
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
card 0: ALSA [bcm2835 ALSA], device 1: bcm2835 IEC958/HDMI [bcm2835 IEC958/HDMI]
Subdevices: 1/1
Subdevice #0: subdevice #0

And then if I plug in my generic USB sound card I get this:

**** List of PLAYBACK Hardware Devices ****
card 0: ALSA [bcm2835 ALSA], device 0: bcm2835 ALSA [bcm2835 ALSA]
Subdevices: 6/7
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
card 0: ALSA [bcm2835 ALSA], device 1: bcm2835 IEC958/HDMI [bcm2835 IEC958/HDMI]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 1: Device [USB PnP Sound Device], device 0: USB Audio [USB Audio]
Subdevices: 1/1
Subdevice #0: subdevice #0

So I don’t know where to feed that info into the ‘jack settings’ or which of those two devices would be easiest to get audio output working with… Right now, the only way I can get Zynthian to boot to the menu screen is by disconnecting my USB card and only using the on-board audio, but hopefully I can work out how to use the USB as it’s likely going to be slightly better audio/latency until I can obtain a HifiBerry or similar (hugely backlogged currently due to all this virus stuff!).

The line you want to modify is the jackd settings. On the on board audio because you have hw:ALSA I suspect it is selecting the default ALSA device which is device 0 which is the on board. I’ve used the on board as a kind of default but I’ve never tried getting audio out of it so I don’t know quite how it is meant to behave. Try substituting USB audio for ALSA as that should select the USB device. As I say I’m away from my zynths so can’t test this directly. I’m pretty sure I listed the jackd options in the yeti thread so try using the generic USB settings as a starting point and see if they can match the settings for whatever your USB device is. I’ve used a ‘normal’ raspbian ssd to start up a zynth and extracted the audio settings from that to get the correct values (does your USB device support 44100 for instance and is it output only?) . Apologies this isn’t a particularly well documented area cos the default is obviously a dedicated audio card. ALSA is famous for its complexity which I’m sure is not much help and you need to get it to match and then it just works. Be sure to note the working setting when you get it. It’s all a bit hit and miss but follow thru the yeti example and keep at it. As I say copy up the gui logs and I will try again in the morning. Sorry I can’t help directly now. :roll_eyes:

1 Like

try aplay -L

root@zynthian-touch:~# aplay -L this lists ALL the available alsa options and as you can see the card is reported in the Yeti case as Microphone.
Doing the same for your USB device should reveal the appropriate hw: instance to put in the jackd dialog box . . .
null
Discard all samples (playback) or generate zero samples (capture)
default:CARD=Microphone
Yeti Stereo Microphone, USB Audio
Default Audio Device
sysdefault:CARD=Microphone
Yeti Stereo Microphone, USB Audio
Default Audio Device
front:CARD=Microphone,DEV=0
Yeti Stereo Microphone, USB Audio
Front speakers
surround21:CARD=Microphone,DEV=0
Yeti Stereo Microphone, USB Audio
2.1 Surround output to Front and Subwoofer speakers
surround40:CARD=Microphone,DEV=0
Yeti Stereo Microphone, USB Audio
4.0 Surround output to Front and Rear speakers
surround41:CARD=Microphone,DEV=0
Yeti Stereo Microphone, USB Audio
4.1 Surround output to Front, Rear and Subwoofer speakers
surround50:CARD=Microphone,DEV=0
Yeti Stereo Microphone, USB Audio
5.0 Surround output to Front, Center and Rear speakers
surround51:CARD=Microphone,DEV=0
Yeti Stereo Microphone, USB Audio
5.1 Surround output to Front, Center, Rear and Subwoofer speakers
surround71:CARD=Microphone,DEV=0
Yeti Stereo Microphone, USB Audio
7.1 Surround output to Front, Center, Side, Rear and Woofer speakers
iec958:CARD=Microphone,DEV=0
Yeti Stereo Microphone, USB Audio
IEC958 (S/PDIF) Digital Audio Output
dmix:CARD=Microphone,DEV=0
Yeti Stereo Microphone, USB Audio
Direct sample mixing device
dsnoop:CARD=Microphone,DEV=0
Yeti Stereo Microphone, USB Audio
Direct sample snooping device
hw:CARD=Microphone,DEV=0
Yeti Stereo Microphone, USB Audio
Direct hardware device without any conversions
plughw:CARD=Microphone,DEV=0
Yeti Stereo Microphone, USB Audio
Hardware device with all software conversions
root@zynthian-touch:~#

The jackd startup details are here:- Audio Setup

Hi there,
it’s been a while I didn’t post here, but, quiet every day, I carefully read all the forum threads.
That one is interesting, because I’ve already had the same thoughts as @peanutismint : controlling the UI with my midi controller surface.

So, this is more or less a request to @jofemodo : do you think CUIA actions for simulating zynthian encoders UP/DOWN could be implemented ?
I will later this afternoon post a NFR on github

1 Like

Already implemented!

But I think the info is a bit incorrect. I tried mapping some pads on my keyboard to Audio and MIDI record, and the actual mapped keys are something like an octave higher or lower. Somebody should update that…

@jofemodo Where in the code are the CUIA-MIDI mappings listed?

Ji @ Jtunes.

51    SELECT                     D#3/Eb3
52    SELECT_UP                  E3
53    SELECT_DOWN                F3

is that correct ?

Try that. It might work, but just be aware that you might have to try other keys.

ok, I will give it a try. thank you

Thanks, this helped and I was able to finally get some audio out of the USB sound card. I just changed ‘hw’ to ‘Device’ in the Jackd settings, and I got it to play the test mp3 a few times, but after a while it stopped playing with some red error text. I’m starting to think it might be something to do with my power supply not giving enough juice to the Raspberry Pi so I’m going to experiment some more with that. But it does feel like I’m getting closer every day! I figured I’d see how good this system was before investing in a DAC and touchscreen but more and more it’s looking like I might need those things (the DAC especially) in order to get a working system with which to test, so it’s a bit of a ‘chicken & egg’ situation…!

1 Like