PlayHapticCommand

public struct PlayHapticCommand : CommandRequest

Command to request the Gear plays a haptic pattern.

Note that the only gear Components (not the tag Component) support haptics.

See also

Commands

See also

Components and Gear
  • Available haptic patterns.

    See more

    Declaration

    Swift

    public enum HapticPatternType : Int
  • Errors that can occur when playing Haptic patterns.

    See more

    Declaration

    Swift

    public enum Error : Swift.Error
    extension PlayHapticCommand.Error: CustomStringConvertible
  • PlayHapticCommand response value is an empty Void to indicate success.

    Declaration

    Swift

    public typealias Response = Void
  • Creates a PlayHapticCommand instance.

    Throws

    if the component does not support haptic.

    Declaration

    Swift

    public init(frame: HapticFrame, component: Component) throws

    Parameters

    frame

    Configuration to play a haptic on the Gear.

    component

    An object that holds information of a Tag or Interposser.

  • Configuration for haptic frame.

    See more

    Declaration

    Swift

    public struct HapticFrame