RNBO on Raspberry Pi 5

Jan M's icon

Has anyone already managed to run RNBO on a Raspberry Pi 5? I got mine today and notices that it won't boot on the image provided by Cycling74. I seems to need debian bookworm.

Alex Norman's icon

I don't have a pi-5 yet, still waiting for my pre-order.. I'd be the one setting up the image for bookwork so, that'll have to wait until I have hardware to test with.

In the mean time, if you want, you can build/install the runner yourself. Here is how I set it up on bullseye: https://github.com/Cycling74/rnbo.oscquery.runner/blob/main/README-rpi.md

Jan M's icon

Thanks Alex!

I'll give it a try.

Jan M's icon

@Alex: I didn't managed to build it myself. But adding the repo manually:

curl https://raw.githubusercontent.com/Cycling74/rnbo.oscquery.runner/main/config/apt-cycling74-pubkey.asc | gpg --dearmor | sudo dd status=none of=/usr/share/keyrings/apt-cycling74-pubkey.gpg
echo "deb [signed-by=/usr/share/keyrings/apt-cycling74-pubkey.gpg] https://c74-apt.nyc3.digitaloceanspaces.com bullseye main extra" | sudo dd status=none of=/etc/apt/sources.list.d/cycling74.list


sudo apt update
sudo apt install -y rnbooscquery rnbo-runner-panel

after removing pulseaudio and installing jack following the link you sent did manage to get it to run and to compile a sample patcher.

Only have a pisound interface right now here - which does not work yet on the Pi5 so i can't test further.

In any case, there's no rush (besides my curiosity :) ). I can wait until you get your Pi5.

Alex Norman's icon

Oh cool to hear that you're able to run via the bullseye repo!!

Jan M's icon

Initially i made just a very quick test. It ran and could compile a simple test patch. Later I realised that the audio engine couldn't be started if didi not set it to the dummy interface. I guess that might be to the configuration of Jack maybe. Jack remains to be very confusing to me.... never really got my head around it.....

bacha's icon

Hey folks. Any news on this? :)

Jan M's icon

From my part no.... I stopped fiddling around. Couldn't get the Jack Audio part solved. I am now waiting for Alex to prepare a new RaspiPi Image.

Alex Norman's icon

I still don't have the hardware. I missed the boat on an order over the christmas/new years holiday but i have made a pre order that says it should be here mid January.. so, hopefully soon after that I can get something together.

Jan M's icon

Thank you Alex! Looking very much forward .

Ian Duclos's icon

Any news on this? Just got a raspberry pi 5, installed the c74 image and I'm not being able to get it recognized by rnbo in the export tab. Not sure if it's the fact that its not yet supported or if I'm doing something wrong.

Jan M's icon

The Raspi 5 requires a current Rasperry Pi OS version (based on debían bookworm). It won't boot on the bullseye image from C74. You can try to install the RNBO runner and Jack manually on a Bookworm (32-bit!) Raspi OS. I could get to show up, but didn't mange to get the audio engine to run.

Alex Norman's icon

my pi 5 has been delayed further but I do plan to work on it as soon as it arrives.. supposedly shipping at the end of Jan.

Yash's icon

Hey, I'm also keen on getting my rnbo patches to work on pi5. Is there a way I can get started?

Jan M's icon

You can try to install it manually on bookworm from the repos. I described the steps earlier in this thread

Yash's icon

I've followed the steps mentioned above and got the pi5 on RNBO but I'm not able to compile with my hifiberry set as the interface. This might be a specific issue so I've created a new thread for this. https://cycling74.com/forums/rnbo-issues-with-pi-5-jackd2-hifiberry-adc-dac-pro

I feel like I'm very close to setting everything up right, any suggestions would be highly appreciated.

Jan M's icon

Thanks for the update Yash,
I came to the exact same point as you did, and couldn't figure out the Jack configuration either. I am using the Pisound. So it seems to something not necessarily related to the sound interface but the jack/RNBO.
If some has an idea I am very interested as well.


Hopefully the Pi5 situation i the US is getting better soon, so Alex can prepare a ready to run image!

Alex Norman's icon

I got my pi-5 at the end of the week last week and hope to get something together with it this week.

Alex Norman's icon

I suspect that the pi-5 OS and jackd running on it are 64-bit executables but the binary that we've provided for the runner is 32-bit and so it is incompatible.

Jan M's icon

I got my pi-5 at the end of the week last week and hope to get something together with it this week.

Ohhhh that’s great news! Thanks a lot for everything, Alex.

Alex Norman's icon

I've created an image for the PI 5.

Here are some notes:

  1. This is very minimally tested, if you all can report your experience back, that would be great.

  2. This image does not have runner updating set up so when we release a new version of rnbo you won't be able to automatically upgrade to that. I hope to setup the infrastructure for that before our next minor release but we may have a patch release before then. You will likely either have to install a completely new image at that point or at least do some setup via sshing into the device.

  3. As with previous images, you must keep the username 'pi'.

  4. You should be able to follow the instructions here: https://rnbo.cycling74.com/learn/raspberry-pi-setup but with the image link from below.

  5. The default hostname for this one is different, c74rpi5, the username and password are the same though.

Jan M's icon

yeahhh :) I'll install it and will give feedback very soon!

Jan M's icon

Hi Alex,
the image installs fine and recognises my Pisound. In a very fast test yesterday I noticed that MIDI input from the Pisound doesn't seem to be recognised (at least MIDI data are not processed properly, like notes not playing etc.), USB MIDI seems to work fine. I'll need a couple of days ore to test ore in depth.

Yash's icon

Hi JAN M, Did you manage to get audio in/out from the pisound working? I've managed to set up the pi5 for rnbo and updated config to get hifiberry on the list but I'm getting the same error as before with the audio at export.

Basically, I'm in the same spot as before,

Jan M's icon

I haven't tested audio input yet. Output seems to work fine. There have been some changes on how I2S is handled on the Raspi 5. It may be related to this. Pisound requires Kernel version >= 6.1.64

Maybe there are similar issues with the hifiberry

You could try to run:

sudo apt update
sudo ate upgrade

the reboot and run :

 sudo rpi-update

and reboot once more

Yash's icon

Still giving me the same error :(

Alex Norman's icon

YASH,

Which hifiberry do you have?

I'm curious if you've done the overlay configuration that they recommend?

I found this blog entry that may be of use:

Alex Norman's icon
Yash's icon

I'm using the hifiberry ADC+DAC Pro,

I've followed all the steps on the main datasheet as well as the general hifiberry setup page.

here's what my config.txt looks like at the moment.

I've also made the changes mentioned in the blog you shared, but still facing the same issue.

Alex Norman's icon

YASH,

We've seen issues with the hifiberry products and jack. You could try connecting to jack directly from your pi to debug, assuming the device shows up as hw:sndrpihifiberry you can do:

jackd -d alsa -d hw:sndrpihifiberry

If that doesn't work, something is wrong with the hifiberry configuration and I'd suggest you follow up with their support. If you get some insights, we'd love to hear about them.

You can discover the alsa name by looking at the output of cat /proc/asound/cards the name you put after the hw: will be in square brackets.

Yash's icon

You're right, jack is not initializing the driver for some reason

Alex Norman's icon

YASH, try running that as the "pi" user instead of "root"

Yash's icon

is it an issue with the buffer size?

Alex Norman's icon

I think it is an issue with their driver.

We've had success adding "-P" to the commandline arguments to only enable playback (output).. but our runner doesn't support that option yet, it really shouldn't need to if the driver correctly identifies its i/o I don't think.

Jan M's icon

@Alex

Yes, I am actually part of the discussion in that thread (yunn02 is I )

Pi5 is a completely new platform so it's normal that it takes time to smooth everything out. I am sure we'll get there eventually!

Yash's icon

Thanks Alex, I've started a new discussion on the HifiBerry Forum,

Will share major updates here as well

Ian Duclos's icon

Hi! I mounted the image and I am now able to get it recognized by rnbo. I ran into the same response error as Yash ("cannot activate audio") when trying to export once connected to my audio interface (Motu Ultralite Mk-5). I find it strange as the interface worked fine on the normal rpi OS. When I try playing audio from the internet I'm not getting sound either so I assume it has something to do with jack. Any ideas or pointers?

Drew Bach's icon

The solution that worked for me was here:

TLDR: The dtoverlay config needs to be changed to the following (from recommended)

force_eeprom_read=0
dtoverlay=
dtparam=audio=on
dtoverlay=hifiberry-digi,slave

The "slave" part isn't actually supposed to work, but for whatever reason it actually made it functional. I have not tried it on the just released image yet, but it worked when I got rnbo running on raspbian (on a pi5 8gb).

Ian Duclos's icon

Would I need to change anything considering I'm not using hifiberry?

Alex Norman's icon

Ian,

I'm curious if you can get jack running directly via ssh?

I detail it above but basically

You can discover the alsa name by looking at the output of cat /proc/asound/cards the name you put after the hw: will be in square brackets.

so, for instance, i have a `USB` named interface so I run

jackd -d alsa -d hw:USB

you'll have something for your Motu Ultralite Mk-5 i assume.

if this fails, I'd love to see what the output is.

Yash's icon

Update:

Although RNBO is giving me the same error even after setting period frames to 128 in target settings.

Jan M's icon

Also an update from my side regarding the Pisound: Blokas has release arm64 packages of their installer/driver scripts a few days ago.


After running those DIN MIDI is recognised fine by RNBO.

Alex Norman's icon

Jan,

Thanks for letting us know, that is great news!

Alex Norman's icon

YASH,

Just to get a little be more info, if you're running jack in a terminal window, can you open another one and restart the rnbo runner, then try exporting from max?

you restart the runner via: sudo service rnbooscquery restart

if that works, I'm curious if you can remove those -i and -o entries from your jack command and try the whole thing again?

jackd -d alsa -d hw:sndrpihifiberry -p 128 -r 48000 -n 2

Thanks!

Patrick Maroney's icon

If one is looking for reliable live performance with RNBO controlling audio/midi on Raspberry Pi, then stick with Model 4?

Jan M's icon

Until there is an official RP5 image released and tested I’d say yes. RP5 may still involve some fiddling.

Patrick Maroney's icon

Many thanks for the quick and effective response! Since I still have drawer full of unused 4s, might as well get things prototyped.

Yash's icon

Alex,

Holy shit that worked!!

I've got sound and real-time control through the OSC interface!

Although removing the i/o tags from the jack command gives me the same error:

ALSA: cannot set period size to 128 frames for capture

Is there a way to include these commands in boot, so that I wouldn't have to do it every time?

Either way, thank you so much for your help! I can finally continue my project with RNBO!

Alex Norman's icon

YASH, that is excellent!

You could look into creating a systemd service that starts jack up with your custom configuration before the RNBO runner. RNBO would then no longer control the jack settings, it would simply connect to your pre-configured jack instance.

Yash's icon

Perfect, I'll do that! Thank you for your prompt responses and support throughout this!

TELEGRAPH HILL's icon

RNBO working on Pi4 + Focusrite Scarlett 4i4 gen4.

Beginning the process of installing and testing RNBO on the same audio interface and a newly arrived RPi 5/8Gb

I will try the image linked above and add my feedback.

EDIT: The disk image (1.2.4) worked great -- I can see and edit the export target params. HOWEVER: I get a compiler error:

Starting Code Generation
Generating Objects
Compiling Patcher
Printing CPP Code
Sending config
Sending code
Compiling
rnbo cmd response error: {"code":2,"message":"compile failed with status: 1"}

I gather that this indicates that the version of RNBO on my computer doesn't match the rnboosc version on my pi.

@Alex: Is there an updated disk image, or is there a way for me to update the version I have installed? I have reasonable *nix chops.

Thanks to everyone supporting RNBO! I love the platform.

Alex Norman's icon

I've just built a .deb for RNBO 1.2.5 that you can use

ssh to your pi5 and do this:

wget https://assets.cycling74.com/rnbo/pi-images/rnbooscquery_1.2.5.deb
sudo dpkg -i rnbooscquery_1.2.5.deb
sudo reboot

If you don't have wget installed you can get it via:

sudo apt-get install wget

For future ref, if you want to build on your own, check: https://github.com/Cycling74/rnbo.oscquery.runner/blob/main/README-rpi.md

Jan M's icon

Hello Alex,

I have some feedback on my experiences so far testing RNBO on the Raspberry 5. I use a Pisound as my audio interface.
I encountered so far 2 issues:
- when using the DIN MIDI in I get hanging MIDI notes when playing a bit faster. It doesn't seem to happen with USB MIDI keyboards.
- When connecting/disconnecting a USB MIDI keyboard on a running Pi5 the web interface stops responding and doesn't reload anymore.

Furthermore the pi gets stuck in shutdown/reboot for maybe 2 minutes or so, when a USB device has been changed
The first issue may be pisound specific I'll try to see if I can get more info from BLOKAS.

PS: Do you know if there will be an official RNBO Rp5 image release in the foreseeable future, or probably you need to wait until the platform matures a bit more...

Alex Norman's icon

I hope to get pi5 "officially" supported with a 64-bit image by our next minor release, 1.3.

This plug/unplug issue is concerning, I'll make a ticket for that.

The DIN MIDI issue is also a bummer, I'm curious to hear if BLOKAS comes up with a solution. Since the runner uses jack for midi, you might verify that some other jack program can also trigger the same behavior.

Jan M's icon

@alex, just a heads up: I am in contact with BLOAKS to figure out if the hanging MIDI notes are related to the pisound or not. Will let you know if I know something.

Jan M's icon

@Alex: It seems that the pisound I was using was on an old firmware version. I just updated it and in first tests the hanging midi note problem seems to have disappeared.

Alex Norman's icon

JAN,

That is really great to hear!!!

Thanks for letting us know.

Mihail S's icon

Guys any news with "officially" supported rpi image?

sorry just seen

I hope to get pi5 "officially" supported with a 64-bit image by our next minor release, 1.3.

Jan M's icon

Hi Alex, I received a forum email notification about a post from you, mentioning bookworm 32 bit image for testing. The post doesn't appear here, but the download link works. It is ready for testing, or did you delete the post for some reason?

Alex Norman's icon

I jumped the gun, posted something then redacted it.. should have a 32-bit bookworm image available for the next release though but I don't yet have a timeline.

Mihail S's icon

Hi Alex could you please share link on 1.3.0 rnbo deb package like above

Alex Norman's icon

If you want to extract the .deb, you can get it by running the image, we don't have direct downloads of the .deb right now.

Mihail S's icon

thanks got it!

one more thing

does 1.3.0 support 64 bit bookworm image if i will install it manually using this?https://github.com/Cycling74/rnbo.oscquery.runner/blob/main/README-rpi.md

Alex Norman's icon

We don't have a 64-bit build.. we might eventually but for now we're just providing 32-bit, but you should be able to build it yourself with those instructions.

Mihail S's icon

could please help me I stuck on this stage:

All packages are up to date.
N: Skipping acquire of configured file 'main/binary-arm64/Packages' as repository 'https://c74-apt.nyc3.digitaloceanspaces.com bullseye InRelease' doesn't support architecture 'arm64'
N: Skipping acquire of configured file 'extra/binary-arm64/Packages' as repository 'https://c74-apt.nyc3.digitaloceanspaces.com bullseye InRelease' doesn't support architecture 'arm64'
root@raspberrypi:/home/pi# apt-get install -y --allow-change-held-packages --allow-downgrades rnbooscquery=1.3.0-dev.75
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Package rnbooscquery is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source

E: Version '1.3.0-dev.75' for 'rnbooscquery' was not found
Mihail S's icon

ahh... i see there is no arm64 package in c74 repo. i have to build it myself

Alex Norman's icon

sorry, you have to build the software yourself, we don't provide an arm64 build.