Of course, you are competing with the machine’s algorithm that syncs up to tempo changes. Only a very naive implementations that basically advances the inner clock with the midi clock pulses it receives can transparently “swing” with an external clock. Anything that produces digital sound cannot rely on such a mechanism.
And If I’m doing the math correctly, you can only swing between 50% and ~58%, because at 24ppqn you’d have skipped a full clock pulse at more than 58%, which can trigger all sorts of reactions in the machine’s sync algorithm —to the machine that looks like a sudden drop to half the previous tempo. If I’m not mistaken, that rules out most variants of triplet swing by design, because that is ~60-66%.
Here’s an article from Attack Magazine that explain how swing actually works DAWs and drum machines, that’s where I get my numbers from:
Do I get this right, or am I missing anything?