Added RVL-CNT-01-TR support to Windows too (but no accelerometers support yet)

git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@12853 178a84e3-b1eb-0310-8ba1-8eac791a3b58
This commit is contained in:
funto66 2013-06-07 21:33:11 +00:00
parent a529a07c99
commit 6db09a5642
2 changed files with 5 additions and 1 deletions

View File

@ -111,10 +111,13 @@ int wiiuse_os_find(struct wiimote_t** wm, int max_wiimotes, int timeout) {
attr.Size = sizeof(attr);
i = HidD_GetAttributes(dev, &attr);
if ((attr.VendorID == WM_VENDOR_ID) && (attr.ProductID == WM_PRODUCT_ID)) {
if ((attr.VendorID == WM_VENDOR_ID) && (attr.ProductID == WM_PRODUCT_ID || attr.ProductID == WM_PLUS_PRODUCT_ID)) {
/* this is a wiimote */
wm[found]->dev_handle = dev;
if(attr.ProductID == WM_PLUS_PRODUCT_ID)
wm[found]->type = WIIUSE_WIIMOTE_MOTION_PLUS_INSIDE;
wm[found]->hid_overlap.hEvent = CreateEvent(NULL, 1, 1, "");
wm[found]->hid_overlap.Offset = 0;
wm[found]->hid_overlap.OffsetHigh = 0;

View File

@ -165,6 +165,7 @@
#endif
#define WM_VENDOR_ID 0x057E
#define WM_PRODUCT_ID 0x0306
#define WM_PLUS_PRODUCT_ID 0x0330
/* controller status stuff */
#define WM_MAX_BATTERY_CODE 0xC8