Adds 3DConnexion Device Button Map loading from XML file (#3065)

Post here if you have re-based and finalised code to integrate into master, which was discussed, agreed to and tested in other forums. You can also submit your PR directly on github.
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Post Reply
SolidDude
Posts: 3
Joined: Tue Dec 31, 2019 10:34 am

Adds 3DConnexion Device Button Map loading from XML file (#3065)

Post by SolidDude »

"3Dconnexion.xml" - at the moment temporarily I've put this file into src/Gui (I'm open for suggestions where such config files should go in the repository).
For use at run-time, the XML file should be copied into the folder containing the FreeCAD executable.
I'm investigating using App.getResourceDir() to place the file into a resources area for FreeCAD.

If the XML file is present, the button mappings for are preloaded into the Tools... Customize...Spaceball Buttons dialog.
If the XML file does not exist, no change in FreeCAD functionality occurs.

The XML file is designed to hold configurations for multiple types of 3Dconnexion mice.
Currently the code is hard-coded to load in the mappings for "SpacePilot Pro" - I need to investigate if the type of mouse can be provided by the spacenavd service; likewise for button held down duration.
User avatar
Kunda1
Veteran
Posts: 13434
Joined: Thu Jan 05, 2017 9:03 pm

Re: Adds 3DConnexion Device Button Map loading from XML file (#3065)

Post by Kunda1 »

Alone you go faster. Together we go farther
Please mark thread [Solved]
Want to contribute back to FC? Checkout:
'good first issues' | Open TODOs and FIXMEs | How to Help FreeCAD | How to report Bugs
josepablo.castro
Posts: 8
Joined: Thu May 07, 2020 7:05 am

Re: Adds 3DConnexion Device Button Map loading from XML file (#3065)

Post by josepablo.castro »

Kunda1 wrote: Sat Mar 07, 2020 11:33 pm Related PR: https://github.com/FreeCAD/FreeCAD/pull/3065
Hi,

I am making an Open 3D Mouse as HOGP (HID Over Gap Profile, Bluetooth Low Energy)
I successfully manage to use the spacenavd on GNU/Linux with only modified the /etc/spnavrc file with this line:
device-id =1915:eeee

I am using a Nordic nRF52 chip for harware and, for the moment, using Nordic's VendorId.
In the future this will change for a VendorId I will get for the non-profit Foundation I am running in Costa Rica.

I want the Open 3D Mouse to work on Windows as well.

I am studying the source code in src/Guid/3Dconnexion and notice the hardcoded for the windows implementation.

It would be great if the windows implementation to be able to read the VendorId:ProductId from an external file or be able to add the VendorId:ProductId from the GUI interface as well.

Thanks and Best Regards,

Jose Pablo
Post Reply