button values from 3d space mouse
Moderator: Moderators
-
- Posts: 17
- Joined: Wed Mar 24, 2021 1:09 pm
button values from 3d space mouse
Hi,
I would really appreciate if someone could help me to get me a vb.net code to get the button values from 3d space mouse while I am pressing them.
There are 2 buttons left and right buttons on 3d space mouse. If I could know the values I could assign actions while the buttons are pressed.
I would really appreciate if someone could help me to get me a vb.net code to get the button values from 3d space mouse while I am pressing them.
There are 2 buttons left and right buttons on 3d space mouse. If I could know the values I could assign actions while the buttons are pressed.
Re: button values from 3d space mouse
I assume you have a SpaceNavigator-type (two button) device.
By default, those are assigned to show radial menus and nothing is sent to the application.
Which API are you using to read the device?
Is this for use in a single application that you are writing, or a general utility?
If you are just trying to have the buttons do something in other applications, there are ways of doing this with the driver.
By default, those are assigned to show radial menus and nothing is sent to the application.
Which API are you using to read the device?
Is this for use in a single application that you are writing, or a general utility?
If you are just trying to have the buttons do something in other applications, there are ways of doing this with the driver.
-
- Posts: 17
- Joined: Wed Mar 24, 2021 1:09 pm
Re: button values from 3d space mouse
Hi jwick,
Thanks for responding.
I got the code from this forum to see the values of 6 axis of the 3D space mouse while they are moved.
Now, I would like to see the values of the buttons while they are pressed.
I am using 'windows forms app (.NET)' in Visual studio 2019 for coding (VB .net).
Thanks for responding.
I got the code from this forum to see the values of 6 axis of the 3D space mouse while they are moved.
Now, I would like to see the values of the buttons while they are pressed.
I am using 'windows forms app (.NET)' in Visual studio 2019 for coding (VB .net).
Re: button values from 3d space mouse
You are using our TDxInput assembly?
Probably the default cfg file is being used for your application. You will see the cfg in use if you hover over the 3Dx systray icon.
Do you see Radial Menus come up when you press the buttons?
You can use the GUI to assign those buttons to events that will be sent to your application, instead of showing Radial Menus. Depending on what cfg gets loaded, you should see something like "Application Use" in the GUI when assigning button actions.
Probably the default cfg file is being used for your application. You will see the cfg in use if you hover over the 3Dx systray icon.
Do you see Radial Menus come up when you press the buttons?
You can use the GUI to assign those buttons to events that will be sent to your application, instead of showing Radial Menus. Depending on what cfg gets loaded, you should see something like "Application Use" in the GUI when assigning button actions.
-
- Posts: 17
- Joined: Wed Mar 24, 2021 1:09 pm
Re: button values from 3d space mouse
Hi jwick,
I tried the way you mentioned, that using GUI instead of radial menus but it didnt work.
Is there some vb code to access the 2 buttons.
I tried the way you mentioned, that using GUI instead of radial menus but it didnt work.
Is there some vb code to access the 2 buttons.
Re: button values from 3d space mouse
Run your program, then start our GUI. Change some button assignment on your 3D mouse.
This will generate an xml file in %appdata%\3dconnexion\3DxWare\Cfg named for your program.
PM that file to me.
This will generate an xml file in %appdata%\3dconnexion\3DxWare\Cfg named for your program.
PM that file to me.
-
- Posts: 17
- Joined: Wed Mar 24, 2021 1:09 pm
Re: button values from 3d space mouse
Hi Jwick,
I have sent the xml file through PM.
I have sent the xml file through PM.
Re: button values from 3d space mouse
Hi AntonyAlbertAnto,
Your file looks fine.
I assume it is getting selected when Prog_Reg_Test1.exe is in focus.
I see you have a two button SpaceMouse Compact.
Does your executable get started when you press the left button?
You are starting another instance of the application from the application?
Your application should be getting a native application button event (10) when you press the right button.
Your app gets nothing? This type of button event was supported from the very beginning.
You could also assign both to:
Then you would get a 1 for the left button and a 2 for the right button (I may have right/left reversed).
We have not had any reports of TDxInput not working, but we haven't tried to keep it up-to-date in years.
We would be very interested in hearing that there are issues with it.
You get axis events using this file?
Your file looks fine.
I assume it is getting selected when Prog_Reg_Test1.exe is in focus.
I see you have a two button SpaceMouse Compact.
Does your executable get started when you press the left button?
You are starting another instance of the application from the application?
Your application should be getting a native application button event (10) when you press the right button.
Your app gets nothing? This type of button event was supported from the very beginning.
You could also assign both to:
Code: Select all
<Output>
<ActionID>App_PassToApplication</ActionID>
We have not had any reports of TDxInput not working, but we haven't tried to keep it up-to-date in years.
We would be very interested in hearing that there are issues with it.
You get axis events using this file?
-
- Posts: 17
- Joined: Wed Mar 24, 2021 1:09 pm
Re: button values from 3d space mouse
I got the axis values using TDxinput. Likewise how could I get the Value 1 and 2 while pressing right and left button using Visual basic coding language
Re: button values from 3d space mouse
Are you getting the 10?
-
- Posts: 17
- Joined: Wed Mar 24, 2021 1:09 pm
Re: button values from 3d space mouse
Hi jwick,
I didnt get you. where should i see 10 or how?
I didnt get you. where should i see 10 or how?
Re: button values from 3d space mouse
The cfg file you sent me sends a button 10 event to your application when the user presses the right button on the SpaceMouse Compact.
Do you get that event?
Is the code responding to any button events?
Do you get that event?
Is the code responding to any button events?
-
- Posts: 17
- Joined: Wed Mar 24, 2021 1:09 pm
Re: button values from 3d space mouse
Hi Jwick,
No, I am not getting any events. nothing happens while I press right or left button.
I do not have a vb codeline to see them.
No, I am not getting any events. nothing happens while I press right or left button.
I do not have a vb codeline to see them.
Re: button values from 3d space mouse
Can you give us your code to have a look at what you are doing? Preferably a small sample without your application-specific code.
-
- Posts: 17
- Joined: Wed Mar 24, 2021 1:09 pm
Re: button values from 3d space mouse
Hi Jwick,
I have send the sample in PM.
I have send the sample in PM.