These are chat archives for nightscout/intend-to-bolus

16th
Sep 2015
Ed Raskin
@msrcgm
Sep 16 2015 00:00
Thanks @danamlewis
Scott Leibrand
@scottleibrand
Sep 16 2015 00:09
merged
Nathan Racklyeft
@loudnate
Sep 16 2015 01:10
@bewest yep I used the resin image as the source: https://gist.github.com/loudnate/e70a2a578ec87e2d17f6#file-dockerfile
Ali Mazaheri
@amazaheri
Sep 16 2015 01:15
@msrcgm w00t! Nice :)
Ben West
@bewest
Sep 16 2015 01:16
I tried mine but can't figure out what now
Peter Miller
@ochenmiller
Sep 16 2015 02:03
Looking for a command in openaps or decoding carelink to serve as an equivalent to "ping" for the medtronic 722 pump. Anything built-in that I'm missing?
Scott Leibrand
@scottleibrand
Sep 16 2015 03:20
we usually use something like read_status or read_clock for that
Ben West
@bewest
Sep 16 2015 03:54
model
model
just reads the model number
Ed Raskin
@msrcgm
Sep 16 2015 03:54
Is there a command to safely shut down the pi or do I just unplug it?
Rachel Sandlain
@audiefile
Sep 16 2015 03:56
sudo shutdown -h now
sudo reboot to reboot
Scott Leibrand
@scottleibrand
Sep 16 2015 05:38
and if you're not logged in and can't do sudo shutdown -h now, then safest thing to do is wait until the green light stops blinking (indicating it's writing to the SD card) and then just unplug it.
John Males
@johnmales
Sep 16 2015 11:27
Ok so have a working Pi with wifi, Carelink USB working, able to connect to pump (Medtronic model 554), able to query glucose levels, pump status, date time, able to suspend and restart basal etc. So I'm feeling a bit lost as to the next step in terms of working on making predictions. I presume I have to make some reports and set some default values? Using openaps-js? If you can point me in the right direction I will keep reading and working on it :)
Chris Hannemann
@channemann
Sep 16 2015 15:21
Hey @johnmales; great to hear you've come that far. I'm interested to know what limitations (if any) you've run into with the 554. You can see that the hardware section of our documentation doesn't list that as an option, but it would be excellent if you can prove us wrong!
As far as next steps, you are correct that adding reports is where you'll want to go. I won't be able to help today, but @eszcloud and I worked to set up her reports earlier this week, so perhaps you can catch her online and she can try and bring you up to speed.
We are also working on formalizing and publishing those steps; hope to get them up soon.
Scott Leibrand
@scottleibrand
Sep 16 2015 15:59
Specifically, we've been able to query data from the newer pump models, but we can't send boluses or temp basals without putting the pump into "PC connect" mode, which only lasts 2 minutes and can't (AFAICT) be extended from the Carelink stick.
Ben West
@bewest
Sep 16 2015 19:44
ooooo giddy
Chris Oattes
@cjo20
Sep 16 2015 19:44
hmm, but the remote still allows you to bolus?
Ben West
@bewest
Sep 16 2015 19:45
the bolus ability has nothing to do with remote
and everything to do with the pump's firmware
I've used bolus command on many european pumps
including 554
however in the US, medtronic stripped these commands off all production builds starting with 523
Chris Oattes
@cjo20
Sep 16 2015 19:45
do you know which firmware version they had?
Ben West
@bewest
Sep 16 2015 19:46
it's not clear that the firmware version string has any relation to this
best way I can find is to try tunring the backlight on
using the "button press down" command
export SERIAL=665455; mm-send-comm.py --init sleep 0 mm-press-key.py down
sets serial environment, turns "on" pump, presses the down button
if it works it'll turn on the light
and it means bolus/basal commands will also work
Chris Oattes
@cjo20
Sep 16 2015 19:48
I'm not actually set up to send stuff to the pump atm
Ben West
@bewest
Sep 16 2015 19:48
the other easiest way is just where/when it came from
Chris Oattes
@cjo20
Sep 16 2015 19:48
I need to buy another pi, my current one is currently in use as a DNS / DHCP server
Ben West
@bewest
Sep 16 2015 19:48
if it's a US pump, it does not have basal/bolus
if you got it from italy or some place, it probably does
Chris Oattes
@cjo20
Sep 16 2015 19:49
I'm in the UK
Ben West
@bewest
Sep 16 2015 19:49
oh, beautiful
it probably works
I'm 83% sure ;-)
Chris Oattes
@cjo20
Sep 16 2015 19:50
That's very exact
Ben West
@bewest
Sep 16 2015 19:51
I'm like the pump whisperer
Chris Oattes
@cjo20
Sep 16 2015 19:52
eugh, I can't access the menus on my old pump without finishing the reservoir fill procedure
Ben West
@bewest
Sep 16 2015 19:53
that's true, it prefers having reservoir that can be emptied
it's generally happiest in that state
Chris Oattes
@cjo20
Sep 16 2015 19:54
does the reservoir need anything in it?
Ben West
@bewest
Sep 16 2015 19:54
nope
I often use a pencil to provide just a little bit of pressure during priming
it does look for a bit of resistance up front
just a bit... not enough to block it
just simulate pressing the base of the reservoir
Scott Leibrand
@scottleibrand
Sep 16 2015 19:55
I use my pinky, but it's skinny. :-)
Ben West
@bewest
Sep 16 2015 19:55
then it's fine after that
Chris Oattes
@cjo20
Sep 16 2015 19:56
so, my old pump (2.6A firmware) didn't have the "PC connect" option under "Connect Devices"
The pump I got 2-3 weeks ago (3.1 firmware) does
Scott Leibrand
@scottleibrand
Sep 16 2015 19:56
air filled reservoir doesn't work well. If you use a real one it needs water, which is a pain. Much better to just push on it during prime.
I think they added that about 523 or so.
Pete Schwamb
@ps2
Sep 16 2015 19:57
Hah, I’ve been refilling a reservoir with water; neat tricks.
Chris Oattes
@cjo20
Sep 16 2015 19:58
These are both 554 devices
Ben West
@bewest
Sep 16 2015 19:58
the pc connect menu is bad sign, I think
might have to retract my 82%
Chris Oattes
@cjo20
Sep 16 2015 19:59
yeah, that's what I was just thinking :P
Sulka Haro
@sulkaharo
Sep 16 2015 19:59
Hey anyone here know Medtronic dudes to the point where you could ask if there's a product like the Connect coming for the 640G
Ben West
@bewest
Sep 16 2015 19:59
yeah, connect will work with 640g
I thought it would anyway
was my impression
Scott Leibrand
@scottleibrand
Sep 16 2015 19:59
We can probably confirm at d-data if not before.
Sulka Haro
@sulkaharo
Sep 16 2015 20:00
640G uses 2.4GHz band, Connect has so far been announced for 915 MHz band devices only
I'm sure they'll eventually do a version for 640, but...
Damn wish I could attend these events :)
John Males
@johnmales
Sep 16 2015 20:10
Hey @bewest @cjo20 @channemann @scottleibrand thanks I'll investigate the 554 pump issues a little more in the next day or two. The biggest limitation is keeping the little man still enough to interrogate the pump. I seem to be chasing him around the house with the Pi and a laptop, looking a little crazy. I can confirm that I can suspend and resume basal from openaps. The pump is from 2010, Australia. It definitely came with a remote to allow for bolusing so fingers crossed.
Dana Lewis
@danamlewis
Sep 16 2015 20:12
If it makes you feel any better, sometimes @scottleibrand chases me around the apartment with a Pi. Every time he sets a new one down near me, I have the urge to go somewhere else.
You could try a flip belt or similar to keep the pi/Carelink close enough to the pump if he'd be willing to wear that for a little bit while you're testing things?
John Males
@johnmales
Sep 16 2015 20:14
I will try a belt or similar or grab it off him when he is in the shower. Don't worry the family all know I'm a crazy nerd anyway :)
Scott Leibrand
@scottleibrand
Sep 16 2015 20:14
Ok, if you can suspend and resume you should be able to do everything else too. Let us know when you get comfortable with the openaps use and openaps report commands and want to move on to a loop.sh. You could do your own simple one first, or jump straight to openaps-js...
Heh
John Males
@johnmales
Sep 16 2015 20:16
I have set up a couple of reports and the pump is reporting back in json format. I'll look further into reporting and let you know.
What is the format of the temp basal command in openaps? Is it in percentage of the current basal or is it measured in an absolute way (units/h or similar?)
Scott Leibrand
@scottleibrand
Sep 16 2015 20:20
If you send temp: absolute it's U/hr.
There is a percentage mode but we don't use it, because in that mode you can't extend/change a temp without canceling it first.
Dana Lewis
@danamlewis
Sep 16 2015 20:21
We need to add that to docs somewhere, but not sure where best - everyone asks that one
Scott Leibrand
@scottleibrand
Sep 16 2015 20:21
You should get familiar enough with the reports to guess what reports you need set to up provide its inputs, and see what the outputs would be used for and validate they all look correct for your situation.
John Males
@johnmales
Sep 16 2015 20:23

So, from openaps:

usage: openaps-use pump set_temp_basal [-h] input

Set temporary basal rates.

positional arguments:
input

optional arguments:
-h, --help show this help message and exit

Do you enter U/h followed by time? What is the format?

I'll make some PR on the docs this weekend. Yes I agree @scottleibrand I need to understand the reports better first before going any further.
Chris Oattes
@cjo20
Sep 16 2015 20:25
@bewest trying to use decocare on windows, but it doesn't look like the carelink stick is recognised as a COM port, any suggestions?
Peter Miller
@ochenmiller
Sep 16 2015 20:30
@bewest, thanks for advice on "model" as a ping equivalent. It seems effective as it just returns an empty string if the pump doesn't answer rather than throwing an error.
Scott Leibrand
@scottleibrand
Sep 16 2015 20:34
@amazaheri has done some work to get openaps working on Windows...
@johnmales look at the output json from the "make" command running determine-basal.js tests.
Only three of those fields are mandatory: temp: absolute, rate, and duration.
Ali Mazaheri
@amazaheri
Sep 16 2015 20:39
@cjo20 you need to look at libusb-1.0.19.tar
as @scottleibrand mentioned I have it up and running and currently testing, had to made changes to @bewest OpenAPS, decoding-carelink
I am working with @bewest to finalize it and potentially create a new branch for Windows
Chris Oattes
@cjo20
Sep 16 2015 20:46
ah, ok
hmm, I think my rpi is sick.
Ben West
@bewest
Sep 16 2015 20:59
I'm hopeful we can just integrate
Dana Lewis
@danamlewis
Sep 16 2015 21:21
FYI if anyone wants to better document how to do questions, this might be a good place to do it: https://openaps.gitbooks.io/building-an-open-artificial-pancreas-system/content/docs/Overview/contribute.html (this is the gitbook view but you can click to the related page in openaps/docs, fork a copy to your own repo, make changes, and then PR back to openaps/docs to get reviews on your suggested changes)
Rachel Sandlain
@audiefile
Sep 16 2015 21:50
@johnmales not sure if you've seen this: https://github.com/bewest/openaps-example It helped me learn what the different commands were expecting
John Males
@johnmales
Sep 16 2015 22:08
@audiefile no I hadn't, that looks like what I need to wrap my head around the next step. Thanks.
Scott Leibrand
@scottleibrand
Sep 16 2015 22:41
:+1:
eszcloud
@eszcloud
Sep 16 2015 23:40
@johnmales I'm happy to share all the knowledge that @channemann shared!