fluttertpc_motion_sensors:基于 Flutter 的运动传感器插件项目

用户可借助该项目在 Flutter 应用中便捷获取设备运动数据,实现对安卓和 iOS 加速度计、陀螺仪、磁力计及方向传感器的访问,支持传感器数据监听功能。【此简介由AI生成】

Branch1Tags0

motion_sensors

pub package

Flutter plugin for accessing the Android and iOS accelerometer, gyroscope, magnetometer and orientation sensors.

Getting Started

To use this plugin, add motion_sensors as a dependency in your pubspec.yaml file.

dependencies:
  motion_sensors: ^0.1.0

Import to your project.

import 'package:motion_sensors/motion_sensors.dart';

motionSensors.magnetometer.listen((MagnetometerEvent event) {
    print(event);
});

Screenshot

Ohos Documentation

中文

EN

Introduction

用户可借助该项目在 Flutter 应用中便捷获取设备运动数据,实现对安卓和 iOS 加速度计、陀螺仪、磁力计及方向传感器的访问,支持传感器数据监听功能。【此简介由AI生成】

Customize your domain