<

Iterate through Polyphonic MIDI files as simultaneous chords with detonate

Load a MIDI file into detonate, send it a “start” message, then send it “next” messages to output each note. Notice that the leftmost outlet sends out the delta time (in ms) until the next note in the score; that value can be tested, and if it’s sufficiently small, say under 50 ms for example, that means that the next note is practically simultaneous with the current one. The example then sends an additional ‘next’ message.

Testing for a range of numbers

If you want to detect when a number has occurred that fits within a particular range, you'll want to use logical operators to test conditions such as is less than, is less than or equal to or is greater than this and less than that. Most logical operators send out the number 1 (meaning true) if the condition is met, and 0 otherwise.