Skip to content
Articles
Article

qibla_math: the maths behind a qibla compass, in pure Dart

by Abdeldjalil Chougui dev.to

6 min read

A qibla compass looks like a small feature: an arrow that points to Makkah. Under the arrow there are three separate problems, and getting any one of them wrong gives an arrow that is confidently off. First, the direction itself. The bearing from your position to the Kaaba is a great-circle calculation, and it is measured from true north. Second, the phone. A magnetometer gives a heading only if …

Forum

Questions about this, or something to add?

Discuss on the forum

Report this · Wrote this? Claim it

FlutterX is supported by