Configuring Sensor Data

Configure smartphone sensors to collect background data that complements your surveys.

The Sensor Data tab in the study edit page allows researchers to configure smartphone sensors that collect data in the background, independent of survey responses. This passive data collection is a powerful feature of the SMAAT platform, enabling you to gather contextual information about participants’ environments, movements, and behaviors without requiring their active input.

Background sensors run continuously (or at specified intervals) while the SMAAT app is active, providing a continuous stream of data that can be correlated with survey responses or analyzed independently. The platform supports fine-grained control over sensor settings to balance data quality and battery efficiency.

Available Sensors

Currently, the SMAAT platform supports the following sensors for background data collection:

  • GPS: Tracks the participant’s geographic location using latitude and longitude coordinates, ideal for studies on mobility, environmental exposure, or location-based behaviors.
  • Health Data: Passively reads health metrics (steps, resting heart rate, and sleep) from the device’s health platform — Apple Health on iOS and Health Connect on Android — ideal for studies on physical activity, sleep, and physiological correlates of behavior.
Note: Additional sensors (e.g., accelerometer, gyroscope) may be available for survey-specific data collection, as covered in the Surveys section.

Configuring GPS Sensor

To enable GPS data collection, activate the GPS sensor in the Sensor Data tab and configure its settings to suit your study’s needs.

Sampling Rate

Choose from predefined sampling rates to balance data granularity and battery usage:

  • Low: Battery-saving mode, collecting data less frequently (e.g., every 5 minutes).
  • Medium: Balanced mode, suitable for most studies (e.g., every 1 minute).
  • High: High-frequency mode for maximum data quality (e.g., every 10 seconds), but more battery-intensive.
  • Custom: Manually configure settings for precise control.

Custom GPS Options

If you select the custom sampling rate, you can fine-tune the following parameters:

  • Activity Type (iOS only): Specify the participant’s activity to optimize location accuracy (e.g., “Other Navigation” for general movement, “Fitness” for exercise tracking).
  • Deferred Updates:
    • Distance: The minimum distance (in meters) the device must move before triggering a location update (e.g., 100 meters).
    • Interval: The time interval (in milliseconds) between location updates (e.g., 60000 for 1 minute).
    • Timeout: The maximum time (in milliseconds) to wait for a location update before stopping the service (e.g., 300000 for 5 minutes).
  • Foreground Service:
    • Notification Title: The title displayed in the notification when the service is active (e.g., “SMAAT Location Tracking”).
    • Notification Body: The body text of the notification (e.g., “Collecting location data for your study.”).
    • Notification Color: The color of the notification icon, enhancing visibility.
    • Kill on Destroy: Option to stop the service if the app is closed, preserving battery life.
  • iOS-Specific Options:
    • Pauses Updates Automatically: Pauses location updates in low-signal areas (e.g., tunnels) to improve accuracy.
    • Shows Background Location Indicator: Displays a blue bar on the iOS device when location services are active in the background.
Example: For a study on urban commuting, configure a custom GPS setting with a 50-meter distance threshold and a 30-second interval to capture participants’ routes efficiently.
Troubleshooting Tip: If GPS data is inconsistent, check the sampling rate and ensure participants have enabled location permissions. High sampling rates may drain batteries faster, so inform participants accordingly.
Sensor Data tab with GPS configuration options, sampling rate selectors, and custom settings.
The Sensor Data tab, displaying GPS sensor configuration options with sampling rate selectors and custom settings.

Configuring Health Data Sensor

The Health Data sensor passively collects health metrics from the device’s health platform once per day in the background. On iOS it reads from Apple Health; on Android from Health Connect. To enable it, turn on the Health Data toggle in the Sensor Data tab and select which data types to collect.

Permission required: Participants must explicitly grant health-data permission inside the SMAAT app. On iOS, access is granted per data type via Apple Health; on Android, via the Health Connect permission screen. Data types the participant declines will not be collected, even if enabled in your study.

Data Types

Choose one or more of the following data types. At least one must be selected for the sensor to collect anything:

  • Steps: Daily step count aggregated per calendar day. Reported as a value with the unit count and a start/end date for each day (e.g., 8342 steps).
  • Resting Heart Rate: Individual resting heart-rate measurements in beats per minute. Each sample includes its value (unit bpm, e.g., 62) and the timestamp it was recorded.
  • Sleep: Sleep stage segments — light, deep, rem, and awake — each with a start time, end time, and duration in minutes.

How Collection Works

  • Frequency: Health data is read once per day in the background, so it has minimal battery impact compared to continuous sensors like GPS.
  • Source platform: SMAAT reads whatever data is already present in Apple Health or Health Connect — it does not measure metrics directly. Data quality therefore depends on the participant’s own devices (phone, smartwatch, fitness tracker) feeding those platforms.
  • Export: Collected values appear in your study data export as separate steps, restingHeartRate, and sleep columns.
Example: For a study correlating physical activity with mood, enable Health Data with Steps and Sleep selected. Each day the app records the participant’s step count and sleep stages, which you can then align with their daily mood survey responses.
Troubleshooting Tip: If health data is missing, confirm the participant granted health permission and that their device actually contains the requested data — for example, resting heart rate and sleep generally require a connected smartwatch or wearable. Consider participant privacy and obtain appropriate consent when collecting sensitive health metrics.
© 2025 SMAAT Platform. All rights reserved.