Works on Windows (and Linux, but not thoroughly tested), now you can configure your hardware and collect data!
optotrak_align_my_system
now works with multiple cameras with OAPI 3.15Requirements:
This toolbox was developed using the following configuration. The more you deviate from it, and the more exotic hardware you want to use, the more likely you will run into problems.
64-bit systems running Windows are recommended, but most functions should work with 32-bit systems too. I tested it on Windows 7 and the 32-bit version of Matlab R2015b, and Ubuntu MATE 18.04 LTS using Matlab R2018a.
Get a release version of the toolbox
$ git clone https://github.com/volcic/motom-toolbox.git
(...or click 'Clone or download -> Download ZIP')
If you are feeling adventurous, try the development version:
$ git clone https://github.com/ha5dzs/motom-toolbox.git
This creates the motom-toolbox directory.
In order to start using the toolbox, you'll need the proprietary files you bought from NDI. There are dedicated spaces for the API files in the toolbox directory. If you are trying to get the toolbox working on some old/weird hardware and you are running into error messages, don't panic, read the Damage Control FAQ!
...or, if you really just want to dive in, and once you got the Optotrak API files:
Replace every #include <ndtypes.h>
with -> #include "ndtypes.h"
Replace every #include <ndpack.h>
with -> #include "ndpack.h"
Replace every #include <ndhost.h>
with -> #include "ndhost.h"
#include "ndtypes.h"
#include "ndpack.h"
#include "ndhost.h"
During compilation and library loading, there will be some warnings about some variable types, these are safe to ignore. Once the script is finished, you will have all the functions described in the API manual available in Matlab. There are commonly used scripts in the 'convenience' directory, and some examples are included too.
There is an open access paper available about the toolbox. If you are using this software in your research project, please cite it as follows:
Derzsi, Z., & Volcic, R. (2018). MOTOM toolbox: MOtion Tracking via Optotrak and Matlab. Journal of neuroscience methods, 308, 129-134.
DOI: https://doi.org/10.1016/j.jneumeth.2018.07.007
Thank you!