mm_device_info

mm_device_info is a Flutter plugin that provides comprehensive device information through a simple and consistent API.

Features

  • Basic Device Info: Model, Brand, Manufacturer, OS Version, and SDK Version.
  • Cross-Platform: Supports Android, iOS, Web, Windows, macOS, and Linux (Initial implementation focused on Android).
  • Type-Safe: Uses strongly typed models instead of raw maps.

Usage

Import the package:

import 'package:mm_device_info/mm_device_info.dart';

Get device information:

final mmDeviceInfo = MmDeviceInfo();
final deviceInfo = await mmDeviceInfo.getDeviceInfo();

print('Device Model: ${deviceInfo.model}');
print('Android Version: ${deviceInfo.androidVersion}');

Data Model

The DeviceInfo class includes:

  • model: Device model (e.g., "Pixel 6")
  • brand: Device brand (e.g., "Google")
  • manufacturer: Device manufacturer (e.g., "Google")
  • androidVersion: Android OS version (e.g., "13")
  • sdkVersion: Android SDK level (e.g., 33)