13
0

Human readable printing of MIDI Position messages

This commit is contained in:
Michael Fisher 2013-08-01 00:55:58 -05:00
parent 6ffdeaa9f8
commit 27a7bd0f12

View File

@ -300,7 +300,12 @@ MidiTracer::tracer (Parser&, byte* msg, size_t len)
s += snprintf (
&buf[s], bufsize, " MTC full frame to %02d:%02d:%02d:%02d\n", msg[5] & 0x1f, msg[6], msg[7], msg[8]
);
} else if (len == 3 && msg[0] == MIDI::position) {
/* MIDI Song Position */
uint16_t midi_beats = (uint16_t) msg[1];
midi_beats |= msg[2];
s += snprintf (&buf[s], bufsize, "%16s %d\n", "Position", (int) midi_beats);
} else {
/* other sys-ex */