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

5th
Mar 2017
John Benjamin
@Bender1061
Mar 05 2017 00:06
@fiberfan you need the dev branch of decocare to get the more than 6.4 units/hour basal. You have a couple of options to get that on your rig. the easiest way is to go to dev branch of all the toolsets. using curl -s https://raw.githubusercontent.com/openaps/docs/master/scripts/quick-src.sh | bash - or you can install the dev version of decocare with mkdir -p ~/src; cd ~/src && git clone -b dev git://github.com/openaps/decocare.git || (cd decocare && git checkout dev && git pull) and then run cd ~/src/decocare && sudo python setup.py develop
at least those are the ways I've been doing it, and as Scotts picture that best explains git, just use what works
@fjungman do you know has anyone tested by putting any of the sparkfun boards in combination with the explorer board? I know theoretically they should work, but I don't know if anyone has. cause a couple of those would be useful for things like screens.
Andrew Baugh
@baughaw
Mar 05 2017 00:29
Just grabbed the latest dev branch and am getting the following error showing up in my cgm log. Any ideas? I am using a G5.. AttributeError: 'NoneType' object has no attribute 'iter_records'
Dana Lewis
@danamlewis
Mar 05 2017 00:38
@baughaw means receiver not plugged in is all
jcorbett80
@jcorbett80
Mar 05 2017 02:07
@diabeticgonewild. Monica this is how you offline set up Explorer board and edison with open aps. https://github.com/openaps/docs/blob/master/docs/docs/walkthrough/phase-1/offline-looping-and-monitoring.md it works great
diabeticgonewild
@diabeticgonewild
Mar 05 2017 02:08
@jcorbett80 Thank you so much! Super helpful! πŸ˜πŸ‘
jcorbett80
@jcorbett80
Mar 05 2017 02:11
@danamlewis thank you. I will get started in it. I am also getting a pi to set up. Because my Explorer runs way to hot. I got the low power but it is extremely hot. There is no way i want to put it in a case. I first thought bad battery but I unplugged it and used pc usb as power and it is still to hot. When I set up the pi I will do the same with it as far as a pr.
jcorbett80
@jcorbett80
Mar 05 2017 02:23
@diabeticgonewild the one thing if you are in the U.S. it works great but if you have AT&T they have removed the ability to bluetooth tether on Samsung Galaxy class phones. Probably all. If you have unlimited data the also kill the Hotspot ability. I had to research why everyone else could bluetooth tether and I couldnt. I am sure it is on all models but for sure on Galaxy class.
@danamlewis I meant to say my edison
fjungman
@fjungman
Mar 05 2017 03:06
@Bender1061 I'm confused now. I thought the Explorer Board was the Sparkfun board. Is there a difference? What would a combination be?
diabeticgonewild
@diabeticgonewild
Mar 05 2017 04:13
@jcorbett80 I have AT&T. I like them. I have an iPhone 6 Plus and will google about AT&T and Bluetooth tethering. I don't have unlimited data (yet...). Thanks for the heads up!
@jcorbett80 I just googled and it's apparent that the Bluetooth tethering issue is an Android issue with some carriers
jcorbett80
@jcorbett80
Mar 05 2017 04:16
@diabeticgonewild iPhone might be ok. It takes an act of Congress to allow a company to root an iPhone and remove something like that with apple. Android is open source....makes them much better for new development options but also allows all to do what they want.
diabeticgonewild
@diabeticgonewild
Mar 05 2017 04:17
It works fine with iPhone. I posted instructions for BT tethering for Android on any carrier
Dana Lewis
@danamlewis
Mar 05 2017 04:21
@fjungman explorer board is not a sparkfun board. It's a custom board with radio stick built on.
And @Bender1061 no, I don't think anyone's played with stacking yet.
jcorbett80
@jcorbett80
Mar 05 2017 04:31
@diabeticgonewild thank you Monica. lol At&T blocks foxfi on the google play store also. I found the at&t version of foxfi for sprint/at&t elsewhere on the net.
diabeticgonewild
@diabeticgonewild
Mar 05 2017 04:31
Awesome!!!!
jcorbett80
@jcorbett80
Mar 05 2017 04:33
@diabeticgonewild well actually it wasnt what it said. I will keep searching for a way to get it downloaded
Paul Dickens
@thebookins
Mar 05 2017 04:42
Loop has been offline today - when I finally got to a computer to check the logs, found we are getting the /dev/spidev5.1 already in use error. I haven't been following this issue closely, but I understand there's a fix in dev?
Keen to get a reliable loop prior to son going to camp next week - are many people running dev without issue at the moment?
What would be the best approach, switch from master to dev, or pull the spidev5.1 in use commit only?
zekeat09
@zekeat09
Mar 05 2017 04:44
@scottleibrand Did restart dynos in heroku, re-run oref0-setup, re check ENABLE. Still the same. I suspect the temp basal not upload, as i can't find them in Mlab entries/devicestatus. Anyway to check or solve ?
zekeat09
@zekeat09
Mar 05 2017 04:50
mlab devicestatus:
{
"_id": {
"$oid": "58ba27ddc014520c00d5253e"
},
"device": "openaps://myedison",
"openaps": {
"iob": {
"iob": 0,
"activity": 0,
"bolussnooze": 0,
"basaliob": 0,
"netbasalinsulin": 0,
"hightempinsulin": 0,
"timestamp": "2017-03-04T02:33:02.000Z"
},
"suggested": {
"temp": "absolute",
"bg": 122,
"tick": -2,
"eventualBG": 115,
"snoozeBG": 115,
"predBGs": {
"IOB": [
122,
120,
119,
117,
116,
115,
114,
113,
112,
112,
111,
111,
111
]
},
"COB": 0,
"IOB": 0,
"reason": "COB: 0, Dev: -7, BGI: 0, ISF: 5.0, Target: 6.3; Eventual BG 6.4 > 6.0 but Min. Delta -2.00 < Exp. Delta -0.1, temp 0.2 ~ req 0.2U/hr",
"timestamp": "2017-03-04T02:34:25.000Z"
},
"enacted": {
"bg": 122,
"temp": "absolute",
"snoozeBG": 115,
"recieved": true,
"rate": 0.2,
"reason": "COB: 0, Dev: -7, BGI: 0, ISF: 5.0, Target: 6.3; Eventual BG 6.4 > 6.0 but Min. Delta -2.00 < Exp. Delta -0.1; setting current basal of 0.2 as temp. Setting neutral temp basal of 0.2U/hr",
"COB": 0,
"eventualBG": 115,
"timestamp": "2017-03-04T02:28:42.000Z",
"duration": 30,
"tick": -2,
"IOB": 0
}
},
"pump": {
"clock": "2017-03-04T10:33:02+08:00",
"battery": {
"status": "normal",
"voltage": 1.55
},
"reservoir": 31.5,
"status": {
"status": "normal",
"bolusing": false,
"suspended": false,
"timestamp": "2017-03-04T02:34:19.000Z"
}
},
"uploader": {
"batteryVoltage": 3854,
"battery": 67
},
"created_at": "2017-03-04T02:35:09.089Z"
}
diabeticgonewild
@diabeticgonewild
Mar 05 2017 05:22
Where do you enter in the Dexcom G4 serial number within the setup script? I think I missed that part. Otherwise, I think I am good to go!
I did put in my CGM as a "G4" though
I just googled and I think it is in the "offline monitoring" section of the docs
Nevermind, no it isn't there in that section
I guess you have to setup openxshareble manually. That would be nice to add as an option for oref0 setup script
Or have another setup script for openxshareble
diabeticgonewild
@diabeticgonewild
Mar 05 2017 05:34
Will try doing some PR work, but not tonight. BG right now is 359 (not wearing CGM or using OpenAPS) and exhausted.
Dana Lewis
@danamlewis
Mar 05 2017 05:52
@thebookins dev branch has a fix for that
@diabeticgonewild it's a command line flag if you want openxshareble
diabeticgonewild
@diabeticgonewild
Mar 05 2017 05:53
@danamlewis on oref0 setup script?
I did select G4 as the CGM I was using in oref0
But it didn't ask me for my CGM serial number
Dana Lewis
@danamlewis
Mar 05 2017 05:55
Correct. I would suggest looking at the code directly in oref0-setup.sh to decide how you might want to add things to the command line directly
diabeticgonewild
@diabeticgonewild
Mar 05 2017 05:55
OK thanks
I guess that's not in the docs? As in the CGM SN option documentation?
I know it's a command line flag, but I searched and I don't think it is mentioned anywhere in the docs for oref0 setup script. Am I correct?
Dana Lewis
@danamlewis
Mar 05 2017 05:59
It is not in the docs, correct (and that's intentional since it's not a reliable setup option currently). You'll want to look at the code directly.
diabeticgonewild
@diabeticgonewild
Mar 05 2017 05:59
OK got it. Thanks. And I do see it in the code. :)
Dana Lewis
@danamlewis
Mar 05 2017 06:00
:+1:
diabeticgonewild
@diabeticgonewild
Mar 05 2017 06:00
I see what I needed to do. I don't read and I tend to be impulsive, so it makes sense that I missed it.
katie disimone
@Kdisimone
Mar 05 2017 06:02
@thebookins if you don't want to do dev branch yet, this was my manual fix for it until then. https://www.dropbox.com/s/ursxcvl9gkrpy04/Fix%20for%20the%20BT.docx?dl=0
@thebookins you may want set up papertrail too so you can see logs without needing to be near rig or on same network https://docs.google.com/document/d/1HJfE4NhASUQr56_37Dl28ZfbYb1DZ8XdWGPkeu5nRIg/mobilebasic
diabeticgonewild
@diabeticgonewild
Mar 05 2017 06:05
@danamlewis So I was just looking at the script, and how do you set up max_iob?
Scott Leibrand
@scottleibrand
Mar 05 2017 06:06
@thebookins probably fine to try dev. the only other major change there is sorting carb treatments to help fix COB decay issues some people are seeing. lots of other little stuff, of course.
diabeticgonewild
@diabeticgonewild
Mar 05 2017 06:06
Do you need a preferences_from_args.json file to use the setup script?
Dana Lewis
@danamlewis
Mar 05 2017 06:08
@diabeticgonewild you can command line flag it as well, otherwise it defaults to 0 and you can edit the preferences file after you run the script
diabeticgonewild
@diabeticgonewild
Mar 05 2017 06:08
nevermind, you need an --update-preferences
I just don't read. It's not a reliable thing to read code via screenreader either
Scott Leibrand
@scottleibrand
Mar 05 2017 06:09
I've never heard of preferences_from_args.json, and --update-preferences is usually not needed
diabeticgonewild
@diabeticgonewild
Mar 05 2017 06:10
OK thanks. I was just looking at code and max_iob looked like it might prevent oref0-setup.sh from being fully setup via the arguments
I guess I will edit the preference file after I setup the script
Scott Leibrand
@scottleibrand
Mar 05 2017 06:12
echo "Usage: oref0-setup.sh <--dir=directory> <--serial=pump_serial_#> [--tty=/dev/ttySOMETHING] [--max_iob=0] [--ns-host=https://mynightscout.azurewebsites.net] [--api-secret=myplaintextsecret] [--cgm=(G4|shareble|G4-raw|G5|MDT|xdrip)] [--bleserial=SM123456] [--blemac=FE:DC:BA:98:76:54] [--btmac=AB:CD:EF:01:23:45] [--enable='autosens meal dexusb'] [--radio_locale=(WW|US)]"
diabeticgonewild
@diabeticgonewild
Mar 05 2017 06:13
Thanks!
That should probably be in the docs too....
I will add it, but not tonight
Nevermind. You guys don't want it in the docs yet.
Sorry I'm high and tired
Scott Leibrand
@scottleibrand
Mar 05 2017 06:14
no worries. have a good night.
diabeticgonewild
@diabeticgonewild
Mar 05 2017 06:15
You too :D
peterfulvi
@peterfulvi
Mar 05 2017 06:27
Have an autotune question. The output that i see in the recommendation log is just suggestion , the loop doesn't automatically adjust your ISF and carb ratio for you in the loop does it?
Recommendations Log File: /root/topenaps/autotune/autotune_recommendations.log

Parameter      | Current  | Autotune
-------------------------------------
ISF            | 35.000   | 30.524
CSF            | n/a      | 4.200
Carb Ratio     | 10.000   | 7.268
  00:00        | 1.200    | 1.151
  01:00        |          | 1.142
  02:00        |          | 1.098
  03:00        |          | 1.145
  04:00        | 1.000    | 0.990
  05:00        |          | 1.043
  06:00        | 1.200    | 1.311
  07:00        |          | 1.261
  08:00        |          | 1.222
  09:00        |          | 1.147
  10:00        |          | 1.173
  11:00        |          | 1.200
  12:00        |          | 1.200
  13:00        |          | 1.215
  14:00        | 1.250    | 1.283
  15:00        |          | 1.304
  16:00        |          | 1.302
  17:00        |          | 1.287
  18:00        |          | 1.254
  19:00        |          | 1.256
  20:00        |          | 1.295
  21:00        |          | 1.311
  22:00        | 1.250    | 1.299
  23:00        |          | 1.252
Dana Lewis
@danamlewis
Mar 05 2017 06:36
How did you run it? As one off, or did you add it to the setup script?
Did you he
(I.e. Did you follow phase a or b instructions?)
peterfulvi
@peterfulvi
Mar 05 2017 06:42
I added with the setup script as one of the advanced features
Dana Lewis
@danamlewis
Mar 05 2017 06:46
Ok. Then yes @peterfulvi, you've enabled it to do that. See the description in the phase B instructions for more detail . http://openaps.readthedocs.io/en/latest/docs/walkthrough/phase-4/autotune.html#phase-b-running-autotune-in-openaps-closed-loop-system
peterfulvi
@peterfulvi
Mar 05 2017 06:46
Thanks
Dana Lewis
@danamlewis
Mar 05 2017 06:48
General comment for everyone: I don't recommend enabling advanced features if you have not read in advance how they work, and intentionally want to turn them on.
Paul Dickens
@thebookins
Mar 05 2017 06:55
Thanks @danamlewis @scottleibrand and @Kdisimone we'll switch to dev and make sure papertrail is working for us. I don't suppose there's any way to remotely trigger a reboot (ie without ssh) if things go awry?
Dana Lewis
@danamlewis
Mar 05 2017 06:57
Nope. But power off/on via the button if not looping is probably a good thing to teach whoever has the rig. Ie if it's not setting temps before bed, press the button to turn it off and turn it back on. (Trying to remember how old the kid in question is for this feasibility wise?)
(Good problem that we have so many families looping that I can't remember how old everyone's kids are off the top of my head? :smile: )
peterfulvi
@peterfulvi
Mar 05 2017 07:01

Im having a problem.Im reruning setup, to try to tether a new phone i have and those showed up

# To run again with these same options, use:
tee: /tmp/oref0-runagain.sh: No space left on device
oref0-setup --dir=/root/myopenaps --serial=303929 --cgm=mdttee: /tmp/oref0-runagain.sh: No space left on device
 --ns-host=https://petersopenaps.herokuapp.com --api-secret=: /tmp/oref0-runagain.sh: No space left on device
 --tty=/dev/spidev5.1tee: /tmp/oref0-runagain.sh: No space left on device
 --enable=' autosens  autotune  meal 'tee: /tmp/oref0-runagain.sh: No space left on device
 --radio_locale='US'tee: /tmp/oref0-runagain.sh: No space left on device
 --btmac='e4:c8:01:5b:49:fe'
tee: /tmp/oref0-runagain.sh: No space left on device

Continue? y/[N] y
Checking /root/myopenaps: Traceback (most recent call last):
  File "/usr/local/bin/openaps-use", line 63, in <module>
    app( )
  File "/usr/local/lib/python2.7/dist-packages/openaps/cli/__init__.py", line 47, in __call__
    self.configure_parser(self.parser)
  File "/usr/local/bin/openaps-use", line 31, in configure_parser
    available = devices.get_device_map(self.config)
  File "/usr/local/lib/python2.7/dist-packages/openaps/devices/__init__.py", line 21, in get_device_map
    for device in Device.FromConfig(vendors, conf):
  File "/usr/local/lib/python2.7/dist-packages/openaps/devices/device.py", line 79, in FromConfig
    device.read(config=config)
  File "/usr/local/lib/python2.7/dist-packages/openaps/devices/device.py", line 35, in read
    extra = config.Read(name=extra_ini)
  File "/usr/local/lib/python2.7/dist-packages/openaps/config.py", line 62, in Read
    config.read(name)
  File "/usr/lib/python2.7/ConfigParser.py", line 305, in read
    self._read(fp, filename)
  File "/usr/lib/python2.7/ConfigParser.py", line 512, in _read
    raise MissingSectionHeaderError(fpname, lineno, line)
ConfigParser.MissingSectionHeaderError: File contains no section headers.
file: ns.ini, line: 1
'\\[device "ns"]\n'
Reinitialized existing Git repository in /root/myopenaps/.git/
On branch master
Untracked files:
        cgm-session.json
        cgm.ini
        cgm/glucose.json
        cgm/ns-glucose.json
        detect-sensitivity.ini
        determine-basal.ini
        get-profile.ini
        glucose.ini
        iob.ini
        meal.ini
        mmtune_old.json
        monitor/carbhistory.json
        monitor/edison-battery.json
        monitor/glucose-unzoned.json
        monitor/meal.json.new
        nightscout/recent-missing-entries.json
        ns-glucose.ini
        ns.ini
        oref0-runagain.sh
        oref0.ini
        pebble.ini
        pump-session.json
        settings/temptargets.json
        tz.ini
        units.ini
        upload/
        xdrip.ini

nothing added to commit but untracked files present
Can't init /root/myopenaps

Also my loop just stopped at 1:07am there is nothing after that logged

Paul Dickens
@thebookins
Mar 05 2017 07:12
Thanks @danamlewis, Oli is 11 so definitely achievable, hardest thing is taking apart the case πŸ˜€
Dana Lewis
@danamlewis
Mar 05 2017 07:14
@thebookins heh :smile: could always do a temporary case that's easier to open for the week if it would make a difference?
Scott Leibrand
@scottleibrand
Mar 05 2017 07:35
@peterfulvi a reboot should fix that for now.
peterfulvi
@peterfulvi
Mar 05 2017 07:36
Thank You
peterfulvi
@peterfulvi
Mar 05 2017 07:44
That fixed it @scottleibrand Thanks
fiberfan
@fiberfan
Mar 05 2017 08:59
@danamlewis My latest setup was run in late January ir early February. I looked at the decocare source and thought it should handle basals larger than 6.3 without a change and didnt run the install until late February.
Paul Dickens
@thebookins
Mar 05 2017 09:47
Another pre-camp question: our edison currently lasts around 12 hours on a full charge - would be great if we could get a few more hours out of it to get our boy to bedtime. Any tricks? I remember someone (maybe @tim2000s) tried changing the crontab timing to every five minutes and saw some benefit...
@danamlewis yeah, a temporary case could be a goer. I'll have to eat lots of tic tacs.
Paul Dickens
@thebookins
Mar 05 2017 10:49
btw @Kdisimone papertrail for OpenAPS is fantastic - thanks for the detailed instructions!
Tim Street
@tim2000s
Mar 05 2017 12:36
@thebookins I swapped it to every 3mins and gained about 20% more battery life.
dan lightner
@danimaniac
Mar 05 2017 12:39
This message was deleted
@tim2000s what is the default crontab timing? How far can we extend that time and maintain an effective loop?
Tim Street
@tim2000s
Mar 05 2017 12:45
Default is every minute. In the past I've run loops with crontab timing ever five minutes with no issues. Pre the setup scripts, that's how frequently my loop ran with no ill effects. Given that it's glucose data that's key and that only changes every five mins, it isn't an issue.
dan lightner
@danimaniac
Mar 05 2017 13:04
@tim2000s do you believe a 3min cycle is the optimal balance between extended battery life and fresh cgm data? Seems it might be.
Tim Street
@tim2000s
Mar 05 2017 13:27
No. Five mins is good enough.
(In my opinion - but i generally don't get huge swings in glucose levels)
katmphil
@katmphil
Mar 05 2017 16:50
I am having trouble with flashing my edison. I went through all the set up but somewhere it failed to flash and now my computer doesn't recognize the edison board. Help! I am on a mac if that helps.
Matthias
@ceben80
Mar 05 2017 17:04
@katmphil Try different micro-USB cables. I've seen that Edisons to be very sensitive to particular cables.
katie disimone
@Kdisimone
Mar 05 2017 18:16
@katmphil if you're getting a can't find pty message, just reverse the USB ports on the Mac that the cables are plugged into
PieterGit
@PieterGit
Mar 05 2017 18:26
I noticed a fresh rpi install with a rpi-update, now updates to kernel 4.9 (4.9.13-v7+ to be exactly). Anybody already running there pi with openaps on kernel 4.9?
katmphil
@katmphil
Mar 05 2017 18:48
@Kdisimone @ceben80 I have tried switching the cables and switching the usb ports. My computer still fails to recognize the edison. I may switch to my husbands pc to see if that will work. If i still can get it up and running I may end up buying new cables. The frustrating part was I got it to connect last weekend and started (but failed) in there flashing process
Geoff Aumaugher
@geoffro10
Mar 05 2017 18:58
Not sure I've seen this asked before... Once your rig is running well, settings and rates are good, do you end up setting a hard number for BG range? Currently we're 100-120. Thinking we can shrink that range. Or, is it not a good idea to do so?
Dana Lewis
@danamlewis
Mar 05 2017 19:12
@geoffro10 that's fine if you are comfortable with how it operates. A tighter range will just mean it oscillates more to set temps more frequently.
dan lightner
@danimaniac
Mar 05 2017 19:29
In our collective exprience, how tight of a range is actually practical for looping? My current pump has a hard number for a target. Any reading over that target produces a bolus reccomendation any reading below produces a carb correction recommendation. I am 35 year t1d, new to looping though. Explorer board is scheduled for delivery tomorrow. I guess I am asking at what point would we simply be wasting processing and battery resources.
Dana Lewis
@danamlewis
Mar 05 2017 19:48
Personal preference re tightness of range for looping. I don't believe a tight range yields wasting of processing or battery, personally. Keep in mind looping will do temp basals based on the target - for the most part, other than meal boluses you will likely stop (and even then might stop) using the bolus wizard as its iob will be incorrect while looping.
Paul Dickens
@thebookins
Mar 05 2017 20:03
@tim2000s a 20% improvement is worth shooting for! Was that every crontab line that currently runs every minute?
Dana Lewis
@danamlewis
Mar 05 2017 20:07
(Keep in mind a 3 min or 5 min run increases risk of not running, because if BG doesn't come on time or you're barely out of range, will take another full cycle before running again and that can stack up quickly)
The other thing re efficiency improvements: we still have a longstanding call for help to improve the efficiency of NS uploads. That would also make a big difference.
pepecb
@pepecb
Mar 05 2017 20:09
Hi. I have to survive with Carelink USB until Edison arrives. As you can imagine itΒ΄s crashing every now and then. I have previously got the suggestion to change the crontab to run every 3 minutes or set up a cron job to run oref0-reset-usb if it found stick.py in the output. Could anyone share the code/give some basic instructions about how to change the timming of the crontab?. Thank you.
pepecb
@pepecb
Mar 05 2017 20:34

Thaks @Kdisimone. Do I have to change all the lines in the crontab or just some of them?

/3 ps aux | grep -v grep | grep -q "oref0-online AA:etc" || oref0-online AA:etc >> /var/log/openaps/network.log /3 sudo wpa_cli scan
/3 killall -g --older-than 15m openaps /3 cd /home/pi/aps && oref0-reset-git
/3 cd /home/pi/aps && oref0-truncate-git-history /3 cd /home/pi/aps && ps aux |(...) cgm-loop.log
/3 cd /home/pi/aps && ps aux (...) ns-loop.log /3 cd /home/pi/aps && (...) pump-loop.log
/3 * ps aux | grep -v grep (...) network.log

JELCRAWFORD
@JELCRAWFORD
Mar 05 2017 20:36
So I just had a Resident Endo ask me if our "artificial pancreas" was a medicine that DS takes daily...... It's difficult to even reply to that question......
Dana Lewis
@danamlewis
Mar 05 2017 20:40
::scratches head::
Did you show them your cinnamon vial? ;)
Scott Leibrand
@scottleibrand
Mar 05 2017 20:42
@thebookins another option would be to run autosens much less frequently: maybe only every hour or two...
Autosens is pretty processor intensive, and generally the results don't change much hour to hour.
Tim Street
@tim2000s
Mar 05 2017 20:43
@scottleibrand I like that idea!
Dana Lewis
@danamlewis
Mar 05 2017 20:43
:+1:
Tim Street
@tim2000s
Mar 05 2017 20:46
I've just reset mine to every 15 mins. Got a feeling that will have a much bigger impact.
Paul Dickens
@thebookins
Mar 05 2017 20:47
Good idea @scottleibrand I will try that too. @danamlewis I reckon the 3 minute cron is worth a try even if I drop a few loops as 20% extra might get us to bedtime. I will keep an eye on it. Btw has anyone done a basic accounting of where the processor spends its time? Would be nice to quantify how much improvement to expect from the NS optimisation for example.
Chris Oattes
@cjo20
Mar 05 2017 20:48
If you run it all at the same frequency, I suspect autosens will be the component that spends the most time running.
@danamlewis I'd hate to see how confused that endo gets when APS manages to shrink down to be pill-sized :P
Tim Street
@tim2000s
Mar 05 2017 20:50
:+1:
John Benjamin
@Bender1061
Mar 05 2017 20:53
@JELCRAWFORD Yes some Endo's are well "WTF Mate?" but there are some out there that have heard of OpenAPS and those are the best ones! When I was in the hospital a few weeks ago, The one knew all about it (even let my system run while in surgery), I had a steady stream of the rest of the Endo's come to my room for the next several days so they could hear about it. The hard part is for the nurses is how to record that kind of information in the hospital systems, since they are supposed to record anything that is changed from what your normal Basal rates are. Luckily the Endo told them to let me completely control it since I have great control, so I just told them when I did any boluses.
JELCRAWFORD
@JELCRAWFORD
Mar 05 2017 20:56
@danamlewis @cjo20 - no, didn't think of it... I knew I was in trouble when she asked (pediatric endo at oncall line - I drew the student) part way through if DS had Type 1 Diabetes.... Perhaps I should have pretended, at that point, to get cut off from the call..... besides, I heard it is either sprouted grains or cumin - someone just told me yesterday this would cure all our ills... imagine the effect of all three, cinnamon, cumin and sprouted grains.. Who needs advanced technology :)
Matthias
@ceben80
Mar 05 2017 21:01
Thx @tim2000s adjusted mine to 15 min as well, good approach!
Scott Leibrand
@scottleibrand
Mar 05 2017 21:40
Nope, that won't help at all.
Autosens only runs when pumphistory-24h gets refreshed, which is every 20-30m I believe. Delaying the cron to */15 will only add a lag in between that refresh and the recalculation.
If you are shooting for something more like every hour or two, you could do that in cron, but otherwise you'll want to adjust the two age checks for refreshing pumphistory-24h.
I was thinking about adding something to oref0-pump-loop to make it refresh that less frequently when the Edison battery voltage is below the "charging" level.
JELCRAWFORD
@JELCRAWFORD
Mar 05 2017 21:52
@Bender1061 we normally have a great endo - so I can't complain really, but today's call was not very helpful to the oncall resident. I have to admit, as a new and upcoming physician, it is a bit alarming to me they can be so under informed. Oh well. Glad your endo team was so great about your surgery and letting you use your rig - that's awesome!
j4cbo
@j4cbo
Mar 05 2017 21:58
speaking of endos, i'm looking for a new one... anyone have recommendations for one in the bay area (preferably in san francisco) who's "aware" of openaps?
Paul Tinson
@ptinson
Mar 05 2017 22:34
Sorry if this is a silly question.. When oref0 gets the latest SGV does it trigger an event that other parts of the code can watch and respond to? I am currently writing a method to start tracking GPS location when SGV is starting to go into hypo, and send that to a remote server.
Once the Hypo event is over it no longer sends GPS co-ords
Dana Lewis
@danamlewis
Mar 05 2017 22:38
No, it triggers based on cron
Paul Tinson
@ptinson
Mar 05 2017 22:38
does it log the value out to a file?
Or set an environment variable?
Paul Dickens
@thebookins
Mar 05 2017 22:44
OK @scottleibrand that makes sense. Where's the low-hanging fruit with loop performance? Has anyone looked into the cost of all the floating-point arithmetic? Probably negligible, but might be worth some profiling?
Arsenijs
@CRImier
Mar 05 2017 22:46
That's a good question, and the one I'm trying to understand right now. However, I just joined this project and, therefore, can't yet understand where the issues lie.
eliotsdad
@eliotsdad
Mar 05 2017 22:51
Hello, I am trying to setup Bluetooth with the Edison, and am getting the following error when trying to restart the Bluetooth after running the "killall" command: [1] 5325
root@ubilinux:~/eliot-nightscout# sudo: unable to resolve host ubilinux
D-Bus setup failed: Name already in use
I saw the "unable to resolve host ubilinux" error several times during the oref0 script, but it didn't cause any problems. Just wondering if I should worry, or not.
John Benjamin
@Bender1061
Mar 05 2017 23:10
@ptinson for what you are wanting, I would use cron to call a bash script, that would read the latest svg in monitor/glucose, and then if it was high, do you thing with gps, but there is not a gps on the edison, so the rest I have no idea how you would do that.
jmcrawford
@jmcrawford
Mar 05 2017 23:12
@eliotsdad Nothing to worry about. Just means you didn't add "ubilinux" to your /etc/hosts file
eliotsdad
@eliotsdad
Mar 05 2017 23:14
Thanks @jmcrawford. So, the "D-Bus setup failed: Name already in use" is an unrelated error?
It was not unrelated. I added ubilinux to the /etc/hosts file and all is going well. Thanks @jmcrawford
Paul Tinson
@ptinson
Mar 05 2017 23:21
@Bender1061 Thanks for the pointer, do you mean run it and grab the latest from nightscout or other SGV sources?
I am fine with the GPS bit.
Andy Sharrow
@dramageek
Mar 05 2017 23:23
I've been on Android Nougat for a while, but haven't had any luck finding a good solution to make sure Bluetooth and BT Tethering stay on. Anybody had success?
Most of the apps I've tried don't seem to play well with Nougat- they don't see the BT radio.
John Benjamin
@Bender1061
Mar 05 2017 23:24
@ptinson I would grab it from the rig itself, use something like jq to get the latest reading. the monitor/glucose.json is the place everyones cgm reading end up before being used. jq is really nice for that type of thing. how do you plan on implementing gps?
Diabetic_Dude
@diabetic_dude_twitter
Mar 05 2017 23:27
hey I am having a hard time getting wireless set up on my edison. could someone please help me to find out where I am messing up? I can post my wpa_supplicant.conf (w/o) my keys and the network interfaces, I have been looking for a few days now and cant see to find out where the errors are
Arsenijs
@CRImier
Mar 05 2017 23:28
Sure, go ahead
The wpa_supplicant.conf and the /etc/network/interfaces both would help
Diabetic_Dude
@diabetic_dude_twitter
Mar 05 2017 23:29
oops
Paul Tinson
@ptinson
Mar 05 2017 23:30
@Bender1061 Thanks, I will take a look and grab it from there.
I am using GPS from a standalone module that is connected via usbserial to the explorer board
In a couple of weeks i will switch to using a GPS from a simcom module that also gives the edison a dedicated 3/4 G connection
John Benjamin
@Bender1061
Mar 05 2017 23:32
@ptinson cool, let us know how it goes!
Paul Tinson
@ptinson
Mar 05 2017 23:32
I am doing what i can while i wait for a pump to arrive:)
Diabetic_Dude
@diabetic_dude_twitter
Mar 05 2017 23:35
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
network={
    ssid="The_Point_5G"
    psk="secret"
}
network={
    ssid="The_Point"
    psk="Secret"
}
network={
    ssid="James's iPhone"
    psk="secret"
}
# interfaces(5) file used by ifup(8) and ifdown(8)
auto lo
iface lo inet loopback

auto usb0
iface usb0 inet static
    address 192.168.2.15
    netmask 255.255.255.0

auto wlan0
iface wlan0 inet dhcp
    wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf
Dana Lewis
@danamlewis
Mar 05 2017 23:41
@jcorbett80 looks like you commented on a commit, but you'll need to do a full PR to add your name to the list. http://openaps.readthedocs.io/en/latest/docs/Resources/my-first-pr.html
John Benjamin
@Bender1061
Mar 05 2017 23:44
@diabetic_dude_twitter
$ sudo nano /etc/network/interfaces

# interfaces(5) file used by ifup(8) and ifdown(8)
auto lo
iface lo inet loopback

#auto usb0
iface usb0 inet static
    address 192.168.2.15
    netmask 255.255.255.0

auto wlan0
allow-hotplug wlan0
iface wlan0 inet manual
   wpa-roam /etc/wpa_supplicant/wpa_supplicant.conf
jcorbett80
@jcorbett80
Mar 05 2017 23:45
@danamlewis lol was trying simply to add my names to the list ad a first try. Followed the link you just gave me. It made a branch in mine. I went to the file and did and edit and a comment but it never took the edit to mine so I could do the pull request. I am about to leave I will see what I missed a little later when I return. Thank you for letting me know. That's what I was waiting for because I knew it didn't act like your docs said it would and you just verified it
John Benjamin
@Bender1061
Mar 05 2017 23:46
@diabetic_dude_twitter looks like you are calling your wpa_supplicant.conf differently than I am
Arsenijs
@CRImier
Mar 05 2017 23:46
@diabetic_dude_twitter So, in the interfaces file, you do need the "allow-hotplug" part, first of all
wpa_supplicant looks like one I personally use, even the formatting should work OK. Do neither of those three networks work?
Scott Leibrand
@scottleibrand
Mar 05 2017 23:49
@thebookins I think the lowest-hanging fruit is reducing the number of times we spin up a full python or nodeis interpreter, by moving things over to an oref0-pump-loop shell script with functions for most of the things we currently do as aliases. I know @cjo20 also wanted to do some things with IOB calculations, moving to lookup tables...
Paul Tinson
@ptinson
Mar 05 2017 23:51
@Bender1061 Will do. My plan at the moment is to store the GPS data locally on the edison in a redis list, it will keep the last 30 minutes of location data. when a hypo is seen it will send that data to my nightscout server.
With the simcom unit I will also listen for SMS events, the response would be an update to my server and an sms response with the last known coordinates
the goal being in the unlikely event my daughter needs assistance and cant help herself I have some location to direct me to
but to also preserve her privacy, I dont have the location information all the time
I considered using find my phone functions, but thats not nearly as much fun
Diabetic_Dude
@diabetic_dude_twitter
Mar 05 2017 23:53
# interfaces(5) file used by ifup(8) and ifdown(8)
auto lo
iface lo inet loopback

auto usb0
iface usb0 inet static
    address 192.168.2.15
    netmask 255.255.255.0

auto wlan0
allow-hotplug wlan0
iface wlan0 inet dhcp
    wpa-roam /etc/wpa_supplicant/wpa_supplicant.conf
Arsenijs
@CRImier
Mar 05 2017 23:55
Like that. I don't know if you need "iface wlan0 inet manual" instead of "iface wlan0 inet dhcp", you might want to try that, too.
Diabetic_Dude
@diabetic_dude_twitter
Mar 05 2017 23:56
ok thnx rebooting now will try if I do not get ssh access