While using an Akai Midimix controller, PD stopped working, and the message, "warning: MIDI timing FIFO overflowed" appeared on the console. What caused this? How can I prevent it from happening again? I'm using vanilla 0.56.5 on Windows. Most of the time it works fine, but this has happened a couple of times. I've got a live performance coming up in a couple of weeks, and I don't want PD to fail during the performance.
-
warning: MIDI timing FIFO overflowed
-
sounds like youre sending too many signals. you should print to pd window the midi out numbers and look at how many times youre sending numbers.
-
@willblackhurst I'm just turning knobs and sliding sliders. I wouldn't think that would send a huge number of MIDI messages to pd. The Midimax has a button that sends the states of all the controls. When I press that button, it sends 59 MIDI messages to pd at the same time. That doesn't cause this problem. I'm not sending any MIDI messages to the Midimax from pd.
When the problem happened, pd not only stopped responding to MIDI messages. It stopped responding to mouse clicks and everything else.
-
@jamcultur Do you have MIDI Real-time messages flooding in? Does your patch ever get really busy doing something so that it can't dequeue incoming MIDI events in time? Are you generating bursts of dense MIDI for output? Are there other applications or services running on your computer that steal CPU cycles from Pd? (If you're on a Mac, QLab has a great sheet explaining how to turn off all the things that might interfere with your show)
Maybe try increasing the delay time in audio settings?
-
@jameslo I don't have MIDI messages flooding in. I only have the CC messages sent by the controller when I move a knob or slider. I'm not generating any MIDI messages, just receiving MIDI messages from the controller. There weren't any other applications running. I don't know what, if anything, Windows was doing in the background at the time. I did have wifi turned on at the time, which I don't normally do when I'm playing music. I don't think my patch has significant bursts of activity. Moving a MIDI control just does things like change the volume or speed of playing a wavetable, which I don't think would create a burst of activity in pd.
-
oh I thought it was your midi out to akai sorry maybe change your buffer size otherwise I dont know what it is.
-
try an earlier version of pd. 51.4 is good for me . the one where it says "snake" every one started having weird issues afterward and I think the new versions are not really as stable as the older ones yet.
-
@jamcultur I always turn off all networking when running a show or use a subnet that no one else can access. Maybe note the time when it happens again and then look at the Windows logs to see if anything unusual happened at that time (search "event viewer")
-
@jamcultur From the source code, the cause is unambiguous: too many MIDI bytes coming in, too quickly.
void sys_midibytein(int portno, int byte) { static int warned = 0; t_midiqelem *midiqelem; int newhead = midi_inhead +1; if (newhead == MIDIQSIZE) newhead = 0; /* if FIFO is full flush an element to make room */ if (newhead == midi_intail) { if (!warned) { post("warning: MIDI timing FIFO overflowed"); warned = 1; } sys_dispatchnextmidiin(); }It looks like a circular buffer of incoming MIDI bytes. If the write head (newhead) crashes into the read position, then MIDI data weren't consumed fast enough compared to the incoming data rate. What it does in that case is to run one MIDI message right now, even if it's early according to the timestamp, to make room for the new data.
"I don't have MIDI messages flooding in" but this is the only place in the source code where this message is logged to the console, so something threw an abnormal amount of MIDI at Pd.
Unfortunately these problems are hard to track down, especially if they're not consistently reproducible.
hjh
-
@ddw_music But couldn't it also be that Pd didn't empty the queue fast enough, either due to Pd being busy doing something else, or Pd not getting enough CPU cycles?
-
I've not encountered this warning with pd and I often send and receive lots of midi. Maybe you have a loop or something like that going on?
-
@jameslo I think that you are correct. I verified that there was not a flood of MIDI messages coming in to pd. Something prevented pd from taking messages off the FIFO in a timely manner which caused it to overflow. I think Windows wasn't giving pd enough cycles to keep up. The problem hasn't reoccurred since I raised the priority of pd in Windows, and ensured that all networking was turned off before using pd.