motion
Installation
SKILL.md
Motion (iOS)
Motion is an experimental capability for streaming inertial sensor samples. Enable it for the app in Wearables Developer Center. It has no runtime Permission value.
Attach, observe, and start
Add Motion only after the DeviceSession reaches .started. Unlike Inputs, Motion is returned stopped: register observers before calling start().
import MWDATCore
import MWDATMotion
let motion = try session.addMotion(
configuration: MotionConfiguration(samplingRate: .hz30)
)
guard let motion else { return }