My Fork of F401RE-USBHost. Add USBHostMIDI functions (originaled by Kaoru Shoji http://mbed.org/users/kshoji/code/USBHostMIDI/)

Dependencies:   FATFileSystem

Dependents:   F401RE-USBHostMIDI_RecieveExample

Fork of F401RE-USBHost by Norimasa Okamoto

Revision:
26:077ab26227c6
Parent:
25:c4fdd0b4e643
Child:
27:23fa4e04b1db
--- a/USBHostMIDI/USBHostMIDI.h	Thu Sep 18 11:34:43 2014 +0000
+++ b/USBHostMIDI/USBHostMIDI.h	Thu Sep 18 12:32:33 2014 +0000
@@ -52,27 +52,27 @@
      */
     bool connect();
     
-//    /**
-//     * Attach a callback called when miscellaneous function code is received
-//     * @warning DISABLED
-//     *
-//     * @param ptr function pointer
-//     *   prototype: void onMiscellaneousFunctionCode(uint8_t data1, uint8_t data2, uint8_t data3);
-//     */
-//    inline void attachMiscellaneousFunctionCode(void (*fn)(uint8_t, uint8_t, uint8_t)) {
-//        miscellaneousFunctionCode = fn;
-//    }
+    /**
+     * Attach a callback called when miscellaneous function code is received
+     * @warning DISABLED
+     *
+     * @param ptr function pointer
+     *   prototype: void onMiscellaneousFunctionCode(uint8_t data1, uint8_t data2, uint8_t data3);
+     */
+    inline void attachMiscellaneousFunctionCode(void (*fn)(uint8_t, uint8_t, uint8_t)) {
+        miscellaneousFunctionCode = fn;
+    }
 
-//    /**
-//     * Attach a callback called when cable event is received
-//     * @warning DISABLED
-//     *
-//     * @param ptr function pointer
-//     *   prototype: void onCableEvent(uint8_t data1, uint8_t data2, uint8_t data3);
-//     */
-//    inline void attachCableEvent(void (*fn)(uint8_t, uint8_t, uint8_t)) {
-//        cableEvent = fn;
-//    }
+    /**
+     * Attach a callback called when cable event is received
+     * @warning DISABLED
+     *
+     * @param ptr function pointer
+     *   prototype: void onCableEvent(uint8_t data1, uint8_t data2, uint8_t data3);
+     */
+    inline void attachCableEvent(void (*fn)(uint8_t, uint8_t, uint8_t)) {
+        cableEvent = fn;
+    }
 
     /**
      * Attach a callback called when system exclusive is received
@@ -332,8 +332,8 @@
 uint16_t sysExBufferPos;
     uint8_t sysExBuffer[64];
 
-//    void (*miscellaneousFunctionCode)(uint8_t, uint8_t, uint8_t);
-//    void (*cableEvent)(uint8_t, uint8_t, uint8_t);
+    void (*miscellaneousFunctionCode)(uint8_t, uint8_t, uint8_t);
+    void (*cableEvent)(uint8_t, uint8_t, uint8_t);
     void (*systemCommonTwoBytes)(uint8_t, uint8_t);
     void (*systemCommonThreeBytes)(uint8_t, uint8_t, uint8_t);
     void (*systemExclusive)(uint8_t *, uint16_t, bool);