Skip to content

Vibration API

All product guides

1. Overview

This document introduces how to send vibration control commands to HandDriver via the UDP protocol to trigger vibration feedback for the vibrators of the glove.

Please ensure that it is used within the same local area network (LAN).

2. Usage Instructions

2.1. Basic Parameters

  • Protocol: UDP
  • Port: 8920
  • IP Address: Local IP or assign a specific IP
  • Data Format: JSON

2.2. Data Format

2.2.1. Glove Controller 2.0

{
    "ctrl": { // character name
        "LeftHand": [ // 
            {"Name": "Vibrators","Value": 0}, // vibrators number ( (int)0/1 ); 0-disable 1-enable

            {"Name": "Duration","Value": 200}, // duration values (int)40~30000 in unit of ms, eg. 200 means 200ms

            {"Name": "Amplitude","Value": 1000}, // intensity value ( (int)1~1000 )

            {"Name": "Rate","Value": 2000} // vibration rate value ( (int)7~3000 )
        ],
        "RightHand": [
            {"Name": "Vibrators","Value": 1}, // vibrators number ( (int)0/1 ); 0-disable 1-enable

            {"Name": "Duration","Value": 1000}, // duration values (int)40~30000 in unit of ms, eg. 1000 means 1s

            {"Name": "Amplitude","Value": 500}, // intensity value ( (int)1~1000 )

            {"Name": "Rate","Value": 3000} // vibration rate value ( (int)7~3000 )
        ]
    }
}

Parameter Description

The Controller2.0 is with a Linear Resonant Actuator (a linear type motor).

  • Vibrators: Vibration enable (0/1), 0 means disable and 1 is enable.
  • Duration: Vibration duration (in unit of milliseconds)
  • Amplitude: Vibration intensity (1-1000)
  • Rate:Vibration rate value (7-3000)

2.2.2. Glove Controller 1.0

{
    "ctrl": { // character name
        "LeftHand": [ // 
            {"Name": "Vibrators","Value": 0}, // vibrators number ( (int)0~3 );0-none,1-vib1,2-vib2,3-both

            {"Name": "Duration","Value": 0.04}, // time value ( (float)0.04~2.5 )

            {"Name": "Amplitude","Value": 4} // intensity value ( (int)4~10 )
        ],
        "RightHand": [
            {"Name": "Vibrators","Value": 2}, // vibrators number ( (int)0~3 );0-none,1-vib1,2-vib2,3-both

            {"Name": "Duration","Value": 1}, // time value ( (float)0.04~2.5 )
            {"Name": "Amplitude","Value": 4} // intensityvalue ( (int)4~10 )
        ]
    }
}

Parameter Description

  • Vibrators: Vibration motor ID (0-3), Vibrator 1 is under the buttons and Virbrator 2 is under the joystick
  • Duration: Vibration duration (seconds)
  • Amplitude: Vibration intensity (4-10)