{"id":28,"date":"2016-03-10T00:01:52","date_gmt":"2016-03-10T00:01:52","guid":{"rendered":"http:\/\/dmirpuri.com\/culmination\/?p=28"},"modified":"2016-05-22T09:01:25","modified_gmt":"2016-05-22T09:01:25","slug":"kinect-setup-on-mac-osx-el-capitan","status":"publish","type":"post","link":"https:\/\/dmirpuri.com\/culmination\/2016\/03\/10\/kinect-setup-on-mac-osx-el-capitan\/","title":{"rendered":"Kinect Setup on Mac OSX El Capitan"},"content":{"rendered":"<p style=\"text-align: justify;\">Since the initial plan of the project was to use a Kinect to track the user&#8217;s hand motion to get accurate data, I was setting it up to run on my MacBook Pro. A few weeks later, my advisor advised to design a simpler system. Hence the decision to use Pixy camera vision sensor instead.<\/p>\n<p>&nbsp;<\/p>\n<h2 class=\"entry-title\">Setting up the Kinect on OSX (El\u00a0Capitan)<\/h2>\n<p>With Apple buying out PrimeSense, installing the Kinect on OSX has become a little fumbly. Here\u2019s a step by step guide on getting it up and running.<\/p>\n<p>&nbsp;<\/p>\n<p><strong><span style=\"color: #ff6600;\">Disable System Integrity Protection<\/span><\/strong><\/p>\n<p>System Integrity Protection (SIP) is a new default security measure introduced by Apple in OS X 10.11 onward. This rootless feature prevents Mac OS X compromise by malicious code, therefore locking down specific system level locations in the file system. This prevents the user from making changes to the system via Sudo commands. Therefore in order for us to proceed, we need to turn it off.<\/p>\n<ul>\n<li>Restart your Mac in\u00a0<em>Recovery mode<\/em>\n<ul>\n<li>Restart your Mac holding down\u00a0<em>Cmd-R<\/em><\/li>\n<\/ul>\n<\/li>\n<li>Find\u00a0<em>\u00a0Terminal<\/em>\u00a0in the\u00a0<em>Utilities<\/em>\u00a0menu and type in the following : csrutil disable<\/li>\n<li>Restart your Mac<\/li>\n<\/ul>\n<p>Great! Easy start. Now we will be able to have full access.<\/p>\n<p>&nbsp;<\/p>\n<p><span style=\"color: #ff6600;\"><strong>Download and install MacPorts<\/strong><\/span><\/p>\n<p><a href=\"http:\/\/www.macports.org\/install.php\" rel=\"nofollow\">http:\/\/www.macports.org\/install.php<\/a><\/p>\n<p>&nbsp;<\/p>\n<p><span style=\"color: #ff6600;\"><strong>Install Dependencies<\/strong><\/span><\/p>\n<ul>\n<li>First we have to download a few libraries in order to get the USB port on your Mac working with the Kinect. If you haven\u2019t got them already.<\/li>\n<li>Go into\u00a0<em>Terminal<\/em>\u00a0and type:<\/li>\n<\/ul>\n<p>\u2014\u2014\u2014\u2014\u2014-<\/p>\n<p>sudo port install libtool<\/p>\n<p>\u2014\u2014\u2014\u2014\u2014-<\/p>\n<ul>\n<li>Next, install the development version of libusb. Type into\u00a0<em>Terminal:<\/em><\/li>\n<\/ul>\n<p>\u2014\u2014\u2014\u2014\u2014-<\/p>\n<p>sudo port install libusb-devel +universal<\/p>\n<p>\u2014\u2014\u2014\u2014\u2014-<\/p>\n<p>&nbsp;<\/p>\n<p><span style=\"color: #ff6600;\"><strong>Install OpenNI<\/strong><\/span><\/p>\n<ul>\n<li>(Optional) Create a\u00a0<em>Kinect\u00a0<\/em>directory in\u00a0<em>Home\u00a0<\/em>to place all applications you\u2019ll need to run the\u00a0<em>Kinect<\/em>\u00a0on the Mac.<\/li>\n<li>Open up\u00a0<em>Terminal\u00a0<\/em>and type in:<\/li>\n<\/ul>\n<p>\u2014\u2014\u2014\u2014\u2014\u2013<\/p>\n<p>mkdir ~\/Kinect<\/p>\n<p>cd ~\/Kinect<\/p>\n<p>\u2014\u2014\u2014\u2014\u2014\u2013<\/p>\n<ul>\n<li>As the download page from the Primesense website is not working. Here\u2019s a link to the OpenNI unstable release. Do not try to Download OpenNI v2 beta as it relies solely on the Microsoft Kinect SDK which we cannot use. The version we are going to use is OpenNI SDK (V1.5.7.10)<\/li>\n<li><a href=\"https:\/\/mega.nz\/#!yJwg1DJS!uJiLY4180QGXjKp7sze8S3eDVU71NHiMrXRq0TA7QpU\" rel=\"nofollow\">https:\/\/mega.nz\/#!yJwg1DJS!uJiLY4180QGXjKp7sze8S3eDVU71NHiMrXRq0TA7QpU<\/a><\/li>\n<li>Move the Zip file to your\u00a0<em>Kinect<\/em>\u00a0folder and double-click to uncompress and reveal the SDK folder.<\/li>\n<li>Open\u00a0<em>Terminal\u00a0<\/em>and navigate to the OpenNI SDK folder.<\/li>\n<li>Once in the folder, type:<\/li>\n<\/ul>\n<p>\u2014\u2014\u2014\u2014\u2014-<\/p>\n<p>sudo .\/<span class=\"skimlinks-unlinked\">install.sh<\/span><\/p>\n<p>\u2014\u2014\u2014\u2014\u2014-<\/p>\n<p>&nbsp;<\/p>\n<p><span style=\"color: #ff6600;\"><strong>Install SensorKinect<\/strong><\/span><\/p>\n<ul>\n<li>First type this command in\u00a0<em>Terminal\u00a0<\/em>to prevent errors when installing\u00a0<em>SensorKinect.<\/em><\/li>\n<\/ul>\n<p>\u2014\u2014\u2014\u2014\u2014<\/p>\n<p>sudo ln -s \/usr\/local\/bin\/niReg \/usr\/bin\/niReg<\/p>\n<p>\u2014\u2014\u2014\u2014\u2014<\/p>\n<ul>\n<li>Go to this Github repository and click Download ZIP.<\/li>\n<li><a href=\"https:\/\/github.com\/avin2\/SensorKinect\" rel=\"nofollow\">https:\/\/github.com\/avin2\/SensorKinect<\/a><\/li>\n<li>Move the Zip to the\u00a0<em>Kinect\u00a0<\/em>folder and uncompress it<\/li>\n<li>Navigate to the\u00a0<em>SensorKinect093-Bin-MacOSX-v5.1.2.1.tar\u00a0<\/em>file inside the\u00a0<em>Bin\u00a0<\/em>folder and uncompress it.<\/li>\n<li>Open\u00a0<em>Terminal\u00a0<\/em>and navigate to the\u00a0<em>SensorKinect093-Bin-MacOSX\u00a0<\/em>folder<\/li>\n<li>Install by typing the following command:<\/li>\n<\/ul>\n<p>\u2014\u2014\u2014\u2014\u2013<\/p>\n<p>sudo .\/<span class=\"skimlinks-unlinked\">install.sh<\/span><\/p>\n<p>\u2014\u2014\u2014\u2014-<\/p>\n<ul>\n<li>It will prompt you to enter your password<\/li>\n<li>If it works it will install the Primesense sensor<\/li>\n<\/ul>\n<p>\u2014\u2014\u2014\u2014-<\/p>\n<p>&nbsp;<\/p>\n<p><span style=\"color: #ff6600;\"><strong>Install NiTE<\/strong><\/span><\/p>\n<ul>\n<li>Last thing to install. Go here and download\u00a0<em>NiTE-Bin-MacOSX-v1.5.2.21.<span class=\"skimlinks-unlinked\">tar.zip<\/span><\/em><\/li>\n<li>Add this file to your\u00a0<em>Kinect\u00a0<\/em>folder and uncompress it<\/li>\n<li>Go into\u00a0<em>Terminal<\/em>\u00a0and navigate to the\u00a0<em>NiTE\u00a0<\/em>folder<\/li>\n<li>Install\u00a0<em>NiTE\u00a0<\/em>by typing in the following command:<\/li>\n<\/ul>\n<p>\u2014\u2014\u2014\u2014-<\/p>\n<p>sudo .\/<span class=\"skimlinks-unlinked\">install.sh<\/span><\/p>\n<p>\u2014\u2014\u2014\u2014-<\/p>\n<p>Once that is done, you\u2019ve pretty much finished! Now try and run some examples!<\/p>\n<ul>\n<li>Plug in the Kinect<\/li>\n<li>Copy the sample XML files from\u00a0<em>NiTE\/Data\u00a0<\/em>over to the\u00a0<em>Data\u00a0<\/em>folder in\u00a0<em>SensorKinect<\/em><\/li>\n<li>Open\u00a0<em>Terminal\u00a0<\/em>and navigate to\u00a0<em>NiTE\/Samples\/Bin\/x64-Release<\/em><\/li>\n<li>Run the first Demo by typing in the following command:<\/li>\n<\/ul>\n<p>\u2014\u2014\u2014\u2014<\/p>\n<p>.\/Sample-PointViewer<\/p>\n<p>\u2014\u2014\u2014\u2014<\/p>\n<p>If everything is setup correctly then a new window should pop up and display a tracking demo!<\/p>\n<p>(Note: You might want to restart and enable the SIP again if you want)<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Since the initial plan of the project was to use a Kinect to track the user&#8217;s hand motion to get accurate data, I was setting it up to run on my MacBook Pro. A few weeks later, my advisor advised to design a simpler system. Hence the decision to use Pixy camera vision sensor instead.&hellip; <\/p>\n<p class=\"more-link-p\"><a class=\"more-link\" href=\"https:\/\/dmirpuri.com\/culmination\/2016\/03\/10\/kinect-setup-on-mac-osx-el-capitan\/\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":39,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"_links":{"self":[{"href":"https:\/\/dmirpuri.com\/culmination\/wp-json\/wp\/v2\/posts\/28"}],"collection":[{"href":"https:\/\/dmirpuri.com\/culmination\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/dmirpuri.com\/culmination\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/dmirpuri.com\/culmination\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/dmirpuri.com\/culmination\/wp-json\/wp\/v2\/comments?post=28"}],"version-history":[{"count":7,"href":"https:\/\/dmirpuri.com\/culmination\/wp-json\/wp\/v2\/posts\/28\/revisions"}],"predecessor-version":[{"id":313,"href":"https:\/\/dmirpuri.com\/culmination\/wp-json\/wp\/v2\/posts\/28\/revisions\/313"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/dmirpuri.com\/culmination\/wp-json\/wp\/v2\/media\/39"}],"wp:attachment":[{"href":"https:\/\/dmirpuri.com\/culmination\/wp-json\/wp\/v2\/media?parent=28"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/dmirpuri.com\/culmination\/wp-json\/wp\/v2\/categories?post=28"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/dmirpuri.com\/culmination\/wp-json\/wp\/v2\/tags?post=28"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}