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

10th
Apr 2018
Martin Haeberli
@mhaeberli
Apr 10 2018 03:56
IMG_2696.PNG
note that the convergence on the 150-120 target range was pretty slow. Is there an easy / safe way to make this happen faster?
(note - bed time, no new carbs being added)
Scott Leibrand
@scottleibrand
Apr 10 2018 04:14
narrow/lower the target range to 120-120?
Martin Haeberli
@mhaeberli
Apr 10 2018 04:30
ok… we almost want smart profiles - lower target range to 120-120 for 90 minutes then the rest of the night 140-120 … ? but too complex for now.
here also there may have been a missed opportunity to log correction carbs added for a low maybe 30 minutes off the left of the screen ...
did I see a suggestion that there may be ways of offline looping w G5 wirelessly rather than with a receiver plugged into the Edison /RPi / whatever?
(iphone is g5 ‘receiver’ and tether…)
Scott Leibrand
@scottleibrand
Apr 10 2018 04:33
search the docs for Lookout, or xdrip-js
Martin Haeberli
@mhaeberli
Apr 10 2018 04:33
k thx
Scott Leibrand
@scottleibrand
Apr 10 2018 04:34
we generally recommend a narrow target range (top=bottom)
and if you want it to bring highs down faster, that's what SMB is for
so whenever you're ready, look into that
Martin Haeberli
@mhaeberli
Apr 10 2018 04:35
smb ing … but maybe not in this context … so probably one of the ‘knife switches’ isn’t set to the right enable
maybe turn on smbenable_always or however it’s spelled?
‘cos we have most other smb enables on...
Scott Leibrand
@scottleibrand
Apr 10 2018 04:39
it might be getting overridden by your high temp target. is that a "normal" target? If so, you might want to set it in the pump instead of as a temp target, to avoid disabling SMB. or if there's some reason you want to run high temp targets (and still have SMB), there's a preference for that too
Martin Haeberli
@mhaeberli
Apr 10 2018 04:41
i don’t remember 723 degrees of freedom, but assuming we can do time-dependent targets, i think you’re suggesting set pump target to 135, say, from 120, from say midnight to 8 am...
Scott Leibrand
@scottleibrand
Apr 10 2018 04:41
yes, the pump can set a target schedule
Martin Haeberli
@mhaeberli
Apr 10 2018 04:42
i’m using the latter, I think :
"enableSMB_with_temptarget": true,
and
"": "high_temptarget_raises_sensitivity default false",
"high_temptarget_raises_sensitivity": true,
Scott Leibrand
@scottleibrand
Apr 10 2018 05:00
I was talking about the preference to allow SMBs with high temp targets, not high_temptarget_raises_sensitivity. the high temp targets override all the enableSMB ones unless the "allow" one is set.
Martin Haeberli
@mhaeberli
Apr 10 2018 05:02
So it sounds like we are configured to use SMBs here...
Scott Leibrand
@scottleibrand
Apr 10 2018 05:07
not without the allowSMB one, unless you stop setting high temp targets.
Martin Haeberli
@mhaeberli
Apr 10 2018 05:15
Ok we ll turn that on... thx
Benjamin Mammon
@bmammon
Apr 10 2018 05:30
Does anyone here have any experience with Amylin? I'm just learning about it now and it looks like it could be a useful hormone for building a true artificial pancreas. Apparently it helps control postprandial BG which is one of the only areas I still struggle with using OpenAPS. Which leads me to wonder... could one OpenAPS rig control 2 pumps with 2 different hormones at the same time?! I know i'm getting really ahead of myself but it's an interesting thought experiment since Amylin is available right now unlike Glucagon. Haha, maybe oref2?!
marafie
@marafie
Apr 10 2018 07:02
@jimrandomh novo rapid
Tore Bjørndalen
@ToreBj
Apr 10 2018 08:38
Warning temp.JPG
Is this a bug? Not very often, but I see it from time to time.
It did set temp=0 in the previous run and it was 1.7 before that.
It recovers in the next run.
Alan
@Alzibiff
Apr 10 2018 08:48
I
Dana Lewis
@danamlewis
Apr 10 2018 15:26
@ToreBj not a bug. That's a safety check
James Babcock
@jimrandomh
Apr 10 2018 18:34
Looking to add a smartwatch to my setup, and a key feature is that I want it to simultaneously pair with a phone (for emails &c) and an Edison (for monitoring), without the watch-Edison communications needing to be routed through a phone or through the internet. Does anyone have experience with that?
(I am expecting to need to write or significantly modify a watch app to make that useful, just want to know how connectivity is going to work before I buy any hardware)
Scott Leibrand
@scottleibrand
Apr 10 2018 18:35
I don't know of any watches that support multiple bluetooth connections like that
James Babcock
@jimrandomh
Apr 10 2018 18:52
Hmm. Internet research suggests that old Pebbles could do it with a hack where you pair one device via Bluetooth and the other via BTLE, but more modern smartwatches only have one radio and can't do that sort of thing. I'll try xda-developers and see if anyone there has ideas.
James Babcock
@jimrandomh
Apr 10 2018 19:32
Hmm. How useful would a smartwatch heart-rate monitor be for predicting future insulin sensitivity?
Scott Leibrand
@scottleibrand
Apr 10 2018 19:34
AFAICT, way less useful than everyone thinks. :-)
alimhassam
@alimhassam
Apr 10 2018 19:34
I remember discussions on this topic but I dunno if anyone pursued the research
Scott Leibrand
@scottleibrand
Apr 10 2018 19:34
there have been good discussions around using activity / heart rate monitors to automatically set activity modes (which already inform autosens)
but AFAICT no one has come up with any way to use them to make sensitivity calculations more accurate than those based on BG deviations alone.
alimhassam
@alimhassam
Apr 10 2018 19:35
@scottleibrand do you know if anyone is tracking hr data now and if anyone is looking for correlation with sensitivity?
James Babcock
@jimrandomh
Apr 10 2018 19:39
My experience with exercise is that there's one case where it really matters, which is if I've been running resistant and have a lot of IOB, and go for a walk, it clears the insulin resistance suddenly and can cause a low. But actually that's probably more the job of a pedometer than of a heart-rate monitor.
Scott Leibrand
@scottleibrand
Apr 10 2018 19:41
and by the time either of those detect it, it's too late to fix with just a zero temp. you need to set the activity mode before you go for the walk.
@alimhassam I know there were a couple people playing around with it, but dunno how systematically
Dana Lewis
@danamlewis
Apr 10 2018 19:42
@jimrandomh from my experience, that's more a result of the IOB and not the resistance level
James Babcock
@jimrandomh
Apr 10 2018 19:47
My thinking is, there's a few limitations in OpenAPS that could be addressed simultaneously by picking a good type of smartwatch and integrating closely--in particular dependence on the cloud for monitoring and alerts, and difficulty entering data that doesn't fit into the pump's bolus wizard. My ideal setup has an Edison talking to a SmartWatch directly, delivering alerts and showing status that way, and occasionally asking questions like "how precise was that carb estimate you just entered into the pump". And I figure if I'm going to invest time into integrating with a watch, it might make sense to choose a watch with a heart rate monitor and pedometer built in.
Dana Lewis
@danamlewis
Apr 10 2018 19:49
yea. I'm wearing a Pebble2HR for that reason (HR), but have not found it useful for real-time integration with OpenAPS. if we get a faster type of insulin, that might change in the future, but doubtful it'll be useful until then.
James Babcock
@jimrandomh
Apr 10 2018 19:50
Faster as compared to Fiasp, you mean?
Dana Lewis
@danamlewis
Apr 10 2018 19:50
yea. like 5-10 min peak, not 45+
James Babcock
@jimrandomh
Apr 10 2018 19:58
How much do current data-entry limitations matter? Eg if you could rewrite the bolus wizard, send arbitrary prompts and get numeric answers back, how useful would that be? I'm thinking of the how-uncertain-is-that-carb-estimate question, but not sure how much that one actually matters or what other opportunities there might be.
Dana Lewis
@danamlewis
Apr 10 2018 20:01
I don't think that it does, but YDMV
Scott Leibrand
@scottleibrand
Apr 10 2018 20:28
@jimrandomh have you looked into AndroidAPS? it has a lot of smartwatch integrations already
it currently requires a SOOIL or Roche pump, though. no one has yet written a RileyLink driver to work with old MDT pumps
James Babcock
@jimrandomh
Apr 10 2018 20:33
Currently using a 523 and a G4 over USB, so would need to replace a lot of hardware at once to use AndroidAPS.
Scott Leibrand
@scottleibrand
Apr 10 2018 20:35
yeah, for that config it might be easier to modify Loop to do what you want
th122
@th122
Apr 10 2018 21:26
I wonder how reliable a combination of HR/activity tracker would be in detecting sleep vs awake and active. Like many in cs, I’m often late in going to sleep, and don’t want to hide the increased sleeptime sensitivity in a fixed BR. Also, when getting up, I usually display that steep incline from the aldosteron-(among other things) based resistance, and at least oref0 is a bit late in countering /that/. (didn’t try oref1 on it yet).
In “manual mode” I had been using a PAL-based model to take that into consideration. (personal activity level)
Tore Bjørndalen
@ToreBj
Apr 10 2018 21:49
@danamlewis I get it's a safety check. But I see it as a false positive. It had already set temp rate = 0 in the previous run(before that it was 1.7) and in the next pump run it says it should have been 1.7 according to pumphistory. Pumphistory not updated/read (yet?) or temp rate=0 actually not set (yet?). What is the test purpose? I couldn't find the code part where the test is performed?
Scott Leibrand
@scottleibrand
Apr 10 2018 22:04
@ToreBj that probably means that either the pump said it accepted a temp basal that it didn't, or we weren't able to read it back in the pumphistory. Either way, the safest course is to cancel / set a neutral temp and try again.
James Babcock
@jimrandomh
Apr 10 2018 22:27
@th122 Fitbit has sleep-vs-wake tracking as a builtin feature, and it's very unreliable.
@th122 I used to have morning spikes, but found that choice of breakfast foods were a big part of it, and properly suspending the pump before getting in the shower was also part of it.
SMB definitely helps too
Tore Bjørndalen
@BjoTore_twitter
Apr 10 2018 22:32
@scottleibrand Ok I see. Could this indicate a problem if I get too many?
Tracey Berg-Fulton
@BergFulton_twitter
Apr 10 2018 22:52
So I ended up with the device full error again tonight again
Scott Leibrand
@scottleibrand
Apr 10 2018 22:53
did you ever try the suggestion to manually run the sed command from the diff?
Tracey Berg-Fulton
@BergFulton_twitter
Apr 10 2018 22:54
Yes but got no input files
Scott Leibrand
@scottleibrand
Apr 10 2018 22:54
that sounds like our problem. do you still have the exact command and its output?
Tracey Berg-Fulton
@BergFulton_twitter
Apr 10 2018 22:55
root@jankypanky:~# sed -i "s/daily/hourly/g" sed: no input files
Scott Leibrand
@scottleibrand
Apr 10 2018 22:55
thx, checking
th122
@th122
Apr 10 2018 22:56
@jimrandomh thanks for the fitbit information - I was afraid that the “going to sleep” part would be really hard to detect - resistance-wise, there’s a big difference between sleep and couch-potatoing, but from the point of view of an activity tracker, probably not.
The morning spikes don’t involve food. from 90 to 140 in 15minutes on a bad day.
My fastest-acting treatment against a morning hypo is “just rise”.
Scott Leibrand
@scottleibrand
Apr 10 2018 22:57
@BergFulton_twitter the command in the diff looks to be sed -i "s/daily/hourly/g" /etc/logrotate.conf - try that?
th122
@th122
Apr 10 2018 22:58
@BergFulton_twitter you need to give sed the input to chew on, as well, and direct the result somewhere
Scott Leibrand
@scottleibrand
Apr 10 2018 22:58
looks like you were missing the /etc/logrotate.conf part at the end
I think there's another problem too, but I want to see that output first
@th122 the -i is supposed to do in-place, but not sure if it needs an argument too
elsewhere we do either -i.bak or -i""
Tracey Berg-Fulton
@BergFulton_twitter
Apr 10 2018 22:59
hmmm..nothing
root@jankypanky:~# sed -i "s/daily/hourly/g" /etc/logrotate.conf root@jankypanky:~#
Scott Leibrand
@scottleibrand
Apr 10 2018 22:59
nothing is good there
grep ly /etc/logrotate.conf now?
Tracey Berg-Fulton
@BergFulton_twitter
Apr 10 2018 23:00
Oh crap, so I changed it manually to see if I could get myself looping again, have I completely borked this debugging process
Scott Leibrand
@scottleibrand
Apr 10 2018 23:00
that's fine
I have some rigs I can debug on. :)
Tracey Berg-Fulton
@BergFulton_twitter
Apr 10 2018 23:00

```root@jankypanky:/# grep ly /etc/logrotate.conf

rotate log files weekly

hourly
monthly
monthly
root@jankypanky:/# ```

OK, so, there's not emojis in that response, but sure, why not
Scott Leibrand
@scottleibrand
Apr 10 2018 23:01
lol
you can test this one for me though: sed -i "s/weekly/hourly/g" /etc/logrotate.conf
that should change the #rotate log files weekly comment to # rotate log files hourly
Tracey Berg-Fulton
@BergFulton_twitter
Apr 10 2018 23:03
k, big nothing from the command line
th122
@th122
Apr 10 2018 23:03
(no need for g, but it doesn’t hurt :)
Scott Leibrand
@scottleibrand
Apr 10 2018 23:03
@BergFulton_twitter then grep again
@th122 no, not unless there are two weeklys on the same line
Tracey Berg-Fulton
@BergFulton_twitter
Apr 10 2018 23:03

`root@jankypanky:/# grep ly /etc/logrotate.conf

rotate log files hourly

hourly
monthly
monthly
root@jankypanky:/# `

Scott Leibrand
@scottleibrand
Apr 10 2018 23:03
yep, that looks like it worked
and would've fixed the problem if you hadn't already done so manually
I'll fix the script
Tracey Berg-Fulton
@BergFulton_twitter
Apr 10 2018 23:04
ok. Do I need to try to clean out the file that's already full?
root@jankypanky:/# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/root 1.4G 1.4G 0 100% /
devtmpfs 481M 0 481M 0% /dev
tmpfs 481M 0 481M 0% /dev/shm
tmpfs 481M 6.7M 474M 2% /run
tmpfs 5.0M 0 5.0M 0% /run/lock
tmpfs 481M 0 481M 0% /sys/fs/cgroup
tmpfs 481M 8.0K 481M 1% /tmp
/dev/mmcblk0p7 32M 4.8M 28M 16% /boot
/dev/mmcblk0p10 1.3G 785M 507M 61% /home
tmpfs 97M 0 97M 0% /run/user/0
root@jankypanky:/#
Scott Leibrand
@scottleibrand
Apr 10 2018 23:04
you'll probably need to do something to free up some space, yeah
Tracey Berg-Fulton
@BergFulton_twitter
Apr 10 2018 23:06
That's what I couldn't really understand...what's safe to delete and what's not safe
Scott Leibrand
@scottleibrand
Apr 10 2018 23:06
you can safely delete anything in /var/log/ if you don't want to review it
th122
@th122
Apr 10 2018 23:07
Now I’m feeling bad for having not pr’d that yet.
nplease don’t delete active files, onl empty them
Scott Leibrand
@scottleibrand
Apr 10 2018 23:07
you can always reboot afterwards
alimhassam
@alimhassam
Apr 10 2018 23:08
also apt-get clean might help save disk space
James Babcock
@jimrandomh
Apr 10 2018 23:08
My dev branch has pushover alerts for low disk space. Not necessarily ready for primetime though.
th122
@th122
Apr 10 2018 23:09
did you already clean out the cached archives of installed software packages?
   sudo apt-get clean
@alimhassam you beat me to it :)
Scott Leibrand
@scottleibrand
Apr 10 2018 23:10
and if apt-get clean frees up some space, that should be sufficient for logrotate to do its normal thing with the logs
(now that we've told it to do so more often)
th122
@th122
Apr 10 2018 23:12
how large is your logfile directory really - is it truly the culprit? Once you’ve gotten some free space, you might watch if there’s anything snatching it up immediately.
Tracey Berg-Fulton
@BergFulton_twitter
Apr 10 2018 23:13
That's the thing, I don't know. i couldn't get NCDU to run
th122
@th122
Apr 10 2018 23:13
To find all files that are currently growing, you can use find.
Create a new file, wait a moment, and let find search for any file
that has been written to more recently than that timestap file:
    :> timestamp
    find / -newer timestamp -ls
Tracey Berg-Fulton
@BergFulton_twitter
Apr 10 2018 23:13
I just did sudo apt-get clean and my /dev/root went from 100% to 91%
th122
@th122
Apr 10 2018 23:14
what does du -h /var/log say?
Tracey Berg-Fulton
@BergFulton_twitter
Apr 10 2018 23:14
root@jankypanky:/# du -h /var/log
48M /var/log/openaps
12K /var/log/fsck
4.0K /var/log/unattended-upgrades
4.0K /var/log/ntpstats
4.0K /var/log/news
28K /var/log/apt
4.0K /var/log/watchdog
729M /var/log
alimhassam
@alimhassam
Apr 10 2018 23:15
another thing that thing that some people have that's was taking quite some space (from memory) is the decocare repository, which unfortunately has a lot of un-necessary data files
th122
@th122
Apr 10 2018 23:15
ok, it’s the system logs that have been growing, then.
/var/log/openaps is completely in range, but the entirety of /var/log isn’t.
alimhassam
@alimhassam
Apr 10 2018 23:16
logrotate should help with these.
Tracey Berg-Fulton
@BergFulton_twitter
Apr 10 2018 23:16
woof, yeah.
Scott Leibrand
@scottleibrand
Apr 10 2018 23:17
if you're impatient, logrotate -f /etc/logrotate.conf
Tracey Berg-Fulton
@BergFulton_twitter
Apr 10 2018 23:18
It sounds like logrotate is kind of a "shuffle and move on but it might come back" kinda scenario?
ideally if I didn't want to have to do this for a while I'd go in there and clean out /var/log, yeah?
Scott Leibrand
@scottleibrand
Apr 10 2018 23:19
logrotate is more like "find everything more than X days old in the filing cabinet and toss it"
the problem is that the intern doing the "find everything more than X days old" job was only coming in once a week
Tracey Berg-Fulton
@BergFulton_twitter
Apr 10 2018 23:19
:laughing:
Scott Leibrand
@scottleibrand
Apr 10 2018 23:19
we just changed their schedule to do the job every hour :)
fortunately the intern works basically for free, and doesn't take very long to do the job. :)
Tracey Berg-Fulton
@BergFulton_twitter
Apr 10 2018 23:20
(good intern!)
th122
@th122
Apr 10 2018 23:20
There’s a few things we could actually do in the preconfiguration to reduce the growth in /var/log - I put them into the documentation I didn’t yet get around to PR: gist.github.com/LongboatAline/87c8e948e011a3fcdf10990c955b73f7
ack, it should be just a link, not that part-blob.
Scott Leibrand
@scottleibrand
Apr 10 2018 23:23
whatever you just did fixed that
th122
@th122
Apr 10 2018 23:23
I removed the https prefix. seems enough to keep the link without the spam.
Scott Leibrand
@scottleibrand
Apr 10 2018 23:23
:+1: good to know
Tracey Berg-Fulton
@BergFulton_twitter
Apr 10 2018 23:30
Ok, going through the gist you set @th122. Commented out authlog
th122
@th122
Apr 10 2018 23:35
That file has a tendency to explode on a rig, I found. Plus, all the spam from each and every call to oref0 and friends really hide the information one might want to find in it.
Tracey Berg-Fulton
@BergFulton_twitter
Apr 10 2018 23:37
cool. I managed to get down into /var/log right now. So if I'm understanding your instructions correctly, I want to use :> <filename> and just plug in each filename in here (or a few at least) to get it even more cleaned out?
th122
@th122
Apr 10 2018 23:39
if you did a successful logrotate, you won’t need that.
the “nuke that big, fast growing logfile” is only needed if you’re in a truly tight squeeze and need to reclaim that space immediately.
Tracey Berg-Fulton
@BergFulton_twitter
Apr 10 2018 23:42

Ah ok. df -h gets me

/dev/root 1.4G 1.2G 161M 88% /
devtmpfs 481M 0 481M 0% /dev
tmpfs 481M 0 481M 0% /dev/shm
tmpfs 481M 13M 468M 3% /run
tmpfs 5.0M 0 5.0M 0% /run/lock
tmpfs 481M 0 481M 0% /sys/fs/cgroup
tmpfs 481M 8.0K 481M 1% /tmp
/dev/mmcblk0p7 32M 4.8M 28M 16% /boot
/dev/mmcblk0p10 1.3G 785M 507M 61% /home
tmpfs 97M 0 97M 0% /run/user/0

if 88% is enough to get me a while (particularly now that I've got the rotate set to daily) then I'll just leave it alone
th122
@th122
Apr 10 2018 23:48
it’s still quite tight. My edison for example reads:
root@antlia:~# df -h /
Filesystem      Size  Used Avail Use% Mounted on
/dev/root       1.4G  639M  677M  49% /
Tracey Berg-Fulton
@BergFulton_twitter
Apr 10 2018 23:48
geez
th122
@th122
Apr 10 2018 23:49
what does du -sh myopenaps/.git/ give you?
Tracey Berg-Fulton
@BergFulton_twitter
Apr 10 2018 23:51
(waiting for ssh to happen)
root@jankypanky:~# du -sh myopenaps/.git/
du: cannot access ‘myopenaps/.git/’: No such file or directory
th122
@th122
Apr 10 2018 23:53
ok, full path: du -sh /root/myopenaps/.git
Tracey Berg-Fulton
@BergFulton_twitter
Apr 10 2018 23:54
root@jankypanky:~# du -sh /root/myopenaps/.git
du: cannot access ‘/root/myopenaps/.git’: No such file or directory
root@jankypanky:~#
th122
@th122
Apr 10 2018 23:55
ok, maybe you’re running a branch that doesn’t need the git? that would eliminate one possible reason of runaway disk space (corrupted git with lots of tmp files)
du -sh /root/myopenaps ?
Tracey Berg-Fulton
@BergFulton_twitter
Apr 10 2018 23:56
There's the winner
root@jankypanky:~# du /root/myopenaps
12 /root/myopenaps/upload
1992 /root/myopenaps/autotune
20 /root/myopenaps/enact
224 /root/myopenaps/cgm
224 /root/myopenaps/settings
232 /root/myopenaps/monitor
4 /root/myopenaps/raw-cgm
2816 /root/myopenaps
root@jankypanky:~#
I'm on branch fix-log-rotate right now
Dana Lewis
@danamlewis
Apr 10 2018 23:57
that was forked from master a few days ago, so that's 0.6.0 (no git)