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

2nd
Mar 2019
jaylagorio
@jaylagorio
Mar 02 00:49
@scottleibrand I still can't explain the behavior with COB calculation from last night, but I ended up reflashing that entire board and starting over with what I could validate was a new 0.7.0-dev. I made sure the ns-loop.log format had changed and checked several files in the dev branch on GitHub with what were on the device. Things seem fine on that rig now. Also took the opportunity to do a better job of the touchscreen support in setup and cron-every-minute as well as integrate a bug fix from @cluckj for both G5 and G6 receivers that had hit me a while ago but that I was unable to track down. So thanks to @cluckj for that work!
djnoor
@djnoor
Mar 02 01:12
If I change settings in myopenaps/preferences.json, do I have to reboot the rig for the changes to take effect?
Dana Lewis
@danamlewis
Mar 02 01:22
No
Make sure to save them though
JustineAnne
@MicheleJustine
Mar 02 01:35
@jaylagorio I am trying to reflash an Intel Edison. I see you just did it. Do you have to delete the old version of jubilinux before you can re-flash or does it write over top?
Dana Lewis
@danamlewis
Mar 02 01:38
It writes over, no need to delete
JustineAnne
@MicheleJustine
Mar 02 01:39
Thank you @danamlewis
jaylagorio
@jaylagorio
Mar 02 02:06
^^ yup!
Dana Lewis
@danamlewis
Mar 02 03:04
Next time someone gets the radio error (the one where you reflash ccprog), tag me? Have something else I need someone to cross check the next time it happens
straykatz
@straykatz
Mar 02 04:11
Next time someone gets the radio error (the one where you reflash ccprog), tag me? Have something else I need someone to cross check the next time it happens will do. I have a few edisons without on-board wifi antenna I am working with right now. Got a couple of WIFI antennas from Mouser in the mail today, so this is a project now. first thing I ran into is that the bootstrap script was not running, but it seems to be working to go the long way as described in the docs.
boc-the-git
@boc-the-git
Mar 02 04:11

I'm getting the same error as @TranceCake above - I don't believe a solution was found.

I'm running PiZero w/ Explorer Hat, on the dev branch. I was 6 commits behind (according to the loop logs) before running oref0-runagain. I then hit the error TranceCake had originally mentioned that ends with Could not run oref0-get-profile. On advice above, I then went and deleted /usr/local/lib/node_modules/oref0 .. now I'm consistently getting the following error:

Reading state information... Done
Removing any existing ns device:
removed process://ns/nightscout/ns NIGHTSCOUT_HOST API_SECRET
Running nightscout autoconfigure-device-crud https://redacted.herokuapp.com redacted
added process://ns/nightscout/ns NIGHTSCOUT_HOST API_SECRET
jq: error: Could not open file jq: No such file or directory
jq: error: Could not open file .extra.args |= sub(" API_SECRET " ; " redacted"): No such file or directory
close failed in file object destructor:
sys.excepthook is missing
lost sys.stderr
Traceback (most recent call last):
  File "/usr/local/bin/openaps-import", line 89, in <module>
    app( )
  File "/usr/local/lib/python2.7/dist-packages/openaps/cli/__init__.py", line 51, in __call__
    self.run(self.args)
  File "/usr/local/bin/openaps-import", line 77, in run
    candidates = json.load(args.input)
  File "/usr/lib/python2.7/json/__init__.py", line 291, in load
    **kw)
  File "/usr/lib/python2.7/json/__init__.py", line 339, in loads
    return _default_decoder.decode(s)
  File "/usr/lib/python2.7/json/decoder.py", line 364, in decode
    obj, end = self.raw_decode(s, idx=_w(s, 0).end())
  File "/usr/lib/python2.7/json/decoder.py", line 382, in raw_decode
    raise ValueError("No JSON object could be decoded")
ValueError: No JSON object could be decoded
Could not run nightscout autoconfigure-device-crud

Any advice welcome!

Scott Leibrand
@scottleibrand
Mar 02 06:24
Did you re-run npm run global-install after deleting?
boc-the-git
@boc-the-git
Mar 02 06:30
I don't believe I explicitly did, just oref0-runagain.. let me run it now
should I re-delete the node_modules, given I've run oref-runagain since deleting?
boc-the-git
@boc-the-git
Mar 02 06:40
npm run global-install seems to have completed successfully.. will now try oref0-runagain (I'm guessing that's the next step)
boc-the-git
@boc-the-git
Mar 02 06:49
Back to the following error unfortunately:
...
/usr/local/lib/node_modules/oref0 -> /root/src/oref0
(node:26224) [DEP0022] DeprecationWarning: os.tmpDir() is deprecated. Use os.tmpdir() instead.
unbuild oref0@0.7.0-dev
/root/src/oref0/node_modules/oref0 -> /usr/local/lib/node_modules/oref0 -> /root/src/oref0
(node:26241) [DEP0022] DeprecationWarning: os.tmpDir() is deprecated. Use os.tmpdir() instead.
npm WARN deprecated crypto@0.0.3: This package is no longer supported. It's now a built-in Node module. If you've depended on crypto, you should switch to the one that's built-in.
npm ERR! cb() never called!
npm ERR! not ok code 0

npm ERR! oref0@0.7.0-dev global-install: `npm install && sudo npm link && sudo npm link oref0 && sudo npm install -g`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the oref0@0.7.0-dev global-install script.
npm ERR! This is most likely a problem with the oref0 package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     npm install && sudo npm link && sudo npm link oref0 && sudo npm install -g
npm ERR! You can get their info via:
npm ERR!     npm owner ls oref0
npm ERR! There is likely additional logging output above.
npm ERR! System Linux 4.14.79+
npm ERR! command "/usr/bin/node" "/usr/bin/npm" "run" "global-install"
npm ERR! cwd /root/src/oref0
npm ERR! node -v v8.11.1
npm ERR! npm -v 1.4.21
npm ERR! code ELIFECYCLE
npm WARN This failure might be due to the use of legacy binary "node"
npm WARN For further explanations, please read
/usr/share/doc/nodejs/README.Debian

npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR!     /root/src/oref0/npm-debug.log
npm ERR! not ok code 0
/root/src/oref0/bin/oref0-setup.sh: line 751: oref0-get-profile: command not found
Could not run oref0-get-profile
boc-the-git
@boc-the-git
Mar 02 06:59
Also Scott, unrelated to this.. I recall reading an issue a while back around bolus wizard entries getting uploaded to NS with only the carbs and not insulin.. I can't find the issue now when I look for it, but this issue occurred for me a few days ago and I backed up quite a few files - do you know the issue I'm referring to? I'd love to share them for reference. (I believe you were commenting on the issue when I saw it previously)
JohnDoeAkira
@JohnDoeAkira
Mar 02 08:51
Hi, so I have to restart something or reboot after having changed the preferences.conf (to enable SMB) ? Or are the changes automatically taken into account ?
Sorry for the typo. The question is DO I have to restart something ?
Riko L
@Ricco555
Mar 02 11:02
@JohnDoeAkira no, if it is preferences.json it will be used on the next loop.
JohnDoeAkira
@JohnDoeAkira
Mar 02 12:54
Thanks riko. I made a typo in the preferences files. Its looping now.
But I think I misunderstood how to deal with meals. Having read that I should not use the bolus wizard anymore, I added a meal bolus (22carb, 2.2u) in nightscout. But nothing happened. I thought that the system would shoot me the 2.2u and deal with deviations. Instead its shooting small .2 microboluses. It will take forever to have my 2.2u !!! What have I done wrong ?
the loop cannot do large boluses
JohnDoeAkira
@JohnDoeAkira
Mar 02 13:08
Yes that I know. But I thought that since I cannot use the wizard anymore, the solution was to set a meal bolus in nightscout. If that does not result in an insulin bolus, how can I get my meal handled ? Put only carbs in nightscout (no insulin) and let smb try to inject enough insulin in very successive small doses ? Go this ifft thing ?
TranceCake
@TranceCake
Mar 02 13:08
you can use the bolus wizard in nightscout, it calculates the amount of insulin needed
you can then manually bolus that amount in the pump (or half manually and let the smb's do the other half. I have heard people do that)
JohnDoeAkira
@JohnDoeAkira
Mar 02 13:09
Sorry for my question that probably sound silly for you. I swear I 've read the docs (and better twice) but it looks I still miss some important points.
TranceCake
@TranceCake
Mar 02 13:09
it's ok
I haven't used smb's either
I missed important stuff too, don't worry
are you aware of the A52 error?
That is why they recommend using the easy bolus button, because it's the quickest
jaylagorio
@jaylagorio
Mar 02 14:57
@JohnDoeAkira What you did was tell NS that you put 2.2u and 22g in. So that's going to throw lots of things off. Adding 2.2u to NS is not a way of telling the loop to dose that much.
I like to think of NS as a way of looking at what reality is, not what I want it to be if that makes sense. So it's not necessarily a way of telling the loop to do something (using temp targets being an exception).
JohnDoeAkira
@JohnDoeAkira
Mar 02 16:07
Ok, I've figured that out with the mess I got after it. So I should try to make my boluses with the easy bolus button, is that it ? And try not to do it during an smb to avoid a52 error. But how is my rig getting how much carb I had if I use the easy button ? It only tells insulin, no carbs, right ?
jaylagorio
@jaylagorio
Mar 02 16:10
Yes, try to do boluses with the easy button. Your best bet to enter carbs, and just the carbs because the rig will get the insulin dose from the pump, is by using Nightscout.
If it's been a while since you've eaten you can use the wizard on the pump for carbs and insulin because the rig is not likely to do an SMB at the same time, which is what causes the A53 error.
You can also time when you use the wizard. When the rig does an SMB you have about 5 minutes where it won't do another one. In that time, as close to the previous SMB as possible, you can use the wizard then. This is what I do, but you have to keep that timing in mind because you're taking a risk.
jaylagorio
@jaylagorio
Mar 02 16:19
^^ *A52 error
Additionally, using the easy button does not cause the A52 error, that only occurs when using the wizard at the same time the rig attempts to SMB
JohnDoeAkira
@JohnDoeAkira
Mar 02 16:34
That's a good news. So easy button + carbs un ns
Carbs in NS is always safe with smb. Great !
rbfussell
@rbfussell
Mar 02 16:36
Quick question about openAPS. Is bidirectional comms with pump an option? I don't remember if it had a transmitter in it or not.
Well not even openAPS, just the pumps themselves. Can they have outbound communication
jaylagorio
@jaylagorio
Mar 02 16:39
@JohnDoeAkira That's right!
@rbfussell Can you elaborate a bit on what you mean? The rig and the pump communicate bidirectionally. Are you asking whether the pump can initiate that communication?
rbfussell
@rbfussell
Mar 02 16:40
Came across a problem that could be very solvable for a very very underrepresented group of T1Ds if I can get data to transmit via radio from the pump to a mobile.
Yes. It's require a fw hack im sure but is the hardware present
Okay so here's the thing.
jaylagorio
@jaylagorio
Mar 02 16:42
Unfortunately the pump uses a proprietary radio that phones do not have, so you need either a rig with the radio (the Explorer block or HAT) or you need an intermediary device like a ReillyLink
The intermediary device has Bluetooth to communicate with the phone and the proprietary radio to communicate with the pump
It doesn't do any processing itself, it just translates between radio types
rbfussell
@rbfussell
Mar 02 16:46
I was talking on FB with some other t1s and we were just talking about our pumps, and one girl said she wished more than anything that she could have one, but being blind, she requires her devices to have auditory feedback. And i thought maybe if I could get it to send just enough data out, to any device to inform of current information displayed, changes in bolus during carb/manual entries etc.
jaylagorio
@jaylagorio
Mar 02 16:49
I think Nightscout includes a speech feature like this now?
So she'd have an internet connected rig talking to Nightscout which she would use to speak the data it has
rbfussell
@rbfussell
Mar 02 16:50
I mean a pi zero or 3 with a custom recv even could work. I guess ns could do this. Can you manual bolus from ns? What I was thinking for example
rbfussell
@rbfussell
Mar 02 16:51
When she's on the pump bolus screen and selecting carbs, when she selects carbs it would say "carb entry" then each increment read the number out when she release the button
jaylagorio
@jaylagorio
Mar 02 16:51
You can't manual bolus from Nightscout, no
rbfussell
@rbfussell
Mar 02 16:51
Yeah. So this would need to be from the pump itself so it'll take a firmware hack
It'll be completely independent i suppose. Just didn't know if there was already existing source material to go from with the receiver side.
I mean I imagine it will be a very limited data set of words. Eg. Entries for what is selected. Numbers. Which menu its on. The receiver itself would just need a word value from the pump ota. Be easy to multilang too.
Riko L
@Ricco555
Mar 02 16:57
sounds like a nice use case for amazon alexa
Eric
@ecc1
Mar 02 16:58
@rbfussell Both Loop and AAPS can perform all pump operations via their UIs, I think, so if their assistive tech is good enough that could work
rbfussell
@rbfussell
Mar 02 17:00
Hmm
Lemme check on that. I felt bad for the girl, and thought it'd be an interesting project. But if something in play already can do this that'd be much quicker for her
I had used openAPS / NS when I had my old Medtronic hadn't looked into any pump hacks in a while.
Let me go see about those. As long as they're open source I can add any lacking accessibility functionality
JohnDoeAkira
@JohnDoeAkira
Mar 02 17:14
I am also having an issue in nightscout. I can only get ar2 predictions, not the openaps ones.
jaylagorio
@jaylagorio
Mar 02 17:16
@JohnDoeAkira Did you make sure the OpenAPS box was checked in the left side menu? And after you did that did you click the ... button near the set of hour display buttons and check the box to display them?
JohnDoeAkira
@JohnDoeAkira
Mar 02 17:42
I don't see any left side menu. That may be the problem !!
The left side menu he’s referring to is the profile settings menu , it may have gotten inadvertently unchecked , or the variable deleted from heroku. Check the display settings first; then if the tick box is not there, check the variable in heroku
Riko L
@Ricco555
Mar 02 17:51
does anyone knows why would the openaps (running on Pi Zero) not take last 3-4 BG entries from NS? and how to troubleshoot that?
network connection should not be an issue as rig is sending logs to papertrail almost in real time. Also, NS i think is not an issue as it gets the BG data from sensor (Bluecon) regularly.
Dana Lewis
@danamlewis
Mar 02 17:54
Are you underclocked?
Riko L
@Ricco555
Mar 02 17:55
I disabled underclock, so now its running on normal. it's not always like that but more regularly .. node service is using 50-70% CPU
JohnDoeAkira
@JohnDoeAkira
Mar 02 18:05
Which config variable would that be in heroku ? I have show_forecast set to openaps. But no openaps bills, neither on the left, noe on the right side. Left side (mn since last bg, battery percentage) right side (bg, variation, iob, cob, bwp, cage, sage,
Cage n/a, sage empty, iage empty, basal)
Riko L
@Ricco555
Mar 02 18:15
@danamlewis you think it's CPU related issue? few times during the day the loop would take 10min to complete, where regularly it takes 4-5min
Riko L
@Ricco555
Mar 02 18:22

This is right now:

Mar 02 19:18:54 pi-zero openaps: enact/smb-suggested.json: {"deliverAt":"2019-03-02T18:18:53.676Z","temp":"absolute","duration":30,"rate":0}
Mar 02 19:18:54 pi-zero openaps: "If current system time Sat Mar 02 2019 19:18:53 GMT+0100 (CET) is correct, then BG data is too old. The last BG data was read 15.9m ago at Sat Mar 02 2019 19:02:58 GMT+0100 (CET). Shortening 34m long zero temp to 30m. "

And last 3 BG data were 1, 6, 12 min ago

trying to figure out where to look
jaylagorio
@jaylagorio
Mar 02 18:31
@JohnDoeAkira You'd want openaps to be listed in your enable variable
On the left side of your Nightscout window at the top there's a hamburger button to press to bring the left menu out
Riko L
@Ricco555
Mar 02 18:32
also I stand corrected, now I am monitoring system usage and it's constantly 80%-98% CPU. Is this normal for the Pi ?
jaylagorio
@jaylagorio
Mar 02 18:32
image.png
@JohnDoeAkira Like this:
JohnDoeAkira
@JohnDoeAkira
Mar 02 20:19
Fantastic ! I had openaps everywhere but in enable. It works now !!! Thanks so much !!
jaylagorio
@jaylagorio
Mar 02 20:33
That's great, congrats!
Stargazer32584
@Stargazer32584
Mar 02 21:24

Hello, now, we bought a Explorer HAT for our project with the RPi Zero and a Medtronic minimed 712. The new installation was very good and much easier as with the HCW - Shield. So we start with the "l" in the Putty - Window to see what's going on. But the system have some problems to find the pump. The pump is online and the "remote-modus" is on. In the instruction manual for the pump, they wrote the following lines to be "remote-able": To use the remote control, these pump settings must be programmed:
➠ Remote Options = On
➠ Remote control ID code entered in pump (code is on back of remote)
➠ Easy Bolus = On

For the second option, i use a 000000 and a second "device" with 111111. But it will not work.

The Terminal-window shows the following picture:

https://drive.google.com/open?id=1bkpRBWavfmm8kXqxpo_E5z8FQPktw4jX

Can anybody help me ?

Thanks a lot....

André

Dana Lewis
@danamlewis
Mar 02 21:34
@Stargazer32584 did you finish the x12 setup steps?
(The error is likely related to those files needing to be set up, or typos fixed there - doesn’t have to do with the remote)
Stargazer32584
@Stargazer32584
Mar 02 22:03

@danamlewis hi !
Yes. After your hint, i finished the complete setup. The values are from my mind, only for the test and they are only 2 - 3 values higher or lower than the example. Now, the system must be ready to work.
On the HAT, both LED's lights shortly up. First the green one, then the red. But one question is in my mind: On mmtune, the third value, is this the strengh of the signal between the rig and the pump ?
These value is higher, when the pump is far away.

Ah..and a second question : The Pi have a 5V 2100mA/h power over usb - cable. Is this enough for both, the Pi and the HAT ? Or need the HAT in this case an extra power ?

Thanks a lot...

André

Stargazer32584
@Stargazer32584
Mar 02 22:16
Now, the mmtune seems to search with different values, like 868.500 --868.550. Now, he looks for the strongest signal for the pump ?
And he wrote this in every loop: grep: monitor/temp_basal.json: No such file or directory. Should i make an empty file with this name in the monitor directory ?
Riko L
@Ricco555
Mar 02 22:20

@Stargazer32584 for mmtune, if it looks like this:

mmtune: "868.400", 3, -47 -- "868.450", 3, -52

the negative value is the signal strength, smaller are better. For power supply, 2A is more then enough.

when I say smaller .. meaning 47 above is better than 52
Riko L
@Ricco555
Mar 02 22:26
practically, you can expect problems in communication when the number is over 80.