Starts magnetometer updates without a block handler.
SDKs
- iOS 5.0+
- Mac Catalyst 13.0+
- watchOS 2.0+
Framework
- Core Motion
Declaration
func startMagnetometerUpdates()
Discussion
You can get the latest magnetometer data through the magnetometer
property. You must call stop
when you no longer want your app to process magnetometer updates.