aidlab_sdk 0.1.0 copy "aidlab_sdk: ^0.1.0" to clipboard
aidlab_sdk: ^0.1.0 copied to clipboard

Aidlab Flutter SDK. For more information please visit https://www.aidlab.com/developer

Aidlab Flutter SDK #

Warning: This is an early version and considered unstable. Breaking changes may occur.

Welcome to the official Aidlab Flutter SDK. For more comprehensive information, please refer to our documentation.

Supported Platforms #

  • Android
  • iOS

Configuration #

Android Configuration #

To integrate the SDK with your Android application, perform the following steps:

  1. Set Minimum SDK Version

    Ensure your build.gradle file sets the minimum SDK version to at least 25:

    minSdkVersion 25
    
  2. Update Manifest for Bluetooth Communication

    Modify your AndroidManifest.xml to include necessary permissions and features for Bluetooth communication:

    <uses-permission android:name="android.permission.BLUETOOTH"/>
    <uses-permission android:name="android.permission.BLUETOOTH_ADMIN"/>
    <uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION"/>
    <uses-feature android:name="android.hardware.bluetooth_le" android:required="true"/>
    

Usage #

Warning: To connect with Aidlab, location permissions must be granted, and Bluetooth must be enabled. This package does not manage permissions or Bluetooth status checks.

Connecting to Aidlab #

  1. Enable Bluetooth

    Before attempting to connect, ensure Bluetooth is enabled on the device.

  2. Scan for Devices

    Begin scanning for devices using the following code snippet:

    // sdkDelegate implements AildabSdkDelegate
    AidlabSdk.instance.aidlabSdkDelegate = sdkDelegate;
    AidlabSdk.instance.scanForDevices();
    
  3. Connect to Aidlab

    When an Aidlab device is detected, the onAidlabDetected function will be triggered. Connect to the device by specifying the desired signals:

    @Override
    void onAidlabDetected(String address, int rssi) {
        final List<Signal> signals = [
            Signal.Ecg,
            Signal.HeartRate,
        ];
    	    
        // aidlabDelegate implements AidlabDelegate
        AidlabSdk.instance.connect(address, signals, aidlabDelegate);
    }
    
4
likes
0
pub points
15%
popularity

Publisher

unverified uploader

Aidlab Flutter SDK. For more information please visit https://www.aidlab.com/developer

Homepage

License

unknown (license)

Dependencies

flutter

More

Packages that depend on aidlab_sdk