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

24th
Sep 2015
Ben West
@bewest
Sep 24 2015 00:07
just fixed a bug that may help some
I discovered that reports should close the serial port so that multiple handles don't grab it
Chris Oattes
@cjo20
Sep 24 2015 00:10
my RPi should be here tomorrow, so I'll have a look at openaps code tomorrow :D
Dana Lewis
@danamlewis
Sep 24 2015 00:11
@cjo20 woot!
Chris Oattes
@cjo20
Sep 24 2015 00:25
I've looked through the ebook, is there anything else I should read?
all the example "output" from the commands
Dana Lewis
@danamlewis
Sep 24 2015 00:27
That's the best place to start for sure, not sure if my getting started emails in openaps-dev are any more helpful than that (I don't think they are). @msrcgm, anything else that was helpful to you from the start other than the ever-evolving docs? Otherwise @cjo20 poking around the openaps repos is good just to start warming up your eyeballs to them.
Ben West
@bewest
Sep 24 2015 00:28
the core toolkit is in python, but is mostly calling out to shell to run node/bash/python tools, it does know how to import python based plugins as well
Dana Lewis
@danamlewis
Sep 24 2015 00:29
ah. and if you're not familiar with basic linux, a linux tutorial (there's some l inked in the resources section of the docs) is helpful also to warm up your brain to it.
Ben West
@bewest
Sep 24 2015 00:29
most of the commands make modifications to openaps.ini and track everything in git
those then open up new menus to do something new with the thing that was recorded earlier
Chris Oattes
@cjo20
Sep 24 2015 00:30
I've been using linux for over a decade, so that should be ok :)
Dana Lewis
@danamlewis
Sep 24 2015 00:30
@cjo20 :) cool
Ben West
@bewest
Sep 24 2015 00:30
if you're familiar with git you'll feel right at home with the tab completion and commands
Chris Oattes
@cjo20
Sep 24 2015 00:30
in fact, if you count a raspberry pi too, there are more linux machines than windows ones in the house at the moment
There seems to be a display issue with part of the documentation btw
Dana Lewis
@danamlewis
Sep 24 2015 00:33
is that with < ?
@channemann I think fixed it in his version, but not sure if it was the same issue in the main docs and if it auto-fixed or not
Dana Lewis
@danamlewis
Sep 24 2015 00:34
yep, same thing
Ben West
@bewest
Sep 24 2015 00:34
yeah, it looks like html
Dana Lewis
@danamlewis
Sep 24 2015 00:34
@channemann , what did you do to fix it in yours, or do we just need to refresh the gitbook? @bewest ideas?
Ben West
@bewest
Sep 24 2015 00:34
recommend $foo over <
Dana Lewis
@danamlewis
Sep 24 2015 00:35
hrm, to a layman that $ seems like it should be a new command line vs could be part of existing line. <> makes sense to me, but we could just do quotes or something too
Chris Oattes
@cjo20
Sep 24 2015 00:36
or if it is only going to be displayed in html format, <stuff>
&lt;stuff&gt;
Dana Lewis
@danamlewis
Sep 24 2015 00:37
remind me what page is that on? i'll go look at it in markdown
Dana Lewis
@danamlewis
Sep 24 2015 00:38
using, k, one sec
Ben West
@bewest
Sep 24 2015 00:38
http://docs.aws.amazon.com/general/latest/gr/docconventions.html would agree that <foobar> is good convention
Dana Lewis
@danamlewis
Sep 24 2015 00:39
it may be as easy as adding spaces inside the ` that turns it into a code command
tried that. it either didn't work, or requires a few minutes to refresh.
Chris Oattes
@cjo20
Sep 24 2015 00:42
still looks the same on gitbooks to me
Dana Lewis
@danamlewis
Sep 24 2015 00:43
yea. will see if a couple minutes does it
(by the way, it should say <my_pump_name>
Ben West
@bewest
Sep 24 2015 00:44
lot of people name their dexcom recievers?
do people also name their pump?
Dana Lewis
@danamlewis
Sep 24 2015 00:44
supposedly
Ben West
@bewest
Sep 24 2015 00:44
lol
Chris Oattes
@cjo20
Sep 24 2015 00:44
I can see it properly in the git repo
Dana Lewis
@danamlewis
Sep 24 2015 00:45
point is consistency though, so you don't do my-pump-name then mypumpname then pumpitypumpitup then BEN WHY ISN"T IT WORKING!!!! ;)
Chris Oattes
@cjo20
Sep 24 2015 00:45
weird that git displays it correctly and gitbooks doesn't
Dana Lewis
@danamlewis
Sep 24 2015 00:45
@cjo20 that's why i think there might be a lag
I'm not 100% sure how sync-y they are, I had formatting issues in the past
and btw @channemann is the one who put in that named example I think ;)
by the way, @bewest , I've channeled you 2x this week in terms of recommending git repos
@cjo20 remind me where you are in the world?
Chris Oattes
@cjo20
Sep 24 2015 00:48
UK
Dana Lewis
@danamlewis
Sep 24 2015 00:48
k
Chris Oattes
@cjo20
Sep 24 2015 00:48
I should probably avoid being up until 5am again tonight, but I'll be around for a bit longer
Dana Lewis
@danamlewis
Sep 24 2015 00:49
I'm getting on a plane myself in an hour, so will be offline for a few hours after that
Chris Oattes
@cjo20
Sep 24 2015 00:50
going anywhere fun?
Ben West
@bewest
Sep 24 2015 00:50
status says it's currently being updated
Dana Lewis
@danamlewis
Sep 24 2015 00:51
SF! (for 25 hours, and not enough time for openaps get-togethers this time unfortunately, I'm speaking at a MedX event tomorrow). Then Alabama. Then Texas. Back next Wednesday :)
@bewest gitbook status? cool
Chris Oattes
@cjo20
Sep 24 2015 00:53
sounds busy
Chris Oattes
@cjo20
Sep 24 2015 00:57
403
I guess you have to be able to commit to the repo to view it
Ben West
@bewest
Sep 24 2015 00:57
it's worse than that
gitbook has their own permissions inside gitbook also
Chris Oattes
@cjo20
Sep 24 2015 01:21
that page doesn't seem to have changed yet
Ben West
@bewest
Sep 24 2015 01:37
yeah, seems stuck
Chris Hannemann
@channemann
Sep 24 2015 01:38
sorry, not completely caught up here, but re: gitbook update, here is the message they sent me:
"I've published a new version of GitBook (2.4.2) that fixes this issue; and I've updated the default version of gitbook used by gitbook.com; I've also rebuilt your book"
Ben West
@bewest
Sep 24 2015 01:38
ah, nice
Chris Hannemann
@channemann
Sep 24 2015 01:38
By "your book," he means my forked one
Ben West
@bewest
Sep 24 2015 01:38
oh
hahaha
ok
hmm
Chris Hannemann
@channemann
Sep 24 2015 01:39
Because that's the one I sent him to look at
I'll send a note about the main one now, see what needs to be done
Dana Lewis
@danamlewis
Sep 24 2015 01:40
Thx
Ben West
@bewest
Sep 24 2015 01:41
we're on 2.4.2 now
Chris Hannemann
@channemann
Sep 24 2015 01:41
Request sent, will let you know what comes back
Ben West
@bewest
Sep 24 2015 01:42
sounds like they are having some technical difficulties
Chris Hannemann
@channemann
Sep 24 2015 01:48
happens
Chris Oattes
@cjo20
Sep 24 2015 01:50
Thanks
Pete Schwamb
@ps2
Sep 24 2015 02:09
openaps installed on my rPI. Now to start config!
diabeticgonewild
@diabeticgonewild
Sep 24 2015 02:11
I can probably write a good configuration doc, given I'm not too sick. I used to work at geek squad and dealt with people with little experience.
Ben West
@bewest
Sep 24 2015 02:12
that's what I've been up to
Pete Schwamb
@ps2
Sep 24 2015 02:13
I’m going through https://openaps.gitbooks.io/building-an-open-artificial-pancreas-system/content/docs/Using-openaps-Tools/using.html, and seeing that any place it’s looking for user specified content, it just shows whitespace, which is confusing. Is there a better place to read the docs?
Chris Oattes
@cjo20
Sep 24 2015 02:13
@ps2 read up about 5 messages
Pete Schwamb
@ps2
Sep 24 2015 02:14
hah, thx
Pete Schwamb
@ps2
Sep 24 2015 02:19
woohoo, talking to my testpump!
Ben West
@bewest
Sep 24 2015 02:19
btw, the toolkit can handle ruby plugins just fine, as well
it's just like git, it'll call out to your ruby tool if you teach it how
Pete Schwamb
@ps2
Sep 24 2015 02:20
that’s cool. My main goal here is to gain a better understanding of openaps and how it is set up.
And I’m very excited to finally get to use your code Ben!
Scott Leibrand
@scottleibrand
Sep 24 2015 02:25
Woot! :-)
Pete Schwamb
@ps2
Sep 24 2015 02:26
I really should have just ordered a carelink stick a long time ago.
Ben West
@bewest
Sep 24 2015 02:26
:-)
I somehow managed to find a way to break one of my git repos
don't start report names with ./
oh that's sad, it'll ruin my examples
Chris Oattes
@cjo20
Sep 24 2015 02:29
ruin how?
Ben West
@bewest
Sep 24 2015 02:30
usually you can look at git log
and the thing that was done is in the log
like the exact command
but I might have to ruin the work I just did over last hour
haha
aha
fixed it
dropped 3 bad commits and it worked
:heart: git rebase
Chris Oattes
@cjo20
Sep 24 2015 02:33

also, in the guide, it says

To do that, you would normally run two commands each time:
$ openaps report invoke last_four_pump_hours.json
$ openaps report invoke last_four_cgm_hours.json

and then says you can add it to an alias by doing

$ openaps alias add last_four_hours "report invoke last_four_pump_hours.json last_four_cgm_hours.json"

Do you actually have to run the commands seperately on the command line, or does the last argument to alias work? i.e.

$ openaps report invoke last_four_pump_hours.json last_four_cgm_hours.json
Ben West
@bewest
Sep 24 2015 02:35
for alias?
for alias the last term has to be a single "word"
should be same semantics as git alias
Scott Leibrand
@scottleibrand
Sep 24 2015 02:36
He's asking if you can run multiple reports without aliasing them.
Ben West
@bewest
Sep 24 2015 02:36
yes
Chris Oattes
@cjo20
Sep 24 2015 02:36
I mean to invoke the reports
Ben West
@bewest
Sep 24 2015 02:36
openaps report invoke any number of reports
they even tab complete
Chris Oattes
@cjo20
Sep 24 2015 02:36
that's nice of them :D
Ben West
@bewest
Sep 24 2015 02:37
$ openaps alias show
get report invoke monitor/pump-history.json monitor/clock.json monitor/temp-basal-status.json monitor/active-basal-profile.json monitor/reservoir.json monitor/settings.json monitor/status.json monitor/battery.json monitor/bg-targets.json monitor/insulin-sensitivities.json monitor/carb-ratios.json
invoke report invoke
mm-prepare report invoke 01.prepare/mm-cleaned.json 01.prepare/mm-reconciled.json 01.prepare/mm-resolved.json 01.prepare/mm-normalized.json
diyps-predict report invoke 02.diyps/profile.json 02.diyps/iob.json 02.diyps/diyps.json
bewest@hither:~/Documents/foo$
Chris Oattes
@cjo20
Sep 24 2015 02:38
invoke report invoke <- that's cheating :P
Chris Oattes
@cjo20
Sep 24 2015 08:24
@bewest have you considered having the device serial codes in a separate file containing just that, so the main config with the aliases etc. could be put in a public git repo with just the serial number file being put in .gitignore?
Scott Leibrand
@scottleibrand
Sep 24 2015 10:47
:+1: good idea.
Chris Oattes
@cjo20
Sep 24 2015 12:56
hmm, ConfigParser won't make that easy
Scott Leibrand
@scottleibrand
Sep 24 2015 14:07
Have it cat two files into a /tmp/ file for it to actually read?
I assume it doesn't support #include or similar?
Chris Oattes
@cjo20
Sep 24 2015 14:14
it doesn't have #include or similar as far as I can see. The problem is that we write out the config file to update any changes that are made, which overwrites the original. As the serial numbers are stored within devices which are part of the structure, it won't automatically split them back out in to two files
So either the structure of the code would have to change to move the serial numbers out of the section they are in
or there would have to be some juggling done with creating a new config object, adding just the serial numbers to it, writing that out to the serial_config file, and then removing the serial numbers from the base config object before writing that out to openaps.ini
Scott Leibrand
@scottleibrand
Sep 24 2015 14:16
I've also had issues with that overwriting behavior leaving me with no openaps.ini, so I have to keep a backup anyway.
Once you get it all set up the only writes are to update the last init time, which could live in /tmp/ just fine.
Chris Oattes
@cjo20
Sep 24 2015 14:24
the last init time?
Scott Leibrand
@scottleibrand
Sep 24 2015 14:28
It updates the timestamp on the pump device based on the last time it did an init, so it knows not to do another one.
Expires I think it calls it.
Chris Oattes
@cjo20
Sep 24 2015 18:06
Chris Hannemann
@channemann
Sep 24 2015 18:07
:clap:
Dana Lewis
@danamlewis
Sep 24 2015 18:08
:D
Ben West
@bewest
Sep 24 2015 18:22
@cjo20 yeah, that's not a bad idea... early on I wanted KISS, but it would be lovely to teach configparser to deal with several files somehow
or even put it in .git/config ;-)
the .git/config file is same syntax...
Chris Oattes
@cjo20
Sep 24 2015 18:23
@bewest I think it gets fiddly trying to keep specific things in specific files unless the structure changes
Ben West
@bewest
Sep 24 2015 18:23
yes
it is
you'd have to know how to create versions with only selected keys for writables
if it would help people share stuff, we should do it
Chris Oattes
@cjo20
Sep 24 2015 18:27
A fast way of doing it might be to create two new ConfigParser objects, serial_config and everything_else, then iterating over everything set in the main config object, if it is a "serial" it gets added to one config, everything else goes to everything_else, then write those out seperately
Ben West
@bewest
Sep 24 2015 18:31
yeah, seems like lot of effort for such small thing, is it literally looking for serial only or is there are more generic rule that other plugins might need
eg, to upload into Nightscout, we need the api key as well
so maybe vendors can annotate some config parts as private/special somehow?
Chris Oattes
@cjo20
Sep 24 2015 18:40
@bewest http://paste.ubuntu.com/12544806/ in the BolusWizard event it seems to have stripped decimal points from my BG / target BG etc. is that just an output problem?
and I think they'd either have to edit the script that dumps the config files, or there would have to be config files for the config files
Ben West
@bewest
Sep 24 2015 18:41
do your bgs usually have decimal points?
Chris Oattes
@cjo20
Sep 24 2015 18:41
they're in mmol/l
Ben West
@bewest
Sep 24 2015 18:41
oh dear
Chris Oattes
@cjo20
Sep 24 2015 18:41
so yes
Ben West
@bewest
Sep 24 2015 18:42
ok need to figure out how to get mmol out ;-)
is 4.5 actually right?
so maybe just need to know somehow it's mmol instead
Chris Oattes
@cjo20
Sep 24 2015 18:43
BG of 85 should have been 8.5, high target of 65 should have been 6.5, and low target of 45 should have been 4.5
oh, and sensitivity of 18 should have been 1.8
Ben West
@bewest
Sep 24 2015 18:45
weird
ok, so there's an extra bit or something somewhere
that says "divide by 10"
lol
if we find that flag/bit somewhere we can make it output correctly
Chris Oattes
@cjo20
Sep 24 2015 18:47
let me know if there are any commands you want me to run to get that data
Ben West
@bewest
Sep 24 2015 18:48
hmmm
Chris Oattes
@cjo20
Sep 24 2015 18:48
pi@scout ~/cjoAPS $ openaps use purple model
"554"
pi@scout ~/cjoAPS $ openaps use purple suspend_pump
{
  "status": "suspended",
  "recieved": true,
  "enacted_at": "2015-09-24T19:47:41.344629"
Ben West
@bewest
Sep 24 2015 18:48
run settings
did you try mm-press-keys?
Chris Oattes
@cjo20
Sep 24 2015 18:48
no, I didn't
Ben West
@bewest
Sep 24 2015 18:48
mm-press-keys.py -h
try pressing down
mm-press-key.py down
light should turn on
Chris Oattes
@cjo20
Sep 24 2015 18:49
hmm, I don't think I've got decocare installed, or somehwere on the path if it is
Ben West
@bewest
Sep 24 2015 18:49
should be
Chris Oattes
@cjo20
Sep 24 2015 18:52
in a very friendly location /usr/local/lib/python2.7/dist-packages/decocare-0.0.18_dev-py2.7.egg/EGG-INFO/scripts/mm-press-key.py :P Yeah, that works
doesn't work on the pump i'm actually using though
Ben West
@bewest
Sep 24 2015 18:54
ok, bummer
Chris Oattes
@cjo20
Sep 24 2015 18:54
which is a VER 3.1E 1.1 0B 0B
Ben West
@bewest
Sep 24 2015 18:54
no bolus/basal for you either
Chris Oattes
@cjo20
Sep 24 2015 18:55
purple is a 2.6A
Ben West
@bewest
Sep 24 2015 18:57
I want a t-shirt with that
openaps use purple model "554"
Chris Oattes
@cjo20
Sep 24 2015 18:57
why?
Ben West
@bewest
Sep 24 2015 18:57
dunno, I'm geeky that way
I'm really proud of the way I organized disparate things into identical interface via the use command
Chris Oattes
@cjo20
Sep 24 2015 18:59
:)
Ben West
@bewest
Sep 24 2015 19:01
does anyone have issues with dexcom during nighttime?
mine often fails or goes to ??? during night
Chris Oattes
@cjo20
Sep 24 2015 19:10
@bewest trying to run mm-latest and I'm getting raise TypeError(repr(o) + " is not JSON serializable") TypeError: datetime.time(0, 0) is not JSON serializable
it ran ok the first time, but not now it seems
Chris Hannemann
@channemann
Sep 24 2015 19:11
@bewest not in particular, other than compression lows if I roll onto it; are you on day 30+ of a sensor?
Ben West
@bewest
Sep 24 2015 19:11
yeah, day 20
rolling on it a lot seems to aggravate the issue
it's on back of arm, so it's easy to put pressure on it
Chris Oattes
@cjo20
Sep 24 2015 19:20
Anything wrong with this .ini (device excluded)
[report "last_four_pump_hours.json"]
device = purple
hours = 4.0
use = iter_pump_hours
reporter = JSON

[report "last_100_glucose.json"]
device = purple
count = 100
use = iter_glucose
reporter = JSON

[alias]
recent_data = report invoke last_four_pump_hours.json last_100_glucose.json
Ben West
@bewest
Sep 24 2015 19:27
looks ok
hours = 4 maybe
it might be that your stick got stuck or something
if you run python -m decocare.stick $(python -m decocare.scan) it should run fine
and print lots of junk with some counters
Chris Oattes
@cjo20
Sep 24 2015 19:28
openaps report invoke last_four_pump_hours.json last_100_glucose.json el
purple://JSON/iter_pump_hours/last_four_pump_hours.json
reporting last_four_pump_hours.json
purple://JSON/iter_glucose/last_100_glucose.json
last_100_glucose.json  raised  /dev/serial/by-id/usb-0a21_8001-if00-port0 already in use
Ben West
@bewest
Sep 24 2015 19:29
ooOooo
yes
Chris Oattes
@cjo20
Sep 24 2015 19:29
that 'el' isn't there, it's just PuTTY being weird
Ben West
@bewest
Sep 24 2015 19:29
you must have installed yesterday to dev before I fixed it
Chris Oattes
@cjo20
Sep 24 2015 19:30
I installed using easy_install -ZU openaps about 2 hours ago
Ben West
@bewest
Sep 24 2015 19:30
oh
uh
hmm
I added some patches to dev today/yesterday to look closer at that kind of issue
the version in dev branch closes the stick between each run
Chris Oattes
@cjo20
Sep 24 2015 19:31
how do I use stuff from git rather than easy_install?
Ben West
@bewest
Sep 24 2015 19:31
hold on, need a magic url
it'll be easy_install -ZU openaps==$url#openaps-$version or similar
Ben West
@bewest
Sep 24 2015 19:39
oy, yeah probably
no
that'll get master branch
you want dev branch
but it'll bootstrap the dev chain if you wind up patching ever
Ali Mazaheri
@amazaheri
Sep 24 2015 20:22
Nice!
From Mongo in case you have issues like I do now
"This free Sandbox database is currently experiencing slowness that is resulting in the database not being accessible through the MongoLab portal. We are working to address this slowness, but the server process is still available and should be responding to queries. We have created a public status event regarding this issue: http://status.mongolab.com/
Sandbox databases are multi-tenanted server processes, which means they can be affected by the activity of other users on the Shared resource. For this reason, these databases should be used mainly for testing and development purposes.
We understand the importance of blood-glucose monitoring and strongly recommend you use a Shared Cluster plan. We do not consider our Sandbox plans to have high-availability, and cannot protect against sudden disruptive activity of other users in the Shared Sandbox environment. While Shared Clusters are still in a shared environment, they offer better isolation from other users. More information about this plan can be found here: https://mongolab.com/plans/
"
Jason Calabrese
@jasoncalabrese
Sep 24 2015 20:30
I've been running my own mongo at digital ocean
Since the beginning
Can't depend on free
Ali Mazaheri
@amazaheri
Sep 24 2015 20:31
yeah
good lessons learned
building my own as well
Ben West
@bewest
Sep 24 2015 20:33
$ openaps device add curl process bash -c \"curl -s bewest.labs.diabetes.watch/api/v1/entries.json \| json -e \'this.glucose = this.sgv\'\"
this converts nightscout feed into openaps style glucose :-)
Ali Mazaheri
@amazaheri
Sep 24 2015 20:33
nice
added to my instance he he
score!
Ben West
@bewest
Sep 24 2015 20:35
openaps use --format text curl shell fetches ;-)
can use it to generate reports, etc...
Ali Mazaheri
@amazaheri
Sep 24 2015 20:36
is latest version .6 still?
Ben West
@bewest
Sep 24 2015 20:36
it's really easy to make new "uses/devices" this way, put what you want in a shell/batch script to make it easier
yes
Ali Mazaheri
@amazaheri
Sep 24 2015 20:36
see u force me to login to PI during work
damn itg!
Ben West
@bewest
Sep 24 2015 20:37
so lot of what is in loop.sh should be in eg validate-foobar.sh and added as device
can do all kinds of fun things with json tool and mv/rm etc
use subdirectories to keep it all separate/organized
Ali Mazaheri
@amazaheri
Sep 24 2015 20:39
groovy
be back later today
Ben West
@bewest
Sep 24 2015 21:01
nice
I now have single alias, gather-and-predict that runs naive steps
Dana Lewis
@danamlewis
Sep 24 2015 21:02
@bewest You are on fire today :)
Ben West
@bewest
Sep 24 2015 21:03
bewest@hither:~/Documents/foo$ openaps gather-and-predict 
curl://text/shell/monitor/glucose.json
reporting monitor/glucose.json
pump://JSON/read_clock/monitor/clock.json
reporting monitor/clock.json
pump://JSON/iter_pump/monitor/pump-history.json
reporting monitor/pump-history.json
pump://JSON/read_selected_basal_profile/monitor/active-basal-profile.json
reporting monitor/active-basal-profile.json
pump://JSON/reservoir/monitor/reservoir.json
reporting monitor/reservoir.json
pump://JSON/settings/monitor/settings.json
reporting monitor/settings.json
pump://JSON/read_status/monitor/status.json
reporting monitor/status.json
pump://JSON/read_battery_status/monitor/battery.json
reporting monitor/battery.json
pump://JSON/read_bg_targets/monitor/bg-targets.json
reporting monitor/bg-targets.json
pump://JSON/read_insulin_sensitivies/monitor/insulin-sensitivities.json
reporting monitor/insulin-sensitivities.json
pump://JSON/read_carb_ratios/monitor/carb-ratios.json
reporting monitor/carb-ratios.json
pump://JSON/read_temp_basal/monitor/temp-basal-status.json
reporting monitor/temp-basal-status.json
munge://JSON/clean/01.prepare/mm-cleaned.json
reporting 01.prepare/mm-cleaned.json
munge://JSON/reconcile/01.prepare/mm-reconciled.json
reporting 01.prepare/mm-reconciled.json
munge://JSON/resolve/01.prepare/mm-resolved.json
reporting 01.prepare/mm-resolved.json
munge://JSON/normalize/01.prepare/mm-normalized.json
reporting 01.prepare/mm-normalized.json
get-profile://text/shell/02.diyps/profile.json
reporting 02.diyps/profile.json
calculate-iob://text/shell/02.diyps/iob.json
reporting 02.diyps/iob.json
determine-basal://text/shell/02.diyps/diyps.json
IOB: 0.00, Bolus IOB: 0.00
Avg. Delta: -3.3, BGI: 0.0
15m deviation: -10
BG: 193-3 -> 183-183 (Unadjusted: 193-193)
-3; no temp to cancel
reporting 02.diyps/diyps.json
bewest@hither:~/Documents/foo$
what is the thing that determine-basal wants for current-temps.json
Ben West
@bewest
Sep 24 2015 21:09
was hoping it would suggest some insulin
Scott Leibrand
@scottleibrand
Sep 24 2015 21:22
if it knew about some IOB it would, (at least the dev branch would)
otherwise, if your delta is moving in the right direction, it won't suggest a high-temp
Chris Oattes
@cjo20
Sep 24 2015 21:45
@bewest you've definitely put together a nice framework here
scottleibrand @scottleibrand needs to sit down with Ben and Dana and get our heads around it. Might be useful to install that on our fourth Pi...
Chris Oattes
@cjo20
Sep 24 2015 21:51
fourth? You're getting on for a farm :P
Scott Leibrand
@scottleibrand
Sep 24 2015 21:52
two by the bed, one mobile, and one dev/backup
Chris Oattes
@cjo20
Sep 24 2015 21:52
so what are you using at the moment?
Scott Leibrand
@scottleibrand
Sep 24 2015 21:52
looks like the mobile one just died today, so we'll either need to re-image its SD card or swap it with the fourth one
openaps-js dev branch
Ben West
@bewest
Sep 24 2015 22:08
looks like d-data this year is about interoperability
can't decide if it's ironic or great
wish I had a chance to speak
Dana Lewis
@danamlewis
Sep 24 2015 22:20
Yea have 4 so when i fry one, Scott has one, I still have two for my red-eye flight tonight ;)
@bewest I decided it's good. Will be fun to see fda s official comments there
Ben West
@bewest
Sep 24 2015 22:26
mmm
dunno, I disagree
I prefer they had contacted me to discuss their position...
why am I being subject to surprise?
Dana Lewis
@danamlewis
Sep 24 2015 22:27
Why you and not anyone else? They've got to be public, although I agree a preview would be nice
Ben West
@bewest
Sep 24 2015 22:28
they demanded I go through a rigorous process to get consultation with them
I did that and they offered very little
dunno, we'll see
I expect them to say it's not secure and bunch of other things
feeling cynical I guess
Scott Leibrand
@scottleibrand
Sep 24 2015 22:30
It's appropriate for them to have a rigorous process for consulting with them about issues specific to your own products and other non-public things. If they're trying to push us down that process when we're trying to get public content, I think that's less appropriate than getting them to come to events like D-Data to discuss their thoughts more broadly on topics that affect all of us.
Ben West
@bewest
Sep 24 2015 22:31
yeah, it'll be interesting to see if they treat it as multi-faceted
or if "DIY" just means all DIY
Scott Leibrand
@scottleibrand
Sep 24 2015 22:32
I suspect there will be a lot of "we value the research being done by individuals, but are really concerned about distributing code to others" and stuff like that
Dana Lewis
@danamlewis
Sep 24 2015 22:32
Yep
Ali Mazaheri
@amazaheri
Sep 24 2015 22:33
how about a demonstration and chanting Another brick in the wall verses
Scott Leibrand
@scottleibrand
Sep 24 2015 22:34
troublemaker. :)
Ben West
@bewest
Sep 24 2015 22:34
lol
Ali Mazaheri
@amazaheri
Sep 24 2015 22:34
talk to u guys later tonight chao
Ben West
@bewest
Sep 24 2015 22:34
my head just filled with visions of getting a rousing chorus of brick in the wall going
hahaha
Ali Mazaheri
@amazaheri
Sep 24 2015 22:34
lol
Dana Lewis
@danamlewis
Sep 24 2015 22:34
We always do a demo of our APs ;) but no chanting :p
Ali Mazaheri
@amazaheri
Sep 24 2015 22:35
u got enough Wish You Were Here during your stay with us and in the car
Dana Lewis
@danamlewis
Sep 24 2015 22:36
Scott and Ben both sing, so don't taunt them too much ;)
Ben West
@bewest
Sep 24 2015 22:38
maybe I dose half a unit to see if it'll try to back off with temp basal
Scott Leibrand
@scottleibrand
Sep 24 2015 22:39
it will go bolus snooze on you
Ben West
@bewest
Sep 24 2015 22:39
ah
Scott Leibrand
@scottleibrand
Sep 24 2015 22:39
interesting, but it will be a bit before it temps
Ben West
@bewest
Sep 24 2015 22:40
just wait
I'm on a nice slide down as-is
Scott Leibrand
@scottleibrand
Sep 24 2015 22:40
ya, do whatever you'd normally do
Ben West
@bewest
Sep 24 2015 22:40
normally I make the computer do stuff
Scott Leibrand
@scottleibrand
Sep 24 2015 22:41
"what do you do for work?" "I command a fleet of computers to do my bidding" :-)
Ben West
@bewest
Sep 24 2015 22:41
so I'm thinking of slicing up lot of the loop stuff into little uses, the npm package makes it really easy to distribute scripts
Scott Leibrand
@scottleibrand
Sep 24 2015 22:44
I don't know about "lots", but there definitely are a few it makes sense to break out. I just hate fiddling with all the openaps.ini details required to support lots of uses
especially since that requires manually shipping around openaps.ini changes to all my pi's
Ben West
@bewest
Sep 24 2015 22:45
you can git pull them
Scott Leibrand
@scottleibrand
Sep 24 2015 22:45
git pull hates multi-pi setups
or rather, git hates being used to automatically push and pull things from pi's
and when you do it manually with 3 pi's who've been running independently, you always get merge conflicts
Ben West
@bewest
Sep 24 2015 22:46
right, I'd bounce via github as the central
Scott Leibrand
@scottleibrand
Sep 24 2015 22:46
doesn't help
two devices simultaneously writing the same file in the same repo is merge conflict hell
I use rsync exclusively now to sync my openaps-dev directory
and have made my loop.sh very careful about only updating mtime on a file if it's actually got valid new data, so rsync can rely on timestamps to decide what to sync
Ben West
@bewest
Sep 24 2015 22:50
if we can get the multiple file config thing @cjo20 was talking about, lot of that pain will go away along with judicious git-foo ;-)
Scott Leibrand
@scottleibrand
Sep 24 2015 22:51
that helps for openaps.ini, but not for any of the data.json files
Ben West
@bewest
Sep 24 2015 22:51
in the case where you are syncing openaps.ini and are about to run the loop again, you can easily ignore all that
Scott Leibrand
@scottleibrand
Sep 24 2015 22:51
I can't ignore merge conflicts
they break git until you manually do something
Ben West
@bewest
Sep 24 2015 22:52
you don't ignore them
they get resolved by git checkout origin/master -- . or similar
maybe with -f ;-)
"just take all theirs and put it here now"
Scott Leibrand
@scottleibrand
Sep 24 2015 22:53
would love to have you work through that and put all the appropriate git-fu into loop.sh to make it do git push and pull 100% reliably in a multi-Pi setup with flaky connectivity
I tried for weeks and finally gave up
Ben West
@bewest
Sep 24 2015 22:53
yeah, have to rip apart loop so it's all simple-single use things
Dana Lewis
@danamlewis
Sep 24 2015 22:53
+1
Scott Leibrand
@scottleibrand
Sep 24 2015 22:53
I tried all kinds of git checkout and git reset type things
not sure how much -f I did...
Ben West
@bewest
Sep 24 2015 22:54
we'll have few more reports with outputs like 00.monitor/sanity.json
I think -f might be needed in that scenario
it's not always obvious how to fix git
but it's pretty hard to actually break it
although we found a few ways ;-)
just surfed into target range
now that I'm in it, any departure should produce some activity?
Scott Leibrand
@scottleibrand
Sep 24 2015 22:59
if you're still trending in the direction of the departure when you run it, ya
Ben West
@bewest
Sep 24 2015 22:59
even if it inflects and I rise "unexpectedly" it should do something too
Scott Leibrand
@scottleibrand
Sep 24 2015 23:01
yes, once the 5m and 15m average are both upticking
Dana Lewis
@danamlewis
Sep 24 2015 23:01
Yea
Ben West
@bewest
Sep 24 2015 23:01
cool, I see a 15m deviation
and then an avg delta
I also thought about a way to make the process/shell registering easier
basically make a --flags option or something, which just prints the needed boiler plate
so something like openaps device add $(calculate-iob --device-flags)
Ben West
@bewest
Sep 24 2015 23:34
great
boom, first temp basal
Dana Lewis
@danamlewis
Sep 24 2015 23:35
Woohoo! The magical moment :)
Chris Oattes
@cjo20
Sep 24 2015 23:47
congrats
Scott Leibrand
@scottleibrand
Sep 24 2015 23:47
nice!
Ben West
@bewest
Sep 24 2015 23:47
that prevented a low just now
looks like it worked
Chris Oattes
@cjo20
Sep 24 2015 23:48
great
@bewest so how do you develop openaps stuff? Do you code on a desktop computer and just copy the files over to a pi?
Ben West
@bewest
Sep 24 2015 23:48
not sure... wouldn't have expected temp basal t nudge so quickly
guess it's been 20 minutes or so
I work on my linux laptop
I do everything there, I'm actually running openaps on my laptop
I have an rpi, it just seems little clunky
Chris Oattes
@cjo20
Sep 24 2015 23:49
I'm trying to work out a good workflow for dev
Ben West
@bewest
Sep 24 2015 23:49
rpi is a little slow
Scott Leibrand
@scottleibrand
Sep 24 2015 23:49
generally temp basals don't take effect for 60-90m, so you probably just got lucky
Ben West
@bewest
Sep 24 2015 23:50
might use ubuntu vm on desktop or something
yeah, that's what I'm thinking
Chris Oattes
@cjo20
Sep 24 2015 23:50
maybe samba on the pi and edit on windows :P
Ben West
@bewest
Sep 24 2015 23:50
ugh, would just do ssh
ssh pi@rasperrypi.local
Scott Leibrand
@scottleibrand
Sep 24 2015 23:51
I've had very little luck with getting mDNS to be reliable, so I usually figure out the IP address and ssh to that
I sometimes edit on the fly on the Pi, and sometimes edit on my VM and then commit/push to github and pull to pi for testing
depends on how confident I am it'll work usually. :)