Android API v1.3 [2014-12-29]

edited December 2014 in Android
Version 1.3 of the Android API is released, adding support for connecting to multiple MetaWear boards, and new features and bug fixes for the temperature, gpio, haptic classes.  

Features

  • Support to communicate with multiple MetaWear boards
  • Thermistor mode for the temperature module
  • GPIO pin state notifications
  • Callback function to notify the user of GATT errors
  • Fixed bug that would falsely report non-existent ble device is connected on Android 4.4 devices
  • Fixed bug with the buzzer code

Known Issues

  • BluetoothGatt is not properly freed when the board disconnects on its own (i.e. out of range, pulled power etc.).  This results in the gatt callbacks being called multiple times if you discard the internal state [with MetaWearController.setRetainState(false)] and reconnect to the board.
    • Work around is to either opt to retain the internal state, or use the same MetaWearController reference to close or reconnect to the board instead of retrieving a new controller form MetaWearBleService.getMetaWearController(BluetoothDevice)

Adding multiple MetaWear support required making some changes to the API.  A blog post about the changes is on our project's page (http://projects.mbientlab.com/?p=551) and full release notes and compiled jar file are are on the Android API releases page (https://github.com/mbientlab/Metawear-AndroidAPI/releases/tag/1.3.3).

While testing the multiple MetaWear code, I was only able to maintain one connection at a time on a 2013 Nexus 7 (Android 4.3), three connections on a Moto G (Android 4.4.4), and four connections on a Nexus 5 (Android 4.4.4).  


----- EDIT -----
I've pushed out a bug fix for the gatt callback issue in v1.3 and a bug with the deprecated connect and reconnect functions.  Full release notes and compiled jar are on the Android API releases page https://github.com/mbientlab/Metawear-AndroidAPI/releases/tag/1.3.4

Comments

  • edited December 2014
    Hi Eric,

    Thanks for your hard work!

    Is there any code or working app based on 1.3.4 api I can look at to see how to use reconnect?

    thanks and happy new year :)

    bio.
  • I'm in the middle of overhauling the app to use the new API.
This discussion has been closed.