psmoveapi icon indicating copy to clipboard operation
psmoveapi copied to clipboard

Unable to get PSMoveTracker

Open steve-hops opened this issue 1 year ago • 9 comments

hi there, im trying to use the psmoveapi for a school project, however, im facing the below error when trying to access tracker. im wondering is there something i might have missed out?

self.tracker = psmove.PSMoveTracker() AttributeError: module 'psmove' has no attribute 'PSMoveTracker'

i checked that the ps eye camera works fine. i'm using verision 4.0.12 of psmoveapi on ubuntu 22.04

thank you!

steve-hops avatar Jan 09 '25 17:01 steve-hops

Have you built the project with tracker support, and installed all dependencies (e.g. OpenCV)? Can you attach the full build log (do a clean rebuild if you haven't captured the log, so it really builds everything from scratch)?

thp avatar Jan 10 '25 05:01 thp

Untitled.odt

hi there, have attached the log. my apologies for my ignorance, how should i enable the tracker?

Thank you!

steve-hops avatar Jan 13 '25 07:01 steve-hops

hi @thp , may i ask how do i build the project with tracker support? also, i cant use the set_led function,im just wondering if i missed out any steps, i followed the instructions on psmoveapi.readthedocs.io/en/latest/

Image

steve-hops avatar Feb 04 '25 13:02 steve-hops

hi @thp , may i ask how do i build the project with tracker support?

Later versions of the scripts/linux/build-debian (browse the code in the Git "master" branch (which is what GitHub shows you by default)) have been changed to automatically build with tracker support. I suggest you take a look at what it does.

also, i cant use the set_led function,im just wondering if i missed out any steps, i followed the instructions on psmoveapi.readthedocs.io/en/latest/

Where in the instructions does that function call appear exactly? I can't seem to find it. And which language bindings are you using?

nitsch avatar Feb 04 '25 20:02 nitsch

hi @nitsch , thanks for responding, i used the 4.0.12 branch as i was facing the same problem as https://github.com/thp/psmoveapi/issues/495, i tried to use the master branch today and am still facing the same problem

build log: Untitled.docx

steve-hops avatar Feb 08 '25 16:02 steve-hops

Before going through the steps for building 4.0.12 with tracker support ... Can't you just use the Linux binaries that come with that release?

nitsch avatar Feb 08 '25 22:02 nitsch

hi @nitsch ,apologies for my ignorance, may i clarify "use the Linux binaries that come with that release"? Thank you!

steve-hops avatar Feb 09 '25 07:02 steve-hops

The psmoveapi releases (https://github.com/thp/psmoveapi/releases/tag/4.0.12) come with pre-built binaries for multiple platforms. Linux is also included.

The library files (.so) can be found in the libs/ subdirectory of the respective archive, header files in the include/ subdirectory and so on.

It looks like libpsmoveapi_tracker.so depends on OpenCV 3.2 (you can use the ldd command-line tool to check), so that would have to be installed on your system in order to use tracking support.

nitsch avatar Feb 09 '25 11:02 nitsch

Also, for the master branch, check out the scripts in https://github.com/thp/psmoveapi/tree/master/scripts -- these also build OpenCV and so should include tracker support. This even works for the master branch (and is what CI uses to verify the API can be built).

thp avatar Feb 15 '25 14:02 thp