Sensores

Teste de bússola

Exiba a direção da bússola em tempo real a partir dos dados de orientação do dispositivo e verifique como ela responde quando você vira.

Privacidade: Os dados de direção são processados ​​localmente. Nenhuma informação de localização ou orientação é carregada.
Rótulos de interface e nomes de ferramentas são traduzidos. Orientações detalhadas e perguntas frequentes nesta página estão atualmente escritas em inglês.

Interface de teste

Seu navegador pode pedir permissão após você pressionar Iniciar.
Preparar. Ative a bússola e gire lentamente.
N E S W
— ° —
Cabeçalho—
Fonte do sensor—
As leituras da bússola podem ser distorcidas por ímãs, metal, alto-falantes e caixas. O rumo pode ser relativo em vez de norte verdadeiro, dependendo do navegador e do dispositivo.

Como usar esta ferramenta

  1. Click Enable compass and grant motion permission if your browser asks.
  2. Hold the device flat and slowly turn in a circle.
  3. Compare the displayed heading with a known direction or a physical compass.
  4. Stop the test when finished.

Anúncio

Explicação técnica

The page reads DeviceOrientationEvent.alpha and, on iOS, webkitCompassHeading. It converts the value into a 0–360° heading and draws a compass dial. Some browsers only provide a relative orientation until an absolute orientation event is available.

Magnetic interference from speakers, metal desks, cases, and magnets can distort the reading. The browser may also apply smoothing. A phone compass is a navigation aid, not a surveying instrument, and it is not calibrated by this page.

Solução de problemas

The compass is unsupported

Desktop devices usually lack a magnetometer. Use a phone or tablet with a modern browser.

Heading is stuck or jumps

Move away from metal and magnetic objects, then wave the device in a figure-eight to help the system calibrate.

North is wrong

Check whether the reading is relative or absolute. Some browsers do not expose true north without a permission or sensor fusion.

Permission was denied

Reset motion access for the site and reload, then press Enable again.

Perguntas frequentes

Anúncio