#OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

97
OpenAPS the open source artificial pancreas system + DIY Diabetes Mark Wilson mark@warkmilson.com

Transcript of #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Page 1: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

OpenAPSthe open source artificial pancreas system

+DIY Diabetes

Mark [email protected]

Page 2: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY
Page 3: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Youneverleavethecar

Page 4: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Learn to use this really well,

and sometimes you get tofocus on this.

Your permanent reality:

Page 5: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

It’s up to youhow often you check the speedometerhow often you make adjustmentswhether you drive on dangerous roads

how you drive

Page 6: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY
Page 7: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

I’m doing my bestto drive this car

What could this car be doingto make my drive easier?

Page 8: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY
Page 9: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

I don’t know how to hotwire a carI don’t have time to learn to hotwire a car

I don’t want to damage my car

Page 10: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Why OpenAPS

What it’s like to use OpenAPS

What OpenAPS is for

What DIY Diabetes is for

Page 11: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Why OpenAPS

What it’s like to use OpenAPS

What OpenAPS is for

What DIY Diabetes is for

Page 12: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Feedback loop

Reality Ideal

Page 13: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

nah, not for me

Nightscout + Dexcom Nightscout + Medtronic

Page 14: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Feedback loop

Reality Ideal

Page 15: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY
Page 16: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Nightscout for Medtronicusing RileyLink

https://github.com/ps2/rileylink

Page 17: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Feedback loop

Reality Ideal

Page 18: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

graph of last 3 hours

insulin on board

https://github.com/mddub/nightscout-osx-menubarhttps://github.com/mddub/urchin-cgm

Page 19: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Feedback loop

Reality Ideal

Page 20: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

OpenAPS

nah, not for me

Page 21: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY
Page 22: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Feedback loop

Reality Ideal

Me

Page 23: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Feedback loop

Reality Ideal

Me

Page 24: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

loop (v):to use a closed feedback loop artificial pancreas

CareLink USB stick

USB battery packRaspberry Pi

portable computer

Dexcom CGM receiver

Page 25: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Why OpenAPS

What it’s like to use OpenAPS

What OpenAPS is for

What DIY Diabetes is for

Page 26: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

CGM distribution by week

Dexcom + Nightscout OpenAPS

MiniMed Enlite sensor

Page 27: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

CGM distribution by week

Dexcom + Nightscout OpenAPS

MiniMed Enlite sensor

Page 28: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

CGM distribution by week

Dexcom + Nightscout OpenAPS

MiniMed Enlite sensor

Page 29: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Overnight CGM distribution by week(02:00-08:00 only)

Dexcom + Nightscout OpenAPS

MiniMed Enlite sensor

Page 30: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

CGM distribution by hour

(94 days)

Dexcom + Nightscout

Dexcom + Nightscout +OpenAPS

(138 days)

Page 31: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Waking up

Page 32: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

I woke up one morning, and I was like,“How do I feel today? What’s my day going to be like?”instead of,“What’s my blood sugar and how can I correct that?”

—Sara Krugman

Page 33: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Making decisionsBG: 65 mg/dL

Rate of change: -3 mg/dL/5min

Deceleration: +0.5 mg/dL/(5min)2

Insulin on board: 0.3 units

Q: How many carbs right now to land at 90 - 110 in 1.5 hours?

Page 34: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Making decisionsBG: 65 mg/dL

Rate of change: -3 mg/dL/5min

Deceleration: +0.5 mg/dL/(5min)2

Insulin on board: 0.3 units

Q: How many carbs right now to land at 90 - 110 in 1.5 hours?

A: Trick question, it’s f*&#ing impossible

I err on the side of over-correcting, and let OpenAPS blunt the spike

Page 35: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Lower highs

Higher lows

Page 36: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Building OpenAPS

• Here’s some instructions• They may not be complete• Here’s how to contribute to the instructions• You may have issues• Here’s how to contribute your fixes

Page 37: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

“You’re spending so much more time on your diabetes than you ever were before.”

Time spent managing diabetes

Page 38: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

“You’re spending so much more time on your diabetes than you ever were before.”

Time spent managing diabetes

Time spent troubleshooting hardware & software

Time spent making diabetes decisions

Page 39: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

“You’re spending so much more time on your diabetes than you ever were before.”

Time spent managing diabetes

Time spent troubleshooting hardware & software

Time spent making diabetes decisions

Page 40: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Building OpenAPS

• Now it’s a few moments of monitoring per day

• You learn how it works and how it can fail …just like your pump and CGM

Page 41: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Trusting OpenAPS

Safety is built into the design of the dosing algorithm.• Temporary basal rates, not boluses• Conservative limits• Conservative adjustments• Adjustments match what a human would do

It’s open source.“Given enough eyeballs, all bugs are shallow.”

Page 42: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Contributors to OpenAPS documentation

May 2015 Aug 2015 Nov 2015 Feb 2016 May 20160

10

20

30

40

Source: GitHub

Page 43: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Credit: Chris Hannemann / Dana Lewis

OpenAPS users

Sep 2014 Dec 2014 Mar 2015 Jun 2015 Sep 2015 Dec 2015 Mar 2016 Jun 20160

10

20

30

40

50

60

70

80

90

# of

Loo

pers

Page 44: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Why OpenAPS

What it’s like to use OpenAPS

What OpenAPS is for

What DIY Diabetes is for

Page 45: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

This is a Fitbit scale

• Costs over $100• Proven less accurate than other scales• Yet tens of thousands sold, because it has Wi-Fi

Page 46: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Fitbit data flowDevice

Wi-FiCloud

Open APIInterfaces/

Applications

novel applications unforeseen by the

device maker

Page 47: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Fitbit data flowDevice

Wi-FiCloud

Open APIInterfaces/

Applications

Page 48: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Fitbit data flowDevice

Wi-FiCloud

Open APIInterfaces/

Applications

…an application which Fitbit knows it won’t think of which Fitbit will not

invest in which adds value to

Fitbit’s platform

Page 49: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Fitbit data flowDevice

Wi-FiCloud

Open APIInterfaces/

Applications

Page 50: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Diabetes data flowDevice

Wi-FiCloud

Open APIInterfaces/

Applications

Private protocols

Device “Reader”Private

protocols

Phone/Computer

Cloud

PrivateAPIs

PrivateAPIs

Vendor-Approved

Apps

Page 51: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Private protocols

Device “Reader”Private

protocols

Phone/Computer

Cloud

PrivateAPIs

PrivateAPIs

Vendor-Approved

Apps

Page 52: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

OpenAPS actually isn’t an artificial pancreas.

OpenAPS is an open platform which enables you to build one.

Page 53: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Private protocols

Device “Reader”Private

protocols

Phone/Computer

Cloud

PrivateAPIs

PrivateAPIs

Vendor-Approved

Apps

Page 54: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Private protocols

Device “Reader” Phone/Computer

OpenAPS

Cloud

PrivateAPIs

PrivateAPIs

Vendor-Approved

Apps

Page 55: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

“Reader”Private

protocols

Device Phone/Computer

OpenAPS

Page 56: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

“Reader”

OpenAPS options: hardware

Private protocols

Device Phone/Computer

Intel EdisonRaspberry Pi RileyLink tinyAP

OpenAPS

?

Page 57: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Private protocols

Device Phone/Computer

OpenAPS

Dosing code“Reader”

OpenAPS options: dosing algorithm

Page 58: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

OpenAPS options: dosing algorithm

Private protocols

Device Phone/Computer

OpenAPS

Dosing code“Reader”

openaps-doseoref0 simPancreas tinyAP

Page 59: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Private protocols

Device Phone/Computer

OpenAPS

PWD“Reader”

OpenAPS options: interface

Page 60: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

OpenAPS options: interface

openaps-monitorNightscout LoopKit

Private protocols

Device Phone/Computer

OpenAPS

PWD

Urchin

“Reader”

Page 61: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

OpenAPSserves many different needs

in many different ways.

Page 62: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

DIY Diabetesserves many different needs

in many different ways.

Page 63: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Why OpenAPS

What it’s like to use OpenAPS

What OpenAPS is for

What DIY Diabetes is for

Page 64: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Private protocols

Device “Reader”Private

protocols

Phone/Computer

Cloud

PrivateAPIs

PrivateAPIs

Vendor-Approved

Apps

Page 65: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

DIY Diabetes: opening device data

Private protocols

Device “Reader”Private

protocols

Phone/Computer

Cloud

PrivateAPIs

PrivateAPIs

Vendor-Approved

Apps

Page 66: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Nightscout

Page 67: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Freestyle Libre

Page 68: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Freestyle Libre

Page 69: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Freestyle Libre + Glimp app

http://www.deebee.it/?p=1411

Upload data to the cloud instantly without wires

Page 70: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Freestyle Libre + LimiTTer

http://joernl.github.io/LimiTTer/

Turn the Libre into a CGM

Page 71: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

DIY Diabetes: opening device data

Private protocols

Device “Reader”Private

protocols

Phone/Computer

Cloud

PrivateAPIs

PrivateAPIs

Vendor-Approved

Apps

Page 72: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

DIY Diabetes: novel interfaces

Private protocols

Device “Reader”Private

protocols

Phone/Computer

Page 73: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Pump push notifications

Kid bolusesat school

Parent receives push notification

https://github.com/nightscout/cgm-remote-monitor

4:05 PMBolus: 3.0 UCarbs: 24 g

Page 74: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

LoopKit

https://github.com/loudnate/LoopKit

Page 75: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Temporary targets

https://github.com/nightscout/cgm-remote-monitor

Page 76: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Urchin

UnopinionatedRidiculouslyConfigurableHuman Interface toNightscout

https://github.com/mddub/urchin-cgm

Page 77: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

DIY Diabetes: novel interfaces

Private protocols

Device “Reader”Private

protocols

Phone/Computer

Page 78: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Diabetes is already DIY.

Page 79: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Why OpenAPS

What it’s like to use OpenAPS

What OpenAPS is for

What DIY Diabetes is for

…Why?

Page 80: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY
Page 81: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY
Page 82: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

I don’t know how to hotwire a carI don’t have time to learn to hotwire a car

I don’t want to damage my car

Page 83: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

I don’t know how to hotwire a carI don’t have time to learn to hotwire a car

I don’t want to damage my car

Page 84: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

I don’t know how to hotwire a carI don’t have time to learn to hotwire a car

I don’t want to damage my car

It would transform the way I drive.

Page 85: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Of course you hotwire the car.

Page 86: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

It’s not about the car.

It’s about the drive.

Page 87: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Misconception

“DIY Diabetes”“Diabetes”

Page 88: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY
Page 89: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

It’s not about the car.

It’s about the drive.

Page 90: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY
Page 91: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

It’s not about the car.

It’s about the drive.

Page 92: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY
Page 93: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY
Page 94: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

Authorized

access ?

Page 95: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY
Page 96: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY
Page 97: #OpenAPS and the DRIVE to DIY DIABETES TECHNOLOGY

#WeAreNotWaiting