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

22nd
Sep 2016
diabeticgonewild
@diabeticgonewild
Sep 22 2016 00:45
I wish I could smoke marijuana right now. I'm under the weather and nauseated from immunomodulatory treatment and I want to eat, but not up to it. It would be nice to have the munchies. But, getting a Marinol prescription tomorrow, as my doctor is clinic tomorrow. But, the pharmacy probably has to special order it so probably won't get it until next week.
But smoking a joint is much more enjoyable than marinol
David
@davidkeddydb
Sep 22 2016 00:46
I am running into a new issue with recent-missing-entries.json. Kicking an error saying: AttributeError: 'NoneType' object has no attribute 'read'
No JSON object could be decoded What did I screw up?
diabeticgonewild
@diabeticgonewild
Sep 22 2016 00:51
Probably there is something wrong with the creation of recent-missing-entries.json and you should check that section on your OpenAPS.ini for any errors
Cause obviously nothing is being written to recent-missing-entries.jaon
Russell Gardner
@RussGG
Sep 22 2016 01:08
The other day I installed the setup script. In the link there wasn’t a step 3, so I started poking around at what had been installed. I ran openaps enact and it connected to NS. I did that several times to watch what was happening. today I received an error when I did it. I went to the link Dana had above and it now has the step 3. I ran that and received the same error
raise AckError("ACK is 0 bytes:\n%s" % lib.hexdump(raw)) decocare.errors.AckError: ACK is 0 bytes:
Any thoughts?
Also….. how do I stop the loop?
Scott Leibrand
@scottleibrand
Sep 22 2016 01:14
to stop the loop, you edit the crontab (crontab -e) and comment out (add a # to the beginning of) the pump-loop line
I don't remember what that AckError means. do you get any errors using the same Carelink stick on the same rig with a different loop config?
Russell Gardner
@RussGG
Sep 22 2016 01:16
This is my first loop.
Scott Leibrand
@scottleibrand
Sep 22 2016 01:20
ah. have you ever gotten this carelink to talk to this pump?
Russell Gardner
@RussGG
Sep 22 2016 01:21
Yes. I have never had a problem with it. The loop keeps retrying so I cant get to a prompt. Is it ok to just unplug the pi?
Scott Leibrand
@scottleibrand
Sep 22 2016 01:21
Ctrl-C
you're just tailing the log file, so you can cancel out of that
Russell Gardner
@RussGG
Sep 22 2016 01:22
done thanks
let me check that I can get to the pump.
Scott Leibrand
@scottleibrand
Sep 22 2016 01:23
don't forget to do the crontab -e thing
before you go running manual commands that use the Carelink
maybe also reboot after that to make sure the carelink is in a good state
running manual commands while the loop is using the carelink can sometimes get it into a bad state
Russell Gardner
@RussGG
Sep 22 2016 01:26
Where do I put the #?
NIGHTSCOUT_HOST=https://ccg2.azurewebsites.net
API_SECRET=72ed4e79dec288f4b3e85466f1f92330771154ac
PATH=/home/pi/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/games:/usr/games
* * * * * sudo wpa_cli scan
* * * * * killall -g --older-than 10m openaps
* * * * * cd /home/pi/ccgoref01 && oref0-reset-git
* * * * * cd /home/pi/ccgoref01 && ps aux | grep -v grep | grep -q 'openaps get-bg' || ( date; openaps get-bg ; cat cgm/glucose.json | json -a $
* * * * * cd /home/pi/ccgoref01 && ps aux | grep -v grep | grep -q 'openaps ns-loop' || openaps ns-loop | tee -a /var/log/openaps/ns-loop.log
* * * * * cd /home/pi/ccgoref01 && ( ps aux | grep -v grep | grep -q 'openaps pump-loop' || openaps pump-loop ) 2>&1 | tee -a /var/log/openaps/$
Scott Leibrand
@scottleibrand
Sep 22 2016 01:26
before the first * on the last line
Russell Gardner
@RussGG
Sep 22 2016 01:32
File Name to Write: /tmp/crontab.VF7lo2/crontab ^G Get Help M-D DOS Format M-A Append M-B Backup File ^C Cancel M-M Mac Format M-P Prepend
Scott Leibrand
@scottleibrand
Sep 22 2016 01:34
just hit enter
Russell Gardner
@RussGG
Sep 22 2016 01:35
LOL!!! I would have never thought it would be that simple!!!
pi@raspberrypi:~/ccgoref01 $ openaps report show settings/model.json pump://JSON/model/settings/model.json pi@raspberrypi:~/ccgoref01 $ pi@raspberrypi:~/ccgoref01 $ cat settings/model.json "722"pi@raspberrypi:~/ccgoref01 $
garykidd
@garykidd
Sep 22 2016 01:40
@scottleibrand git the following error while tailing pumpo-loop after latest install via your script...
tarting pump-loop at Wed 21 Sep 21:31:17 EDT 2016:
pump://JSON/read_temp_basal/monitor/temp_basal.json
reporting monitor/temp_basal.json
Profile less than 60m old
temp_basal.json less than 5m old
pumphistory more than 5m old: Refreshed pumphistory
Could not parse input data:  { [Error: Cannot find module '/home/pi/APS401/monitor/glucose.json'] code: 'MODULE_NOT_FOUND' }
determine-basal://text/shell/enact/suggested.json
reporting enact/suggested.json
Settings less than 10m old
Pumphistory-24 less than 20m old
Completed pump-loop at Wed 21 Sep 21:31:46 EDT 2016
is that just stale bg data maybe?
but it doesn't seem to be uploading pump / openaps data either actually
Scott Leibrand
@scottleibrand
Sep 22 2016 01:43
it looks like all the pump data is current
except pumphistory, which it successfully refreshed
but for some reason glucose.json isn't getting written at all
David
@davidkeddydb
Sep 22 2016 01:48
@diabeticgonewild \openaps report show nightscout/recent-missing-entries.json --cli
openaps use ns shell format-recent-type tz entries monitor/glucose.json
dkeopenaps/monitor $ cat glucose.json
[
{
"trend_arrow": "FLAT",
"system_time": "2016-09-22T03:22:45",
"display_time": "2016-09-21T21:29:14",
"glucose": 100
},
{
"trend_arrow": "FLAT",
"system_time": "2016-09-22T03:17:45",
"display_time": "2016-09-21T21:24:15",
"glucose": 99
Russell Gardner
@RussGG
Sep 22 2016 01:49
I just realized that 'report show' is an old report. I can’t connect to the pump now. I will look back and find out how to reset the USB ports
garykidd
@garykidd
Sep 22 2016 01:52
@scottleibrand yeah have no idea why that's not there
back to APS301 for tonight if I can manage to...
Scott Leibrand
@scottleibrand
Sep 22 2016 01:52
before you do that...
did you have APS301 stuff in cron when you ran APS401?
and did all the APS401 stuff get created in cron, or just some of it?
there are some checks of whether things are already in cron that might've prevented it from adding all of them
given the way people are using the script, I should tighten up those greps
as a workaround, if it looks like cron lines are missing, you can save a backup of crontab -l, delete the entire crontab with crontab -e, and then re-run the setup script on APS401
Russell Gardner
@RussGG
Sep 22 2016 01:57
I just unplugged the carestick and put it back in now its getting to the pump.
pi@raspberrypi:~/ccgoref01 $ cat settings/model.json "722"pi@raspberrypi:~/ccgoref01 $ tail -F /var/log/openaps/pump-loop.log File "/usr/local/lib/python2.7/dist-packages/decocare-0.0.30-py2.7.egg/decocare/stick.py", line 515, in product_info return self.query(ProductInfo) File "/usr/local/lib/python2.7/dist-packages/decocare-0.0.30-py2.7.egg/decocare/stick.py", line 509, in query return self.process( ) File "/usr/local/lib/python2.7/dist-packages/decocare-0.0.30-py2.7.egg/decocare/stick.py", line 496, in process ack, response = self.command.respond(raw) File "/usr/local/lib/python2.7/dist-packages/decocare-0.0.30-py2.7.egg/decocare/stick.py", line 71, in respond raise AckError("ACK is 0 bytes:\n%s" % lib.hexdump(raw)) decocare.errors.AckError: ACK is 0 bytes:
Eric Jensen
@elnjensen
Sep 22 2016 01:59
@scottleibrand Just taking a run through the setup script. I see it doesn't ask about Dexcom G4 vs. G5 in the interactive setup - just assumes G4 if you don't specify on command line. Any reason not to have it prompt the way it does for other things? I could try to add that, unless there's a reason not to.
garykidd
@garykidd
Sep 22 2016 02:03
@scottleibrand will try one more time tonight...will install without adding port info tty..... it seems to run but not report to NS...and also stumbles everytime pump history is actually refreshed.....
This message was deleted
pi@raspberrypi:~/APS401 $ tail -F /var/log/openaps/pump-loop.log
Starting pump-loop at Wed 21 Sep 21:56:04 EDT 2016:
pump://JSON/read_temp_basal/monitor/temp_basal.json
reporting monitor/temp_basal.json
Profile less than 60m old
temp_basal.json less than 5m old
Pumphistory less than 5m old
Settings less than 10m old
Pumphistory-24 less than 20m old
Completed pump-loop at Wed 21 Sep 21:56:08 EDT 2016

Starting pump-loop at Wed 21 Sep 21:57:09 EDT 2016:
pump://JSON/read_temp_basal/monitor/temp_basal.json
reporting monitor/temp_basal.json
Profile less than 60m old
temp_basal.json less than 5m old
Pumphistory less than 5m old
Settings refreshed
Pumphistory-24 less than 20m old
Completed pump-loop at Wed 21 Sep 21:57:30 EDT 2016

Starting pump-loop at Wed 21 Sep 21:58:11 EDT 2016:
pump://JSON/read_temp_basal/monitor/temp_basal.json
reporting monitor/temp_basal.json
Profile less than 60m old
temp_basal.json less than 5m old
Pumphistory less than 5m old
Settings less than 10m old
Pumphistory-24 less than 20m old
Completed pump-loop at Wed 21 Sep 21:58:15 EDT 2016

Starting pump-loop at Wed 21 Sep 21:59:06 EDT 2016:
pump://JSON/read_temp_basal/monitor/temp_basal.json
reporting monitor/temp_basal.json
Profile less than 60m old
temp_basal.json less than 5m old
Pumphistory less than 5m old
Settings less than 10m old
Pumphistory-24 less than 20m old
Completed pump-loop at Wed 21 Sep 21:59:09 EDT 2016

Starting pump-loop at Wed 21 Sep 22:00:02 EDT 2016:
pump://JSON/read_temp_basal/monitor/temp_basal.json
reporting monitor/temp_basal.json
Profile less than 60m old
temp_basal.json less than 5m old
Pumphistory less than 5m old
Settings less than 10m old
Pumphistory-24 less than 20m old
Completed pump-loop at Wed 21 Sep 22:00:15 EDT 2016

Starting pump-loop at Wed 21 Sep 22:01:07 EDT 2016:
pump://JSON/read_temp_basal/monitor/temp_basal.json
reporting monitor/temp_basal.json
Profile less than 60m old
temp_basal.json less than 5m old
pumphistory more than 5m old: Refreshed pumphistory
Could not parse input data:  { [Error: Cannot find module '/home/pi/APS401/monitor/glucose.json'] code: 'MODULE_NOT_FOUND' }
determine-basal://text/shell/enact/suggested.json
reporting enact/suggested.json
Settings less than 10m old
Pumphistory-24 less than 20m old
Completed pump-loop at Wed 21 Sep 22:01:25 EDT 2016

Starting pump-loop at Wed 21 Sep 22:02:14 EDT 2016:
pump://JSON/read_temp_basal/monitor/temp_basal.json
reporting monitor/temp_basal.json
Profile less than 60m old
temp_basal.json less than 5m old
Pumphistory less than 5m old
Settings less than 10m old
Pumphistory-24 less than 20m old
Completed pump-loop at Wed 21 Sep 22:02:30 EDT 2016
John Benjamin
@Bender1061
Sep 22 2016 02:05
@elnjensen and @scottleibrand I was thinking the same thing with the mdt on the ored Setup as well. I still have not been able to get the parameters formated correct, so I just change the file and make the mdt the default. (easy way to change the Maxiob as well.
garykidd
@garykidd
Sep 22 2016 02:21
@scottleibrand is this simply becuase I didnt plug in my receiver? would that also cause it to not upload OPenaps pill and PUMP PILLS ON NS though?
Starting pump-loop at Wed 21 Sep 22:20:07 EDT 2016:
pump://JSON/read_temp_basal/monitor/temp_basal.json
reporting monitor/temp_basal.json
Profile less than 60m old
temp_basal.json less than 5m old
pumphistory more than 5m old: Refreshed pumphistory
Could not parse input data:  { [Error: Cannot find module '/home/pi/APS401/monitor/glucose.json'] code: 'MODULE_NOT_FOUND' }
determine-basal://text/shell/enact/suggested.json
reporting enact/suggested.json
Settings less than 10m old
Pumphistory-24 less than 20m old
Completed pump-loop at Wed 21 Sep 22:20:37 EDT 2016
garykidd
@garykidd
Sep 22 2016 02:26
nope
back to 301 for tonight
Eric Jensen
@elnjensen
Sep 22 2016 02:57
So I decided to try testing the new setup script tonight, and didn't get far enough to even try running it. (Not through fault of the script, just ran out of time.) BUT - it seems to have affected my main loop a little bit, I'm guessing because the setup process installs a newer version of oref0 than I had before. (At least that's the only thing I can identify.) The change is not in the loop per se, but in what I see in Nightscout - it went from showing me the IOB that is bolus+extra basals (the "net IOB") to now showing me only the bolus IOB.
How can I get the previous behavior back?
dougtakeuti
@dougtakeuti
Sep 22 2016 02:58

@scottleibrand I'll be testing the setup script for enlites tonight. However, when I try to switch branches I get.

pi@raspberrypi:~/src/oref0 $ git checkout dev
error: Your local changes to the following files would be overwritten by checkout:
        bin/clockset.sh
Please, commit your changes or stash them before you can switch branches.
Aborting

How can I get around this?

Eric Jensen
@elnjensen
Sep 22 2016 03:02
I recall that @jasoncalabrese had posted here a while back the variables that set how NS would determine which IOB calculation to display, but I can't locate the post.
Jason Calabrese
@jasoncalabrese
Sep 22 2016 03:06
If there device status data with iob, that gets displayed, NS also does it's bolus only iob in the tooltip on the iob pill
Eric Jensen
@elnjensen
Sep 22 2016 03:08
Hmm, so must be in how IOB is getting put into the report.
Tooltip on the IOB pill shows me what the last bolus amount and time were.
Jason Calabrese
@jasoncalabrese
Sep 22 2016 03:14
That's what it would look like if you were only uploading treatments, and not device status
Eric Jensen
@elnjensen
Sep 22 2016 03:19
Screen Shot 2016-09-21 at 11.17.43 PM.png
Here's what I'm seeing - openaps pill shows both IOB and basal IOB to be > 0, but IOB pill says 0.
Sorry "openaps tooltip" from the pill gives the non-zero IOB values.
dougtakeuti
@dougtakeuti
Sep 22 2016 03:22
@scottleibrand please ignore my former message. I got that sorted.
Eric Jensen
@elnjensen
Sep 22 2016 03:23
Think I'll just head to bed and see if this sorts itself out once it has run longer since the upgrade. Might be just some inconsistencies in the before/after reporting that will sort itself out once the old data cycles out. Will post again tomorrow if it's still an issue. Thanks @jasoncalabrese for taking a look, have a good night.
Jason Calabrese
@jasoncalabrese
Sep 22 2016 03:33
That's really weird @elnjensen, see what YOUR_ SITE/api/v2/properties/iob,pump shows
dougtakeuti
@dougtakeuti
Sep 22 2016 03:51
@scottleibrand this is what I get running the oref0-setup.sh scripthttps://gist.github.com/dougtakeuti/a1ef058c1068ac79df322a62739b8715
Matthias
@ceben80
Sep 22 2016 03:56
@scottleibrand Good morning Scott, new loop was running fine, see twitter, but very strange, my azure is working again, didn't expand my contingent, glad to see Nightscout is working again :star2:
Scott Leibrand
@scottleibrand
Sep 22 2016 04:14
@ceben80 must have been a 24h quota. Did you change anything to prevent it from using it up early again?
@dougtakeuti looks like your src/oref0 dir or a subdir is owned by root. Probably just sudo rm it and try again
Matthias
@ceben80
Sep 22 2016 04:17
I limited the count ns-glucose.ini to 288, that's all
Scott Leibrand
@scottleibrand
Sep 22 2016 04:19
@elnjensen adding the CGM question to interactive setup would be great.
Matthias
@ceben80
Sep 22 2016 04:19
nevertheless I am going to plan a local ns installation for offline looping independent of internet usage
Scott Leibrand
@scottleibrand
Sep 22 2016 04:20
Any other outstanding questions I missed?
dougtakeuti
@dougtakeuti
Sep 22 2016 04:49
@scottleibrand ok, done that. Now I get this:
Checking /home/pi/myopenaps: Traceback (most recent call last):
  File "/usr/local/bin/openaps", line 4, in <module>
    __import__('pkg_resources').require('openaps==0.1.6.dev0')
  File "build/bdist.linux-armv7l/egg/pkg_resources/__init__.py", line 2927, in <module>
  File "build/bdist.linux-armv7l/egg/pkg_resources/__init__.py", line 2913, in _call_aside
  File "build/bdist.linux-armv7l/egg/pkg_resources/__init__.py", line 2940, in _initialize_master_working_set
  File "build/bdist.linux-armv7l/egg/pkg_resources/__init__.py", line 635, in _build_master
  File "build/bdist.linux-armv7l/egg/pkg_resources/__init__.py", line 943, in require
  File "build/bdist.linux-armv7l/egg/pkg_resources/__init__.py", line 829, in resolve
pkg_resources.DistributionNotFound: The 'openaps==0.1.6.dev0' distribution was not found and is required by the application
Can't init /home/pi/myopenaps
Scott Leibrand
@scottleibrand
Sep 22 2016 05:21
Try to reinstall the openaps toolkit. sudo pip install -U openaps
Jason Calabrese
@jasoncalabrese
Sep 22 2016 05:25
it would be cool to have NS run only using the local report files, instead of mongo
@SandraK82 that might make more sense than adjusting queries for mongo 2
Sandra Keßler
@SandraK82
Sep 22 2016 05:29
@jasoncalabrese of course, however i want to have all on a single raspi3, ns instance, mongo and loop
Jason Calabrese
@jasoncalabrese
Sep 22 2016 05:29
would be much lighter without mongo
all the data that you need to real time is in the report files
would need to swap out the storage, with a setting
Sandra Keßler
@SandraK82
Sep 22 2016 05:30
for me Looping on raspi will be only an intermidiate step, longterm i want to move all to iOS and switch looppump from 522 to combo
Matthias
@ceben80
Sep 22 2016 05:47
:+1:
C-Ville
@C-Ville
Sep 22 2016 06:21
an accessible combo would take a lot of pressure from people that want to start looping as it is still available. In Germany it is currently the biggest hurdle when you want to start looping, getting a Medtronic pump that can loop
Jason Calabrese
@jasoncalabrese
Sep 22 2016 06:31
Screenshot 2016-09-21 23.30.52.png
multi rig battery monitoring
C-Ville
@C-Ville
Sep 22 2016 06:31
very nice
Matthias
@ceben80
Sep 22 2016 07:06
great @jasoncalabrese :clap:
Jason Calabrese
@jasoncalabrese
Sep 22 2016 07:06
Screenshot 2016-09-22 00.06.38.png
alarms with custom battery levels too
Matthias
@ceben80
Sep 22 2016 07:40
@jasoncalabrese multi rig battery monitoring is realized with monitor/openaps-status.json :question:
Jason Calabrese
@jasoncalabrese
Sep 22 2016 07:45
Matthias
@ceben80
Sep 22 2016 07:58
jupp
edison@ubilinux:~/EdisonVoltage$ sudo ./voltage short
91% 4090mVedison@ubilinux:~/EdisonVoltage$ sudo ./voltage short
96% 4145mVedison@ubilinux:~/EdisonVoltage$
Tim Street
@tim2000s
Sep 22 2016 10:08
Well the scripts ran well for me last night. Had to go in and modify a couple of pieces but I don't think they're standard mods as I'm not sure how many people are using a 640g as sg uploader. It all seems to work okay and my only issue is now with some of my non-aps code which isn't always generating clean values.
Tim Street
@tim2000s
Sep 22 2016 10:17
But like @SandraK82 I get the benefit of a phone based solution.
Eric Jensen
@elnjensen
Sep 22 2016 11:03
Good morning - still seeing the issue with NS only reporting my bolus IOB, not the IOB that OpenAPS uploads. @jasoncalabrese it's a while since your question so not sure if it's still useful, but here's what I see in api/v2/properties/iob,pump:
{"iob":{"iob":0.7822652651804854,"activity":0.10651413333333332,"lastBolus":{"_id":"57e3b5d150351f905150bd7a","bg":"153","ratio":"11","bolus":{"programmed":0.8,"_type":"Bolus","_description":"Bolus 2016-09-22T06:41:22 head[8], body[0] op[0x01]","timestamp":"2016-09-22T06:41:22-04:00","_body":"","_head":"0100200020000000","amount":0.8,"unabsorbed":0,"duration":0,"type":"normal","_date":"9669461610"},"timestamp":"2016-09-22T06:41:22-04:00","created_at":"2016-09-22T06:41:22-04:00","glucoseType":"BolusWizard","enteredBy":"openaps://medtronic/523","wizard":{"_type":"BolusWizard","bg":153,"bg_target_low":90,"_description":"BolusWizard 2016-09-22T06:41:22 head[2], body[15] op[0x5b]","timestamp":"2016-09-22T06:41:22-04:00","_body":"0050006e3c5a200000000000002069","bg_target_high":105,"carb_ratio":11,"food_estimate":0,"unabsorbed_insulin_total":0,"correction_estimate":0.8,"carb_input":0,"_head":"5b99","bolus_estimate":0.8,"sensitivity":60,"_date":"9669061610"},"insulin":0.8,"eventType":"Correction Bolus","duration":0,"notes":"Normal bolus with wizard.\nProgrammed bolus 0.8\nDelivered bolus 0.8\nPercent delivered:  100%\nFood estimate 0\nCorrection estimate 0.8\nBolus estimate 0.8\nTarget low 90\nTarget high 105\nHypothetical glucose delta -48\nGlucose was: 153","medtronic":"mm://openaps/mm-format-ns-treatments/Correction Bolus","glucose":153,"mills":1474540882000,"mgdl":153},"source":"Care Portal","display":"0.78","displayLine":"IOB: 0.78U"},"pump":{"_id":"57e3b86c9366a8781da15819","device":"openaps://raspberrypi","pump":{"battery":{"status":"normal","voltage":1.33},"status":{"status":"normal","timestamp":"2016-09-22T10:54:29.000Z","bolusing":false,"suspended":false},"reservoir":131.15,"clock":"2016-09-22T06:54:11"},"openaps":{"suggested":{"bg":156,"temp":"absolute","snoozeBG":183,"timestamp":"2016-09-22T10:54:22.000Z","rate":1.25,"reason":"COB: undefined, Dev: 28, BGI: -2.22, ISF: 60, Target: 98; Eventual BG 115 >= 105, temp 0.85<1.25U/hr","eventualBG":115,"duration":30,"tick":"+3","IOB":1.146,"moment":"2016-09-22T10:54:22.000Z"},"iob":{"netbasalinsulin":0.95,"timestamp":"2016-09-22T06:54:11.000Z","activity":0.0074,"basaliob":0.359,"hightempinsulin":0.95,"bolussnooze":0.753,"iob":1.146,"moment":"2016-09-22T06:54:11.000Z"},"enacted":{"bg":156,"temp":"absolute","snoozeBG":183,"recieved":true,"predBGs":{"IOB":[156,158,160,161,161,161,161,159,158,156,153,150,146,142,139,135,132,129,125,123,120,118,115,113,111,110,108,107,106,105,104,103,103,102],"moment":"2016-09-22T10:54:26.000Z"},"reason":"COB: undefined, Dev: 28, BGI: -2.22, ISF: 60, Target: 98; Eventual BG 115 >= 105, temp 0.85<1.25U/hr","rate":1.25,"eventualBG":115,"timestamp":"2016-09-22T10:54:26.000Z","duration":30,"tick":"+3","IOB":1.146,"moment":"2016-09-22T10:54:26.000Z"}},"created_at":"2016-09-22T10:54:36.932Z","mills":1474541676932,"clockMills":1474527251000,"data":{"level":2,"clock":{"value":"2016-09-22T06:54:11.000Z","label":"Last Clock","display":"4h ago","level":2,"message":"URGENT: Pump data stale"},"reservoir":{"value":131.15,"label":"Reservoir","display":"131.15U","level":-3},"status":{"value":"normal","display":"normal","label":"Status"},"battery":{"value":1.33,"label":"Battery","display":"1.33v","level":-3},"device":{"label":"Device","display":"openaps://raspberrypi"},"title":"URGENT: Pump data stale","message":"Pump Battery: 1.33v\nPump Reservoir: 131.15U"}}}
Took a 0.8 u bolus this morning (loop corrections not quite right overnight :worried: ) and that's all that's currently showing in NS despite there also being some active basal IOB.
Eric Jensen
@elnjensen
Sep 22 2016 11:18
@scottleibrand @danamlewis Some feedback on the descriptive text for the testing page for the new setup script. Right now it says "You can run the following without affecting your existing loop setup" which isn't quite true, since it upgrades oref0 to the latest dev. So changing oref0 does affect the existing loops for those who didn't already have it. In my case it seems to have broken NS reporting of current IOB. I have a recent full image of my Raspberry Pi SD card so I'm thinking of rolling back to that to recover previous functionality and then can more deliberately try to figure out what's going on while still maintaining my existing loop functionality. There are a lot of things in dev I'd like to get to (e.g. AMA) but have really come to rely on the IOB reporting to know where I stand.
Eric Jensen
@elnjensen
Sep 22 2016 11:30
Sorry, one quick clarification - when I said above "loop corrections not quite right overnight" what I really mean is "loop can't quite keep up with whatever my body is trying to do right now" :smiley_cat: - loop itself is still running fine.
Tim Street
@tim2000s
Sep 22 2016 12:48
How do I turn on the prediction lines in Nightscout?
Tim Street
@tim2000s
Sep 22 2016 13:06
Is it SHOW_FORECAST openaps?
Also.... enabling the OPENAPS_FIELDS in nightscout, it seems to have stopped working. Anyone else find this?
Tim Street
@tim2000s
Sep 22 2016 13:19
So it is. I have the pink lines 🎉
OPENAPS_FIELDS kills my NS set up though!
David
@davidkeddydb
Sep 22 2016 13:36
I thought I was close then I screwed something up again and my recent-missing-entries is now giving me: AttributeError: 'NoneType' object has no attribute 'read'
reporting nightscout/recent-missing-entries.json
openaps report show nightscout/recent-missing-entries.json --cli
openaps use ns shell format-recent-type tz entries monitor/glucose.json
pi@raspberrypi:~/dkeopenaps $
openaps report invoke monitor/glucose.json
cgm://JSON/iter_glucose/monitor/glucose.json
reporting monitor/glucose.json
pi@raspberrypi:~/dkeopenaps $ openaps report show monitor/glucose.json
cgm://JSON/iter_glucose/monitor/glucose.json
Eric Jensen
@elnjensen
Sep 22 2016 13:50
@tim2000s I think you might want PUMP_FIELDS instead. Mine is reservoir battery clock status but you can choose of course. And then openaps is a separate plugin. Mine just shows last loop time in the pill, and then lots of other info in the hover-tooltip.
Hmm, but this suggests that OPENAPS_FIELDS should be OK.
Do you have DEVICESTATUS_ADVANCED="true" ?
Eric Jensen
@elnjensen
Sep 22 2016 14:02
@tim2000s Tried OPENAPS_FIELDS in my setup, per the docs I linked to. It doesn't break my setup, but adding fields there doesn't change the display, either.
Tim Street
@tim2000s
Sep 22 2016 14:03
Odd
Eric Jensen
@elnjensen
Sep 22 2016 14:06
Could be that latest dev has some fixes for this that I don't have. I think I am running 0.9.0-beta3.
Tim Street
@tim2000s
Sep 22 2016 14:10
Me too.
Scott Leibrand
@scottleibrand
Sep 22 2016 15:46
@elnjensen if you want to go back to oref0 master, I think you can cd ~/src/oref0 && git checkout master && npm run global-install
David
@davidkeddydb
Sep 22 2016 15:51
Ok, so I am running (still not connected to me yet) but now, though I don't know why I am still having an issue with the monitor/glucose tz issue @elnjensen helped me a few nights ago and it resolved it. I re-ran everything exactly as we did it, and now, no-go. I likely screwed it up when trying to correct something else. Watching on the 722, it is doing what it should be, but would love to get that back showing on nightscout
Scott Leibrand
@scottleibrand
Sep 22 2016 15:54
@elnjensen I would be interested to know if switching back to master fixes your IOB thing, and if so investigate what the backwards incompatibility is
David
@davidkeddydb
Sep 22 2016 16:10
I am getting a raise ValueError, "No closing quotation"
ValueError: No closing quotation on monitor/glucose.json
ig888ack
@ig888ack
Sep 22 2016 16:12
Hi everyone, I just wanted to introduce myself. I'm new to OpenAPS and just bought my 723 pump off of MedWow. I'll be looking to purchase the rest of the equipment over the next few weeks :)
Matthias
@ceben80
Sep 22 2016 16:20
Welcome
Rob Kresha
@rkresha
Sep 22 2016 16:22
@elnjensen @jasoncalabrese I too have a mismatch between Pill and what the rig reports as IOB, just like Eric, it appears to be just showing bolus
dev branch of cgm-remote-monitor
Tim Street
@tim2000s
Sep 22 2016 16:23
@davidkeddydb check your OPENAPS scripts where monitor/glucose.json is being launched from. I had a similar problem yesterday and the alias had an extra character in it.
David
@davidkeddydb
Sep 22 2016 16:27
@tim2000s is happening somewhere in the do-everything alias
Rob Kresha
@rkresha
Sep 22 2016 16:27
@jasoncalabrese Also I noticed you mention /api/v2/, everything in terms of setup and posting all reference /api/v1/ , I assume this is still accurate
Eric Jensen
@elnjensen
Sep 22 2016 16:29
@scottleibrand Good idea - I'll try rolling back to master tonight and see if that fixes it. Formatting of the monitor/iob.json file is definitely different with the two branches, so perhaps it's the creation or parsing of that somehow.
Jason Calabrese
@jasoncalabrese
Sep 22 2016 16:56
the v1 and v2 NS apis will both be active, the v1 apis are almost direct to the db, where the v2 apis include more processing, plugin integration, etc
@rkresha @elnjensen I wonder it it could be an issues with device times/time zones/report zoning, I'd probably have to look at 1 of your sites to figure it out and might take some digging
I'll try to do that tonight if you want to pm a url
also check that you're current with the NS dev branch
Jason Calabrese
@jasoncalabrese
Sep 22 2016 17:10

also @elnjensen I saw this in the json to posted

           "clock": {
                "value": "2016-09-22T06:54:11.000Z",
                "label": "Last Clock",
                "display": "4h ago",
                "level": 2,
                "message": "URGENT: Pump data stale"
            }

so something is out of sync,

Eric Jensen
@elnjensen
Sep 22 2016 17:26
Good catch. Quite likely a zoning issue, as I'm at UTC-4:00 (EDT).
Eric Jensen
@elnjensen
Sep 22 2016 17:37
Looking at my monitor/iob.json, I see all the timestamps have the local time, but with Z appended, so it is flagging them as UTC rather than local.
Looking at this now to see if I can sort it out.
Eric Jensen
@elnjensen
Sep 22 2016 17:46
OK @jasoncalabrese @scottleibrand here is a clue to what may be at the heart of the IOB / NS problem. Looking back at a monitor/iob/json file I saved in a backup last night before upgrading oref0 to dev, the entire file contents look like this:
{
  "netbasalinsulin": 0.4, 
  "activity": 0.0241, 
  "basaliob": -0.191, 
  "hightempinsulin": 0.65, 
  "bolussnooze": 0, 
  "iob": 0.586
}
Whereas now that I have updated to dev, the same report comes out with a bunch of entries that look like this:
[
  {
    "netbasalinsulin": -0.25, 
    "activity": 0.0448, 
    "basaliob": -0.376, 
    "time": "2016-09-22T13:45:23.000Z", 
    "hightempinsulin": 0.35, 
    "bolussnooze": 0.005, 
    "iob": 1.675
  }, 
  {
    "netbasalinsulin": -0.35, 
    "activity": 0.0418, 
    "basaliob": -0.408, 
    "time": "2016-09-22T13:50:23.000Z", 
    "hightempinsulin": 0.3, 
    "bolussnooze": 0, 
    "iob": 1.415
  }, 
  {
    "netbasalinsulin": -0.4, 
    "activity": 0.0389, 
    "basaliob": -0.388, 
    "time": "2016-09-22T13:55:23.000Z", 
    "hightempinsulin": 0.25, 
    "bolussnooze": 0, 
    "iob": 1.221
  }, 
  {
    "netbasalinsulin": -0.45, 
    "activity": 0.036, 
    "basaliob": -0.367, 
    "time": "2016-09-22T14:00:23.000Z", 
    "hightempinsulin": 0.2, 
    "bolussnooze": 0, 
    "iob": 1.041
  },
etc.
(Note that those are from different times, IOB values shouldn't be the same. )
The main differences are (a) the multiple entries, and (b) the presence of a timestamp.
And in this case the timestamps are zoned incorrectly - they show the trailing 'Z' which implies UTC. Should be -4:00 instead.
Eric Jensen
@elnjensen
Sep 22 2016 17:51
Changing the iob report to use monitor/pumphistory-zoned.json (my zoned version of the pump history) doesn't change anything - still comes out as above.
If indeed that zoning in the monitor/iob.json file is the issue, then let me know of any thoughts as how to fix it. (Aside from perl -pi -e 's/(\d+)Z\"/$1-04:00\"/' :smirk: )
Scott Leibrand
@scottleibrand
Sep 22 2016 18:06
I've seen similar issues related to old versions of openapscontrib.timezones I think it was
what timezone is your rig set in?
date should show it
could be that your rig is UTC but all your reports are hard-coded to EDT on your old loop
Jason Calabrese
@jasoncalabrese
Sep 22 2016 18:27
I think the time fields in iob.json are always in utc, mine are in utc too
diabeticgonewild
@diabeticgonewild
Sep 22 2016 19:30
Yeah having trouble writing and even driving cause my hands and legs shake like this. My blood sugar is NOT low.
https://youtu.be/yl9wYZH7-d8
So FML
wendycrumrine
@wendycrumrine
Sep 22 2016 21:12
Hello, so I'm a 35 yo Type1 in SF, starting to work through the documentation materials to finally build a CGM... I thought I'd say hello. This is terrifying, but also inspiring. I'm hoping this will help my control, as I am in need of some help! And I'm glad to be joining a community. Hope everyone's having a good day.
David
@davidkeddydb
Sep 22 2016 21:24
Has anyone done set up from Oref0 set up and had any of the timezone issues? I am considering doing a quick reinstall va wasting hours trying to find the ridiculous mistakes I must have made. Thanks in advance.
Dana Lewis
@danamlewis
Sep 22 2016 22:04
welcome @wendycrumrine!
Scott Leibrand
@scottleibrand
Sep 22 2016 22:20
@jasoncalabrese I read what @elnjensen wrote as meaning that the UTC times in his iob.json were off by 4 hours (EDT times with a Z appended). @elnjensen can you clarify?
Jason Calabrese
@jasoncalabrese
Sep 22 2016 22:31
I looked at @rkresha's site a little, it seems to have the same issue, a timezone issue does seem likely
Scott Leibrand
@scottleibrand
Sep 22 2016 22:37
I believe oref0-setup assumes that timezone is not specified in the .ini, and that openapscontrib.timezone uses the rig timezone instead
Jason Curry
@mccgm
Sep 22 2016 23:36
I never see more than one purple line in NS even when COB>0. Any thoughts?
Scott Leibrand
@scottleibrand
Sep 22 2016 23:42
does the suggested.json output have multiple prediction arrays?
Jason Curry
@mccgm
Sep 22 2016 23:45
This message was deleted
It doesn't look like it, no. cat suggested.json
{"temp":"absolute","bg":110,"tick":-3,"eventualBG":-77,"snoozeBG":183,"predBGs":{"IOB":[110,107,103,99,95,90,85,79,73,66,59,51,42,39]},"IOB":8.959,"reason":"COB: undefined, Dev: -8, BGI: -2.17, ISF: 20, Target: 100; Eventual BG -77 < 100, bolus snooze: eventual BG range -77-183, temp 1.95 ~ req 1.95U/hr"}