PDA

View Full Version : 5dt driver question


bjgold
07-30-2007, 10:57 AM
All:

When using our 5DT Data Glove 5 Ultra glove, we import it via

gloveSensor = viz.add('5dt.dls')

If we were to be using both a Data Glove 5 and a Data Glove 14 Ultra, would this same code above be able to distinguish between the two gloves? Or would we need to use a different driver? Of course, due to the different number of sensors on the two gloves, the values sent to/returned from the glove would differ, but I didn't know if the single 5dt.dls driver could drive both gloves.

Thanks!

farshizzo
07-30-2007, 11:09 AM
Hi,

You should be able to connect to 2 gloves by specifying the port for each glove. Example:PORT_5DT_USB = 0
glove1 = viz.add('5dt.dls')

PORT_5DT_USB = 1
glove2 = viz.add('5dt.dls')

bjgold
07-30-2007, 11:13 AM
And that would automatically know that glove1 is the 5 sensor and glove2 the 14 sensor one without any work on our end?

farshizzo
07-30-2007, 11:17 AM
Hi,

You would need to detect that yourself. You can check the length of the data list returned by the gloves to figure out which one is 14 sensor and 5 sensor. The 14 sensor glove will return a longer list.

bjgold
07-30-2007, 11:20 AM
Ahh, great. Thanks!