Corrections, improvements and additions to the incomplete RNDISHost demo.
[pub/USBasp.git] / Demos / Device / ClassDriver / Mouse / Mouse.c
index c53d429..c29cc15 100644 (file)
@@ -148,10 +148,10 @@ bool CALLBACK_HID_Device_CreateHIDReport(USB_ClassInfo_HID_Device_t* const HIDIn
        else if (JoyStatus_LCL & JOY_DOWN)\r
          MouseReport->Y =  1;\r
 \r
-       if (JoyStatus_LCL & JOY_RIGHT)\r
-         MouseReport->X =  1;\r
-       else if (JoyStatus_LCL & JOY_LEFT)\r
+       if (JoyStatus_LCL & JOY_LEFT)\r
          MouseReport->X = -1;\r
+       else if (JoyStatus_LCL & JOY_RIGHT)\r
+         MouseReport->X =  1;\r
 \r
        if (JoyStatus_LCL & JOY_PRESS)\r
          MouseReport->Button  = (1 << 0);\r