pyvjoy
pyvjoy copied to clipboard
vjoy device not in VJD_STAT_FREE
the line
j = pyvjoy.VJoyDevice(1)
results in the error
Traceback (most recent call last): File "C:\Users\Michael\Documents\Python\pyInputTester.py", line 5, in <module> j = pyvjoy.VJoyDevice(1) File "C:\Users\Michael\AppData\Local\Programs\Python\Python36\lib\pyvjoy\vjoydevice.py", line 25, in __init__ _sdk.AcquireVJD(rID) File "C:\Users\Michael\AppData\Local\Programs\Python\Python36\lib\pyvjoy\_sdk.py", line 53, in AcquireVJD raise vJoyFailedToAcquireException("Cannot acquire vJoy Device because it is not in VJD_STAT_FREE") pyvjoy.exceptions.vJoyFailedToAcquireException: Cannot acquire vJoy Device because it is not in VJD_STAT_FREE
rendering me unable to use the device at all.
This happens because you have not register the VJoy device (specified by N in pyvjoy.VJoyDevice( N )) yet. You can do that by using the VJoy config program.
In my case, I have registered vJoy Device May there is another issue.
They are presented in Game Controllers tab.