Coder Social home page Coder Social logo

udev, C, python and gyro... about emokit HOT 5 CLOSED

openyou avatar openyou commented on July 28, 2024
udev, C, python and gyro...

from emokit.

Comments (5)

antoche avatar antoche commented on July 28, 2024

Update on the C situation: by default I get garbage, but if I change type from 0 to 1 in emokit.c line 40, I get correct data. The gyro data is skewed as in the python case, though.

I also noticed that running the C code makes the emokit's hidraw devices disappear, making the python script unusable until I unplug and re-plug the usb dongle. Is there a way to avoid that?

Cheers,
A.

from emokit.

qdot avatar qdot commented on July 28, 2024

Ah, yeah, that's my fault for not having report parsing in the C version then. I'm hoping to convert to HIDAPI soon (note: soon can sometimes take months for me :( ), which'll make that work automatically.

As for the hidraw device, yeah, I just noticed that too. We do a kernel detach to make linux's HID manager go away when we use libusb, and I don't think I ever reattach before closing. This is yet another thing just going to HIDAPI will fix. :)

from emokit.

antoche avatar antoche commented on July 28, 2024

Thanks for the reply. None of these issues are blocking for me right now, so it's fine. I'm still just puzzled about the gyro data not being 0 at rest, but I'm not using it right now so it's not blocking either.
I'm having a look at making an emokit acquisition driver in openvibe, I'll post something here if I get any success. I managed to get the data through to openvibe by modifying emokitd to make it output the binary data into a fifo and using openvibe's raw file reader (similar to http://www.giammy.com/files/bci.html#x1-200004.6.2 but simpler), but it's a bit crude.

from emokit.

qdot avatar qdot commented on July 28, 2024

Ah, hey, I'm doing that too! :D

Or, well, was. I started trying to do an acq server in OpenVibe a couple of months ago, just haven't had time to finish it. It's at

https://github.com/qdot/openvibe/tree/emokit-acquisition

If you're interested. Dunno if there's much different from yours.

Also: I'm working on the hidapi stuff now, hopefully will have the library done tonight or tomorrow. It's gonna be an API breaker, but I think this will work much better in the long run.

from emokit.

antoche avatar antoche commented on July 28, 2024

I'm pretty much at the same point: copy the Emokit-epoc driver, rip out the entrails and try to get it to compile to start with. :)

No worries about the API breaking for me. The code is simple enough to update it when needed.

from emokit.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.