Meant to be Seen
https://www.mtbs3d.com/phpbb/

P5 Glove finger reading DLL and Unity3d demo
https://www.mtbs3d.com/phpbb/viewtopic.php?f=145&t=19551
Page 1 of 1

Author:  WiredEarp [ Tue May 06, 2014 10:29 am ]
Post subject:  P5 Glove finger reading DLL and Unity3d demo

P5GloveDLL

This uses the P5Glove class I wrote for the mouse driver, and compiles it into a DLL. I wrote this so I could read my P5 Glove in Unity3d Pro. Its so basic its not even worth explaining, just drop it into your Unity project and access it (see the Unity sample here for an example of its use if you haven't used DLL's in Unity before). Note this DLL only reads the fingers positions, it doesn't bother with the sensor data from the outdated P5 sensor base.

Attachment:
P5GloveDLL bare DLL.rar
Attachment:
P5GloveDLL sourcecode.rar


P5GloveUnityTest

Attachment:
P5 Glove unity demo screenshot.jpg


This is a very simple example showing how to use the P5 Glove DLL in Unity. I assume you can probably use other P5 DLL's instead if you'd rather, such as the GlovePIE one (as long as they work for your glove). In it, i've taken the Sixense hand sample and put some very simple code in to make the fingers onscreen bend when you bend the P5 Gloves fingers. I haven't used the Hydra specific components (so no Hydra tracking in the example, just finger motion), so as to make it as simple as possible to understand. Just take a look at the 'P5Fingers.cs' class, and you'll see how simple it is to get finger tracking into your Unity application.

Attachment:
UnityDLLTest.rar

Author:  cybereality [ Tue May 06, 2014 10:05 pm ]
Post subject:  Re: P5 Glove finger reading DLL and Unity3d demo

Ha! Is the P5 making a comeback?

Author:  WiredEarp [ Wed May 07, 2014 9:30 am ]
Post subject:  Re: P5 Glove finger reading DLL and Unity3d demo

Quote:
Ha! Is the P5 making a comeback?


I doubt it :D but it sure is nice to flex the fingers. I'm sure something much more capable will come along soon 8-)

Author:  Caliber Mengsk [ Wed May 07, 2014 12:54 pm ]
Post subject:  Re: P5 Glove finger reading DLL and Unity3d demo

WiredEarp wrote:
Quote:
Ha! Is the P5 making a comeback?


I doubt it :D but it sure is nice to flex the fingers. I'm sure something much more capable will come along soon 8-)

viewtopic.php?f=145&t=19117
Working on it :D

Been having issues getting it started as of late, and have finally fixed those bugs, so hopefully can get a new video up soon with it interacting with things in a useful way. :D

Author:  Krenzo [ Wed May 07, 2014 3:44 pm ]
Post subject:  Re: P5 Glove finger reading DLL and Unity3d demo

I ordered a P5 Glove off of ebay, and I was surprised to find that each flex sensor actually has two sensors in it to track both the knuckle and the proximal joints. It's not all that bad for finger tracking.

Author:  WiredEarp [ Wed May 07, 2014 7:24 pm ]
Post subject:  Re: P5 Glove finger reading DLL and Unity3d demo

@ Caliber Mengsk: I saw your video a week or two back and it looks quite smooth. Seems slightly more accurate than one of my P5s (my other one is brand new and seems ok).

I have another glove design I wish to work on now that doesn't use resistive finger tracking (like you mentioned you were planning on moving away from). Resistive is nice to implement but I'd rather use something more reliable/less fragile for a heavy use glove. Maybe i'm just biased due to the buggy thumb on one of my P5's. Be interested to see your next version.

Author:  erb365 [ Thu Dec 18, 2014 3:10 am ]
Post subject:  Re: P5 Glove finger reading DLL and Unity3d demo

Thats cool how do I make it so that if i move my hand in real life it moves the hand in unity also? I tried attaching the sixens scripts but it din't work

Author:  WiredEarp [ Wed Jul 04, 2018 5:45 am ]
Post subject:  Re: P5 Glove finger reading DLL and Unity3d demo

Well... this is a 4 year late reply, sorry erb365!

The driver only includes finger tracking, as the P5 tracking was simply too unreliable (and not 6dof) to be useable. You need to provide your own tracker.
The app I provided in another link (viewtopic.php?f=145&t=19552) allows/allowed you to use any VRPN source as the tracker, or you can use a Razor Hydra.

Since its now 4 years later, and VR has advanced a lot, I'd simply add a SteamVR tracker. This driver should still work for reading the finger bends from a P5 glove.

Author:  Jabberwock [ Fri Aug 10, 2018 8:56 am ]
Post subject:  Re: P5 Glove finger reading DLL and Unity3d demo

I wish I knew enough about programming to write a P5 plugin for FreePIE... My glove is still working quite well, I have considered disassembling it to use the flex sensors with some kind of orientation tracker, but I did not have the heart to take it apart.

Author:  cybereality [ Thu Sep 06, 2018 9:56 pm ]
Post subject:  Re: P5 Glove finger reading DLL and Unity3d demo

You can buy flex sensors, you don't need to take the glove apart.
https://www.sparkfun.com/products/8606

Page 1 of 1 All times are UTC - 6 hours
Powered by phpBB® Forum Software © phpBB Group
http://www.phpbb.com/