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

7th
Feb 2018
tepidjuice
@tepidjuice
Feb 07 2018 00:12
@scottleibrand yes I reseated the board. If it's the explorer board that's broken I'll order another but if it's the Edison I should wait for the hat. Anymore testing I could do to work out what happened?
Scott Leibrand
@scottleibrand
Feb 07 2018 00:27
What did you say the LED pattern is?
tepidjuice
@tepidjuice
Feb 07 2018 00:34
Rapidly flashing green led.
Scott Leibrand
@scottleibrand
Feb 07 2018 00:38
And what does the LED do when you ccprog?
tepidjuice
@tepidjuice
Feb 07 2018 00:40
Keeps rapidly flashing.
glenrob1940
@glenrob1940
Feb 07 2018 02:03
Currently using openaps with 2 edison rigs and dexcom G5/iPhone. I also use the G5/iPhone with a riley link when I work in a building without internet access (half days 4 days a week). Is it possible to run openaps offline with xdrip+ and a cheap android phone that would not have a cellular contract?
Dave Acklam
@dcacklam
Feb 07 2018 02:04
So... I now have my pi W rig fully assembled & in it's 3d printed case...
6000mah lipo cell, Geekworm 'Pi UPS' for charging/power-management, and slice-of-radio/SRF...
And an external (usb) bluetooth adapter to try and get around the constant connect/disconnect problems BT has on the Pis...
Seems to be working, but load averages are high & it's clearly CPU bound...
(As for why-so-big, (a) the lipo board is originally designed for a full sized pi, and (B) the battery is actually the largest (length-x-width) component.... I could go with a smaller battery, but the rig would be thicker. I could also shrink it down to the size of one-deck-of-cards if I desoldered the Slice from it's GPIO female header, and soldered it directly to the GPIO pins on-top-of the pi zero W)
I was wondering, if any thought has been given to rewriting the shell scripts to use something more efficient than bash (dash, for example)? Might reduce the CPU load... Would require conversion of the double-bracket logic & some other 'bash-isims' to strait up bourne shell syntax though...
FWIW, the Slice of Radio has given me better range than either of my previous Edison rigs...
peterfulvi
@peterfulvi
Feb 07 2018 03:05

Ok i think i enabled SMB features on my rig this is what my preferences look like

      "max_iob": 12,
        "max_daily_safety_multiplier": 3,
        "current_basal_safety_multiplier": 4,
        "autosens_max": 1.2,
        "autosens_min": 0.7,
        "rewind_resets_autosens": true,
        "adv_target_adjustments": false,
        "exercise_mode": false,
        "wide_bg_target_range": false,
        "sensitivity_raises_target": true,
        "unsuspend_if_no_temp": false,
        "enableSMB_with_COB": true,
        "enableSMB_with_temptarget": true,
        "enableUAM": true,
        "enableSMB_always": true,
        "enableSMB_after_carbs": true,
        "allowSMB_with_high_temptarget": true,
        "maxSMBBasalMinutes": 30,

now this line shows up SMB not enabled for Bolus Wizard carbs
I just want to verify my approach. Im just going to get the suggested carbs form the bolus wizard without using it, and with easy bolus give my self a portion of that amount then SMB will take care of the rest.

Dave Acklam
@dcacklam
Feb 07 2018 03:37

Also: Loop breaking bug... oref0-set-device-clocks attempting to set the 'CGM time' when cgm is xdrip causes the loop to fail:

Setting CGM time to Tue Feb 6 19:33:46 PST 2018
AttributeError: 'NoneType' object has no attribute 'ReadSystemTime'

(Which makes sense, as there is no clock that OpenAPS has access to associated with the xdrip-based setup)
Scott Leibrand
@scottleibrand
Feb 07 2018 04:17
@dcacklam We got power usage down to 166mA with the Go based loop and underclocking. See the #hardware-dev channel for details.
Dave Acklam
@dcacklam
Feb 07 2018 04:18
The issue I am running into here, is CPU utilization & the effects of the loop running slower than-expected screwing up the time-based checks
Scott Leibrand
@scottleibrand
Feb 07 2018 04:18
Yeah we fixed all that. You’re on way old code.
Dave Acklam
@dcacklam
Feb 07 2018 04:18
I'm on oref0-dev & git pull says I'm current
Am I missing something?
Scott Leibrand
@scottleibrand
Feb 07 2018 04:18
Pi isn’t GA yet, so it’s still in dev branches
Not even main dev yet.
We’ve been working with the team doing HAT dev and testing.
Dave Acklam
@dcacklam
Feb 07 2018 04:19
Got it.
Where can I get the pi-friendly code?
er, pi-zero
Scott Leibrand
@scottleibrand
Feb 07 2018 04:20
Depends on whether you’re working on a dev or your main rig.
The in-development stuff replaces the openaps toolkit with @ecc1’s new go libraries, but that isn’t ready for general use yet.
We haven’t tried porting it all back to use with openaps as that’s 3x slower and won’t be supported with the Pi Zero.
We’ll probably be releasing the new Go based oref0, probably as 0.7.0, by the time the HATs come out (probably early April)
But if you have a Pi Zero dev rig you’re more than welcome to hop over to #hardware-dev and help test it out.
But I wouldn’t recommend using it for unattended looping on a human-connected insulin pump yet.
Dave Acklam
@dcacklam
Feb 07 2018 04:25

All of the work I've been doing (from the x12 stuff to present) has been on my primary.

The dev- branch code you guys had back in December actually worked pretty well on the zero-W, but I fried that one trying to solder it to the power-board...

At this point I think I got most of the time-based race-conditions (eg, 'something checks to see if 2 times are correct, but enough time passes before the check is done, that it fails) ironed out in 0.60-dev, such that it is looping properly (if flogging the crap out of the CPU)...

I guess I'll wait and see what you release in terms of go-based code..
Scott Leibrand
@scottleibrand
Feb 07 2018 04:26
You might want to just go through our commits and see which ones you want to cherry-pick.
Dave Acklam
@dcacklam
Feb 07 2018 04:26
Hopefully it will work with more than just the hat (eg, my SRF based gear)...
Scott Leibrand
@scottleibrand
Feb 07 2018 04:26
This is the go-explorer-hat branch.
Dave Acklam
@dcacklam
Feb 07 2018 04:27
Ok...
Scott Leibrand
@scottleibrand
Feb 07 2018 04:27
Happy to merge a PR to dev with stuff you’ve tested without Go.
Dave Acklam
@dcacklam
Feb 07 2018 04:28
I'll let you know if anything else comes up. I have one filed right now for a section that says it is waiting 90 seconds to test something, but the code actually is checking for 55.
Scott Leibrand
@scottleibrand
Feb 07 2018 04:28
It should work with that, but will probably need some oref0-setup tweaks, and possibly some tweaks to the Go code’s GPIO settings etc.
Dave Acklam
@dcacklam
Feb 07 2018 04:28
The rest of my changes have been stuff like calling '$(date %s)' once, and storing the result in a variable, rather than calling '$(date %s)' multiple times in a given test...
Does the go code interact with the radio via serial port?
Or directly via GPIO?
Scott Leibrand
@scottleibrand
Feb 07 2018 04:29
I can’t recall. Hop over to hardware-dev for that one.
It might be SPI
Over GPIO pins.
Dave Acklam
@dcacklam
Feb 07 2018 04:30
Thanks...
Scott Leibrand
@scottleibrand
Feb 07 2018 04:30
For the 55s thing, I think I allow it to loop up to 90s off, but set the clock above 55s.
Pretty sure that code changed a bit recently: check the commits.
Dave Acklam
@dcacklam
Feb 07 2018 04:31
Will do.
In any case, between the trying-to-set-the-CGM-clock on xdrip, and the date-call optimization, I'm back up and running...
Do have a few bits and pieces to clean up, may do a PR this weekend.

The next 'evolution' of what I am doing, will be to take that SRF board off it's header & solder it directly to the GPIO pins of the power-board (right above where I soldered the pi zero itself)...

And to decide whether I really need 6000mah of battery (for the Pi3 I absolutely did - it didn't even finish a full day, even with that pack)

Well, anyway... goodnight
Paul Delano
@spike1197
Feb 07 2018 05:28
At this point we have several rigs of various types. 2 rasp pi and 3 (the ones not crunched by 9yr old lifestyle) edison devices. Any recommendations for keeping them all on the same level? I should probably just run oref0-setup if they have been offline for a while.
Sacha M
@coolestkidsever
Feb 07 2018 05:50
Hi all, I'm still struggling to get BT to connect when there's no wifi.. is anyone able to help me troubleshoot please? I've been through all the docs that i can find..
also is there any reason why network log doesn't seem to come up in papertrail anymore?
peterfulvi
@peterfulvi
Feb 07 2018 14:25
With SMB features do i have to make a carb announcement or can i just figure the carbs in bolus wizard and easy bolus a portion of the bolus and expect SMB to manage the rest? Im running an offline setup with Lookout.
Scott Leibrand
@scottleibrand
Feb 07 2018 14:56
Entering carbs into the Bolus Wizard with a small bolus is one way to do a bolus announcement, but it will disable SMB unless you have the a52 risk preference on.
Eric
@ecc1
Feb 07 2018 15:19
@dcacklam the Go packages currently support only SPI-connected radios (Explorer board, Explorer hat, or TI stick/srf or rfm69 connected via SPI). Serial or USB connection could fit in as"just another driver" but it's not on my to-do list
Luis Betancourt
@betluis
Feb 07 2018 16:43
Hello, I have been wondering why when a BG check entered to the pump does not change the trend in the BG that the pump and Openaps use and continue as if the BG check had not been there at all.. check the picture below
image.png
would anybody help me understanding this?
in this case, the current BG is 148, but you can see the red dot indicating the BG check (in the finger) was 87
peterfulvi
@peterfulvi
Feb 07 2018 17:44
@scottleibrand what if I used the bolus wizard to just figure the amount to I need for that meal the cancel and use the easy bolus button to deliver a portion of that dose. Microbolusing has been working since lunch . Also is there a way to manually enter carb amounts directly in your rig just like temp targets?
Scott Leibrand
@scottleibrand
Feb 07 2018 17:45
if you're using SMB you don't need to be very precise about your bolus, so you might be able to do it with rough mental math. you can enter carbs via IFTTT or using the meal marker journal thing on at least some pumps
Dana Lewis
@danamlewis
Feb 07 2018 18:46
@betluis OpenAPS only uses the CGM data. It does not use fingerstick BGs in any way. If you think your bg is off, you should use the fingerstick to calibrate your CGM.
Luis Betancourt
@betluis
Feb 07 2018 19:25
Dana, yes. thanks. I understand that... my question is more regarding the delay that the pump has to adjust the BG level to the calibration point. It seems as if sometimes the calibration did not actually do anything
despite the gap between both readings
Dana Lewis
@danamlewis
Feb 07 2018 19:31
@betluis did you enter it as a fingerstick? or an actual calibration to your CGM?
peterfulvi
@peterfulvi
Feb 07 2018 19:41
thanks
Tim Street
@tim2000s
Feb 07 2018 19:56
@betluis - the Medtronic CGM adjusts much more slowly than dexcom or xDrip
Luis Betancourt
@betluis
Feb 07 2018 20:12
Thanks @tim2000s @danamlewis , I am not sure about that, I will check.. I thought bought were the same thing, are they not?
Tim Street
@tim2000s
Feb 07 2018 20:17
No. My experience with Medtronic sensors is that they slowly migrate to the calibration where dexcom is much more likely to allow a step change.
Luis Betancourt
@betluis
Feb 07 2018 22:16
thanks
phoenixflame611
@phoenixflame611
Feb 07 2018 23:01
Has anyone ever not been able to SSH into their rig? It has an IP, loops fine, but SSH does not work.