API

1
Setup

Listen to message events on the window.

2
Events

Listen to message events on the window.

'mt-play'
when controller starts playing
'mt-stop'
when controller stops playing
'mt-beat'
at the beggining of each beat
{ currentBeat }
absolute current beat since last play
'mt-sequence'
at the beggining of each sequence
'mt-channel-on'
when a note starts at a channel
{ channel }
channel index (0-7)
'mt-channel-off'
when a note ends at a channel
{ channel }
channel index (0-7)
'mt-channel${i}-on'
when a note starts at a channel,
${i} is the channel index (0-7)
'mt-channel${i}-off'
when a note ends at a channel,
${i} is the channel index (0-7)