The Mercury Engine can output MIDI if this is supported by your browser. The midi instrument can send notes and chords at rhythmical timing and also send out control change (cc) messages. Find more info and tutorials on how to use MIDI in Mercury code in the documentation