Start of trail End of trail navigation bar

Table of Contents

Leap Motion

Reads linear translation, rotation matrix and scale factor from Leap Motion detector.

Beta This block is currently a beta version. If you are using this block, we would appreciate any feedback at tech@quanser.com.

Library

QUARC Targets Beta/Devices/Third-Party/Leap Motion

MATLAB Command Line

Click to copy the following command line to the clipboard. Then paste it in the MATLAB Command Window:

qc_open_library('quarc_library_beta/Devices/Third-Party/Leap Motion')

Description

Leap Motion

The Leap Motion block can be used to read linear velocity, rotation matrix and scale factor from Leap Motion detector. Also each output associates with a probability value for the user to distinguish the motion.

By default, the Leap Motion block uses right-handed coordinate system as shown below:

The Leap Motion Right Handed Coordinate System

Limitations

Only one device supported!

Warning This block only supports one device attached to the PC target.

Installation Requirements

Install In order to use the Leap Motion block, the Leap Motion driver version 2.3.1+31549 as well as development kit version 2.3.1+31549, must be installed. Add the directory containing the Leap.dll file to the system PATH environment variable, e.g. C:\Program Files\LeapSDK\lib\x86 for 32-bit Windows, or C:\Program Files\LeapSDK\lib\x64 for 64-bit Windows.

Input Ports

This block has no input ports.

Output Ports

lin

outputs the linear translation of hand motion from the previous sample.

lin_prob

outputs the probability that the motion is a linear translation. The value ranges from 0 to 1.

rot

outputs the rotation matrix of hand motion from the previous sample.

rot_prob

outputs the probability that the motion is a rotation. The value ranges from 0 to 1.

scale

outputs the scale factor of hand motion from the previous sample.

scale_prob

outputs the probability that the motion is a scalar movement. The value ranges from 0 to 1.

con

indicates if the Leap Motion device is connected.

err

outputs error.

Parameters and Dialog Box

Leap Motion

The Leap Motion block has no parameters.

Targets

Target Name

Compatible*

Model Referencing

Comments

QUARC Win32 Target

Yes

Not supported in a referenced model. Use in top-level model only.

No multiple devices support.

QUARC Win64 Target

Yes

Not supported in a referenced model. Use in top-level model only.

No multiple devices support.

QUARC Linux Nvidia Target

Yes

Yes

QUARC Linux QBot Platform Target

Yes

Yes

QUARC Linux QCar 2 Target

Yes

Yes

QUARC Linux QDrone 2 Target

Yes

Yes

QUARC Linux Raspberry Pi 3 Target

Yes

Yes

QUARC Linux Raspberry Pi 4 Target

Yes

Yes

QUARC Linux RT ARMv7 Target

Yes

Yes

QUARC Linux x64 Target

Yes

Yes

QUARC Linux DuoVero Target

No

No

Not supported.

QUARC Linux DuoVero 2016 Target

Yes

Yes

QUARC Linux Verdex Target

No

No

Not supported.

QUARC QNX x86 Target

No

No

Not supported.

Rapid Simulation (RSIM) Target

No

No

Due to safety and liability concerns, the hardware may not be accessed during rapid simulation.

S-Function Target

No

N/A

Old technology. Use model referencing instead.

Normal simulation

Yes

No

* Compatible means that the block can be compiled for the target.

 

navigation bar