- Android platform tools for your OS (for
adb, to be installed in$PATHortools/) - Android Backup Extractor https://sourceforge.net/projects/adbextractor/ (
abe.jar) - Rename
abe.shintools/toabe, installabe.jarnext to it - Install
sqlite3, required to dump the database - Install
ruby, needed to convert date/time representations in an OS-independent way
-
Connect your data collector smartphone
-
Run
adb devicesto verify you've got access; confirm on Android device if necessary -
Apparently, opening the LibreLink app in the foreground may keep it from being stopped.
-
Run
db-from-appto backup thecom.freestylelibre.app.dedata, decompress and unpack the tree containing the database - intermediate files are removed on success -
VERY IMPORTANT: RESTART THE LIBRELINK APP TO AVOID DATA LOSS if it's no longer running!
-
Run
db-to-dumpto extract sensor serials and glucose readings from the database -
Create
.settings(using the template) with your Nightscout server data and credentials -
Run
query-last-sensorto get the last "Sensor Change" treatment known to Nightscout -
Run
query-last-sgvto get the timestamp of the last sgv reading submitted to Nightscout -
Run
dump-to-sensors-jsonto convert the sensor list into an uploadable json file, selecting only events newer than the already known ones -
Run
dump-to-sgv-jsonto convert both the 15-minute and manual-scan readings into an uploadable json file, selecting only events newer than the already known ones (there are no 1-minute readings if no bluetooth connection has been established!) -
Use
json-uploadto upload the (non-empty only) result files to Nightscout; logs are kept in logs/ -
Archive: create a tarball in
SAVE/oftmp/,data/andlog/ -
Clean up: remove whole
tmp/subtree, possibly do the same withdata/ -
This can also be done by running
make allafter connecting your smartphone.
- Run
make serial. This will backup the database, fetch the latest sensor records from Nightscout, upload the yet unknown ones, and finally clean up.
- The database storing the glucose values,
sas.db, grows by about 10MB per month, or 5MB per sensor lifetime. Each (uncompressed) tarball will have about the same size!
- MacOSX 10.11.6, HomeBrew, Ruby 2.3.1