ios_device_monitor 0.1.1
ios_device_monitor: ^0.1.1 copied to clipboard
Comprehensive iOS device monitoring plugin with CPU, GPU, thermal, uptime, and advanced CPU usage tracking.
Changelog #
All notable changes to the iOS Device Monitor plugin will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
0.1.0 2025-01-XX #
Added - Initial Release #
Core Features
-
✅ CPU Information API (
getCpuInfo)- CPU architecture detection (arm64, arm64e, x86_64)
- core count
- CPU frequency information
- Human-readable display names
-
✅ GPU/Metal Information API (
getGpuInfo)- GPU name, type
- Unified memory architecture detection
- Recommended maximum working set size (iOS 16+)
- Registry ID information (iOS 11+)
- Metal GPU family support detection (iOS 13+)
- Maximum threads per threadgroup (iOS 12+)
- Supported Metal features list
- GPU architecture details
-
✅ Thermal State Monitoring API (
getThermalState)- Real-time thermal state (nominal, fair, serious, critical)
- Performance throttling detection
- User-friendly status messages
- Temperature readings (when available)
- Thermal level enum for easy comparisons
- Warning and critical state helpers
-
✅ System Uptime API (
getSystemUptime)- Boot time as Unix timestamp
- System uptime in seconds
- Formatted uptime strings (e.g., "2d 5h 32m 18s")
- Boot date as DateTime
- Uptime in hours and days
- Duration check helpers (running for a day/week)
-
✅ Advanced CPU Usage API (
getAdvancedCpuUsage)- Overall CPU usage percentage
- User and system time breakdown
- Per-thread statistics (ID, usage, run state, core affinity, name)
- Per-core usage statistics (usage, times, frequency, assigned threads)
- Total and active thread counts
- Usage level indicators (low, medium, high)
- Timestamp information
Model Classes
- CpuInfo (137 lines) - Comprehensive CPU information model
- GpuInfo (297 lines) - GPU/Metal framework information model
- Includes nested
MaxThreadsPerThreadgroupclass
- Includes nested
- ThermalState (202 lines) - Thermal state information model
- Includes
ThermalLevelenum
- Includes
- SystemUptime (150 lines) - System uptime information model
- AdvancedCpuUsage (516 lines) - Advanced CPU usage model
- Includes nested
ThreadDetailclass - Includes nested
CoreUsageclass
- Includes nested
Code Quality Features
- ✅ Full null safety support (Dart 3.0+)
- ✅ Complete JSON serialization (
fromJson,toJson) - ✅ String representation (
toString) for all models - ✅ Equality operators (
==,hashCode) for all models - ✅ Immutable models with
copyWithmethods - ✅ Extensive helper getters and computed properties
- ✅ Comprehensive documentation comments
- ✅ Robust error handling with PlatformException
- ✅ No Dart analysis warnings or errors
Platform Support
- iOS 11.0+ minimum deployment target
- Optimized for iOS 12.0+ (enhanced thread information)
- Full support for iOS 13.0+ (Metal GPU families)
- Extended features on iOS 16.0+ (working set size)
Documentation
- Comprehensive README with usage examples
- Detailed API documentation (API_DOCUMENTATION.md)
- Extensive usage examples (USAGE_EXAMPLES.md)
- MIT License
- Contributing guidelines
- Troubleshooting section
Developer Experience
- Method channel:
com.device_monitor/ios - Platform check:
isIOSproperty - Plugin version:
pluginVersionproperty - Clean, type-safe Dart API
- Production-ready code (1,600+ lines)
Known Limitations #
Platform Limitations
- iOS only - No Android, macOS, Windows, Linux, or Web support
- Physical devices recommended - Some features (thermal state) may show limited data on simulators
- iOS version dependent - Some features require specific iOS versions:
- iOS 11.0+: Basic features
- iOS 12.0+: Enhanced thread information
- iOS 13.0+: Metal GPU family support
- iOS 16.0+: Recommended max working set size
Performance Considerations
- Advanced CPU usage can be computationally expensive when tracking many threads
- Polling frequency should be limited to 1-5 seconds for dynamic metrics
- Thread details collection may impact performance in high-thread-count scenarios
- Static information (CPU/GPU) should be cached, not repeatedly queried
API Limitations
- Temperature readings in
ThermalStatemay not be available on all devices - Some GPU information may be unavailable on older devices or iOS versions
- Thread names in
AdvancedCpuUsagemay not always be available - Core affinity information may be limited or unavailable on some iOS versions
No Special Permissions Required
- Uses standard iOS APIs that don't require user authorization
- No privacy concerns or App Store approval issues
Technical Details #
Dependencies
- Flutter SDK: 3.3.0+
- Dart SDK: 3.0.0+
- plugin_platform_interface: ^2.0.2
Build Requirements
- Xcode 14.0 or higher
- CocoaPods (latest stable version)
- iOS Deployment Target: 11.0+
File Statistics
- Total Lines: 1,645 lines of production code
- Model Files: 6 comprehensive model classes
- Main API: Clean, well-documented interface
- Analysis: Zero Dart analysis issues
Migration Guide #
This is the initial release - no migration required.
Future Roadmap #
Planned features for future releases:
- Battery monitoring and health information
- Memory pressure detection and statistics
- Network interface statistics
- Disk I/O monitoring
- Process information and management
- Real-time streaming APIs with callbacks
- macOS platform support
- Enhanced performance optimizations
Credits #
- Built with Flutter and iOS native APIs
- Uses Metal framework for GPU information
- Comprehensive system monitoring capabilities
- Developed for the Flutter community
Links #
Previous Versions #
None - this is the initial release.
Note: This changelog follows Keep a Changelog principles. All dates are in YYYY-MM-DD format. Version numbers follow Semantic Versioning.