Hi, I’m using Pisound with my raspberry pi 4, 4gb ram, latest Patchbox OS installed. I’m trying to use it with Pure Data as a Midi processor and eventually sample playback device.
Everything works great but I’m having problem with latency. I’m not able to measure how much it is, but it is definitely noticeable and too much for me to play comfortably with. I’m using a midi keyboard into the raspberry via the Pisound midi port, through PD with a simple notein → noteout patch, going to an analog synth. I’ve tried running at 192khz but without a difference.
Any other suggestions as how to lower the latency using PD? Or will I have more luck using another software than PD?
What Jack backend settings are you using? The buffer size is the major factor that determines the latency you’re going to get.
Please see Suitable as guitar effect pedal? - #2 by Giedrius for some additional details.
1 Like
Hey thanks for the reply, I’m using 128 frames, 2 periods. Its the lowest i think? I did read in another thread that PD was introducing latency when using “notein” instead of “midiin”, so I will try that soon too!
An update here if anyone is having the same issue, I built a small midi latency tester and found that using notein → noteout yielded around 40 ms latency. But changing it to midiin → midiout gave me around 5ms! So there is obviously something happening with that pure data object. It is kind of tricky to convert the raw midiin data in PD to note and velocity values but I got a patch from the PD forums that does the trick if anyone is looking
1 Like
(edit: updated patch, see following message)
Hello, thanks for this information - I came across it randomly but have been playing around with pure data recently and wanted a vanilla solution to parsing midi data with MPE content such as note off/release velocity. I took the patch you linked to on the pure data forums and made it a little bit more efficient and, I believe, complete. It works well for me so just sharing it here in case it helps anyone. I didn’t know that about the native objects and latency, quite surprising!
1 Like
midi-up.pd (4.2 KB)
This is the updated patch: I hadn’t quite got the hang of ‘running status’, and have now added all the midi real time messages as well.
Here is the most helpful midi tutorial I have found: https://learn.sparkfun.com/tutorials/midi-tutorial/all
1 Like
Hey! Amazing work thanks for sharing!
1 Like