title: Cannot request compass calibration from Core Location callback
body: <p>I am using Core Location in my app and I am trying to present a calibration alert when the device compass / heading values are too imprecise.</p>
  
  <p>I am correctly reading the heading values from the didUpdateHeading delegate function.</p>
  
  <p>I read the related posts and I the CLLocationManager documentation (<a href="https://developer.apple.com/documentation/corelocation/cllocationmanagerdelegate/1621457-locationmanagershoulddisplayhead" rel="nofollow noreferrer">https://developer.apple.com/documentation/corelocation/cllocationmanagerdelegate/1621457-locationmanagershoulddisplayhead</a>).</p>
  
  <p>In the locationManagerShouldDisplayHeadingCalibration(_:) delegate function I tried those two implementations:</p>
  
  <pre><code>func locationManagerShouldDisplayHeadingCalibration(_ manager: CLLocationManager) -&gt; Bool {
      return true
  }
  </code></pre>
  
  <p>And:</p>
  
  <pre><code>func locationManagerShouldDisplayHeadingCalibration(_ manager: CLLocationManager) -&gt; Bool {
      print("locationManagerShouldDisplayHeadingCalibration")
      if let h = manager.heading {
          return h.headingAccuracy &lt; 0 || h.headingAccuracy &gt; 10
      }
      return true
  }
  </code></pre>
  
  <p>In the documentation, it is stated "If you return false from this method or do not provide an implementation for it in your delegate, Core Location does not display the heading calibration alert. Even if the alert is not displayed", but I don't know how to "provide an implementation for it".</p>
  
  <p>Moreover, I see that there is no way to present the system calibration alert manually, if the alert is not presented as often as I want, is it a good solution to poll the headingAccuracy value on the didUpdateHeading callback and to present a system-like alert ? Also as I never saw it is there any way I can trigger the system calibration alert ?</p>