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

17th
May 2016
Paul Martin
@Spazholio
May 17 2016 00:24

"mealAssist": "On: 18%, 18%, Carbs: 0 Boluses: 0 ISF: 20, Target: 99 Deviation: 9 BGI: 1.9”,

Holy hell, I think I made progress.

Dana Lewis
@danamlewis
May 17 2016 00:25
:)
Paul Martin
@Spazholio
May 17 2016 00:26
I mean…I’m 99% sure it’s not actually working because whenever I generate auto-sens.json I get pretty much NaN across the board, but at least my loop’s running again...
(I know I’m talking about 2 different things, but I’ve been working on several things at once) =)
Brett
@burgertime14
May 17 2016 02:05
getting "Carb ratio data should have an array called schedule with a start and ratio fields." search is not turning anything up, anyone have any ideas?
Dana Lewis
@danamlewis
May 17 2016 02:05
carb ratio should be being pulled in from the pump, are you missing a carb ratio in the pump profile?
Brett
@burgertime14
May 17 2016 02:06
cat profile.json
[{"msg":"Carb ratio data should have an array called schedule with a start and ratio fields.","file":"settings/basal_profile.json","data":[{"i":0,"start":"00:00:00","rate":1,"minutes":0},{"i":1,"start":"03:00:00","rate":1.25,"minutes":180},{"i":2,"start":"05:00:00","rate":1,"minutes":300},{"i":3,"start":"12:00:00","rate":1.75,"minutes":720}]},{"msg":"Carb ratio should have units field set to 'grams'.","file":"settings/basal_profile.json","data":[{"i":0,"start":"00:00:00","rate":1,"minutes":0},{"i":1,"start":"03:00:00","rate":1.25,"minutes":180},{"i":2,"start":"05:00:00","rate":1,"minutes":300},{"i":3,"start":"12:00:00","rate":1.75,"minutes":720}]}]
Dana Lewis
@danamlewis
May 17 2016 02:07
that looks like the basal profile. carb ratio should be in settings
(sorry for being confusing. In the pump, carb ratio is considered to be in the profile, usually here we talk about pulling the basal profile but everything else is really considered settings)
so either cat into your settings, and/or also check on the pump itself to see what the carb ratio(s) are
Brett
@burgertime14
May 17 2016 02:09
is this the right file: cat settings/profile.json
[{"msg":"Carb ratio data should have an array called schedule with a start and ratio fields.","file":"settings/basal_profile.json","data":[{"i":0,"start":"00:00:00","rate":1,"minutes":0},{"i":1,"start":"03:00:00","rate":1.25,"minutes":180},{"i":2,"start":"05:00:00","rate":1,"minutes":300},{"i":3,"start":"12:00:00","rate":1.75,"minutes":720}]},{"msg":"Carb ratio should have units field set to 'grams'.","file":"settings/basal_profile.json","data":[{"i":0,"start":"00:00:00","rate":1,"minutes":0},{"i":1,"start":"03:00:00","rate":1.25,"minutes":180},{"i":2,"start":"05:00:00","rate":1,"minutes":300},{"i":3,"start":"12:00:00","rate":1.75,"minutes":720}]}]
Ali Mazaheri
@amazaheri
May 17 2016 02:12
Hi Brett, as Dana said you need to first run your carbratios.json report and then pass it along with other inputs to your get-profile process
Brett
@burgertime14
May 17 2016 02:13
ok, I will try that, must have missed a step, thanks
Ali Mazaheri
@amazaheri
May 17 2016 02:13
no worries! thats why we have the gitter channel
Paul Martin
@Spazholio
May 17 2016 02:30
So, I think will all my toying around, I’ve gotten a little confused. Could someone give me a quick refresher on the differences between AMA, BWP, and auto-sens? I apparently have AMA enabled, but I’m not entirely certain what it does. I thought I did, but may have been mistaken. My auto-sens is quasi-functional, and the BWP pill in NS is showing data where it tells me to bolus more to bring me closer to my targets, but is that all it’s supposed to do? I think my focus went a little too narrow, so I’m looking to refocus and make sure I have a better handle on these different aspects.
Dana Lewis
@danamlewis
May 17 2016 02:35
FYI bwp was built as a NS thing, it's not a specific openaps tool
Scott Leibrand
@scottleibrand
May 17 2016 02:36
Meal assist (advanced or not) will high-temp to help out after you do your initial meal bolus.
Automatic sensitivity detection adjusts what OpenAPS starts with as your current basal, based on the last 24h of deviations.
The other new feature in AMA branch is temp targets, which lets you set
(Silly gitter app)
lets you set eating soon or activity mode in NS, and OpenAPS will shoot for a different target temporarily.
Paul Martin
@Spazholio
May 17 2016 02:43

@danamlewis Oh, it’s strictly NS? Well…neat. I suppose I have that one working then. I think. Wasn’t that the one with the purple dots?

@scottleibrand So I probably have mealAssist enabled, and not AMA. I only say that because that’s what the output of my loop seems to indicate. And it’s modifying things on the fly as well? I’m not sure that I understand temp targets conceptually though - don’t I always to want to be in my regular ranges?

And while I don’t know that it’s strictly needed, the fact I can’t get auto-sens working properly (I think) is vexing the hell out of me, so I may revisit it tomorrow with you guys, if I haven’t already beaten that horse too severely. =)

Scott Leibrand
@scottleibrand
May 17 2016 02:45
The purple line comes from uploading the data from the AMA branch. Totally unrelated to BWP. Guess you could call that anothe feature.
Paul Martin
@Spazholio
May 17 2016 02:46
Oh! Got the wrong acronym.
Scott Leibrand
@scottleibrand
May 17 2016 02:46
If you're gonna eat soon, you can set a temp target to 80, up to an hour before the meal, and it will high-temp to get you down to 80, which will get some insulin going by the time you eat and blunt the meal spike.
Advantage of that over a prebolus is you can easily recover without carbs if you don't eat, so it doesn't require exquisite timing.
For activity mode, we set temp target higher than normal if we expect activity to cause BG to fall, to give you more of a safety buffer.
Paul Martin
@Spazholio
May 17 2016 02:49
Once AMA merges into dev, I’ll pull again, and give it a shot. When I tried before, it broke, and while I changed the meal.json like you showed me, I couldn’t find anything else about that carbhistory.json file (I think that was the name) that was apparently added so it wasn’t doing much. However, I think I understand how Namespaces work now whenever it throws that error. So I got that going for me, which is nice.
Ahhh, ok. I think I get that now.
Scott Leibrand
@scottleibrand
May 17 2016 02:50
Carbhistory is only necessary if you don't plan to enter carbs via bolus wizard. That's how we get them from NS if you enter them there instead.
Will let everyone know when we start to improve the AMA upgrade process a bit and get it ready for dev.
Until then it's a bit of an adventure. :-)
Paul Martin
@Spazholio
May 17 2016 02:52
Yeah, I’ve started trying to use the wizard rather than the manual bolus lately, since @danamlewis mentioned that it was essential to the process.
Yeah, I’ve noticed. No worries. =)
One other thing that’s not critical at all (but I’m still curious about) is how to upgrade NS. I’m on 0.9.0-dev, but all the notes I found on the NS site seemed to be Azure-geared. A simple git pull was…less than successful, so is there a doc that goes through the steps? Or guides me in the right direction?
Rob Kresha
@rkresha
May 17 2016 02:53
This message was deleted
Scott Leibrand
@scottleibrand
May 17 2016 02:55
I always have to do some npm / bower things.
Generally that means searching my .bash_history for what I did last time. ;-)
Paul Martin
@Spazholio
May 17 2016 02:55
This is literally my first nodejs app ever, so that sounds like oodles of fun. =)
Scott Leibrand
@scottleibrand
May 17 2016 02:56
mine too. ;-)
i learned php and then js for DIYPS and NS/OpenAPS.
Rob Kresha
@rkresha
May 17 2016 02:56
I'm struggling with the usage of the (!) in the following command... openaps alias add gather '! bash -c "rm -f monitor/*; openaps gather-profile && openaps monitor-cgm && openaps monitor-pump && openaps report invoke monitor/iob.json"' ... I'm very familiar with linux, just not this particular usage
Paul Martin
@Spazholio
May 17 2016 02:56
Oh? What parts of it are in PHP?
Scott Leibrand
@scottleibrand
May 17 2016 02:57
It's not Linux, it's openaps magic syntax. The ! just means "don't put an OpenAPS in front of what follows"
Rob Kresha
@rkresha
May 17 2016 02:58
bingo bango
thanks Scott!
Scott Leibrand
@scottleibrand
May 17 2016 02:58
silly autocorrect. An "openaps" (lowercase)
DIYPS is PHP, not any of the public stuff.
Paul Martin
@Spazholio
May 17 2016 02:59
Ahhh, ok.
Ben West
@bewest
May 17 2016 03:02
a lot of frameworks use bang like that
git alias works same way
! means use the shell, like hash-bang, start with exec/shell
otherwise, the prefix is always openaps and exec that
Rob Kresha
@rkresha
May 17 2016 03:04
yeah I thought it was shell related, not framework
wish I was more familiar with python
Paul Martin
@Spazholio
May 17 2016 03:09

Every once in a while, I get:

pump://JSON/iter_pump_hours/settings/pumphistory-24h.json
subg_rfspy status: OK
Version: subg_rfspy 0.8
settings/pumphistory-24h.json  raised  need more than 0 values to unpack

Any ideas what it is? It generally breaks the loop until I do…something. But what I normally do isn’t working at the moment.

And while I think that No handlers could be found for logger “mmeowlink.handlers.stick” can be ignored (I think I read that somewhere), the error generally only seems to happen whenever that “no handlers” thing shows up...
Ben West
@bewest
May 17 2016 03:23
that's not a python thing
hmm
that indicates a failure to parse the history, @Spazholio
Paul Martin
@Spazholio
May 17 2016 03:31
Yeah, I’m perplexed. Nothing changed. For once, I wasn’t monkeying with it. =)
Scott Leibrand
@scottleibrand
May 17 2016 03:59
Was it persistent, or one-off?
Paul Martin
@Spazholio
May 17 2016 04:00
Recurring.
Scott Leibrand
@scottleibrand
May 17 2016 04:02
And did regular pumphistory run fine?
Paul Martin
@Spazholio
May 17 2016 04:05
I’ve been poking at a NS upgrade, so I killed the loop and let it sit for a while. Thinking maybe the pump wasn’t happy with me trying to communicate so much. Running again...
Nope, dead in the same spot.
It appears to be skipping the error, since it’s not a needed report to complete a loop, but still.
And oddly enough, the files appear to all be there and recently written to.
Scott Leibrand
@scottleibrand
May 17 2016 04:09
How do the recent treatments in pumphistory and pumphistory-24h compare?
Paul Martin
@Spazholio
May 17 2016 04:10
The first 2 JSON elements are identical. I assume the rest are as well, I just checked the first two.
I should probably move the pump history-24h stuff out of get-settings and throw it on the end of the loop, after I’ve uploaded everything, just to move non-critical stuff out of the way.
Running loop again...
And now we run into the other error...
pump://JSON/read_bg_targets/settings/bg_targets.json
subg_rfspy status: OK
Version: subg_rfspy 0.8
No handlers could be found for logger "mmeowlink.handlers.stick"
settings/bg_targets.json  raised  bytearray index out of range
Traceback (most recent call last):
  File "/usr/local/bin/openaps-report", line 6, in <module>
    exec(compile(open(__file__).read(), __file__, 'exec'))
  File "/home/pi/src/openaps/bin/openaps-report", line 82, in <module>
    app( )
  File "/home/pi/src/openaps/openaps/cli/__init__.py", line 51, in __call__
    self.run(self.args)
  File "/home/pi/src/openaps/bin/openaps-report", line 75, in run
    output = app(args, self)
  File "/home/pi/src/openaps/openaps/cli/subcommand.py", line 52, in __call__
    return self.method.main(args, app)
  File "/home/pi/src/openaps/openaps/reports/invoke.py", line 40, in main
    output = task.method(args, app)
  File "/home/pi/src/openaps/openaps/uses/use.py", line 45, in __call__
    output = self.main(args, app)
  File "/home/pi/src/openaps/openaps/vendors/medtronic.py", line 224, in main
    return getattr(self.pump.model, name)(**self.get_params(args))
  File "/home/pi/src/decoding-carelink/decocare/models/__init__.py", line 26, in __call__
    self.validate( )
  File "/home/pi/src/decoding-carelink/decocare/models/__init__.py", line 17, in validate
    data = self.response.getData( )
  File "/home/pi/src/decoding-carelink/decocare/commands.py", line 1051, in getData
    units = self.data[0]
IndexError: bytearray index out of range
GET-SETTINGS COMPLETE
STARTING ENACT
oref0-determine-basal://text/shell/enact/suggested.json
Could not parse input data:  { [Error: Cannot find module '/home/pi/openaps/monitor/iob.json'] code: 'MODULE_NOT_FOUND' }
reporting enact/suggested.json
No action required
ENACT COMPLETE
And this one breaks the whole thing.
Paul Martin
@Spazholio
May 17 2016 04:19
And this run through worked just fine. Grr.
Scott Leibrand
@scottleibrand
May 17 2016 04:25
Welcome to the wonderful world of 900MHz comms
if you expect a 50% failure rate you won't be far off.
The longest command by far is pumphistory, especially the 24h version, and therefore most likely to fail.
Paul Martin
@Spazholio
May 17 2016 04:27
Well, I’m trying a hail mary due to something I saw happen a few days ago. I have a 4” USB extender cable attaching the TI stick because the 3D printed case for the stick doesn’t allow it to be plugged directly into the Pi. I’m going to try removing that and seeing if maybe the cable’s bad. It happened to me when trying to read from the Dexcom, so...
I run my loop every 5 mins. Is that what most people do? And you’re saying I might expect a 50% failure rate on that?
Holy cow! My auto-sens.json generated properly! And…the one time I had the CGM plugged in. Hmmmmm.
JaysonEwer
@JaysonEwer
May 17 2016 04:29
@Spazholio my loop runs every 3 min.
Scott Leibrand
@scottleibrand
May 17 2016 04:30
My cron attempts to loop every minute if the process isn't already running.
And I built multiple rigs to get whole-apartment coverage.
Paul Martin
@Spazholio
May 17 2016 04:31
Any idea how long it generally takes to finish? Just trying to benchmark my setup here...
Ok, well at the very least, my auto-sens.json is consistently working now, so there must be an issue with the data coming back from NS because withthe CGM, I’m getting legit data. At least gives me a point to start troubleshooting.
Dana Lewis
@danamlewis
May 17 2016 04:35
Meetup link for DC area loopers: http://whoozin.com/TC9-WDK-YKX4 (June 1, 8pm)
Scott Leibrand
@scottleibrand
May 17 2016 04:35
Depends. If you do everything I do, the whole loop often takes more than 5 minutes, but during that time it will have had at least two chances to enact... Simpler loops usually take closer to 3.
JaysonEwer
@JaysonEwer
May 17 2016 04:52
@danamlewis 👍 Thanks for helping put the DC meetup together, Dana!
Dana Lewis
@danamlewis
May 17 2016 05:10
Thanks for hosting! @JaysonEwer
Ben West
@bewest
May 17 2016 05:39
FWIW, my subg_rfspy/mmeowlink rarely fails, ever
JaysonEwer
@JaysonEwer
May 17 2016 06:14
I just ran auto-sens.json for the first time. I know, I know, I'm very late to the party...anyway...is this what it's supposed to look like?
pi@Ewer-Open-APS:~/Documents/openaps $ openaps report invoke monitor/auto-sens.json
auto-sens://text/shell/monitor/auto-sens.json
...................................................................................................................................................................................................................................................................................!!!!!!!...
p=0.60: 0.60, 0.00, 0.33
p=0.58: 0.33, 0.00, 0.00
p=0.56: 0.00, 0.00, 0.00
p=0.54: 0.00, 0.00, 0.00
p=0.52: 0.00, 0.00, -0.33
p=0.50: -0.33, 0.00, -0.33
p=0.48: -0.33, 0.00, -0.67
p=0.46: -0.67, 0.00, -0.67
p=0.44: -0.67, 0.00, -1.00
p=0.42: -1.00, 0.00, -1.08
p=0.40: -1.33, 0.00, -1.60
p=0.38: -1.67, 0.00, -1.67
p=0.36: -1.67, 0.00, -2.00
p=0.34: -2.00, 0.00, -2.67
p=0.32: -2.33, 0.00, -3.12
p=0.30: -2.67, 0.00, -4.00
p=0.28: -3.00, 0.00, -4.33
p=0.26: -3.57, 0.00, -4.62
Mean deviation: -0.01
Excess insulin sensitivity detected
Basal adjustment -0.08U/hr
Ratio: 97%: new ISF: 51.5mg/dL/U
reporting monitor/auto-sens.json
pi@Ewer-Open-APS:~/Documents/openaps $
BTW, I had a very bad BG day... Don't ask.
@bewest Are you still there?
Ben West
@bewest
May 17 2016 06:18
yeha
JaysonEwer
@JaysonEwer
May 17 2016 06:19
So, I think i'm invoking my auto-sens.json correctly, does it look good to you?
Now what? :-D
how do I incorporate that into my loop?
Ben West
@bewest
May 17 2016 06:21
I have no idea :)
JaysonEwer
@JaysonEwer
May 17 2016 06:21
I was following along here: https://github.com/openaps/docs/blob/dev/docs/docs/walkthrough/phase-6/Configure-Automatic-Sensitivity-Mode.md but it doesn't say what to do once you generate the auto-sens.json file.
I guess i'll have to add it to my alias gather alias, that should generate it, and then all your whiz-bang-awesome coding should auto-magically use it, right?
JaysonEwer
@JaysonEwer
May 17 2016 06:27
Perhaps another day then.
:-D
JaysonEwer
@JaysonEwer
May 17 2016 06:43
I think I did it. :-)
Matthias
@ceben80
May 17 2016 08:14
:+1:
John Sjolund
@sjolundjohn
May 17 2016 09:08
@scottleibrand yes indeed I made a pull request on the docs, and updated, to try to help with the setting needed on actual bug
dougtakeuti
@dougtakeuti
May 17 2016 09:46
@jasoncalabrese @scottleibrand I've been learning from observing your loop setups and trying to improve mine with some of your ideas. Let me clarify something: I understand that in your openaps.ini the aliases upload treatments only and not glucose data. Is that correct? How do you upload glucose data? Xdrip?
John Sjolund
@sjolundjohn
May 17 2016 10:03
I am trying to determine why my Nightscout upload doesn't seem to be working, I have all reports generted, output when I invoke seems correct etc. Seems it just doesn't update
Any tips on how to troubleshoot why Nightscout doesn't seem to be receiving data?
dougtakeuti
@dougtakeuti
May 17 2016 10:06
@sjolundjohn all the upload problems I've had were related to env vars. Are you uploading manually or using cron?
John Sjolund
@sjolundjohn
May 17 2016 10:08
@dougtakeuti trying to get manual working firstly
dougtakeuti
@dougtakeuti
May 17 2016 10:09
Have you exported NIGHTSCOUT_HOST and API_SECRET?
John Sjolund
@sjolundjohn
May 17 2016 10:10
@dougtakeuti I believe so yes, however let me re-trace steps
@dougtakeuti yes it was in my .profile file. Note that I had this file in the root of the pi not the root of OpenAPS, could that be issue?
Actually doesn't matter, seems to be the same
dougtakeuti
@dougtakeuti
May 17 2016 10:15
In mine it is in /etc/. Not sure if it matters. Try
export NIGHTSCOUT_HOST=yourwebsite
export API_SECRET=thathorriblehashcode
John Sjolund
@sjolundjohn
May 17 2016 10:16
it to add that to the profile file instead of:
NIGHTSCOUT_HOST=https://<your Nightscout address>; export NIGHTSCOUT_HOST
API_SECRET=<your hashed password>; export API_SECRET
*ie
John Sjolund
@sjolundjohn
May 17 2016 10:22
I edited the .profile file, didn't seem to do it
I will step back and re-create reports
dougtakeuti
@dougtakeuti
May 17 2016 10:24
I don't think the export bit should be added to .profile. I meant to say just export before you run it manually
John Sjolund
@sjolundjohn
May 17 2016 10:24
will try
John Sjolund
@sjolundjohn
May 17 2016 10:34
@dougtakeuti no luck. Report runs right, exports to terminal right, but Nightscout doesn't update
ah wait, I can see that the OpenAPS status is updated, just doesn't seem that blood glucose has updated
hmm, I think it is a timezone issue
dougtakeuti
@dougtakeuti
May 17 2016 10:36
Sorry, got to dash to work, but will check gitter later good luck!
John Sjolund
@sjolundjohn
May 17 2016 10:37
Thanks!
John Sjolund
@sjolundjohn
May 17 2016 11:03
Still troubleshooting Nightscout upload - it seems that it uploads OpenAPS status, clock, resevoir. It does not update blood glucose, IOB.
I think problem lies in the fact that there are issues with Timezone. I have checked that time on all devices + NS is the same AND monitor/clock-zoned.json is the same.
However when I invoke monitor/upload-status.json, these are two hours off
The only part of the chain I can't figure out is where ´devicestatus.json´lies
John Sjolund
@sjolundjohn
May 17 2016 11:22
I am thinking this is the problem:
pi@raspberrypi:~/openaps $ openaps report invoke monitor/pumphistory-zoned.json
tz://JSON/clock/monitor/pumphistory-zoned.json
monitor/pumphistory-zoned.json  raised  'list' object has no attribute 'read'
Traceback (most recent call last):
  File "/usr/local/bin/openaps-report", line 4, in <module>
    __import__('pkg_resources').run_script('openaps==0.1.0', 'openaps-report')
  File "build/bdist.linux-armv7l/egg/pkg_resources/__init__.py", line 719, in run_script
  File "build/bdist.linux-armv7l/egg/pkg_resources/__init__.py", line 1504, in run_script
  File "/usr/local/lib/python2.7/dist-packages/openaps-0.1.0-py2.7.egg/EGG-INFO/scripts/openaps-report", line 82, in <module>
    app( )
  File "/usr/local/lib/python2.7/dist-packages/openaps-0.1.0-py2.7.egg/openaps/cli/__init__.py", line 51, in __call__
    self.run(self.args)
  File "/usr/local/lib/python2.7/dist-packages/openaps-0.1.0-py2.7.egg/EGG-INFO/scripts/openaps-report", line 75, in run
    output = app(args, self)
  File "/usr/local/lib/python2.7/dist-packages/openaps-0.1.0-py2.7.egg/openaps/cli/subcommand.py", line 52, in __call__
    return self.method.main(args, app)
  File "/usr/local/lib/python2.7/dist-packages/openaps-0.1.0-py2.7.egg/openaps/reports/invoke.py", line 40, in main
    output = task.method(args, app)
  File "/usr/local/lib/python2.7/dist-packages/openaps-0.1.0-py2.7.egg/openaps/uses/use.py", line 45, in __call__
    output = self.main(args, app)
  File "/usr/local/lib/python2.7/dist-packages/openaps_contrib-0.0.7-py2.7.egg/openapscontrib/timezones/__init__.py", line 86, in main
    results = self.convert(inputs)
  File "/usr/local/lib/python2.7/dist-packages/openaps_contrib-0.0.7-py2.7.egg/openapscontrib/timezones/__init__.py", line 98, in convert
    program = self.rezone(parse(program)).isoformat( )
  File "/usr/local/lib/python2.7/dist-packages/python_dateutil-2.5.3-py2.7.egg/dateutil/parser.py", line 1164, in parse
    return DEFAULTPARSER.parse(timestr, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/python_dateutil-2.5.3-py2.7.egg/dateutil/parser.py", line 552, in parse
    res, skipped_tokens = self._parse(timestr, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/python_dateutil-2.5.3-py2.7.egg/dateutil/parser.py", line 671, in _parse
    l = _timelex.split(timestr)         # Splits the timestr into tokens
  File "/usr/local/lib/python2.7/dist-packages/python_dateutil-2.5.3-py2.7.egg/dateutil/parser.py", line 188, in split
    return list(cls(s))
  File "/usr/local/lib/python2.7/dist-packages/python_dateutil-2.5.3-py2.7.egg/dateutil/parser.py", line 184, in next
    return self.__next__()  # Python 2.x support
  File "/usr/local/lib/python2.7/dist-packages/python_dateutil-2.5.3-py2.7.egg/dateutil/parser.py", line 177, in __next__
    token = self.get_token()
  File "/usr/local/lib/python2.7/dist-packages/python_dateutil-2.5.3-py2.7.egg/dateutil/parser.py", line 93, in get_token
    nextchar = self.instream.read(1)
AttributeError: 'list' object has no attribute 'read'
dougtakeuti
@dougtakeuti
May 17 2016 11:30
Not sure where you are on the globe, but I think you need those brainy people from the US west coast to help you out here... but they must be fast asleep right now (at least I hope so, for their own good :smile: )
John Sjolund
@sjolundjohn
May 17 2016 11:32
I think I need to get the rezone funtion working as the problems seem to be that times are 2 hours out
I am in Stockholm by the way :-)
Officially stuck on this one, will need to get some more support. Thanks for the help so far @dougtakeuti
John Sjolund
@sjolundjohn
May 17 2016 11:45

On same topic, if I run:

openaps use nightscout iter_pump_hours 4

I don't get any records that have been updated in last few hours, is that expected? As temp bolus have been adjusted etc, that doesn't make sense to me

Hristina Dimova
@xpucuto
May 17 2016 13:13
I am trying to setup the RPI3 as hotspot so when there is no internet to be able to command it from my iphone. So far i have success with it but once i enable the RPI as a hotpost I no longer can connect to other WIFI . Is there a command to add in interfaces so when there are no known WIFI my RPI3 to switch to hotspot and the opposite ? With my trip coming soon i am wondering how to command the RPI offline . If anyone has experince to share i will be very trankful.
John Sjolund
@sjolundjohn
May 17 2016 13:19

Hi! having to work against timezone, I thought I would list the problems I having. I am successful in running the loop manually, now trying to get tweaks to Cron and NS upload working.

In summary:
Problem 1:
Chrontab, keep getting errors such as:

tee: /var/log/openaps/uploader.log: No such file or directory

AND

openaps: no process found

Problem 2:
Root of the problem is that I can't seem to get new data up to Nightscout - I think it is related to timezone. All files and devices show same time, but I am having issues with monitor/pumphistory.json. How do I troubleshoot this?

The reports sending to Nightscout all seem to work, but I believe timestamp in data is giving issues.

Getting there though :-)

Jason Calabrese
@jasoncalabrese
May 17 2016 13:19
@dougtakeuti I'm using xdrip most of the time, if needed I plug a dex into a pi, @scottleibrand & @danamlewis use a mix of Share, ble to share, and dex USB to a pi
Andrew Warrington
@andrew-warrington
May 17 2016 13:34
@danamlewis, way off topic, but I just realised I know a couple of people who work at the same company you do. Eric Shenfield is one; knew him briefly back in Canada 10 years ago. The other is the new guy who started your Basel office a couple of weeks ago, Jeroen Aarden.
Jason Calabrese
@jasoncalabrese
May 17 2016 13:43
@sjolundjohn I'm busy getting ready for work and don't have time to dig in, but looks like you maybe be naming your pump nightscout, that could cause you and others done confusion
John Sjolund
@sjolundjohn
May 17 2016 13:44
@jasoncalabrese that is true: possible to do a copy/replace funtion and I can change it without having to dig into reports?
Bill Stackpole
@billstackpole
May 17 2016 14:09
@xpucuto - with my Pi3 I use a usb to ethernet adapter, connect a physical cable between my pi and laptop, which gives the pi an automatic private ip address (169.254.x.x address). I then access the pi from my laptop via it's piname.local address. Do I understand you correctly - you are trying to make your pi into the hotspot and have the pi advertise an SSID as if it was an access point, and then wanting to autoswitch back and forth between being a wireless client and being a wireless access point? Have never heard of this being done but am interested to know if it is possible...
Hristina Dimova
@xpucuto
May 17 2016 14:24
@billstackpole the problem is that i want to command it with my iphone , so idont have to bring a laptop with me. It will be a holiday :) but yes you have understood me right, this is what i am asking and i hope its not mission immpossible :)
Bill Stackpole
@billstackpole
May 17 2016 14:31
why not just make your phone into a hotspot and setup the pi to connect automatically to the named hotspot in your phone? You could then use a terminal app like serverauditor (iOS - not sure of the Android analog) to connect to and manage your pi from the CLI. Probably would need to manage via wpa_supplicant or similar but that should work (provided that you can setup your phone to be a hotspot). Could also carry a standalone hotspot and have both the Pi and the Phone connect to it, then manage in a similar fashion.
sidenote question: @scottleibrand - from where do we get the "max IOB" value that you use in your setup.sh? (I have some idea of my max bolus value, max limit on what I expect to have for temp basal rates, etc but not sure where we get / calculate / decide on "max IOB")
Hristina Dimova
@xpucuto
May 17 2016 14:33
I need cellular data to make my phone as hotspot ;(
Oskar Pearson
@oskarpearson
May 17 2016 14:34
I thought I'd note an interesting problem we had the other evening... just in case someone else ever sees it.
Bill Stackpole
@billstackpole
May 17 2016 14:34
fire away - listening.
Oskar Pearson
@oskarpearson
May 17 2016 14:34
Our openaps is set to run out of cron every 5 minutes (*/5 in cron)
We also use medtronic sensors
Bill Stackpole
@billstackpole
May 17 2016 14:34
me too.
same
Oskar Pearson
@oskarpearson
May 17 2016 14:35
Siobhan put on a new sensor the other day... and we just had untold issues with lost sensor messages
It woke us up the whole night, pestered us. She'd fiddle with it and get things to re-link etc.
Painful mostly-awake night
Bill Stackpole
@billstackpole
May 17 2016 14:35
I've been having similar issues recently. Lots of disconnects between the sensor and the pump
Oskar Pearson
@oskarpearson
May 17 2016 14:35
I think I figured out what the problem was though... (unconfirmed... bit of a guess..)
Bill Stackpole
@billstackpole
May 17 2016 14:36
I have a new transmitter at home - intend to swap out the one I have for new to see if that helps
Oskar Pearson
@oskarpearson
May 17 2016 14:36
I think she either calibrated somewhere close to the 5 mins past mark, or plugged the transmitter in close to the 5 minute mark
So every time the sensor transmitted, it coincidentally transmitted at the same time as openaps was trying to communicate with the pump...
The radio has no decent retry or whatever.. so it just leads to garbled packets - but openaps retries.
So the sensor transmissions were being mangled by the openaps pump comms..
and it'd lose the sensor
Bill Stackpole
@billstackpole
May 17 2016 14:38
ouch.
Oskar Pearson
@oskarpearson
May 17 2016 14:38
5 mins later the sensor would retry. And OpenAPS would also have just kicked in. So it'd mangle them again.
Bill Stackpole
@billstackpole
May 17 2016 14:38
hadn't considered the potential for ooverlap
Oskar Pearson
@oskarpearson
May 17 2016 14:38
Yeah!
Also: the sensor transmission doesn't really work very well - the pump still loses it.
Bill Stackpole
@billstackpole
May 17 2016 14:38
so a cron job of something other than 5 min (or multiples of 5) would probably make sense
yeah - I'm considering moving to the G5 Dexcom for connectivity reasons (but don't want to re-learn everything - grr)
JaysonEwer
@JaysonEwer
May 17 2016 14:39
Nice. Good catch.
Bill Stackpole
@billstackpole
May 17 2016 14:39
and am not yet sure if the G5 is yet ready for prime time w/OpenAPS
Oskar Pearson
@oskarpearson
May 17 2016 14:39
I was thinking of writing some code that would listen for a sensor broadcast, wait 5 seconds, then retransmit the sensor broadcast via the TI stick, wait 5 seconds, and then start the actual openaps run
Bill Stackpole
@billstackpole
May 17 2016 14:40
good idea.
I'm willing to try it out as well when you're ready.
Oskar Pearson
@oskarpearson
May 17 2016 14:40
The TI stick's transmissions are much more likely to be read by the pump - since they are "at max volume" and tuned to the pump
Bill Stackpole
@billstackpole
May 17 2016 14:40
I need to rebuild anyway - borked my production Pi yesterday. Backup not working right either (hence my question about max_iob for Scott)
Oskar Pearson
@oskarpearson
May 17 2016 14:40
And that way the openaps run will always have the latest data, and not overrun the sensor transmissions
I'm just a bit concerned that we're going to be doubling-up the pump sensor values
I'm not sure if that might cause issues for the medtronic software
Bill Stackpole
@billstackpole
May 17 2016 14:41
One issue might be that you might see errant 900 MHz traffic and interpret that as sensor traffic. How will you be sure you are getting sensor traffic and not just other ISM band noise?
Oskar Pearson
@oskarpearson
May 17 2016 14:41
eg - they might assume that exactly 5 minutes have occurred between readings. If we send 2 it might lead to chaos and unsafe software activities
@billstackpole In our case it's actaully at 868mhz as we're in the EU.
But to answer the actual question:
The protocol that the medtronic stuff uses is pretty unusual - so I'd be surprised if anything else was using it
Bill Stackpole
@billstackpole
May 17 2016 14:42
Ah - ISM (Instrumentation Scientific and Medical) are less regulated wireless bands in the US. Not sure of the EU counterparts or if they are the same.
Oskar Pearson
@oskarpearson
May 17 2016 14:42
Also, it has checksum values that should help
Bill Stackpole
@billstackpole
May 17 2016 14:43
so you'd check for the right protocol patterns to ID?
Oskar Pearson
@oskarpearson
May 17 2016 14:43
And specific packet formats (2 specific leading digits each time)
Bill Stackpole
@billstackpole
May 17 2016 14:43
kind of like ID'ing UDP vs TCP vs ICMP vs others...
nice
Andrew Baugh
@baughaw
May 17 2016 15:02

So I am trying to build out a openaps tool to format Enlite sensor data so that it can be uploaded to NS.

Does anyone know if there is something currently built in openaps to get isig and calabrationFactor data? Here is an example of my entries.json from NS. This JSON was generated using the mmcommander.

{
    "_id":"573b1d7eb70874d86e373328",
    "date":1463491966000,
    "device":"Medtronic_CGM",
    "sgv":110,
    "direction":"FortyFiveDown",
    "isig":57.96169662475586,
    "calibrationFactor":3.2782459259033203,
    "calibrationStatus":1,
    "unfilteredGlucose":110.0126953125,
    "isCalibrating":false}
}
Also, maybe NS doesn't even care about those fields. I was just trying to mimic what mmcommander was doing.
Bill Stackpole
@billstackpole
May 17 2016 15:15
@baughaw - I think that if you look at the report in OpenAPS that creates glucose.json there is an add-on for the carelink sensor to convert the data from Medtronic to Dexcom format (as I think that the info it returns can be massaged into an upload to NightScout). Mine is called glucoseclean.json
Hope that helps
Andrew Baugh
@baughaw
May 17 2016 15:27
HI Bill, Thanks for the response. I believe the glucoseclean tool only renames fields for openaps to use for the suggestion.json. Honestly I am not sure NS needs those additional fields (isig, calfactor) so I am going to try to upload some sample json without and see what happens. <crossing fingers>
Dana Lewis
@danamlewis
May 17 2016 15:32
@andrew-warrington small world :)
David Cintron
@loudestnoise
May 17 2016 15:46
Hi #OpenAPS ers, I’m thinking about diving into this world. I wanted to know if y’all can let me know if it’s even possible to work with my setup. I’ve got a 722 in what I believe is working order. I have Dexcom G5 and I use it with my iPhone. I am using Nightscout via the Bridge and have that up and running. Am I able to use the rest of the hardware like the RPi and CareLink stick but not have a Dexcom receiver connected via USB? I mean I guess I do have a G4 with Share Receiver that I haven’t upgraded to the new software I could use. My only other major problem is I currently use OmniPod, so I don’t have access to Medtronic infusion sets and tubing, but I’m thinking I can probably figure that out somehow.
Dana Lewis
@danamlewis
May 17 2016 15:49
Hey @loudestnoise . Yes possible to use with G5 but will require some more work since it's less well documented comparatively. The usb plugged receiver means it would work offline, but that may not matter to you.
And many people have been able to use third party suppliers to get their Medtronic disposable supplies fairly easily
David Cintron
@loudestnoise
May 17 2016 15:51
Ah yes, the Internet. I hadn’t considered that would only work with that.
Dana Lewis
@danamlewis
May 17 2016 15:53
Yep. So hiking plane camping etc or if wifi goes out...loop will be less likely to work. Some people don't care.
David Cintron
@loudestnoise
May 17 2016 15:55
Yeah, I guess since I have the G4 Receiver with Share I can use that with my G5 transmitter, I just haven’t since I opted to go the iPhone route.
Is anyone using the RPi 3 in their setup? Wouldn’t that avoid having to get a USB WiFi adapter.
Dana Lewis
@danamlewis
May 17 2016 15:56
I don't know that it is true (G5 transmitter working without the upgraded receiver)?
Paul Martin
@Spazholio
May 17 2016 15:58
Ok, so I've got auto-sens.json working if I have the CGM plugged in, but not if it's pulling from NS. So there's something about the NS data that seems to be in the wrong format or that OpenAPS just doesn't like. Does anyone know offhand which fields are needed to make the auto-sense calculations? I'm seeing some differences between the JSON that's returned by each of the different reports, but I'm not sure which ones actually matter.
David Cintron
@loudestnoise
May 17 2016 15:58
@danamlewis No, it doesn’t work unless you upgrade the software. I just never did it because I started using my iPhone immediately when I got the G5 transmitter.
Dana Lewis
@danamlewis
May 17 2016 16:00
@loudestnoise ah gotcha. So if you still had a working G4 transmitter you could switch back.
Paul Martin
@Spazholio
May 17 2016 16:01
@loudestnoise I'm using a Pi3 with a TI stick, G4+Share.
David Cintron
@loudestnoise
May 17 2016 16:02
@Spazholio Nice!
@danamlewis I could be totally wrong on this, but it was my understanding that the G5 transmitter does work with software upgraded G4 with Share receiver.
Dana Lewis
@danamlewis
May 17 2016 16:09
@loudestnoise yes. if you upgrade the receiver. but I don’t think you can use a G5 transmitter and a non-upgraded receiver.
David Cintron
@loudestnoise
May 17 2016 16:11
Yeah, no you definitely have to upgrade the software on it. I still have the receiver, it’s just been sitting in my desk drawer.
Dana Lewis
@danamlewis
May 17 2016 16:11
right. but then it’s no longer a G4 receiver.
David Cintron
@loudestnoise
May 17 2016 16:13
Oh yep, you’re definitely right. It’s a little confusing the way they worded all of that.
Scott Leibrand
@scottleibrand
May 17 2016 17:35
@billstackpole I would raise it gradually, and see if you hit the max IOB limits. maybe start with 1U, and expect to ramp up to 2U or so if you start hitting the max IOB limits.
@dougtakeuti we are not yet uploading BG data from OpenAPS to NS. we use the Share bridge; @jasoncalabrese uses xDrip. I'd like to get that set up at some point, but lots of other stuff to do, and the process isn't well documented yet. Ben has helped a few people through it, but not sure if any of them have written it up yet.
JaysonEwer
@JaysonEwer
May 17 2016 17:40
Hi @scottleibrand I've got auto-sens running, but i'm not sure its actually working properly. Also, it looks like I've got a new profile.json that has been pre populated with default values, rather than the values that are set in my pump. Is that part of the new oref0, or is that from the auto-sens settings? This is the output of my auto-sense as it runs in my loop:
May 17 13:37:09 Ewer-Open-APS openaps: reporting settings/insulin_sensitivities.json
May 17 13:37:16 Ewer-Open-APS openaps: .............................................................................................................................................................................................................................................................................................
May 17 13:37:16 Ewer-Open-APS openaps: p=0.60: 0.00, 0.00, 0.00
May 17 13:37:16 Ewer-Open-APS openaps: p=0.58: -0.33, 0.00, 0.00
May 17 13:37:16 Ewer-Open-APS openaps: p=0.56: -0.33, 0.00, -0.33
May 17 13:37:16 Ewer-Open-APS openaps: p=0.54: -0.33, 0.00, -0.33
May 17 13:37:16 Ewer-Open-APS openaps: p=0.52: -0.67, 0.00, -0.33
May 17 13:37:16 Ewer-Open-APS openaps: p=0.50: -0.67, 0.00, -0.67
May 17 13:37:16 Ewer-Open-APS openaps: p=0.48: -0.67, 0.00, -0.67
May 17 13:37:16 Ewer-Open-APS openaps: p=0.46: -1.00, 0.00, -1.00
May 17 13:37:16 Ewer-Open-APS openaps: p=0.44: -1.00, 0.00, -1.00
May 17 13:37:16 Ewer-Open-APS openaps: p=0.42: -1.33, 0.00, -1.33
May 17 13:37:16 Ewer-Open-APS openaps: p=0.40: -1.33, 0.00, -1.33
May 17 13:37:16 Ewer-Open-APS openaps: p=0.38: -1.33, 0.00, -1.33
May 17 13:37:16 Ewer-Open-APS openaps: p=0.36: -1.67, 0.00, -1.67
May 17 13:37:16 Ewer-Open-APS openaps: p=0.34: -1.67, 0.00, -1.67
May 17 13:37:16 Ewer-Open-APS openaps: p=0.32: -2.00, 0.00, -2.00
May 17 13:37:16 Ewer-Open-APS openaps: p=0.30: -2.00, 0.00, -2.00
May 17 13:37:16 Ewer-Open-APS openaps: p=0.28: -2.00, 0.00, -2.00
May 17 13:37:16 Ewer-Open-APS openaps: p=0.26: -2.33, 0.00, -2.33
May 17 13:37:16 Ewer-Open-APS openaps: Mean deviation: 0.69
May 17 13:37:16 Ewer-Open-APS openaps: Excess insulin sensitivity detected
May 17 13:37:16 Ewer-Open-APS openaps: Basal adjustment -0.16U/hr
May 17 13:37:16 Ewer-Open-APS openaps: Ratio: 94%: new ISF: 53.2mg/dL/U
May 17 13:37:17 Ewer-Open-APS openaps: auto-sens://text/shell/monitor/auto-sens.json
May 17 13:37:17 Ewer-Open-APS openaps: reporting monitor/auto-sens.json
May 17 13:37:23 Ewer-Open-APS openaps: {"delta":-1,"glucose":215,"avgdelta":-0.667}
May 17 13:37:23 Ewer-Open-APS openaps: {"duration":22,"rate":3.2,"temp":"absolute"}
May 17 13:37:23 Ewer-Open-APS openaps: {"netbasalinsulin":0.25,"activity":0.018,"basaliob":0.784,"hightempinsulin":1.5,"bolussnooze":0,"iob":1.447}
May 17 13:37:23 Ewer-Open-APS openaps: {"max_iob":3,"type":"current","dia":4,"current_basal":2.5,"max_daily_basal":2.5,"max_basal":5,"min_bg":120,"max_bg":120,"sens":50}
Does it look correct to you?
Ben West
@bewest
May 17 2016 17:47
@baughaw I've been looking for help with that... if you can give me several pages of glucose data, it would help
Scott Leibrand
@scottleibrand
May 17 2016 17:48
@JaysonEwer it's kinda hard to tell from that output if you have a full 24h of pumphistory data or not
JaysonEwer
@JaysonEwer
May 17 2016 17:55
yeah, thats kinda what It looks like to me too. When I compare my output to the output at the site I used to set it up. Also, I'm not sure what the three numbers represent, but i'm noticing my center column is always 0.00, is that "ok"/"normal"?
Also, I see the "new ISF: " calculated, but how does that end up getting used?
so the zero one is BGIs
which means autosens doesn't know about any insulin activity for most of the day
which means your pumphistory data doesn't cover 24h, or isn't zoned, or something
JaysonEwer
@JaysonEwer
May 17 2016 17:59
ah, ok
I guess I was expecting it to fail if I didn't have things setup correctly? I was slightly surprised it "worked" the first time I tried running it, but kinda figured something wasn't quite right. :-D
dougtakeuti
@dougtakeuti
May 17 2016 18:01
@jasoncalabrese and @scottleibrand Thank you. Since I use medtronic sensors, I don't see any other way to upload glucose data but using openaps, as mmcommander picks up all the pump comms and crashes. In fact, I have been uploading glucose data from openaps, but I do it in a very primitive way. I get the last 30 min of BG entries and upload all the (hopefully) 6 points to NS, every 5 min. Obviously this quickly makes me run into my allowed limits in heroku or azure. I've seen pieces of code where people compare NS entries to retrieved pump entries and only upload what is missing, but I haven't been able to make that work. Do you know what do other users of Enlite do? @johnmales ? @oskarpearson ?
Scott Leibrand
@scottleibrand
May 17 2016 18:01
yeah, sounds like we need to set up a bunch of error checking in autosens for missing pumphistory data like we have for missing glucose data
the difficult bit there is knowing the difference between "openaps wasn't running and there were no boluses" and "your reports are screwed up"
JaysonEwer
@JaysonEwer
May 17 2016 18:02
right
Yeah, i guess i'm trying to figure out a way to debug my SHTUFF. :-D
Regarding the profile.json, that came with the autosense instructions...I think that broke something, because I used to be able to change my bg_targets on my pump and I would see that reflected in the loop on the next loop run. But now It looks like i've got a hard coded profile that is not being dynamically generated.
Scott Leibrand
@scottleibrand
May 17 2016 18:05
where do the docs say to set up a hard coded profile? that's not right.
JaysonEwer
@JaysonEwer
May 17 2016 18:06
Well, i'm not sure It "said" that, but when I followed the instructions that was what I observed happening. :-D
Andrew Baugh
@baughaw
May 17 2016 18:06
@bewest I sent you a direct message with the glucose vals.
Scott Leibrand
@scottleibrand
May 17 2016 18:07
@JaysonEwer which instructions?
JaysonEwer
@JaysonEwer
May 17 2016 18:07
I just restarted my browser and thought all my tabs would reopen, but they didn't. :-/ It will take me a moment to find that...
found it
Step 4
Scott Leibrand
@scottleibrand
May 17 2016 18:11
that just creates an auto-sens.json report, not a profile.json report
it assumes you already have a profile.json report, and you point to the output of it
JaysonEwer
@JaysonEwer
May 17 2016 18:12
ok, I guess i'm not sure why the generation of my profile.json, is now set to settings I have no idea where they came from? :-/
benhamou
@benhamou
May 17 2016 18:13
hi @scottleibrand I tried ur openaps/oref0@d995168 but what directory do I have to enter
JaysonEwer
@JaysonEwer
May 17 2016 18:13
hence the term, hard coded. Its almost as if it is assuming some detault settings
benhamou
@benhamou
May 17 2016 18:13
before my serial no
Scott Leibrand
@scottleibrand
May 17 2016 18:14
@benhamou you should be able to run that from your home directory, and just pick a name for your openaps data directory
also, that script will not upload any BG data
benhamou
@benhamou
May 17 2016 18:15
the bg data are already there
Scott Leibrand
@scottleibrand
May 17 2016 18:15
k
benhamou
@benhamou
May 17 2016 18:15
but i do have to enter in this liine my serial no, not
die "Usage: $self <directory> <pump serial #>"
Is directory an arbitrarily chosen directory
what do u mean by openaps data directory
Paul Martin
@Spazholio
May 17 2016 18:18
Odd question, but is this considered zoned? "dateString": "2016-05-17T18:13:36.000Z"
Because when I attempted to zone the data from NS, I get this as a result: "dateString": "2016-05-17T18:13:36+00:00". Which is incorrect, I believe.
benhamou
@benhamou
May 17 2016 18:26

[device "ns-status"]
vendor = openaps.vendors.process
extra = ns-status.ini

the processes are not entered properly

Scott Leibrand
@scottleibrand
May 17 2016 18:27
@Spazholio that Z dateString is already zoned, yes. no need to zone it again, though I think the +00:00 syntax should also work
Paul Martin
@Spazholio
May 17 2016 18:28
Well, hell. I thought that might have been why my auto-sens.json report was only working with data from the CGM and not from NS.
Scott Leibrand
@scottleibrand
May 17 2016 18:28
@benhamou I think you might be the first person to actually use that script since I wrote it. if it's missing things, you're welcome to submit PR's to fix. it should be pretty straightforward what it's doing if you run through the normal openaps setup process alongside.
Hristina Dimova
@xpucuto
May 17 2016 18:28
@scottleibrand how do you command your pi without Internet ?
Scott Leibrand
@scottleibrand
May 17 2016 18:28
@benhamou you have to pick a name for the directory where all your ini files etc. will live
JaysonEwer
@JaysonEwer
May 17 2016 18:28
@scottleibrand It may be time to start over, as I'm not sure I was successful in upgrading to the latest dev branch. :-D
Scott Leibrand
@scottleibrand
May 17 2016 18:29
@xpucuto for the cruise I set up a Pi to be a standalone hotspot on a second wifi dongle
JaysonEwer
@JaysonEwer
May 17 2016 18:29
I guess I can try to fulfil the required reports that are needed, but things changed along the way. :-D
Matt Pressnall
@logichammer
May 17 2016 18:29
@scottleibrand , starting to write the documentation but wanted to cover / understand this "Exercise Mode" I have been hearing about (JS Irwin). Is it just built into AMA and does predictions or something you actively enable and disable?
Hristina Dimova
@xpucuto
May 17 2016 18:30
@scottleibrand does this mean you can use the pi as a hotspot and connect it to awifi (if present later ) at the same time ?
Scott Leibrand
@scottleibrand
May 17 2016 18:30
@xpucuto yeah
Paul Martin
@Spazholio
May 17 2016 18:31
@JaysonEwer I'm running into the same stuff. =)
@JaysonEwer If you get your auto-sens.json working with NS data once you get everything set up again, I'd love to pick your brain.
Scott Leibrand
@scottleibrand
May 17 2016 18:32
@logichammer the ability to pull in temp targets from NS is built into AMA, but for it to do anything you have to set up the temptargets report and also enter activity mode into NS
Hristina Dimova
@xpucuto
May 17 2016 18:32
@scottleibrand that's great news :) is it documented somewhere ? So can give it a try ?
Scott Leibrand
@scottleibrand
May 17 2016 18:33
not really, as it is highly customized
Matt Pressnall
@logichammer
May 17 2016 18:33
Gotcha and badass...will see what I can figure out on my own...or what is JS Irwin's handle if I want hit him up / not bug you?
Scott Leibrand
@scottleibrand
May 17 2016 18:34
@xpucuto:
auto wlan0
allow-hotplug wlan0
iface wlan0 inet manual
wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf

auto wlan1
allow-hotplug wlan1
iface wlan1 inet static
address 10.29.29.1
netmask 255.255.255.0
and also probably want to set up a dhcp server like dnsmasq
John Sjolund
@sjolundjohn
May 17 2016 18:35
Hi, is there anybody that is available to help me trouble shoot timezones?
Hristina Dimova
@xpucuto
May 17 2016 18:35
I have dnsmasq on my test rig this how I made it as a hotspot today
Scott Leibrand
@scottleibrand
May 17 2016 18:35
oh, that part actually is documented I think
John Sjolund
@sjolundjohn
May 17 2016 18:35
I have been running a open loop today (Woohoo) but unable to get last little issues solved
Scott Leibrand
@scottleibrand
May 17 2016 18:35
most of that stuff is from an earlier attempt, but the dnsmasq.conf is probably useful, and maybe a few other pieces
Dana Lewis
@danamlewis
May 17 2016 18:36
@logichammer not sure who js irwin is. but I can add to the documentation on Activity mode and temp targets once you get your version in
Ben West
@bewest
May 17 2016 18:37
Z is a legit zone
math is fine between any zoned dates, even if zones are different
if you want zones to become same, or pick a particular zone, use --astimezone
Matt Pressnall
@logichammer
May 17 2016 18:39
@danamlewis, sounds good and looking forward to implementing myself. I assumed JS Irwin was on OpenAPS (FB Friend) since he was posting this which lines up pretty much with what OpenAPS has been doing but maybe he is doing a trial:
This message was deleted
This message was deleted
Dana Lewis
@danamlewis
May 17 2016 18:40
@logichammer not sure what he’s using, you should ask him :) looks like maybe a UVA trial version?
Ben West
@bewest
May 17 2016 18:40
you can play with that/prove it to yourself with lsgaps: if you ask for gaps spanning DST changes, the gap spec will use the correct local offset per DST
Matt Pressnall
@logichammer
May 17 2016 18:40
I will do that...
Dana Lewis
@danamlewis
May 17 2016 18:41
:+1:
John Sjolund
@sjolundjohn
May 17 2016 18:41

@bewest ok thanks I will try that. I just realized I left my ethernet adapter at my office so I can't connect to pi. Bummer.

The problem I had was everything I was pulling from pump seemed to be two hours old, I am hoping that this will resolve it

@bewest another one, somebody earlier didn't like that I had my pump called Nightscout, which I understand. If I change name in config.ini manually, will this update all the reports? I am hoping to change pump name without having to manually recreate everything
Scott Leibrand
@scottleibrand
May 17 2016 18:45
yeah, if you update all the .ini's that should be sufficient.
John Sjolund
@sjolundjohn
May 17 2016 18:46

@bewest last one for me today since I can't access, I have gotten crontab setup, but having some issues and keep getting new mail.

It seems amoung others that the uploader.log file is never created.

Will the first time it runs, create file automatically? I tried to manually setup but ran into issue with permissions.

| tee -a /var/log/openaps/uploader.log
Paul Martin
@Spazholio
May 17 2016 18:46
So if I copy my raw-cgm/glucose.json over to monitor/glucose.json and run the auto-sens.json report, it works just fine. If I copy the raw-ns/glucose.json to monitor/glucose.json, it is less-than-fine. I get NaN all over the place. Any ideas what might be happening there? I believe I've followed the instructions to the letter, but...
Scott Leibrand
@scottleibrand
May 17 2016 18:47
maybe paste a single BG data point from each?
Ben West
@bewest
May 17 2016 18:47
if everything is two hours old
check date on pi itself
for logging
I really prefer to use syslog
so I would remove the | tee -a /var/log/myfile
and instead do | logger -t openaps-loop or similar
then it'll always be in /var/log/syslog
you can use papertrail.com or similar to get it to show up on a website or elsewhere
John Sjolund
@sjolundjohn
May 17 2016 18:50
Ok will test!
benhamou
@benhamou
May 17 2016 18:50
when I enter:
openaps device add ns-status process --require "clock iob suggested enacted battery reservoir status" ns-status
my openaps.ini only shows this
John Sjolund
@sjolundjohn
May 17 2016 18:51
The issue is that when run 'inter_pump' everything seemed old in there by at least 2h
benhamou
@benhamou
May 17 2016 18:51
[device "ns-status"]
vendor = openaps.vendors.process
extra = ns-status.ini
Ben West
@bewest
May 17 2016 18:51
that creates an ns-status.ini file
try: openaps device show ns-status --ini
Paul Martin
@Spazholio
May 17 2016 18:51
@scottleibrand Ok. From NS:
  {
    "direction": "Flat",.
    "trend": 4,.
    "dateString": "2016-05-17T18:48:35.000Z",.
    "sgv": 114,.
    "device": "share2",.
    "date": 1463510915000,.
    "_id": "573b679c2f763e5e5929ef5f",.
    "type": "sgv",.
    "glucose": 114
  },
From CGM:
  {
    "trend_arrow": "FLAT",.
    "system_time": "2016-05-17T21:47:49",.
    "direction": "Flat",.
    "sgv": 114,.
    "display_time": "2016-05-17T14:47:49",.
    "date": 1463510869000.0,.
    "dateString": "2016-05-17T14:47:49",.
    "unfiltered": 124496,.
    "filtered": 128912,.
    "device": "openaps://cgm",.
    "rssi": 189,.
    "type": "sgv",.
    "glucose": 114
  },
Ben West
@bewest
May 17 2016 18:52
or even: openaps device show ns-status --json
benhamou
@benhamou
May 17 2016 18:52
I removed and added it now seeral times
Ben West
@bewest
May 17 2016 18:52
yay oref0_glucose :)
oh it's missing zones
need to zone that sucker
Paul Martin
@Spazholio
May 17 2016 18:53
I have. No change. =)
Ben West
@bewest
May 17 2016 18:53
openaps use tz rezone --date dateString
need --date dateString at least in there
would do --date dateString --date display_time --date system_time probably
Paul Martin
@Spazholio
May 17 2016 18:54
From my ns-glucose-zoned.json:
  {
    "direction": "Flat",.
    "trend": 4,.
    "dateString": "2016-05-17T18:48:35+00:00",.
    "sgv": 114,.
    "date": 1463510915000,.
    "device": "share2",.
    "_id": "573b679c2f763e5e5929ef5f",.
    "type": "sgv",.
    "glucose": 114
  },
benhamou
@benhamou
May 17 2016 18:54
pi@raspberrypi:~/my_openaps$ openaps device show ns-status --json
'''{"extra": {"fields": "clock iob suggested enacted battery reservoir status", "cmd": "ns-status", "args": ""}, "type": "device", "name": "ns-status", "ns-status": {"vendor": "openaps.vendors.process", "extra": "ns-status.ini"}}
Ben West
@bewest
May 17 2016 18:54
that's from share2
looks ok, @benhamou
try the --ini variant
Paul Martin
@Spazholio
May 17 2016 18:54
From cgm-zoned.json:
  {
    "trend_arrow": "FLAT",.
    "display_time": "2016-05-17T14:47:49",.
    "direction": "Flat",.
    "system_time": "2016-05-17T21:47:49",.
    "sgv": 114,.
    "dateString": "2016-05-17T14:47:49-04:00",.
    "device": "openaps://cgm",.
    "unfiltered": 124496,.
    "rssi": 189,.
    "date": 1463510869000.0,.
    "filtered": 128912,.
    "type": "sgv",.
    "glucose": 114
  },
John Sjolund
@sjolundjohn
May 17 2016 18:55
@benhamou this seems like my issue also
Ben West
@bewest
May 17 2016 18:55
ah ok, you need to be referring to cgm-zoned.json instead of the other one
Paul Martin
@Spazholio
May 17 2016 18:55
What if the CGM isn't plugged in?
Ben West
@bewest
May 17 2016 18:55
this is one reason, I recommend keeping a directory that is for raw/unzoned stuff
Paul Martin
@Spazholio
May 17 2016 18:55
Can auto-sens.json ONLY work with CGM data?
Ben West
@bewest
May 17 2016 18:55
you just need to adjust your aliases to refer to that file instead of the other
Paul Martin
@Spazholio
May 17 2016 18:56
It works flawlessly with the CGM stuff. It's getting it to run with data from NS that's broken.
Ben West
@bewest
May 17 2016 18:57
is that being rezoned with --astimezone?
Paul Martin
@Spazholio
May 17 2016 18:57
The ns-glucose-zoned.json? Let me check.
Ben West
@bewest
May 17 2016 18:57
hmmm, well there's two sides to this
Paul Martin
@Spazholio
May 17 2016 18:57
[report "raw-ns/ns-glucose-zoned.json"]                                                                                                                                                                                                                                    
use = rezone
reporter = JSON
astimezone = True
date = timestamp dateString start_at end_at created_at display_time dateString
adjust = missing
input = raw-ns/ns-glucose.json
device = tz
timezone =.
Ben West
@bewest
May 17 2016 18:57
the reports allow you to save config for how to generates pieces of information reliably
the aliases are what controls when and how that happens
timezone =.?
hmm
Paul Martin
@Spazholio
May 17 2016 18:58
Ignore the .
Ben West
@bewest
May 17 2016 18:58
ok
Paul Martin
@Spazholio
May 17 2016 18:58
(that's just how my .vimrc shows a space)
Ben West
@bewest
May 17 2016 18:59
you've got an alias which is removing/moving files around outside of the report system
Paul Martin
@Spazholio
May 17 2016 19:00
I do in some parts, but I'm running in a dev directory, and I've put every file where I intend it to be manually, just to test this.
Ben West
@bewest
May 17 2016 19:00
ah, you have raw-ns
Paul Martin
@Spazholio
May 17 2016 19:01
Here's what it looks like if I run auto-sens.json with NS data, zoned or unzoned:
auto-sens://text/shell/settings/auto-sens.json
.............................................................................................................................................................................................................................................................................................
p=0.60: NaN, 0.72, NaN
p=0.58: NaN, 0.63, NaN
p=0.56: NaN, 0.56, NaN
p=0.54: NaN, 0.41, NaN
p=0.52: NaN, 0.31, NaN
p=0.50: NaN, 0.23, NaN
p=0.48: NaN, 0.15, NaN
p=0.46: NaN, 0.07, NaN
p=0.44: 6.20, -0.05, NaN
p=0.42: NaN, -0.10, NaN
p=0.40: NaN, -0.19, NaN
p=0.38: NaN, -0.26, NaN
p=0.36: NaN, -0.44, NaN
p=0.34: NaN, -0.59, NaN
p=0.32: NaN, -0.68, NaN
p=0.30: NaN, -0.76, NaN
p=0.28: NaN, -0.91, NaN
p=0.26: NaN, -1.25, NaN
Mean deviation: NaN
Sensitivity within normal ranges
Basal adjustment 0.00U/hr
Ratio: 100%: new ISF: 20.0mg/dL/U
reporting settings/auto-sens.json
Ben West
@bewest
May 17 2016 19:01
is this same as problem with running against NS data?
Paul Martin
@Spazholio
May 17 2016 19:01
Yeah, I liked your idea of using raw directories, so I'm trying to integrate it. Getting it into my main loop comes next, so I don't think that's screwing me up too much here.
This is the problem running with NS data, yes. CGM works perfectly.
Ben West
@bewest
May 17 2016 19:02
there's an error before this somehow though
I don't know what use you ran
openaps report show settings/auto-sens.json --cli
then cat or tail all the files mentioned
Paul Martin
@Spazholio
May 17 2016 19:03
openaps use auto-sens shell monitor/glucose.json settings/pumphistory-24h-zoned.json settings/insulin_sensitivities.json settings/basal_profile.json settings/profile.json []
Ben West
@bewest
May 17 2016 19:03
ah
remainder = []
make it say remainder =
Paul Martin
@Spazholio
May 17 2016 19:03
Done.
Ben West
@bewest
May 17 2016 19:04
same deal, show --cli again, run it like that, cat all the arguments
Paul Martin
@Spazholio
May 17 2016 19:04
Now it shows openaps use auto-sens shell monitor/glucose.json settings/pumphistory-24h-zoned.json settings/insulin_sensitivities.json settings/basal_profile.json settings/profile.json
k
Ben West
@bewest
May 17 2016 19:04
does that run, if you type all that in?
Paul Martin
@Spazholio
May 17 2016 19:04
Yes.
Not correctly, but it runs.
The glucose.json and pumphistory-24h-zoned.json files will be HUGE. What should I get out of them specifically? Last entry?
Or did you just want to know that I CAN cat them? If so, yes, I can.
Ben West
@bewest
May 17 2016 19:15
what's wrong with it?
what do you mean not correctly?
are they zoned the same way?
Paul Martin
@Spazholio
May 17 2016 19:15
.............................................................................................................................................................................................................................................................................................
p=0.60: NaN, 0.72, NaN
p=0.58: NaN, 0.63, NaN
p=0.56: NaN, 0.56, NaN
p=0.54: NaN, 0.41, NaN
p=0.52: NaN, 0.31, NaN
p=0.50: NaN, 0.23, NaN
p=0.48: NaN, 0.15, NaN
p=0.46: NaN, 0.07, NaN
p=0.44: NaN, -0.05, NaN
p=0.42: NaN, -0.10, NaN
p=0.40: NaN, -0.19, NaN
p=0.38: NaN, -0.26, NaN
p=0.36: NaN, -0.44, NaN
p=0.34: NaN, -0.59, NaN
p=0.32: NaN, -0.68, NaN
p=0.30: NaN, -0.76, NaN
p=0.28: NaN, -0.91, NaN
p=0.26: NaN, -1.25, NaN
Mean deviation: NaN
Sensitivity within normal ranges
Basal adjustment 0.00U/hr
Ratio: 100%: new ISF: 20.0mg/dL/U
Ben West
@bewest
May 17 2016 19:15
if they aren't zoned the same way, it will probably fail
Paul Martin
@Spazholio
May 17 2016 19:15
Let me check.
Ben West
@bewest
May 17 2016 19:16
that tool in particular is @scottleibrand's expertise though
yeah, I'd find first entry in both files
Paul Martin
@Spazholio
May 17 2016 19:16
What's funny is that the CGM data runs just fine whether it's zoned or not.
Ben West
@bewest
May 17 2016 19:17
json -f glucose.json -- 1 | json dateString and json -f pumphistory-24h-zoned.json -- 1 | json created_at timestamp
Paul Martin
@Spazholio
May 17 2016 19:17
For this, what settings do you recommend for the date and astimezone entries in the reports?
Ben West
@bewest
May 17 2016 19:17
should print just the times for comparison
whatever the datefield is actually called
Paul Martin
@Spazholio
May 17 2016 19:18
2016-05-17T12:39:52-04:00
Ben West
@bewest
May 17 2016 19:18
ok, so that's zoned fine
next :-)
Paul Martin
@Spazholio
May 17 2016 19:19
Oh hell, hang on....
First: 2016-05-17T19:03:35+00:00
Second: 2016-05-17T12:39:52-04:00
Ben West
@bewest
May 17 2016 19:20
ok, great
so, that tool might not handle date/times so well
Scott Leibrand
@scottleibrand
May 17 2016 19:20
Quite possible.
Ben West
@bewest
May 17 2016 19:20
right way to do it is new Date(Date.parse(dateField))
or we can use sugarjs :-D
Paul Martin
@Spazholio
May 17 2016 19:21
Looks like my 2 reports are using different fields to generate them...hang on, I'll show you what I mean...
Ben West
@bewest
May 17 2016 19:21
ah, for the rezoning?
Scott Leibrand
@scottleibrand
May 17 2016 19:21
At this point I would start adding or uncommenting print statements.
Ben West
@bewest
May 17 2016 19:21
it might help to add --astimezone to some of those
Paul Martin
@Spazholio
May 17 2016 19:21
[report "raw-cgm/glucose-zoned.json"]
use = rezone
reporter = JSON
astimezone = False
date = timestamp dateString start_at end_at created_at
adjust = missing
input = raw-cgm/glucose.json
device = tz
timezone = EDT

[report "raw-ns/ns-glucose-zoned.json"]
use = rezone
reporter = JSON
astimezone = True
date = timestamp dateString start_at end_at created_at display_time dateString
adjust = missing
input = raw-ns/ns-glucose.json
device = tz
timezone =
Ben West
@bewest
May 17 2016 19:21
--astimezone by itself with rezone will "cast" them all into the same timezone expression
Paul Martin
@Spazholio
May 17 2016 19:22
If you tell me which of those is totally wonked and what I should set it to, I'll make 'em match. =)
Because I figure they probably should.
I have no idea why dateString is in there twice on that second report...
Ben West
@bewest
May 17 2016 19:23
astimezone = True
Paul Martin
@Spazholio
May 17 2016 19:24
Ok.
Should I adjust the date fields as well?
Ben West
@bewest
May 17 2016 19:25
I'd try tweaking one thing at a time
Paul Martin
@Spazholio
May 17 2016 19:26
Sure thing. I'll re-run the NS stuff and see what happens. Standby...
Same result. Lots of NaN.
Next thing I did was set both of the entries to have timezone = EDT so they match. Same result.
Ben West
@bewest
May 17 2016 19:30
think you're going to need help from the author :-)
on what is likely to cause nans, I have no idea if date mismatch or something can cause it
which tool is that?
I'd have to add print statements like @scottleibrand suggested
Paul Martin
@Spazholio
May 17 2016 19:31
Which tool is what?
Ben West
@bewest
May 17 2016 19:31
openaps device show auto-sens --ini
Paul Martin
@Spazholio
May 17 2016 19:32
[device "auto-sens"]
vendor = openaps.vendors.process
extra = auto-sens.ini
fields = glucose pumphistory insulin_sensitivities basal_profile profile
cmd = oref0
args = detect-sensitivity
Ben West
@bewest
May 17 2016 19:34
ah, looks like zone info is tossed when considering times/minutes/hours
so if they aren't in same zone, it likely won't work
astimezone should have helped, one of the reports should look a little different
if not, it's time to experiment with the date fields
Paul Martin
@Spazholio
May 17 2016 19:35
Am I possibly pulling NS data incorrectly or something? I've done what's in here: https://github.com/openaps/docs/blob/dev/docs/docs/walkthrough/phase-6/Configure-Automatic-Sensitivity-Mode.md
Ben West
@bewest
May 17 2016 19:35
just need to add another field to the list
do you remember the json command we ran to get the dates?
Paul Martin
@Spazholio
May 17 2016 19:36
history does.
Ben West
@bewest
May 17 2016 19:36
run it again so we can see what changed
it should also give us a clue which field needs to be added by comparing them
Paul Martin
@Spazholio
May 17 2016 19:36
json -f monitor/glucose.json -- 1 | json dateString yields 2016-05-17T19:23:35+00:00
json -f settings/pumphistory-24h-zoned.json -- 1 | json created_at timestamp yields 2016-05-17T12:39:52-04:00
In those two commands, the first one has dateString and the second has created_at timestamp. Is that...right?
Ben West
@bewest
May 17 2016 19:38
how does it correspond with the configured reports?
Paul Martin
@Spazholio
May 17 2016 19:39
[report "monitor/pumphistory-zoned.json"]
use = rezone
reporter = JSON
astimezone = False
date = timestamp dateString start_at end_at created_at
adjust = missing
input = monitor/pumphistory.json
device = tz
timezone = EDT
[report "raw-ns/ns-glucose-zoned.json"]
use = rezone
reporter = JSON
astimezone = True
date = timestamp dateString start_at end_at created_at
adjust = missing
input = raw-ns/ns-glucose.json
device = tz
timezone = EDT
JaysonEwer
@JaysonEwer
May 17 2016 19:39
@Spazholio I'd be happy to assist you with auto-sens once I get it operational. :-)
Paul Martin
@Spazholio
May 17 2016 19:40
@JaysonEwer HURRY. UP! :laughing:
I'm pulling NS data via:
[device "ns-glucose"]                                                                                                                                                                                                                                                      
fields =.
cmd = bash
args = -c "curl -s https://www.lexal.net:1337/api/v1/entries.json?count=288 | json -e 'this.glucose = this.sgv'"
Ben West
@bewest
May 17 2016 19:42
ah
recommend checking out nightscout autoconfigure-device-crud and using resulting ns device, which can download as well as upload, as well as many other things (get latest)
Paul Martin
@Spazholio
May 17 2016 19:44
Oh. I have that configured already. The nsdevice, at least.
Ben West
@bewest
May 17 2016 19:44
openaps/docs#129
ah, you can use openaps use ns shell get entries.json count=288 instead as a report
should be same thing
Paul Martin
@Spazholio
May 17 2016 19:45
Looks zoned and evetything.
Ben West
@bewest
May 17 2016 19:45
no, it doesn't looks similarly zoned
one has GMT, other has -4
Paul Martin
@Spazholio
May 17 2016 19:45
Not similarly, but zoned in general.
Ben West
@bewest
May 17 2016 19:45
need to experiment with that date list until they are the same
Paul Martin
@Spazholio
May 17 2016 19:45
Like, I don't need to run it through a rezoning once I have the data...
Ben West
@bewest
May 17 2016 19:46
I usually do openaps use tz rezone ... interactively with different arguments to figure it out
then I make sure the report is configured the same way as that
Paul Martin
@Spazholio
May 17 2016 19:47
Well to be honest, I don't know what I'm looking for. Do I just need to make sure the NS data has the exact same fields as the CGM data? Are there fields I should be specifically looking for?
Ben West
@bewest
May 17 2016 19:47
the ones that looks like dates
the list of fields in the date list controls which fields get modified
looks like some of them may be missing for some report
since your alias moves things around, it's harder to track which report is actually responsible
there's a new tool made to help out with this kind of thing
Paul Martin
@Spazholio
May 17 2016 19:48
True, but the alias isn't in play right now. I'm invoking reports directly since I want as little confusion (HAH!) as possible. =)
Oh?
Ben West
@bewest
May 17 2016 19:49
ah
ok
so, I'd try experimenting with the use
what's the report name?
you can get the cli use with openaps report show --cli myreport.json
Paul Martin
@Spazholio
May 17 2016 19:49
For which, specifically? Pulling NS data?
Ben West
@bewest
May 17 2016 19:49
for rezoning
the rezoning step doesn't have the right date argument
Paul Martin
@Spazholio
May 17 2016 19:50
Ah.
Andrew Baugh
@baughaw
May 17 2016 19:50
@bewest Was that enough data for the Enlite?
Paul Martin
@Spazholio
May 17 2016 19:50
This is for raw-ns/ns-glucose-rezoned.json: openaps use tz rezone --timezone "EDT" --adjust "missing" --date "timestamp dateString start_at end_at created_at" --astimezone raw-ns/ns-glucose.json
Ben West
@bewest
May 17 2016 19:51
@baughaw any chance you could put it in gist.github.com or maybe in comment? openaps/docs#129
try running that
there are two in question here, right?
Paul Martin
@Spazholio
May 17 2016 19:52
Oh, for the CGM as well, right. 1 sec.
Andrew Baugh
@baughaw
May 17 2016 19:52
sure
Ben West
@bewest
May 17 2016 19:52
you can get just the first one by adding | json -- 0 on the end
right, it's the difference between them we care about
Paul Martin
@Spazholio
May 17 2016 19:52
For the NS rezoning:
{
  "direction": "Flat",
  "trend": 4,
  "dateString": "2016-05-17T15:28:35-04:00",
  "sgv": 83,
  "date": 1463513315000,
  "device": "share2",
  "_id": "573b70fc2f763e5e5929ef67",
  "type": "sgv",
  "glucose": 83
}
For CGM rezoning:
{
  "trend_arrow": "FLAT",
  "display_time": "2016-05-17T14:47:49",
  "direction": "Flat",
  "system_time": "2016-05-17T21:47:49",
  "sgv": 114,
  "dateString": "2016-05-17T14:47:49-04:00",
  "device": "openaps://cgm",
  "unfiltered": 124496,
  "rssi": 189,
  "date": 1463510869000,
  "filtered": 128912,
  "type": "sgv",
  "glucose": 114
}
Ben West
@bewest
May 17 2016 19:53
hmm I thought the other file was a pump history file?
that one gets rezoned as well
that's what has to match
Paul Martin
@Spazholio
May 17 2016 19:54
Oh, balls. Sorry. I thought you wanted to compare what works with what doesn't. My bad. 1 sec.
Ben West
@bewest
May 17 2016 19:54
they all have to match :-)
Andrew Baugh
@baughaw
May 17 2016 19:54
@bewest added to the comments. Let me know what else I can do to help! Thanks
Ben West
@bewest
May 17 2016 19:54
actually
I see what happened here
what does just --cli say for that cgm rezoning?
I'm 100% certain it's missing --date display_time
I can see in the code, it looks first for display_time
so that's probably the issue
either that or pump-history is not zoned same way
Paul Martin
@Spazholio
May 17 2016 19:56
Really? But the CGM is the only one that works! headdesk
Hang on...
Ben West
@bewest
May 17 2016 19:56
yeah, that means pump-history zoning is questionable
Paul Martin
@Spazholio
May 17 2016 19:57
openaps report show --cli raw-cgm/glucose-zoned.json == openaps use tz rezone --timezone "EDT" --adjust "missing" --date "timestamp dateString start_at end_at created_at" --astimezone raw-cgm/glucose.json. Running that gets me:
{
  "trend_arrow": "FLAT",
  "display_time": "2016-05-17T14:47:49",
  "direction": "Flat",
  "system_time": "2016-05-17T21:47:49",
  "sgv": 114,
  "dateString": "2016-05-17T14:47:49-04:00",
  "device": "openaps://cgm",
  "unfiltered": 124496,
  "rssi": 189,
  "date": 1463510869000,
  "filtered": 128912,
  "type": "sgv",
  "glucose": 114
}
Ben West
@bewest
May 17 2016 19:57
let's look at the pump history zoning
Paul Martin
@Spazholio
May 17 2016 19:57
Yup. Just the JSON, or do you want to see the command?
openaps use tz rezone --timezone "EDT" --adjust "missing" --date "timestamp dateString start_at end_at created_at" --astimezone settings/pumphistory-24h.json shows
{
  "_type": "Bolus",
  "_description": "Bolus 2016-05-17T13:22:05 head[4], body[0] op[0x01]",
  "timestamp": "2016-05-17T13:22:05-04:00",
  "_body": "",
  "programmed": 4,
  "_head": "01282800",
  "amount": 4,
  "duration": 0,
  "type": "normal",
  "_date": "45564d1110"
}
Ben West
@bewest
May 17 2016 20:00
ok
file a bug on detect-sensitivity in oref0 :-)
Paul Martin
@Spazholio
May 17 2016 20:01
I'M NOT CRAZY! WOOOO!
What details would you like in the bug report?
Ben West
@bewest
May 17 2016 20:02
if you could make a gist (or small github repo) with the files needed to checkout/run this example that would be incredibly helpful
just enough to run zoning on static json file, and detect sensitivity on this
you can delete/remove everything else
Paul Martin
@Spazholio
May 17 2016 20:04
I don't even have this repo on Github right now. Is it simple to take what I have right now and stuff it into a repo? =)
Ben West
@bewest
May 17 2016 20:04
yeah
ls ns-*.ini, we'll delete the bits with your private info
if you have any private stuff in openaps.ini delete it
then you can git add .; git commit -avm 'checkin everything'
Paul Martin
@Spazholio
May 17 2016 20:05
I mean, right now, it's just an empty git repo locally. I assume there are docs somewhere that illustrate how to push 'em to Github? My local repo knows nothing about Github right now...
Ben West
@bewest
May 17 2016 20:06
then on github you can create new example-auto-sens-issue maybe
Paul Martin
@Spazholio
May 17 2016 20:06
Ack, shouldn't have said "empty" git repo. It just knows nothing about Github.
Ben West
@bewest
May 17 2016 20:06
a screen will show up with stuff to type
you'll type it into your openaps area, and I believe the instructions will sync it up
it'll look something like git remote add origin https://github.com/Spazholio/example-auto-sens-issue.git; git push -u origin master
Paul Martin
@Spazholio
May 17 2016 20:08
Gotcha.
I'll do that in a bit. Gotta head out now.
Hristina Dimova
@xpucuto
May 17 2016 20:17
@ will the Edimax do the work ? If I don't want it to drain my battery can I unplug it and later use it by only plugging it into the pi?
@scottleibrand the question was for you but couldn't tag you ;)
Scott Leibrand
@scottleibrand
May 17 2016 20:27
Not sure: try it? :-)
Hristina Dimova
@xpucuto
May 17 2016 20:32
I have already checked in my local store , first thing tomorrow on my list. :)
@scottleibrand last question for tonight . Do you use your pebble alias to send information about temp basal to your watch when you are offline ( with pancreabble) ?
Ben West
@bewest
May 17 2016 20:48
heading out :-)
Dana Lewis
@danamlewis
May 17 2016 20:49
see you soon, @bewest ! and a few others, too :)
Dana Lewis
@danamlewis
May 17 2016 20:55
just added to the docs re: flying with loop, since it’s a very common question: https://github.com/openaps/docs/blob/dev/docs/docs/walkthrough/phase-6/Usability-considerations.md
Andrew Baugh
@baughaw
May 17 2016 21:03
:thumbsup:
Scott Leibrand
@scottleibrand
May 17 2016 21:38
@xpucuto have never tried pancreabble. We used cards for pebble with a local webserver on the Pi.
John Males
@johnmales
May 17 2016 21:51
@dougtakeuti I agree that mmcommander won't work reliably when looping - too much pump communications seems to crash the uploader app. I haven't yet got nightscout working to upload medtronic cgm data in a way that I'm happy with and use another custom method to monitor glucose readings. I think last I heard @oskarpearson wasn't using nightscout either but I'm not sure. It is definitely on the list though
dougtakeuti
@dougtakeuti
May 17 2016 21:53
ok thank you.
John Males
@johnmales
May 17 2016 21:55
Another question about auto-sens: determine-basal last night threw an error saying auto-sens didn't have enough data to calculate sensitivities. I think there were some gaps in glucose data over the 24 hours. Later in the night the loop restarted when enough data was available. 2 questions - what are the limits to getting auto-sens to work - do you need to have x number of data points, or is it just data points over 24h or both? Second question - I would still want to loop even if there is inadequate information to do auto-sens. Are people doing some logic to have an alternate determine-basal without auto-sens if there is inadequate data to calculate auto-sens?
Scott Leibrand
@scottleibrand
May 17 2016 21:58
That looks like a regression: seems that @bewest's change to make it fail when autosens is misconfigured is also triggering for what should only be a warning.
Please file an issue on that.
It looks for a minimum number of BG data points in the glucose.json provided.
I don't recall the exact threshold.
Stephan
@MosiGitHub
May 17 2016 22:06
has anybody a hint why I get IOB: NaNU in my OpenAps status indication on the Nightscout site?
Stephan
@MosiGitHub
May 17 2016 22:14
I checked it on both rigs: one is running on the dev version with MA & auto-sens (currently disabled) - and the other one on the AMA branch. The monitor/iob.json in the first one looks okay from my point of view:
cat monitor/iob.json
{
"netbasalinsulin": 1.5,
"activity": 0.0075,
"basaliob": 1.007,
"hightempinsulin": 1.5,
"bolussnooze": 0,
"iob": 1.007
the other monitor/iob.json file seems to have a problem with the timezone:
cat monitor/iob.json
[
{
"netbasalinsulin": 1.4,
"activity": 0.0083,
"basaliob": 0.899,
"time": "2016-05-18T00:08:41.000Z",
"hightempinsulin": 1.45,
"bolussnooze": 0,
"iob": 0.899
},
{
"netbasalinsulin": 1.35,
"activity": 0.0089,
"basaliob": 0.804,
"time": "2016-05-18T00:13:41.000Z",
"hightempinsulin": 1.45,
"bolussnooze": 0,
"iob": 0.804
},
{
"netbasalinsulin": 1.25,
"activity": 0.0092,
"basaliob": 0.708,
"time": "2016-05-18T00:18:41.000Z",
"hightempinsulin": 1.4,
"bolussnooze": 0,
"iob": 0.708
},
{
"netbasalinsulin": 1.25,
"activity": 0.0095,
"basaliob": 0.661,
"time": "2016-05-18T00:23:41.000Z",
"hightempinsulin": 1.4,
"bolussnooze": 0,
"iob": 0.661
},
{
"netbasalinsulin": 1.2,
"activity": 0.0096,
"basaliob": 0.562,
"time": "2016-05-18T00:28:41.000Z",
"hightempinsulin": 1.4,
"bolussnooze": 0,
"iob": 0.562
},
{
"netbasalinsulin": 1.15,
"activity": 0.0096,
"basaliob": 0.514,
"time": "2016-05-18T00:33:41.000Z",
"hightempinsulin": 1.35,
"bolussnooze": 0,
"iob": 0.514
},
{
"netbasalinsulin": 1.1,
"activity": 0.0096,
"basaliob": 0.466,
"time": "2016-05-18T00:38:41.000Z",
"hightempinsulin": 1.3,
"bolussnooze": 0,
"iob": 0.466
},
{
"netbasalinsulin": 1.05,
"activity": 0.0094,
"basaliob": 0.419,
"time": "2016-05-18T00:43:41.000Z",
"hightempinsulin": 1.25,
"bolussnooze": 0,
"iob": 0.419
},
{
"netbasalinsulin": 1.05,
"activity": 0.0092,
"basaliob": 0.373,
"time": "2016-05-18T00:48:41.000Z",
"hightempinsulin": 1.25,
"bolussnooze": 0,
"iob": 0.373
},
{
"netbasalinsulin": 1.05,
"activity": 0.009,
"basaliob": 0.328,
"time": "2016-05-18T00:53:41.000Z",
"hightempinsulin": 1.25,
"bolussnooze": 0,
"iob": 0.328
},
{
"netbasalinsulin": 1.05,
"activity": 0.0086,
"basaliob": 0.285,
"time": "2016-05-18T00:58:41.000Z",
"hightempinsulin": 1.25,
"bolussnooze": 0,
"iob": 0.285
},
{
"netbasalinsulin": 1,
"activity": 0.0081,
"basaliob": 0.244,
"time": "2016-05-18T01:03:41.000Z",
"hightempinsulin": 1.2,
"bolussnooze": 0,
"iob": 0.244
},
{
"netbasalinsulin": 1,
"activity": 0.0075,
"basaliob": 0.207,
"time": "2016-05-18T01:08:41.000Z",
"hightempinsulin": 1.2,
"bolussnooze": 0,
"iob": 0.207
},
{
"netbasalinsulin": 1,
"activity": 0.0068,
"basaliob": 0.173,
"time": "2016-05-18T01:13:41.000Z",
"hightempinsulin": 1.2,
"bolussnooze": 0,
"iob": 0.173
},
{
"netbasalinsulin": 0.95,
"activity": 0.0061,
"basaliob": 0.142,
"time": "2016-05-18T01:18:41.000Z",
"hightempinsulin": 1.15,
"bolussnooze": 0,
"iob": 0.142
},
{
"netbasalinsulin": 0.95,
"activity": 0.0054,
"basaliob": 0.115,
"time": "2016-05-18T01:23:41.000Z",
"hightempinsulin": 1.15,
"bolussnooze": 0,
"iob": 0.115
},
{
"netbasalinsulin": 0.95,
"activity": 0.0048,
"basaliob": 0.091,
"time": "2016-05-18T01:28:41.000Z",
"hightempinsulin": 1.15,
"bolussnooze": 0,
"iob": 0.091
},
{
"netbasalinsulin": 0.95,
"activity": 0.0041,
"basaliob": 0.071,
"time": "2016-05-18T01:33:41.000Z",
"hightempinsulin": 1.15,
"bolussnooze": 0,
"iob": 0.071
},
{
"netbasalinsulin": 0.9,
"activity": 0.0036,
"basaliob": 0.053,
"time": "2016-05-18T01:38:41.000Z",
"hightempinsulin": 1.1,
"bolussnooze": 0,
"iob": 0.053
},
{
"netbasalinsulin": 0.9,
"activity": 0.0031,
"basaliob": 0.037,
"time": "2016-05-18T01:43:41.000Z",
"hightempinsulin": 1.1,
"bolussnooze": 0,
"iob": 0.037
},
{
"netbasalinsulin": 0.9,
"activity": 0.0026,
"basaliob": 0.024,
"time": "2016-05-18T01:48:41.000Z",
"hightempinsulin": 1.1,
"bolussnooze": 0,
"iob": 0.024
},
{
"netbasalinsulin": 0.9,
"activity"
{
"netbasalinsulin": 0.9,
"activity": 0.0022,
"basaliob": 0.013,
"time": "2016-05-18T01:53:41.000Z",
"hightempinsulin": 1.1,
"bolussnooze": 0,
"iob": 0.013
},
{
"netbasalinsulin": 0.8,
"activity": 0.0017,
"basaliob": 0.005,
"time": "2016-05-18T01:58:41.000Z",
"hightempinsulin": 1,
"bolussnooze": 0,
"iob": 0.005
},
{
"netbasalinsulin": 0.75,
"activity": 0.0013,
"basaliob": -0.002,
"time": "2016-05-18T02:03:41.000Z",
"hightempinsulin": 0.95,
"bolussnooze": 0,
"iob": -0.002
},
{
"netbasalinsulin": 0.65,
"activity": 0.0009,
"basaliob": -0.007,
"time": "2016-05-18T02:08:41.000Z",
"hightempinsulin": 0.85,
"bolussnooze": 0,
"iob": -0.007
},
{
"netbasalinsulin": 0.55,
"activity": 0.0006,
"basaliob": -0.01,
"time": "2016-05-18T02:13:41.000Z",
"hightempinsulin": 0.75,
"bolussnooze": 0,
"iob": -0.01
},
{
"netbasalinsulin": 0.45,
"activity": 0.0004,
"basaliob": -0.011,
"time": "2016-05-18T02:18:41.000Z",
"hightempinsulin": 0.65,
"bolussnooze": 0,
"iob": -0.011
},
{
"netbasalinsulin": 0.35,
"activity": 0.0001,
"basaliob": -0.012,
"time": "2016-05-18T02:23:41.000Z",
"hightempinsulin": 0.55,
"bolussnooze": 0,
"iob": -0.012
},
{
"netbasalinsulin": 0.3,
"activity": 0,
"basaliob": -0.012,
"time": "2016-05-18T02:28:41.000Z",
"hightempinsulin": 0.5,
"bolussnooze": 0,
"iob": -0.012
},
{
"netbasalinsulin": 0.25,
"activity": -0.0002,
"basaliob": -0.011,
"time": "2016-05-18T02:33:41.000Z",
"hightempinsulin": 0.45,
"bolussnooze": 0,
"iob": -0.011
},
{
"netbasalinsulin": 0.2,
"activity": -0.0003,
"basaliob": -0.01,
"time": "2016-05-18T02:38:41.000Z",
"hightempinsulin": 0.4,
"bolussnooze": 0,
"iob": -0.01
},
{
"netbasalinsulin": 0.1,
"activity": -0.0004,
"basaliob": -0.008,
"time": "2016-05-18T02:43:41.000Z",
"hightempinsulin": 0.3,
"bolussnooze": 0,
"iob": -0.008
},
{
"netbasalinsulin": 0,
"activity": -0.0004,
"basaliob": -0.006,
"time": "2016-05-18T02:48:41.000Z",
"hightempinsulin": 0.2,
"bolussnooze": 0,
"iob": -0.006
},
{
"netbasalinsulin": -0.1,
"activity": -0.0004,
"basaliob": -0.004,
"time": "2016-05-18T02:53:41.000Z",
"hightempinsulin": 0.1,
"bolussnooze": 0,
"iob": -0.004
},
{
"netbasalinsulin": -0.15,
"activity": -0.0003,
"basaliob": -0.002,
"time": "2016-05-18T02:58:41.000Z",
"hightempinsulin": 0.05,
"bolussnooze": 0,
"iob": -0.002
},
{
"netbasalinsulin": -0.15,
"activity": -0.0002,
"basaliob": -0.001,
"time": "2016-05-18T03:03:41.000Z",
"hightempinsulin": 0,
"bolussnooze": 0,
"iob": -0.001
}
it is definitly not 3:03 UTC on the 18th right now....
Scott Leibrand
@scottleibrand
May 17 2016 22:21
that is an array of predicted IOBs
you probably need to update NS to the version that can handle those
Stephan
@MosiGitHub
May 17 2016 22:30
@scottleibrand thanks... I didn't update NS for a while. It is still the "old" 0.9.0 dev version.... But it should work with the other rig, right? The iob became an array with AMA not with the version before. I am wondering what is going wrong with the "old " one. Also I am wondering why the times are worng in the array of the iob.json of the AMA rig. I haven't used any zoned information for the calculate_iob process so far. Maybe I should try this...
okay.. ... I see: "predicted " IOBs ... that explains the time difference ;-)
Paul Martin
@Spazholio
May 17 2016 22:52
BG data is too old, or clock set incorrectly Tue May 17 2016 18:24:27 GMT-0400 (EDT) vs Tue May 17 2016 18:49:08 GMT-0400 (EDT) <— I’m in the middle of swapping out sensors on my Dexcom. Is that why the data’s too old? I’ve checked that everything else is synced.
Stephan
@MosiGitHub
May 17 2016 22:52
@scottleibrand : great .... after updating nightscout it is working - as you told me :clap: thankyou again for your great support - and yes, it is now working on both rigs. So , I can go to bed now...
Paul Martin
@Spazholio
May 17 2016 22:53
@MosiGitHub Do you self-host Nightscout, by any chance? Because I’d love to update NS, and I can’t figure out how. =)
Stephan
@MosiGitHub
May 17 2016 22:56
first go to the cgm-remote-monitor github page, scroll down, presss update my page and follow the instructions .. I selected the dev branch from their site and on my site for update.
Paul Martin
@Spazholio
May 17 2016 22:56
Where do you host NS?
Your own server?
Stephan
@MosiGitHub
May 17 2016 22:57
no, I normally use azure, but I also have it set up at heroku
Paul Martin
@Spazholio
May 17 2016 22:57
Ah, ok.
Stephan
@MosiGitHub
May 17 2016 22:57
sorry :worried:
Paul Martin
@Spazholio
May 17 2016 22:57
No worries!
John Males
@johnmales
May 17 2016 23:14
Issue filed openaps/oref0#117 - consider this a placeholder until I get home and can flesh it out a bit more
Dana Lewis
@danamlewis
May 17 2016 23:15
Thx @johnmales
John Males
@johnmales
May 17 2016 23:29
I filed the issue in dev but I guess the issue will be in master as well given that they are more or less the same at the moment
Scott Leibrand
@scottleibrand
May 17 2016 23:47
I think issues are just against the entire repo, not a particular branch
John Males
@johnmales
May 17 2016 23:47
ok thanks
Scott Leibrand
@scottleibrand
May 17 2016 23:49
@Spazholio try sudo npm install and then node node_modules/bower/bin/bower --allow-root install
that's what I had to do last time
Paul Martin
@Spazholio
May 17 2016 23:51
So just do a git pull and run those? Trying now...
Oh man, if you weren’t already, you’re my new favorite person.
What’s the most recent version? =)
Scott Leibrand
@scottleibrand
May 17 2016 23:55
not sure: I'm still running 0.9.0-beta2
Paul Martin
@Spazholio
May 17 2016 23:55
Ok, same here. Now, if only I weren’t in the middle of swapping sensors so I could verify. =)
Thanks!
Scott Leibrand
@scottleibrand
May 17 2016 23:58
time to figure out how to pull in raw data from the cgm and use oref0-raw? :)
and then write it up so I don't have to figure it out the next time we have a sensor restart. :)
Paul Martin
@Spazholio
May 17 2016 23:59
Wait, what’s that for? Is there something I need to do during a sensor swap?
Scott Leibrand
@scottleibrand
May 17 2016 23:59
depends: do you want openaps to loop based on raw data even before you calibrate?