API referenceQnbot Exo PlusPython

Haptics control

Core interfaces

Current version · 1.4.0

ExoHaptics

Configure haptic strength for the left and right sides.

Type

ExoHaptics(left: int | None = None, right: int | None = None)

Details

Non-null intensities must be in the range 0…100. HapticsState inherits ReadChannel[ExoHaptics] operations such as latest(), subscribe(), and asynchronous reads, and adds:

| clear() | Clear haptics output |

HapticsState.set()

Set left and right haptics; an empty value leaves that side out of this update.

Type

HapticsState.set(value: ExoHaptics) -> None

Parameters

  • value: left and right strength settings; each supplied strength is in 0…100.

Returns

None.

Example

device is a started exoskeleton device with haptics support. The complete example checks the capability before setting, holding, and clearing the output.

from qnbot_sdk.exo import ExoHaptics
import time

haptics = device.haptics()
try:
    haptics.set(ExoHaptics(left=30, right=20))
    time.sleep(0.5)
finally:
    haptics.clear()

Complete example: haptics.py.

See also

HapticsState.clear()

Clear haptic output.

Type

HapticsState.clear() -> None

Returns

None.

See also