noisybox.net

P5 glove now working in Linux!
Saturday, October 2nd 2004 11:37pm

So I spent entirely too long troubleshooting and otherwise trying to make my p5 glove work in Linux. I was especially interested in the open source 3rd party driver, but alas, I had no success with any driver.

At least until tonight, when I stumbled on a solution! I kinda assumed my USB setup was proper, and that the drivers were just outdated or somehow out of sync with the latest kernel usb support. Sure enough, my hunch was right. I ran across a post somewhere that mentioned that the libusb function usb_bulk_read is used with older kernerls (like 2.4 series), but that the newer ones (like 2.6 series) use usb_interrupt_read. I changed one function call name in the C code and *viola*, the 3rd party driver stopped erroring out and started working!

So now I'm able to dump the raw data from the device, but it's still not terribly interesting. The next step is to set up USB hotplug scripts to set permissions when it's plugged in. After that, I'm going to try and track down code that will convert LED readings into true (read: useful) x,y,z and roll,pitch,yaw. I'm fairly certain that this code exists somewhere already...so hopefully I don't have to write it myself (my matrix math is rusty).

Once that's in place, I'll either track down a pd external to use the glove...or maybe even write one myself. The existing approach seems to use OSC fed into pd, but I'm a little concerned about adding latency. I'd rather have a component that reads directly from the glove...so I guess we'll see.

On a side note, I did a short interview for the upcoming 2 Gyrlz Quarterly, mostly regarding my attendance at the noise fest earlier this year. So if you're in PDX and care, pay attention to the EL festival and pick up a copy.

this is a noisybox.net blog permalink

Want to go to the current blog?