A Message sent to the current card of the defaultStack when the heading of the device changes. If there is a message handler by the same name in the message path, then it will be executed.
Message[]
Syntax:
headingChanged <heading>
The parameter <heading> is the heading of the device, in degrees relative to true north if available, otherwise relative to magnetic north.
The headingChanged message is sent to the current card of the defaultStack when the heading of the device changes.
If heading tracking cannot be started (typically due to a lack of calibration) then a trackingError message is sent instead.
Message handler[]
Examples:
on headingChanged theHeading updateMapPosition theHeading -- update the marker on the map showing the current heading end headingChanged
Use the headingChanged Message handler if you want to perform tasks when the heading of the device changes.
See also: mobileCanTrackHeading, mobileCanTrackLocation, mobileCurrentHeading, iphoneHeadingCalibrationTimeout & trackingError.