made midi dispatching more sophisticated
added reference for midi.org; fixed NOTE_ON <-> NOTE_OFF confusion