Space Pilot Pro (COM API) keyboard events do not work

Post questions, comments and feedback to our 3Dconnexion Windows Development Team.

Moderator: Moderators

Post Reply
kfilimon
Posts: 5
Joined: Sat Jul 31, 2010 5:07 pm

Space Pilot Pro (COM API) keyboard events do not work

Post by kfilimon »

Hello,

I downloaded and tried csMonito (C# example) program that used COM API TDxInput.
Sensor events work fine, but keyboard events do not work. Only pressing the button "FIT" can be detected as the button 31. All other buttons cannot be detected.

However, when this demo program is loading it can correctly recognize the device and all its keys (keyboard.Keys).

So, if anybody help me with this issue I would really appreciate it.

Thank you,
Konstantin
jwick
Moderator
Moderator
Posts: 3341
Joined: Wed Dec 20, 2006 2:25 pm
Location: USA
Contact:

Post by jwick »

Hello kfilimon,

We are now recommending that developers use the Microsoft Raw Input API instead of the TDxInput COM API. See the current SDK page.

The problem you are seeing with your application is probably because the configuration that is being used by the 3DxWare driver has all the other keys from your device mapped to internal driver functions. Open the 3DxWare panel and map the buttons to Button 1, Button 2, Button 3, etc. The button events will then get sent straight to your application.

Thank you for supporting 3Dx devices in your application.

Jim
3Dx Software Development
kfilimon
Posts: 5
Joined: Sat Jul 31, 2010 5:07 pm

Post by kfilimon »

Thank you jwick for so fast reply,

I will try to remap the keys. Should help I think.

According to Raw Input API I have a few more questions.
I downloaded SDK and looked at the examples and documentation.

1) I'm wondering how I can use Raw Input API in C#. All the examples and docs are for C++. Are there any samples for C#? (Visual Basic would be also fine).
I tried to Google "Using Raw Input C#" just to get the concept, but didn't find anything useful.

2) I'm using MS Visual Studio 2010 and the samples from SDK could not be opened there.

Problems to convert project files.
Conversion Report for mcad.vcproj:
- Line: 121 Column: 5 Error Message: System error: -2147154677. The file
- Failed to upgrade platform 'x64'. Please make sure you have it installed under '%vctargetspath%\platforms\x64'
- VCWebServiceProxyGeneratorTool is no longer supported. The tool has been removed from your project settings.
- Failed to upgrade 'Debug|x64'. Please make sure you have the corresponding platform installed under '%vctargetspath%\platforms\x64'
- The project configuration dimension name/value "(Platform, Win32)" was not found in the project manifest.

What could you recommend to me that I could launch the samples and study how Raw Input API works?

Thank you for any help,
Konstantin
mbonk
Moderator
Moderator
Posts: 181
Joined: Mon Dec 04, 2006 4:06 am

Post by mbonk »

Hi Konstantin,

We are really sorry this is taking so long to get you an answer.

About the COM API (TDxInput) and keys. Keys are pre-processed by the 3dxware driver. Basically this means that if a key is assigned to a function that the 3dxware driver can execute the button press will not be passed on to the target application i.e. csMonitor in this case.

So to get a '1' when pressing button 1, the configuration in 3dxware needs to be set to 'Button 1' (or the very first entry in the drop down for Button 1).

Managed code samples fro RawInput is something which is on the plate at the moment, but I will see if I can dig something up for you that will get you started.

Markus
Post Reply