CARP Health Sampling Package
This library contains a sampling package for sampling health data from Apple Health and/or Google Fit to work with
This packages supports sampling of the following
HealthDataType documentation for a complete list.
For Flutter plugins for other CARP products, see CARP Mobile Sensing in Flutter.
If you're interested in writing you own sampling packages for CARP, see the description on how to extend CARP on the wiki.
To use this package, add the following to you
pubspc.yaml file. Note that
this package only works together with
dependencies: flutter: sdk: flutter carp_mobile_sensing: ^0.11.0 carp_health_package: ^0.11.0 ...
This package uses AndroidX. See Flutter AndroidX compatibility
Replace the content of the
android/gradle.properties file with the following lines:
org.gradle.jvmargs=-Xmx1536M android.enableJetifier=true android.useAndroidX=true
Add this permission in the
Info.plist file located in
<key>NSHealthShareUsageDescription</key> <string>We will sync your data with the Apple Health app to give you better insights</string> <key>NSHealthUpdateUsageDescription</key> <string>We will sync your data with the Apple Health app to give you better insights</string>
To use this package, import it into your app together with the
import 'package:carp_mobile_sensing/carp_mobile_sensing.dart'; import 'package:carp_health_package/health.dart';
Before creating a study and running it, register this package in the SamplingPackageRegistry.