talira

sensors_plus

A Flutter plugin to read the accelerometer, gyroscope, magnetometer and barometer

open sourceBSD-3-Clausefree

sensors_plus is a Flutter plugin from the Flutter Community's Plus plugins that gives a Flutter app the device's accelerometer, gyroscope, magnetometer and barometer as streams of events. It works on Android, iOS and the web (where the sampling rate can't be set). On iOS the app has to declare motion-data access in its Info.plist. It is BSD-3-Clause licensed and lives in the fluttercommunity/plus_plugins monorepo.

Problems it solves

  • read the phone's accelerometer and gyroscope in my Flutter app
  • detect device motion or orientation changes in Flutter
  • get barometric pressure readings from a phone in a Flutter app

Features

  • accelerometer and user accelerometer events
  • gyroscope and magnetometer events
  • barometer events
  • sensor readings as Dart streams

Limitations

  • Can't set the sensors' sampling rate on the web1

Alternatives

The same job

These do what sensors_plus does.

  1. local_auth Flutter plugin for local authentication with biometrics, passcode, PIN or pattern
  2. Location (Flutter) Real-time device location for Flutter on every platform

Compare sensors_plus with the top 3