Help Developing Sugarmate and/or Dexcom G6 Reading App

Is there anyway to get Tidbyt to work with the Sugarmate Type1 Diabetes app? I feel like it should be a relatively simple lift from there, but I’m also not a programmer. Would be nice to have that data on the Tidbyt for simple, large format monitoring when in bed at night with just the glucose number and a colored glucose level trend arrow (up, down, diagonal up, diagonal down, straight right.) I wear glasses so I can’t read the level on my phone without them on which mean fully waking up to put them on and check my phone. For those who don’t know, Type1 Diabetes requires 24/7 monitoring to essentially prevent seizures or comas based on low or high sugar levels so parents of kids with it don’t get much sleep! Would be a game changer for monitoring sugar levels at night, even if it was just a simple (or cool scaling) color scheme- green they’re in a good rang (75 - 149); Yellow they’re 150 - 199; Orange they’re 200 - 249; Amber they’re 250 - 299; Blinking Red they’re above 300. Rapid Blinking Blue they’re 74 or below.
Whoever can help me develop this for the Tidbyt, I’d be happy to make a donation to the Juvenile Diabetes Research Foundation in your name. Nightscout is far too complicated to setup. I see so much more utility for the Tidbyt via direct broadcast of what’s on your phone of simple apps like Sugarmate, but most of the apps on the Tidbyt are gimmicky. I bought it to figure out a way, but I’m out of my league. Many thanks in advance.

2 Likes

The sugarmate software seems pretty closed. I don’t see anything about an api that could be used although there is a web app for windows people. The tidbyt doesn’t have firmware that allows it to transfer data over bluetooth so going directly from the phone to tidbyt won’t work. If there was some sort of webhook functionality in sugarmate that might make it work.

1 Like

Thank you for looking at it Tavis!

I can’t speak for Sugarmate, but I know Dexcom has an API. I’m evaluating their docs to see if a Tidbyt app would be feasible. Will post progress updates here!

1 Like

You’re awesome Gabe, thank you! We do have the Dexcom app, so that gives me hope. Keep me posted.

Unfortunately, I have some bad news. I created an initial integration using the Dexcom API and realized it’s only a retrospective API and has a 3-hour delay.

There’s an unofficial API used by Home Assistant in GitHub - gagebenne/pydexcom: A simple Python API to interact with Dexcom Share service which is realtime, but it would require users to enter their username and password. That would not be secure, and I imagine a PR would not be accepted by the Tidbyt team. :confused: I’ll see if that API requires creating a separate read-only Dexcom Share user. If so, then it would maybe be acceptable.

Grr, from that repo:

  1. Note: the service requires setup of at least one follower to enable the share service, but pydexcom will use your credentials, not the follower’s.

This may not be doable in a secure way.

I know you mentioned not wanting to set up a Nightscout server, but that may be your best bet. There are some pretty helpful guides out there, and Nightscout can be set up to scrape data from Dexcom directly.

I’ll let you know if I come across anything else!

1 Like

There’s a fully functioning Nightscout app live in the app store. Just search for “nightscout” in the mobile app.

There is another way to pull data in realish time thats used by a smaller led display esp32 device (SugarPixel by CustomTypeOne) and since the code is open source… wonder if it could be used to port it into this displays ecosystem… the three hour thing in the API is purportedly due to FDA… but there is a way to pull data using Dexcom Share (by the app)… Know I dont have the programming experience but there is purportedly code out there for the SugarPixel …

I’m not finding the source code anywhere, but the device most likely still requires the username/password of the user.

1 Like