EXOS Unity SDK  0.7.0
Developer Manual

Ver

Managed Unity DLL / Unity 2018 or Later / .Net Framework 4.7.1


Setup Device

Read DK2 Setup Manual

Japanese version

English version

How to install

  1. Install follow asset from Asset Store
    • SteamVR Plugin (Tested up to version 2.0.1)
  2. Select .NET 4.X on Runtime ver selection in Player Settings
  3. Install EXOS_Unity_SDK_vXXX
  4. Generate SteamVR_Input (with default)

Install Sample package when necessary

  1. Install follow asset from Asset Store
    • 1911 Pistol Pack (Tested up to version 1.0)
    • InkPainter (Tested up to version 1.2.1)
  2. Install EXOS_Unity_SDK_vXXX_Sample


Sample Code

  1. Create script like below.
  2. Attach the script to game object.
  3. Set .assets to ExosDevice from EXOS_SDK/Standard/ExosAssets/Device.
    • If you want to use right Wrist, you should select EXOS_Wrist_DK2_R.

A sample code of getting values from Wrist.

using exiii.Unity.Device;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class SampleTest : MonoBehaviour {

    [SerializeField]
    private ExosDevice m_Device;

    void Start () {

        if (m_Device == null)
        {
            return;
        }

        if(!m_Device.Enabled)
        {
            m_Device.Initialize();
        }
    }

    void Update () {

        ExosJoint joint_abduction = m_Device.GetJoint(exiii.Unity.EAxisType.Abduction);
        ExosJoint joint_flextion = m_Device.GetJoint(exiii.Unity.EAxisType.Flexion);
        if (joint_abduction == null || joint_flextion == null)
        {
            return;
        }

        float force_abduction = joint_abduction.ForceRatio;
        float force_flextion = joint_flextion.ForceRatio;

        float angle_abduction = joint_abduction.AngleRatio;
        float angle_flextion = joint_flextion.AngleRatio;

        Debug.LogFormat("force: abduction:{0} flextion:{1}", force_abduction, force_flextion);
        Debug.LogFormat("angle: abduction:{0} flextion:{1}", angle_abduction, angle_flextion);            
    }

    public void OnDestroy()
    {
        if (m_Device.Enabled)
        {
            m_Device.Termination();
        }
    }
}

This sample can add torque to Wrist, please be careful of injuries.

void Update () {

    ExosJoint joint_abduction = m_Device.GetJoint(exiii.Unity.EAxisType.Abduction);
    ExosJoint joint_flextion = m_Device.GetJoint(exiii.Unity.EAxisType.Flexion);
    if (joint_abduction == null || joint_flextion == null)
    {
        return;
    }

    joint_flextion.ForceRatio = 0.5f;
    joint_abduction.ForceRatio = 0.5f;
}


Sample Scene

SDK 0.6.X : EXOS_UNITY_SDK\SAMPLES\Standard\Scene\Sample_SimpleControl.unity
SDK 0.7.X : EXOS_UNITY_SDK\SDK_CORE\Samples\Scene\Sample_SimpleControl.unity

Very simple device control demo. It can check device angle and input force value on Inspector.


SDK 0.6.X : EXOS_UNITY_SDK\SAMPLES\VR\Scenes\Sample_Wrist.unity
SDK 0.6.X : EXOS_UNITY_SDK\SAMPLES\VR\Scenes\Sample_Gripper.unity

SDK 0.7.X : EXOS_UNITY_SDK\SDK_SteamVR\Samples\Scene\Sample_Wrist.unity
SDK 0.7.X : EXOS_UNITY_SDK\SDK_SteamVR\Samples\Scene\Sample_Gripper.unity

A sample of the device control in VR for each device.


Object Generater

When importing the SDK, several objects are automatically generated at the beginning of the scene. To change this behavior, please check the following Asset.

EXOS_UNITY_SDK\EXOS_SDK\Utility\Resources\ExObjectGenerator


Preload Asset

When importing the SDK, the following Asset is registered in Unity's PreloadAsset.

EXOS_UNITY_SDK\EXOS_SDK\Utility\Resources\ResourcesContainer


License

EXOS_SDK

Copyright (c) exiii Inc.


ViveInputUtility

Copyright 2016-2018, HTC Corporation. All rights reserved.
License https://github.com/ViveSoftware/ViveInputUtility-Unity/blob/develop/LICENSE

The works ("Work") herein refer to the software developed or owned by 
HTC Corporation ("HTC") under the terms of the license. The information 
contained in the Work is the exclusive property of HTC. HTC grants the 
legal user the right to use the Work within the scope of the legitimate 
development of software. No further right is granted under this license, 
including but not limited to, distribution, reproduction and 
modification. Any other usage of the Works shall be subject to the 
written consent of HTC.


uOSC

Copyright (c) 2017 hecomi
The MIT License (MIT) https://github.com/hecomi/uOSC#license


UniRx

Copyright (c) 2018 Yoshifumi Kawai
The MIT License (MIT) https://github.com/neuecc/UniRx/blob/master/LICENSE


SharpOSC

Copyright (c) 2012 Valdemar Örn Erlingsson
The MIT License (MIT) https://github.com/ValdemarOrn/SharpOSC/blob/master/License.txt


System.Reactive

Copyright (c) .NET Foundation and Contributors
Apache License Version 2.0 https://github.com/dotnet/reactive/blob/master/LICENSE


SuperCharactorController

Copyright (c) 2015 IronWarrior
The MIT license (MIT) https://github.com/IronWarrior/SuperCharacterController/blob/master/LICENSE