Added Midi Clock Types
Fork of USBMIDI by
Revision 3:7fe47e708ca6, committed 2014-08-19
- Comitter:
- alfaleader
- Date:
- Tue Aug 19 14:08:19 2014 +0000
- Parent:
- 2:10d694d6ccdc
- Commit message:
- Added Midi MTC, Midi Clock Start, Midi Clock Continue, Midi Clock Stop and Midi Clock as types
Changed in this revision
MIDIMessage.h | Show annotated file Show diff for this revision Revisions of this file |
diff -r 10d694d6ccdc -r 7fe47e708ca6 MIDIMessage.h --- a/MIDIMessage.h Sun Feb 20 13:12:22 2011 +0000 +++ b/MIDIMessage.h Tue Aug 19 14:08:19 2014 +0000 @@ -177,7 +177,12 @@ ProgramChangeType, ChannelAftertouchType, PitchWheelType, - AllNotesOffType + AllNotesOffType, + MTCType, + ClockType, + StartType, + ContinueType, + StopType }; /** Read the message type @@ -199,6 +204,15 @@ case 0xC: return ProgramChangeType; case 0xD: return ChannelAftertouchType; case 0xE: return PitchWheelType; + case 0xF: //MIDI CLOCK + switch(data[1] & 0x0F){ + case 0x01: return MTCType; + case 0x08: return ClockType; + case 0x0A: return StartType; + case 0x0B: return ContinueType; + case 0x0C: return StopType; + default: return ErrorType; + } default: return ErrorType; } } @@ -248,6 +262,8 @@ return p - 8192; // 0 - 16383, 8192 is center } + + uint8_t data[4]; };