<!--
{
  "availability" : [
    "iOS: 4.0.0 -",
    "iPadOS: 4.0.0 -",
    "macCatalyst: 13.0.0 -",
    "macOS: 10.15.0 -",
    "visionOS: 1.0.0 -",
    "watchOS: 2.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "CoreMotion",
  "identifier" : "/documentation/CoreMotion/CMAttitudeReferenceFrame/xArbitraryCorrectedZVertical",
  "metadataVersion" : "0.1.0",
  "role" : "Type Property",
  "symbol" : {
    "kind" : "Type Property",
    "modules" : [
      "Core Motion"
    ],
    "preciseIdentifier" : "c:@E@CMAttitudeReferenceFrame@CMAttitudeReferenceFrameXArbitraryCorrectedZVertical"
  },
  "title" : "xArbitraryCorrectedZVertical"
}
-->

# xArbitraryCorrectedZVertical

A reference frame where the Z axis is vertical and has improved rotation accuracy, and the X axis points in an arbitrary direction in the horizontal plane.

```
static var xArbitraryCorrectedZVertical: CMAttitudeReferenceFrame { get }
```

## Discussion

When you start the device-motion service, Core Motion uses the current device orientation to set the initial frame of reference. You might use this option when you don’t need to know the device’s attitude relative to true or magnetic north, and only track rotational changes over time.

This option uses the magnetometer to improve long-term accuracy for the z axis (yaw) measurements. The device must have a magnetometer and that sensor must be available and calibrated.

This option requires more CPU usage than the [`xArbitraryZVertical`](/documentation/CoreMotion/CMAttitudeReferenceFrame/xArbitraryZVertical) option.

> Tip:
> Save the first reported attitude value, and compare it to new values to determine changes since the start of the service.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)