< Back to IRCAM Forum

Good idea to use Spat5.osc.speedlim?


I am trying to figure out what is best.

I have a spat5.oper to spat5.spat~.

And I have OSc position messages flowing in at very high rates.

is it useful to use a spat5.osc.speedlim? or does this create other problems?

spat5.osc.speedlim was clearly designed with such a use case (reducing data rate for trajectories) in mind.
So I hope it can be useful.
I’m not aware of existing problems, but feel free to report…

Thank you for your reply.

My exact problem is this:

I am controlling spat5.oper params via OSC

As soon as I start moving a knob in spat5.oper, Audio crackles start to appear. [spat5.osc.speedlim] does not help. Changing the buffer size has some effect, but does not solve the issue completely.

cracles happen mostly with:

  • Source positions
  • Axis params

Hi Marijn,

The o.var object, part of the o.dot package (CNMAT ?) is very useful for this. It stores an OSC packet, which can then be banged with a metro, like the i and f objects.



Good point @davehunt. The spat5.osc.var object also does something similar (to o.var)

@marijn : However, moving a knob (with the mouse) generates relatively slow data flow. If you get audio crackles in that context, then something else is probably wrong (just a guess), and “speedlimiting” the data might not be enough to fix the issue.


Hi T, what could be the problem here?

  • Running a Maxforlive device with Spat5.2
  • Moving audio sources around with mouse or OSC: Both result in Crackles (you can head it really clearly with a sinewave)
  • CPU usage is around 30% in Ableton

Greetings, Marijn

Is the problem specific to Ableton ? Or do you have similar issue with Max ?
Can you maybe send the device/patch ?


Hi T, the problem is not specific to Ableton. It also Happens in MaxMSP. It seems to be linked to my CPU. The severity of the audio crackles varies a lot. the problem also tends to get worse when spat is running for a while (maybe my laptop is heating up).

I have a fairly good laptop: 16ich Macbook pro I7 from 2020

Mostly, the crackles are soft, they can be best noticed with a sinewave

I noticed that moving sources trough the middle will generate more crackles (maybe because it’s louder).

My patch is this:

[Spat5.oper] > [Spat5.spat~ @inputs 15 @ outputs 42]

Two times spat5.spat~, running in parallel to create reverberation zones (see my earlier post about smoothly transitioning between rooms)

Furthermore: the crackles get worse when I move sources faster. If I move them really slow, there are no crackles.

It will happen on both mac and windows.

Greetings, Marijn

Aarfff. I see : it’s a very silly (but very serious) bug with the filter’s crossfade.
It will be fixed in the next release (coming in a couple of days).

Thanks for spotting that !


1 Like

Hello Tcarpent. Thank you for this good news! I have been searching for days looking to fix a mistake in my setup. Now that I know that it is a bug of spat itself, it comforts me. I hope this new release comes soon! because right now this bug is really a showstopper :wink:

Thanks a lot for taking the time to investigate!

Using spat5.eq, I think I have a similar problem like marjin had with controlling spat.oper (should be fixed meanwhile). With spat5.eq I realised 32 “PeakingEQs”, their parameters are controlled by another max8-MIDI-patcher. This leads to crackles in the audio signals passing the filters. To explain it some more: a sine wave passing one filter is disturbed when I change any other parameter of the other filters using the OSC spat5 syntax.
What do you mean? How can I go further?
Thank you for helping,

Hi Bruno,

  1. the filter crossfade bug should have been fixed in v5.2.2, so make sure to use that version or anything newer
  2. can you share a patcher that demonstrate the issue ? that would be helpful to isolate the (possible) issue.
  3. how fast are you changing the parameters ?


Hi again,
thank you very much for your help!
I am dealing with a max8/javaScript system to produce and control acoustic feedback (effet Larsen) to make the room resonances hearable and also to play with them.

Yes, I am using version 5.2.3

The parameter’s change speed is determined by midi-devices. To reduce it I used „speedlim 300“ and „spat5.osc.speedlim @rate 300“; then, the crackles occurred with intervals defined by these, every 300ms.

I have attached the entire patcher „fbC_Instr_spatTC“. It doesn’t work without the acoustic feedback loop which is a bit tricky; to avoid difficulties I cut the line to dac~ of the acoustic feedback.

The subpatcher „p spatEq“, derivated from the „spa5.eq.maxhelp“ is to find in „p acousticLoopSP“. The data for controlling spat5.eq, which induce the crackles are emitted by „js playWithResSpat“ (in the subpatcher „p liveElectronics“) using midi-data.

If anybody needs some more informations or if you can give me some tips where I can search and explore possible reasons, please tell me. Actually it worked well with the jamoma equalizer but I would be happy to have 32 Filters and the overall comfort of Spat5 :slight_smile:
Thanks a lot for your efforts,

fbC_Instr_spatTC.maxpat (222.5 KB)

Hum. That seems quite complex, and many files are missing.
Could you please try to make a stripped down version ?


high, this might be an open door… But changing all filters at once with a value jump will cause crackles. Also check out the peak CPU load when sending such a vast amount of processing. As quick spikes in CPU kan cause crackles, this would explain the crackles only happening with the 300ms interval.

Hello again
Thank you very much for helping me, for your good ideas and sorry for the missing parts …
Following your suggestions, I started with spat5.eq.maxhelp and included a sonogram. The screenshot, added, shows my surroundings and also the disturbances of a simple sine, passing the EQ-filter 1. It seems understandable for me, that a sudden step in gain will cause such distortions. Because an amplitude step will cause partials. How to avoid it? line?
But if one change parameters of other filters, e.g. EQ-filter 2, the same occurs on EQ-filter 1 with the sine, seems no difference.
I’d be very glad for any suggestions,
thank you for helping,

spat5.eq_modif.maxhelp (59.6 KB)

I think you have two options to (try to) reduce the artefacts :

  • smooth the change of parameters (using line for instance)
  • increase the crossfade time in cascade~
    And of course you can combine both options.

Hope this helps,

Thanks a lot! I’ll do so,