Skip to content

Commit

Permalink
Add section for new depth sensor device
Browse files Browse the repository at this point in the history
  • Loading branch information
PeterBowman authored May 13, 2019
1 parent d186edc commit 2491869
Showing 1 changed file with 22 additions and 6 deletions.
28 changes: 22 additions & 6 deletions install-yarp.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,35 +71,51 @@ sudo make install && sudo ldconfig && cd # Install and go home

# Install Additional Plugins: Devices

## Install additional YARP device: OpenNI2DeviceServer (Ubuntu)

***Note:** tested on YARP 2.3.68.x and YARP 2.3.72.1, not compatible with YARP 3.x.*
## Install additional YARP device: depthCamera (Ubuntu)

Make sure you have previously installed YARP and:

- [Install OpenNI2 & NiTE2](install-openni-nite.md)
- [Install OpenNI2 (Ubuntu)](install-openni-nite.md#install-openni2-ubuntu)

```bash
cd ~/repos/yarp/build
cmake .. -DCREATE_DEVICE_LIBRARY_MODULES=ON -DENABLE_yarpmod_OpenNI2DeviceServer=ON -DENABLE_yarpmod_OpenNI2DeviceClient=ON -DOpenNI2_INCLUDE_DIR=/usr/local/include/OpenNI2/ -DOpenNI2_LIBRARY=/usr/local/lib/libOpenNI2.so
cmake .. -DOpenNI2_INCLUDE_DIR=/usr/local/include/OpenNI2/ -DOpenNI2_LIBRARY=/usr/local/lib/libOpenNI2.so -DENABLE_yarpmod_depthCamera=ON
make -j$(nproc) # Compile
sudo make install && sudo ldconfig && cd # Install and go home
```
You should now be able to launch `yarpdev --device OpenNI2DeviceServer`. It is a complex device, see options with `yarpdev --device OpenNI2DeviceServer --verbose` (where there is an option to see modes) or example [here](https://github.com/roboticslab-uc3m/teo-configuration-files/blob/ee168eaf61454113b1ac7113fbb24e10af679bc3/share/teoBase/scripts/teoBase.xml#L35-L36).

You'll need a configuration file in order to launch this device. For instance, we use this command with an ASUS camera: `yarpdev --from xtion.ini` ([ref](https://github.com/roboticslab-uc3m/vision/blob/255af0dd568e90da854edfd3cadc8ecf155a9337/share/sensors/conf/xtion.ini)).

Note ([ref](https://github.com/roboticslab-uc3m/vision/issues/83#issuecomment-390326913)): installation of *depthCamera* is broken at YARP 2.3.72 (and probably at 2.3.70.x, too). Did work at 2.3.68.x, fixed upstream at 2.3.72.1. Workaround: do `cmake . -DYARP_HAS_OpenNI2=ON` and configure again.

## Install additional YARP device: OpenNI2DeviceServer (Ubuntu)

***Note:** tested on YARP 2.3.68.x and YARP 2.3.72.1, not compatible with YARP 3.x.*

```bash
cd ~/repos/yarp/build
cmake .. -DCREATE_DEVICE_LIBRARY_MODULES=ON -DENABLE_yarpmod_OpenNI2DeviceServer=ON -DENABLE_yarpmod_OpenNI2DeviceClient=ON -DOpenNI2_INCLUDE_DIR=/usr/local/include/OpenNI2/ -DOpenNI2_LIBRARY=/usr/local/lib/libOpenNI2.so
make -j$(nproc) # Compile
sudo make install && sudo ldconfig && cd # Install and go home
```

You should now be able to launch `yarpdev --device OpenNI2DeviceServer`. It is a complex device, see options with `yarpdev --device OpenNI2DeviceServer --verbose` (where there is an option to see modes) or example [here](https://github.com/roboticslab-uc3m/teo-configuration-files/blob/ee168eaf61454113b1ac7113fbb24e10af679bc3/share/teoBase/scripts/teoBase.xml#L35-L36).

### Install additional YARP device: OpenNI2DeviceServer (Ubuntu) with NiTE (skeletons)

***Note:** not compatible with YARP 3.x.*

NiTE only required for skeletons. In addition to above steps for OpenNI:

- [Install NiTE2.2 (Ubuntu)](install-openni-nite.md#install-nite22-ubuntu)

```bash
cd ~/repos/yarp/build
cmake .. -DNITE2_INCLUDE_LOCAL=/usr/local/include/NiTE-Linux-x64-2.2 -DNITE2_LIBRARY=/usr/local/lib/libNiTE2.so
make -j$(nproc) # Compile
sudo make install && sudo ldconfig && cd # Install and go home
```

You may need to launch `yarpdev --device OpenNI2DeviceServer` from `/YOUR_PATH_TO/NiTE-Linux-x64-2.2/Redist` if using NiTE.

# Install Bindings
Expand Down

0 comments on commit 2491869

Please sign in to comment.