Looking-Glass / JoyconLib

Joy-Con library for Unity.
MIT License
467 stars 91 forks source link

HIDapi.hid_open_path unable to open path #7

Closed Davidobot closed 6 years ago

Davidobot commented 6 years ago

When attempting to start JoyconManager, Visual Studio throws me an error: System.AccessViolationException: 'Attempted to read or write protected memory. This is often an indication that other memory is corrupt.'

Open investigating, it turns out that the handle passed by IntPtr handle = HIDapi.hid_open_path(enumerate.path); Gives an all-zeroed out value. Is this a known problem and can it be resolved?

EDIT: Solved by taking care with 32/64-bit .dlls and build properties.