Mirror with some correction

Dependencies:   mbed FastIO FastPWM USBDevice

Revision:
75:677892300e7a
Parent:
73:4e8ce0b18915
Child:
77:0b96f6867312
--- a/USBJoystick/USBJoystick.cpp	Fri Jan 27 23:47:15 2017 +0000
+++ b/USBJoystick/USBJoystick.cpp	Sun Jan 29 19:04:47 2017 +0000
@@ -276,6 +276,7 @@
     int numOutputs, int unitNo, 
     int plungerZero, int plungerMax, int plungerRlsTime,
     bool configured,
+    bool sbxpbx,
     size_t freeHeapBytes)
 {
     HID_REPORT report;
@@ -300,7 +301,10 @@
     
     // write the status bits: 
     //  0x01  -> configuration loaded
-    report.data[11] = (configured ? 0x01 : 0x00);
+    //  0x02  -> SBX/PBX protocol extensions supported
+    report.data[11] = 
+        (configured ? 0x01 : 0x00)
+        | (sbxpbx ? 0x02 : 0x00);
     
     // write the free heap space
     put(12, freeHeapBytes);