Freestyle Libre Android App

maglil55

Expert
Messages
6,535
Type of diabetes
Type 2
Treatment type
Tablets (oral)
I am an App user with the Freestyle Libre. I am in the process of changing mobiles (both Samsung) and have setup and transferred my apps to the new Smartphone.
The Libre App transferred with smartswitch but the data didn t go with it. I expected it to be simply sign into my account and the data would appear. It didn't!
I've tried uninstalling and reinstalling - didn't work either. I've gone back to my previous handset for now , signed back into my account and the data was still there so I'm using that handset for now.
Does anyone know how to get the data to appear on the new handset?
 

LooperCat

Expert
Messages
5,223
Type of diabetes
Type 1
Treatment type
Other
If it’s the same as the iPhone app, it won’t. It’ll all be on your LibreLink account on a computer, but their (very basic, imo) app doesn’t import old data.
 

barrym

Well-Known Member
Messages
803
Type of diabetes
LADA
Treatment type
Insulin
How are you with Android development tools?
I used to pull the data from mine to mess with the mysql database underneath the hood. But just extracting from the old and pushing it to the new should do it. I've not done it so you take the risk!
Here's my notes:
>>>
Install adb on your PC and connect old phone

# backup single app

adb backup [-apk] com.librelink.app # -apk will backup the app too

# on the new phone restore database

adb restore com.librelink.app

Good luck.
 

maglil55

Expert
Messages
6,535
Type of diabetes
Type 2
Treatment type
Tablets (oral)
How are you with Android development tools?
I used to pull the data from mine to mess with the mysql database underneath the hood. But just extracting from the old and pushing it to the new should do it. I've not done it so you take the risk!
Here's my notes:
>>>
Install adb on your PC and connect old phone

# backup single app

adb backup [-apk] com.librelink.app # -apk will backup the app too

# on the new phone restore database

adb restore com.librelink.app

Good luck.
Not worked. I downloaded the adb zip files to my PC and extracted them to c:\adb.
Enabled developer mode on my old phone and set USB debugging to On and USB configuration to MTP.
From c:\adb I opened PowerShell (I use Windows 10) and that's where it stops. Doesn't recognise any of the commands. I've raked through the help suggestions but no luck yet.
Had to stop for now to cook!
PS I did copy a backup to Excel before I started just in case.
Current sensor ends tonight.
 

barrym

Well-Known Member
Messages
803
Type of diabetes
LADA
Treatment type
Insulin
Hmm, I haven't used windows for years now but I'd expect something silly like cable or similarly basic.

The data will obviously remain on the phone despite the sensor expiring.

Suggest checking Google for help in setting up adb.
 

maglil55

Expert
Messages
6,535
Type of diabetes
Type 2
Treatment type
Tablets (oral)
Hmm, I haven't used windows for years now but I'd expect something silly like cable or similarly basic.

The data will obviously remain on the phone despite the sensor expiring.

Suggest checking Google for help in setting up adb.
I think it's Windows 10 that's the issue. I've started the new sensor on the new Smartphone and yes the data is still on the old phone plus the backup on the PC.
 

barrym

Well-Known Member
Messages
803
Type of diabetes
LADA
Treatment type
Insulin
Are you uploading to libreview? The data from both phones is consolidated there. Likewise if you register on Diasend, both phones data will be sucked up.
 
  • Like
Reactions: maglil55

maglil55

Expert
Messages
6,535
Type of diabetes
Type 2
Treatment type
Tablets (oral)
Are you uploading to libreview? The data from both phones is consolidated there. Likewise if you register on Diasend, both phones data will be sucked up.
Yes. I did upload to LibreView and yes both phones data is there.
Got a reply from Abbott today and not surprisingly they said you cannot transfer the data from one Smartphone to another so no reports on the Smartphone until the data builds up again. Only reports for now are from LibreView which does have the combined data. As I mentioned yesterday I also have a backup on Excel.
Must admit I hoped it would have just been a case of logging into LibreLink on the new phone but no such luck. Ah well, such is life. LibreView it will be for a while then.
 

maglil55

Expert
Messages
6,535
Type of diabetes
Type 2
Treatment type
Tablets (oral)
Are you uploading to libreview? The data from both phones is consolidated there. Likewise if you register on Diasend, both phones data will be sucked up.
I've installed Diasend now too and as you said that's giving me all the data.
 

barrym

Well-Known Member
Messages
803
Type of diabetes
LADA
Treatment type
Insulin
The app is quite nice too as you can browse along your graph and see each 15 minute reading numerically as you scroll through.
 
Messages
5
Type of diabetes
Type 1
Treatment type
Insulin
Hi Barry,

Sorry to resurrect an old thread but I'm trying to do the same thing!

I'm just in the process of switching from my old S7 to a new S20. I too was amazed and disappointed to say the least when my S20 didn't bring in the history which my S7 had been uploading to LibreView for 2 months! MySugr worked seamlessly and all my data was on my S20.

I've used ADB briefly before so I thought I'd have a go.

I connected my S7 via USB cable and enabled USB debugging in the Developer Options, which I had previously enabled.

I ran Command Prompt (Windows 10) and ran this:

adb backup com.librelink.app

I confirmed the backup was OK to do on my phone and a file was created called backup.ab in the same folder on my PC as ADB. However it's only 47 bytes which seems FAR too small!

I've opened the backup with Notepad++ and this is all that's inside:

ANDROID BACKUP
5
1
none

(next line is a load of control characters)

Does this seem right to you?

I would try restoring to my S20 but I haven't got a USB-C port on my PC so I can't connect it just yet.

Any ideas please? I really don't want to have to lose all the data from my S7 or have to resort to using LibreView!

Thanks
Steven
 
Messages
5
Type of diabetes
Type 1
Treatment type
Insulin
Thanks for the quick reply and suggestion!

I tried that but it's still the same. I'm on Android 8.0.0 on my S7 so maybe that isn't old enough?

Silly question maybe but does my phone need to be rooted for this to work? It's not.

Thanks
Steven
 

barrym

Well-Known Member
Messages
803
Type of diabetes
LADA
Treatment type
Insulin
Thinking about this, I'm wondering if the file name is right. If you run adb shell there is s list package command. Not sure of the syntax, you'll have to check it out. Sorry
 

barrym

Well-Known Member
Messages
803
Type of diabetes
LADA
Treatment type
Insulin
Yep, just checked. File name has changed. I think it was when they switched from the initial software which I think was from a third party to their own (the current) version.

adb backup [-apk] com.freestylelibre.app.gb

Should do the trick. Mine is 17.7mb


We'll get there eventually ;-)
 
  • Like
Reactions: Steven_Rangeley
Messages
5
Type of diabetes
Type 1
Treatment type
Insulin
Hi Barry,

Thanks again. Just tried this and it seems to have worked - the backup file is now 599 KB which seems a LOT better. You must have loads of data on yours!

I wonder why adb didn't give any errors when it couldn't find the other filename?

I assume there's no easy way of viewing the data on a PC without it being just control characters?

Hopefully all I need to do now is order myself some USB-C adaptors and then reinstall the app on my S20 followed by the adb restore command once it's connected to my PC? Obviously I'll make another up-to-date backup just before I do that!

Cheers
Steven
 
Last edited:

barrym

Well-Known Member
Messages
803
Type of diabetes
LADA
Treatment type
Insulin
Try this:

# backup single app

adb backup [-apk] com.freestylelibre.app.gb # -apk will backup the app too

##### first time ########

# If you want to examine backup.ab
sudo apt install default-jre

# download abe.jar then run:

##### end of first time ########

java -jar abe.jar unpack backup.ab backup.tar password
ls
tar -xvf backup.tar

# use SQLite to look at databases

# copy to new phone
#on old phone

./adb backup com.freestylelibre.app.gb

#on new phone install app from play store

./adb restore backup.ab

NB Linux installation notes, windows will be similar.
 

barrym

Well-Known Member
Messages
803
Type of diabetes
LADA
Treatment type
Insulin
Regarding your comment on file size. Within reason everybody's should be approximately the same as it's a rolling 90 days in the app.

When you look in the database you'll see the sophisticated (?) design. Each 15 Mon reading is stored, each scan, and a multiple number of note records, one got each you've created and I think one each for every time you amended one. Make sense?
 
Messages
5
Type of diabetes
Type 1
Treatment type
Insulin
Regarding your comment on file size. Within reason everybody's should be approximately the same as it's a rolling 90 days in the app.

When you look in the database you'll see the sophisticated (?) design. Each 15 Mon reading is stored, each scan, and a multiple number of note records, one got each you've created and I think one each for every time you amended one. Make sense?

Hmm, well I've only got 63 days, I suppose the proof will be in the pudding!

I've downloaded the CSV files from LibreView before so I know there is a type e.g. 1 to 6 depending on the type of entry.