mirror of
https://github.com/cathery/sys-con.git
synced 2025-01-29 00:33:02 +00:00
Move ds3 event to index 0
This commit is contained in:
parent
fc0d3136e3
commit
47dfafaaac
@ -47,25 +47,25 @@ Result mainLoop()
|
|||||||
|
|
||||||
{
|
{
|
||||||
UsbHsInterfaceFilter filter;
|
UsbHsInterfaceFilter filter;
|
||||||
filter.Flags = UsbHsInterfaceFilterFlags_bcdDevice_Min;
|
|
||||||
filter.bcdDevice_Min = 0;
|
|
||||||
rc = usbHsCreateInterfaceAvailableEvent(&catchAllEvent, true, 0, &filter);
|
|
||||||
if (R_FAILED(rc))
|
|
||||||
WriteToLog("Failed to open catch-all event");
|
|
||||||
else
|
|
||||||
WriteToLog("Successfully created catch-all event");
|
|
||||||
|
|
||||||
//filter.Flags = UsbHsInterfaceFilterFlags_bInterfaceClass | UsbHsInterfaceFilterFlags_bcdDevice_Min;
|
//filter.Flags = UsbHsInterfaceFilterFlags_bInterfaceClass | UsbHsInterfaceFilterFlags_bcdDevice_Min;
|
||||||
//filter.bInterfaceClass = USB_CLASS_HID;
|
//filter.bInterfaceClass = USB_CLASS_HID;
|
||||||
//filter.bcdDevice_Min = 0;
|
//filter.bcdDevice_Min = 0;
|
||||||
filter.Flags = UsbHsInterfaceFilterFlags_idVendor | UsbHsInterfaceFilterFlags_idProduct;
|
filter.Flags = UsbHsInterfaceFilterFlags_idVendor | UsbHsInterfaceFilterFlags_idProduct;
|
||||||
filter.idVendor = VENDOR_SONY;
|
filter.idVendor = VENDOR_SONY;
|
||||||
filter.idProduct = PRODUCT_DUALSHOCK3;
|
filter.idProduct = PRODUCT_DUALSHOCK3;
|
||||||
rc = usbHsCreateInterfaceAvailableEvent(&ds3Event, true, 1, &filter);
|
rc = usbHsCreateInterfaceAvailableEvent(&ds3Event, true, 0, &filter);
|
||||||
if (R_FAILED(rc))
|
if (R_FAILED(rc))
|
||||||
WriteToLog("Failed to open event for Dualshock 3");
|
WriteToLog("Failed to open event for Dualshock 3");
|
||||||
else
|
else
|
||||||
WriteToLog("Successfully created event for Dualshock 3");
|
WriteToLog("Successfully created event for Dualshock 3");
|
||||||
|
|
||||||
|
filter.Flags = UsbHsInterfaceFilterFlags_bcdDevice_Min;
|
||||||
|
filter.bcdDevice_Min = 0;
|
||||||
|
rc = usbHsCreateInterfaceAvailableEvent(&catchAllEvent, true, 1, &filter);
|
||||||
|
if (R_FAILED(rc))
|
||||||
|
WriteToLog("Failed to open catch-all event");
|
||||||
|
else
|
||||||
|
WriteToLog("Successfully created catch-all event");
|
||||||
}
|
}
|
||||||
|
|
||||||
controllerInterfaces.reserve(8);
|
controllerInterfaces.reserve(8);
|
||||||
@ -209,8 +209,8 @@ Result mainLoop()
|
|||||||
|
|
||||||
//After we break out of the loop, close all events and exit
|
//After we break out of the loop, close all events and exit
|
||||||
WriteToLog("Destroying events");
|
WriteToLog("Destroying events");
|
||||||
usbHsDestroyInterfaceAvailableEvent(&catchAllEvent, 0);
|
usbHsDestroyInterfaceAvailableEvent(&ds3Event, 0);
|
||||||
usbHsDestroyInterfaceAvailableEvent(&ds3Event, 1);
|
usbHsDestroyInterfaceAvailableEvent(&catchAllEvent, 1);
|
||||||
|
|
||||||
//controllerInterfaces.clear();
|
//controllerInterfaces.clear();
|
||||||
return rc;
|
return rc;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user