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

15th
Jan 2016
Alin Artiom Kenibasov
@ktomy
Jan 15 2016 00:01
yes, but it is about how complex and modular your project is, when using just vim-like editor you can't live-debug and it leads to much more runs of your application. For a script it is absolutely ok, but when you're working on a complex project and you need to make 20 clicks before your modified code is executed, you will not want to run it from the beginning for 300 times just to find a +- sign error :)
Matthias Granberry
@mgranberry
Jan 15 2016 03:38
Most of my paid work has been big distributed computation work. IDEs are my friend but I also use vim 20 times/day. I always hate the "vim or ide" question.
Pete Schwamb
@ps2
Jan 15 2016 03:40
Use the tools that work for you. :)
Jim Matheson
@jmatheson
Jan 15 2016 04:04
interesting… https://getocean.io/
Ali Mazaheri
@amazaheri
Jan 15 2016 04:22
ditto @ps2
well said ☺
Howard Look
@HowardLook
Jan 15 2016 06:00
@bewest @scottleibrand I’m seeing very intermittent failures of “openaps use pump model”. About 1 out of 10 times it will return “” instead of “723” but no other obvious errors. Any suggestions of what to look for?
Ben West
@bewest
Jan 15 2016 06:01
hmm, I think at edge of session that can happen
I think default is 3 minutes
does the next one take around 17 seconds and then works?
Howard Look
@HowardLook
Jan 15 2016 06:04
yes, when it works it takes around 17 seconds
what do you mean by “edge of session”? My loop session? Or a session talking to the stick?
default for what is 3 minutes?
(sorry for the probably dumb quesionts…)
Dana Lewis
@danamlewis
Jan 15 2016 06:05
Radio communication I believe. For when pump is awake to talk.
(And no such thing as dumb questions)
Usually means something needs documenting ;)
Howard Look
@HowardLook
Jan 15 2016 06:06
So my loop runs every 5 minutes. Better to make it run every 3 minutes so the pump comms don’t go to sleep?
Dana Lewis
@danamlewis
Jan 15 2016 06:07
Or you could run something like every minute and test to see if it is already looping. Helps for range too in case you walk away/come back.
Howard Look
@HowardLook
Jan 15 2016 06:09
So do you get “” for model if the pump is already awake? Or you get that if something else is already talking to it?
Dana Lewis
@danamlewis
Jan 15 2016 06:10
If not running, we query pump and pull BG, and do enact. Wait for next bg, then do another enact. On average, one of every 5 runs because it's checking output and that process takes 5 min as a result of the Bg timing.
Ben West
@bewest
Jan 15 2016 06:11
normally the pump is asleep
Dana Lewis
@danamlewis
Jan 15 2016 06:11
No, I think it's turning off at the end of the session when you get ""
Ben West
@bewest
Jan 15 2016 06:11
sorry, most of the time, the pump's radio is off
so you can't talk to it
it takes around 17 seconds to wake it up
openaps takes care of noticing when it's probably asleep vs awake and automatically issues the wake up command for you
so normally, if pump is asleep, you start using openaps and it will wake up pump for 3 minutes
at 2 minutes and 50 seconds, I guess it's a little questionable
that's the "edge" of the session
Dana Lewis
@danamlewis
Jan 15 2016 06:13
If we get that error, @HowardLook , preflight fails and we try again, at which point it'll have woken up the pump again
Howard Look
@HowardLook
Jan 15 2016 06:14
Right. In all cases, Preflight is passing, but then reading clock fails because there is no model.
Ben West
@bewest
Jan 15 2016 06:15
hmm, need to double check that session length
old default was 10
you can tweak it in the pump.ini file
Dana Lewis
@danamlewis
Jan 15 2016 06:15
What does your preflight ask for? Model? Or clock? Needs to ask for clock.
Model is too easy
Longer commands require better radio, aka being in good enough range
Howard Look
@HowardLook
Jan 15 2016 06:17
My preflight asks for model: preflight ! bash -c "rm -f model.json && openaps report invoke model.json && test -n $(json -f model.json) && echo \"PREFLIGHT OK\" || ( mm-stick warmup fail \"NO PUMP MODEL RESPONDED\" || mm-stick fail \"NO MEDTRONIC CARELINK STICK AVAILABLE\")"
Dana Lewis
@danamlewis
Jan 15 2016 06:18
Try switching model to clock
Ben West
@bewest
Jan 15 2016 06:18
or do both
report invoke model.json clock.json
Howard Look
@HowardLook
Jan 15 2016 06:19
Great, will try that, thanks! And if that works well will update the last paragraph of https://github.com/openaps/docs/blob/master/docs/Build-manual-system/Using-oref0-tools.md
Dana Lewis
@danamlewis
Jan 15 2016 06:19
Clock does model, though
Cool :)
Howard Look
@HowardLook
Jan 15 2016 06:29
So far so good. Changed my preflight to: preflight ! bash -c "rm -f monitor/clock.json && openaps report invoke monitor/clock.json && test -n $(json -f monitor/clock.json) && echo \"PREFLIGHT OK\" || ( mm-stick warmup fail \"NO PUMP MODEL RESPONDED\" || mm-stick fail \"NO MEDTRONIC CARELINK STICK AVAILABLE\")"
dekecoder
@dekecoder
Jan 15 2016 08:29
Hi, all! I'm looking to build a rig with the eventual goal of closing the loop. I've been reading through the docs on github.com/openaps (and fixing some typos/broken links in a fork - will do a PR back after I'm done). I don't have one of the supported pumps, so I'll have to buy one. Since any of the supported pumps are fair game, any 'best choice' or one that works the best/easiest? Perhaps a list of pros/cons for the various supported pumps?
Ben West
@bewest
Jan 15 2016 09:21
522 or 722 is bes
dekecoder
@dekecoder
Jan 15 2016 10:36
Is that because with the 523/723 you have to ensure the firmware version is <= 2.4A or is there something else? Also, how much bigger is the 722 from the 522? I think the larger one will work better as long as it isn't too much bigger
Rachel Sandlain
@audiefile
Jan 15 2016 14:20
The big difference is reservior size. 2.8 mL in the 522 but 3mL in the 722
Air
Sorry 1.8 not 2.8
Scott Leibrand
@scottleibrand
Jan 15 2016 17:34
@dekecoder correct re: x23. A 523/723 with old firmware is slightly more capable than an x22, but there's more risk and hassle trying to verify the firmware version. Main thing x23 gets you is the ability to listen to MySentry packets with a RileyLink or similar.
Jason Calabrese
@jasoncalabrese
Jan 15 2016 17:37
and smaller bolus increments
Scott Leibrand
@scottleibrand
Jan 15 2016 19:39
@ktomy you want to try to set up tests for openaps/oref0#54, or should we merge it to another branch and have one of us work on those?
Thomas Emge
@ThomasEmge
Jan 15 2016 20:13
Now that I have the overall segments in place I am observing how everything works out (and actually sleeping through the night :sparkles: ) Now on to the next thing for the weekend. I would really like to lose the cable between dexcom and RPI and use the Bluetooth if possible. How do I approach this challenge?
Scott Leibrand
@scottleibrand
Jan 15 2016 20:14
Is it a share receiver?
Thomas Emge
@ThomasEmge
Jan 15 2016 20:14
yes
Scott Leibrand
@scottleibrand
Jan 15 2016 20:15
If so, a Bluetooth adapter should let you use openxshareble
however, I haven't gotten it working yet, so YMMV.
Thomas Emge
@ThomasEmge
Jan 15 2016 20:17
Ben has it working?
Scott Leibrand
@scottleibrand
Jan 15 2016 20:18
Yes, but not sure if @bewest has it working on a Pi or just his Linux laptop.
@TC2013 was also trying it.
Thomas Emge
@ThomasEmge
Jan 15 2016 20:26
Thanks, I'll start reading on the weekend and see where it goes...
Ben West
@bewest
Jan 15 2016 22:08
suggest trying it and see how it goes
lemme know of any issues
you need quite a few repos/libs installed I think, docs are not that great right now
neither are the packages, I guess :-(
Eric
@ecc1
Jan 15 2016 22:16
Were you ever able to use gatttool to connect to the G4 receiver and get either heartbeat notifications or anything else back from it? If so, do you have the commands anywhere?
(The AdaFruit python lib isn't seeing any advertised services from my receiver, so it fails to find the device.)
Alin Artiom Kenibasov
@ktomy
Jan 15 2016 22:18
Good evening/morning
Ben West
@bewest
Jan 15 2016 22:18
btw
I was able to introduce usb support to the new subg_rfspy firmware for the cc1111 ti-dongle
hmmm should test the range somehow
Eric
@ecc1
Jan 15 2016 22:19
Yeah, I'm lurking in rileylink too :-)
Ben West
@bewest
Jan 15 2016 22:20
it's faster than carelink stick
Alin Artiom Kenibasov
@ktomy
Jan 15 2016 22:20
@scottleibrand i was thinking about writing unit tests for my function, but as I am not used with unit testing as it is made in oref0 I didn't managed to do it, but I'll try to write tests as soon as I will finish setting up dev environment (in this evening)
Ben West
@bewest
Jan 15 2016 22:20
carelink takes 14-15 seconds to wake up
$ time openaps use pump model
subg_rfspy status: OK
Version: subg_rfspy 0.3
"522"
real    0m10.710s
user    0m0.448s
sys     0m0.104s
bewest@bewest-MacBookPro:~/Documents/openaps$
definitely better range
oh boy
Jason Calabrese
@jasoncalabrese
Jan 15 2016 22:23
nice
Ben West
@bewest
Jan 15 2016 22:24
it works from couch to bedroom entrance
lots of stuff in the way, tv, walls, oven, microwave
my body
Ali Mazaheri
@amazaheri
Jan 15 2016 22:25
nice!
I just soldered Edison for RL, what I need to try and test TI?
this is with RasPI correct?
Ben West
@bewest
Jan 15 2016 22:26
flash it with the usb image and plug it in to usb
oh
yeah
Ali Mazaheri
@amazaheri
Jan 15 2016 22:32
on ur repo?
I try it today :) and compare with Edison/RL
Ali Mazaheri
@amazaheri
Jan 15 2016 22:35
:+1:
Ben West
@bewest
Jan 15 2016 22:35
or pete's dev branch
Ali Mazaheri
@amazaheri
Jan 15 2016 22:44
CC Debugger will be busy tonight
hehe
Jason Calabrese
@jasoncalabrese
Jan 15 2016 23:17
over in the xdrip room @mgranberry suggested adding sync to the fstab option on the pi to help with coruption
anyone try that, seem like it could work or at least help
Ben West
@bewest
Jan 15 2016 23:18
hmmm should probably go to central computers to get some ble modules for rpi
Ali Mazaheri
@amazaheri
Jan 15 2016 23:20
:fire:
David Wright
@wright-david
Jan 15 2016 23:45
@jasoncalabrese Re SD corruption, actually I think @mgranberry may be suggesting that you should not have sync set. We had serious uSD card corruption issues on an embedded product at work (Gumstix based) that were caused by having sync turned on (async should be default IIRC)
David Wright
@wright-david
Jan 15 2016 23:51
If you want to see how much hammering the SD card is getting, cat /proc/diskstats Also fstab setting relatime is helpful