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

10th
Feb 2017
Eric
@ecc1
Feb 10 2017 00:09
My rig usually does pretty well in "camping mode", only backfilling to Nightscout when it has connectivity but otherwise not requiring it. But one weak point is at startup: if it boots without internet access, then NTP sets a random time (in November 2016, which I don't understand yet), and that screws up my sanity checks on time difference w.r.t the pump and cgm. What do other campers do to avoid that?
Scott Leibrand
@scottleibrand
Feb 10 2017 00:11
there are some tools in oref0 that will set the rig time from the pump/cgm time
it should actually already be running via your enact alias if it throws a time error
Eric
@ecc1
Feb 10 2017 00:14
I don't run openaps, so I was really asking about overall approach. I've thought about a 3-way vote among Edison, pump, and cgm, averaging whichever 2 are close to one another and setting the 3rd to that.
Scott Leibrand
@scottleibrand
Feb 10 2017 00:15
nah, doesn't have to be that complicated. take a look at oref0-set-system-clock
tazitoo
@tazitoo
Feb 10 2017 00:15
at boot, I set the edison time to the pump time
you can visually check that CGM and pump are close enough to not cause issues
Eric
@ecc1
Feb 10 2017 00:25
Ah, thanks. ntp-wait is what I was looking for
Kate Farnsworth
@ELUTE
Feb 10 2017 00:28
BT version is 5.28
Scott Leibrand
@scottleibrand
Feb 10 2017 00:30
that won't work. you'll probably need to re-flash and let oref0-setup compile and install Bluetooth for you.
Kate Farnsworth
@ELUTE
Feb 10 2017 00:33
What would cause it to not be installed and compiled correctly in the first place?
Scott Leibrand
@scottleibrand
Feb 10 2017 00:35
following the old directions probably
katie disimone
@Kdisimone
Feb 10 2017 00:36
She was following new directions....
Scott Leibrand
@scottleibrand
Feb 10 2017 00:36
hmm. maybe don't need to re-flash then
perhaps you just need to re-run oref0-setup with the btmac stuff to install 5.37?
katie disimone
@Kdisimone
Feb 10 2017 00:36
If she deleted 5.28 from /src wouldn't rerun
Fix it?
Scott Leibrand
@scottleibrand
Feb 10 2017 00:37
not sure I follow
Kate Farnsworth
@ELUTE
Feb 10 2017 00:37
I have rerun the setup with the bit Mac stuff already
Btmac
Scott Leibrand
@scottleibrand
Feb 10 2017 00:38
hmm.. let me check what it's doing and have you try some things manually then
Kate Farnsworth
@ELUTE
Feb 10 2017 00:41
Would love to know how this happened so I can prevent others from having the same problem
Scott Leibrand
@scottleibrand
Feb 10 2017 00:43
try if ! bluetoothd --version | grep -q 5.37 2>/dev/null; then echo We need to install BlueZ; done
I assume that will tell you that We need to install BlueZ
if so, then maybe ls ~/src/bluez-5.37/ to see if it already downloaded the source code last time you ran oref0-setup
Sacha M
@coolestkidsever
Feb 10 2017 00:47
@scottleibrand re > @coolestkidsever normally oref0-reset-git fixes that, but if not you may need to figure out what git commands fail so we can have it check those too.
it was 4am, so I may not have entirely run it correclty, but pretty sure i did, and tried again this morning, and it didn't seem to fix it
Scott Leibrand
@scottleibrand
Feb 10 2017 00:47
ok, can you paste the output?
Sacha M
@coolestkidsever
Feb 10 2017 00:48
can i get back into the log file for that specific time to copy? (not sure how)
Scott Leibrand
@scottleibrand
Feb 10 2017 00:48
easier to just re-run it
cd ~/myopenaps and then oref0-reset-git
Sacha M
@coolestkidsever
Feb 10 2017 00:49
File "/usr/local/lib/python2.7/dist-packages/openaps/cli/subcommand.py", line 52, in call
return self.method.main(args, app)
File "/usr/local/lib/python2.7/dist-packages/openaps/reports/invoke.py", line 37, in main
repo = app.git_repo( )
File "/usr/local/lib/python2.7/dist-packages/openaps/cli/init.py", line 78, in git_repo
self.repo = getattr(self, 'repo', Repo(os.getcwd( ), odbt=GitCmdObjectDB))
File "/usr/local/lib/python2.7/dist-packages/git/repo/base.py", line 156, in init
raise InvalidGitRepositoryError(epath)
git.exc.InvalidGitRepositoryError: /home/pi/myopenaps
Error, retrying
Scott Leibrand
@scottleibrand
Feb 10 2017 00:49
that's from your pump-log?
Sacha M
@coolestkidsever
Feb 10 2017 00:49
sorry wrong paste
yeah that was from log, actually thats what i was getting at 4am from memory
currently not connected to anything so unsure if it wil lgive me the right info
Attempting to fix git corruption. Please wait 15s.
Git repo does not appear to be corrupt.
/usr/local/bin/oref0-reset-git: line 52: 13439 Terminated ( sleep 15; killall oref0-fix-git-corruption )
so it must have fixed it, or it's becuase I'm not connected
Scott Leibrand
@scottleibrand
Feb 10 2017 00:50
no, that's just its way of saying it didn't find the problem
Sacha M
@coolestkidsever
Feb 10 2017 00:51
ok, will try again tonight once son is home and we're connected again
Scott Leibrand
@scottleibrand
Feb 10 2017 00:51
it doesn't matter if the pump is around
can you run npm list -g oref0 to see which oref0 version you have?
Sacha M
@coolestkidsever
Feb 10 2017 00:52
0.3.3
Scott Leibrand
@scottleibrand
Feb 10 2017 00:52
ok, let's get you upgraded and see if the new one fixes it better
use the Recommended method of step 1 only for now
Kate Farnsworth
@ELUTE
Feb 10 2017 00:53
@scottleibrand doesn't like the done was that supposed to be included?
Scott Leibrand
@scottleibrand
Feb 10 2017 00:53
you're right
it's supposed to be a fi instead
if ! bluetoothd --version | grep -q 5.37 2>/dev/null; then echo We need to install BlueZ; fi
Kate Farnsworth
@ELUTE
Feb 10 2017 00:55
we need to install bluez
Scott Leibrand
@scottleibrand
Feb 10 2017 00:55
k. so now ls ~/src/bluez-5.37/
Kate Farnsworth
@ELUTE
Feb 10 2017 00:56
ls: cannot access /root/src/bluez-5.37/: No such file or directory
Scott Leibrand
@scottleibrand
Feb 10 2017 00:56
so you never actually managed to get oref0-setup to run that part of the script for some reason
Kate Farnsworth
@ELUTE
Feb 10 2017 00:57
very weird that only that part seems to not have installed
Scott Leibrand
@scottleibrand
Feb 10 2017 00:59
can you paste me your cat ~/myopenaps/oref0-runagain.sh with your api-secret, URL, and pump serial number removed or redacted?
Sacha M
@coolestkidsever
Feb 10 2017 01:02
Have updated, now on 0.4.1
Scott Leibrand
@scottleibrand
Feb 10 2017 01:03
ok, now try oref0-reset-git again from your ~/myopenaps directory and see if it does anything different
Sacha M
@coolestkidsever
Feb 10 2017 01:04
does not appear to be corrupt
:-)
Attempting to fix git corruption. Please wait 15s.
Git repo does not appear to be corrupt.
/usr/local/bin/oref0-reset-git: line 52: 17958 Terminated ( sleep 15; killall oref0-fix-git-corruption )
Scott Leibrand
@scottleibrand
Feb 10 2017 01:05
k
next step will be to try some manual git commands and see if we can reproduce the problem
git status, git diff, and git symbolic-ref HEAD are the three that oref0-reset-git tries
Kate Farnsworth
@ELUTE
Feb 10 2017 01:06
Screen Shot 2017-02-09 at 8.02.30 PM.jpg
Sacha M
@coolestkidsever
Feb 10 2017 01:06
what sort of output are we looking for? just that it works?
Scott Leibrand
@scottleibrand
Feb 10 2017 01:06
trying to find a command that gives you an error similar to what is in pump-loop.log
if it works without error, don't bother pasting it
@ELUTE ok, so that does not contain the --btmac= flag. next step would be to edit that file to add it (or copy and paste it and add it there) to re-run oref0-setup with --btmac=yourmacaddress
Sacha M
@coolestkidsever
Feb 10 2017 01:08
looking at the first one, git status, it's showing files from one directory that I'm not using (i've done multiple setups with diff directorys) i wonder if thats causing the problem
@coolestkidsever possible, hard to tell. you can delete any unused stuff by doing rm -rf thedirectoryname
Kate Farnsworth
@ELUTE
Feb 10 2017 01:09
So I did run it with the btmac previously
Scott Leibrand
@scottleibrand
Feb 10 2017 01:10
yeah, wondering if the syntax was incorrect or something
Dana Lewis
@danamlewis
Feb 10 2017 01:10
have you updated oref0 since 2/7?
Scott Leibrand
@scottleibrand
Feb 10 2017 01:10
maybe it's in your history?
Kate Farnsworth
@ELUTE
Feb 10 2017 01:10
This cd && ~/src/oref0/bin/oref0-setup.sh —btmac=54:EA:A8:E3:52:20
Scott Leibrand
@scottleibrand
Feb 10 2017 01:10
ah yeah, npm list -g oref0 to check version
@ELUTE that looks like a long dash rather than two short ones
Kate Farnsworth
@ELUTE
Feb 10 2017 01:11
freaking autocorrect
Scott Leibrand
@scottleibrand
Feb 10 2017 01:11
if you want to check what you did before, you can try history | grep btmac
as long as it's not autocorrecting what goes into the rig. :)
Kate Farnsworth
@ELUTE
Feb 10 2017 01:11
163 cd && ~/src/oref0/bin/oref0-setup.sh --btmac=AA:BB:CC:DD:EE:FF
164 cd && ~/src/oref0/bin/oref0-setup.sh —btmac=54:EA:A8:E3:52:20
184 cd && ~/src/oref0/bin/oref0-setup.sh —btmac=54:EA:A8:E3:52:20
249 cd && ~/src/oref0/bin/oref0-setup.sh —btmac=54:EA:A8:E3:52:20
263 cd && ~/src/oref0/bin/oref0-setup.sh —btmac=54:EA:A8:E3:52:20
Scott Leibrand
@scottleibrand
Feb 10 2017 01:12
so only the first one had the two dashes, and all the ones with the right MAC had a long dash
Kate Farnsworth
@ELUTE
Feb 10 2017 01:12
yeah will fix
turning autocorrect off
Scott Leibrand
@scottleibrand
Feb 10 2017 01:12
if you add --btmac=54:EA:A8:E3:52:20 to the runagain line, you can skip the interview this time
or re-answer the questions, whatever's easiest
Kate Farnsworth
@ELUTE
Feb 10 2017 01:13
ok ty
Scott Leibrand
@scottleibrand
Feb 10 2017 01:13
so how are you interacting with your rig that autocorrect got involved?
Kate Farnsworth
@ELUTE
Feb 10 2017 01:13
I copied and pasted the line into my mac and edited the BT
Scott Leibrand
@scottleibrand
Feb 10 2017 01:14
k
might want to add a note to the docs to be careful about that, if you think anyone else might do it
@coolestkidsever if removing unneeded directories doesn't fix it, I'd like to drill down to find out what the problem is, so we can update oref0-reset-git to check for it. but if you need to get your rig back up and working and don't have time to troubleshoot further, you can fix it manually too
Sacha M
@coolestkidsever
Feb 10 2017 01:17
when removing the dir, should it show anything (can I list directories?)
wanting to check that i removed them correctly
as when I run git status, they still seem to be showing up under new file
Scott Leibrand
@scottleibrand
Feb 10 2017 01:17
just ls will show everything, files and directories both
Kate Farnsworth
@ELUTE
Feb 10 2017 01:18
ty for that @scottleibrand
Scott Leibrand
@scottleibrand
Feb 10 2017 01:18
yw
Sacha M
@coolestkidsever
Feb 10 2017 01:18
ok definitely gone, but still showing in "new files"
when running gitstatus
oh could they still be in cron
Scott Leibrand
@scottleibrand
Feb 10 2017 01:19
unless it starts with a .
then you need ls -a to see all hidden files too
I usually use ls -la to get more details
Sacha M
@coolestkidsever
Feb 10 2017 01:20
ok, only dir that i've made is the myopenaps one
rest are gone
Scott Leibrand
@scottleibrand
Feb 10 2017 01:20
wait, what directory are you running all this in?
Sacha M
@coolestkidsever
Feb 10 2017 01:20
(apart from system ones obvioulsy)
oh.. I relogged in and forgot to change!
doh!
from root
oh, no thats correct aye, as they're all under root
Scott Leibrand
@scottleibrand
Feb 10 2017 01:22
that's fine, question is whether you're in ~ or ~/myopenaps
Sacha M
@coolestkidsever
Feb 10 2017 01:22
was running in ~
Scott Leibrand
@scottleibrand
Feb 10 2017 01:22
if you run git status in ~ and it doesn't complain that it's not a repo, then you have another problem
because your repo should be rooted in ~/myopenaps, not ~
if so, do rm -rf ~/.git to remove the extra git repo in ~
Sacha M
@coolestkidsever
Feb 10 2017 01:26
ah so running 'git status' in ~ and in ~/myopenaps outputs the exact same thing
Scott Leibrand
@scottleibrand
Feb 10 2017 01:26
that means your repo is in the wrong place. try the rm command
and then go back to ~/myopenaps and re-run oref0-reset-git
Sacha M
@coolestkidsever
Feb 10 2017 01:28
pi@raspberrypi:~/myopenaps $ cd
pi@raspberrypi:~ $ rm -rf ~/.git
pi@raspberrypi:~ $ cd myopenaps
pi@raspberrypi:~/myopenaps $ oref0-reset-git
Attempting to fix git corruption. Please wait 15s.
Git repo does not appear to be corrupt.
/usr/local/bin/oref0-reset-git: line 52: 25540 Terminated ( sleep 15; killall oref0-fix-git-corruption )
pi@raspberrypi:~/myopenaps $
ah, and now pump log hasn't got the same error
so somehow i managed to get setups set up in the wrong place? but now they're gone... and the reset seems to have fixed? Does that sound like what happened? (just tyring to make sure i understand it all)
Scott Leibrand
@scottleibrand
Feb 10 2017 01:31
I don't think oref0-reset-git did anything: i think just removing the corrupted repository in ~ allowed it to use the non-corrupted one in ~/myopenaps - not sure though
I don't fully understand how git works when you have nested repositories. I just know it breaks things
Sacha M
@coolestkidsever
Feb 10 2017 01:32
ah ok, all good. thanks so much for your assistance!
Scott Leibrand
@scottleibrand
Feb 10 2017 01:35
yw
Paul Tinson
@ptinson
Feb 10 2017 01:38
@scottleibrand i just put the PR in for that oref0-online change
let me know if you want anything changed
i also changed how you get local ip for wlan and bnep interfaces
Dana Lewis
@danamlewis
Feb 10 2017 01:40
:+1:
Kate Farnsworth
@ELUTE
Feb 10 2017 02:13
Do I have to wait out the BT scan on?
katie disimone
@Kdisimone
Feb 10 2017 02:15
No
It keeps running. But you can keep going
Kate Farnsworth
@ELUTE
Feb 10 2017 02:16
ok ty
kws1969
@kws1969
Feb 10 2017 02:57
@scottleibrand I managed to get another edison flashed and while installing open on the new one i get this
openaps installed
openaps 0.1.5
root@edisonhost:~# Macintosh HD:Users:iMac4K:Downloads:Quick-Packages.png
-bash: Macintosh: command not found
what does the last line mean??
Scott Leibrand
@scottleibrand
Feb 10 2017 02:59
you pasted in something you shouldn't have
just ignore it and proceed
kws1969
@kws1969
Feb 10 2017 03:00
ok
kws1969
@kws1969
Feb 10 2017 03:17
CCLD tools/l2ping
CC tools/sdptool.o
CC src/sdp-xml.o
CCLD tools/sdptool
CC tools/ciptool.o
CCLD tools/ciptool
CC tools/bccmd.o
CC tools/csr_hci.o
CC tools/csr_usb.o
CC tools/csr_h4.o
CC tools/csr_3wire.o
CC tools/csr_bcsp.o
CC tools/ubcsp.o
CCLD tools/bccmd
CC tools/bluemoon.o
CCLD tools/bluemoon
CC tools/hex2hcd.o
CCLD tools/hex2hcd
CC tools/mpris-proxy.o
CCLD tools/mpris-proxy
CC tools/btattach.o
CCLD tools/btattach
CC profiles/cups/main.o
it this normal…..its been doing this for awhile
Dana Lewis
@danamlewis
Feb 10 2017 03:17
What command are you trying to run?
kws1969
@kws1969
Feb 10 2017 03:19
this is after i rancd && ~/src/oref0/bin/oref0-setup.sh
Dana Lewis
@danamlewis
Feb 10 2017 03:20
You should be copying and pasting, not trying to type any of the grey box commands.
Carl-c to quit whatever is going, and make sure to copy and paste the setup script line into the terminal
kws1969
@kws1969
Feb 10 2017 03:21
k
acerrone
@acerrone
Feb 10 2017 03:23
I currently have one rig running in my sons bedroom and i'm setting up a second one for mobile/school. I seem to have an issue with mmtune taking forever sometimes in his bedroom to reconnect when he cruises in. He is using a WW pump also. My question is, can I run something to determine which freq connects the best to his pump "i believe its 868.414" and set the rig up to only work on that frequency?
Dana Lewis
@danamlewis
Feb 10 2017 03:24
@acerrone one or two people have talked about that, but frequency changes depending on temp and location and a lot of things so not ideal..
What rig is in the bedroom? When was it last updated?
I believe in latest release there were some Mmtune speed up improvements that may help..
Scott Leibrand
@scottleibrand
Feb 10 2017 03:28
@kws1969 that was normal yes.
It was compiling stuff.
Sacha M
@coolestkidsever
Feb 10 2017 04:15
sorry if this is a silly question, but ive moved NS from Azure to Heroku today, is there anything i need to change in the OpenAPS setup? (going over the docs again, but don't want to miss anything)
Scott Leibrand
@scottleibrand
Feb 10 2017 04:16
you'll need to re-run oref0-setup with the new NS URL, and say yes to removing your old cron and re-creating it
Sacha M
@coolestkidsever
Feb 10 2017 04:17
ok cool
can i use ash ~/myopenaps/oref0-runagain.sh or from scratch?
katie disimone
@Kdisimone
Feb 10 2017 04:18
Can't use that. Need to edit what's in the rerun script because it is currently populated with the old site URL
You can edit the file though.
And then use that
acerrone
@acerrone
Feb 10 2017 04:21
ok thanks Dana. My old setup is working, but the new one isn't. I'll run it again to try.
Dana Lewis
@danamlewis
Feb 10 2017 04:22
Might be something else going on then that needs checking
katie disimone
@Kdisimone
Feb 10 2017 05:07
Can we just have a woot woot for @kws1969 who just got his loop going?!? :clap: :clap:
acerrone
@acerrone
Feb 10 2017 05:17

Re-ran setup on new rig and got it going now. Getting the loop complete but Nightscout not updated. This is my log. Pumphistory-24 less than 20m old
Completed pump-loop at Thu Feb 9 21:13:55 PST 2017

Starting pump-loop at Thu Feb 9 21:14:03 PST 2017:
Radio ok, Listening: .No pump comms detected from other rigs
Profile less than 60m old
glucose.json newer than temp_basal.json
Temp refreshError, retrying
Starting pump-loop at Thu Feb 9 21:14:53 PST 2017:
Radio ok, Listening: .No pump comms detected from other rigs
Profile less than 60m old
glucose.json newer than temp_basal.json
Temp refreshed
Could not parse input data: [SyntaxError: /root/myopenaps/monitor/iob.json: Unexpected end of input]
determine-basal://text/shell/enact/suggested.json
reporting enact/suggested.json
{"bg":210,"temp":"absolute","snoozeBG":206,"recieved":true,"predBGs":{"IOB":[210,208,206,205,204,203,202,202,201,201,201,201,201]},"rate":2,"reason":"COB: undefined, Dev: 1, BGI: -1.55, ISF: 45, Target: 120; Eventual BG 206 >= 125, adj. req. rate: 3.35 to maxSafeBasal: 2, no temp, setting 2U/hr","eventualBG":206,"timestamp":"2017-02-06T17:23:58.317650","duration":30,"tick":-2,"IOB":0.116}
glucose.json newer than pumphistory: Refreshed pumphistory

Dana Lewis
@danamlewis
Feb 10 2017 05:25
@Kdisimone @kws1969 :confetti_ball:
Scott Leibrand
@scottleibrand
Feb 10 2017 05:48
@acerrone openaps report invoke monitor/iob.json- you want to run the report for the file it's complaining about being empty (Unexpected end of input)
jmcrawford
@jmcrawford
Feb 10 2017 05:48
Had an explorer board almost start on fire tonight. The battery was low so we plugged it in, started to smell something bad, quickly found smoke coming out of the ports in the case. Unplugged it and took it outside. There is a scorch mark on the board, I plugged it back in to see which USB port was the problem (both). One of the components started to glow before I could unplug it. Oddly, it was still working the whole time. Just can't charge the battery on it any more.
Scott Leibrand
@scottleibrand
Feb 10 2017 05:49
@jmcrawford uh oh! so the problem was the Explorer board itself, not the battery?
do you know which component was overheating / burnt? or can you tell what area it was?
Darrell Wright
@beached
Feb 10 2017 05:50
I wonder if the charger was actually putting out 5v
sometimes those get messed too
jmcrawford
@jmcrawford
Feb 10 2017 05:50
Battery seems fine. I'll take a picture of the board, not sure if it'll show up very well. There is a big dark patch between the JST and OTG ports
It was plugged into an Anker USB charging station
Scott Leibrand
@scottleibrand
Feb 10 2017 05:51
please contact ERD right away and give them all the details. they'll need to see if this is something that was due to a board defect or not, and/or if there's anything that needs done to the board (beyond what he has already done in this new batch) to help protect the Explorer from over-current
that sounds like the area that normally gets a little bit hot as it charges the battery, and where he just reduced max current from 500mA to 250mA to reduce overheating. not sure if that would help against whatever happened here
you might want to take that anker out of service for forensics. maybe leave the cables plugged into the same ports they were when it was plugged in and overheating
acerrone
@acerrone
Feb 10 2017 06:00
@scottleibrand so I run that command in the myopenaps directory? openaps report invoke monitor/iob.json
acerrone
@acerrone
Feb 10 2017 06:06

root@jacobcgm:~/myopenaps# openaps report invoke monitor/iob.json
iob://text/shell/monitor/iob.json

module.js:340
throw err;
^
Error: Cannot find module 'moment-timezone'
at Function.Module._resolveFilename (module.js:338:15)
at Function.Module._load (module.js:280:25)
at Module.require (module.js:364:17)
at require (module.js:380:17)
at Object.<anonymous> (/root/src/oref0/lib/iob/index.js:2:10)
at Module._compile (module.js:456:26)
at Object.Module._extensions..js (module.js:474:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:312:12)
at Module.require (module.js:364:17)
reporting monitor/iob.json
root@jacobcgm:~/myopenaps#

Scott Leibrand
@scottleibrand
Feb 10 2017 06:10
hmm, are you on oref0 dev?
cd ~/src/oref0 && git branch
acerrone
@acerrone
Feb 10 2017 06:11
cd && ~/src/oref0/bin/oref0-setup.sh --btmac=AA:BB:CC:DD:EE:FF
I also have a WW pump
jmcrawford
@jmcrawford
Feb 10 2017 06:12
IMG_0930.JPG
Scott Leibrand
@scottleibrand
Feb 10 2017 06:13
@acerrone right, but run that git branch command to see which branch of oref0 you're on
acerrone
@acerrone
Feb 10 2017 06:14
root@jacobcgm:~/myopenaps# cd ~/src/oref0 && git branch
I think my other rig "main original" might be on master?
looks like you managed to get half upgraded to the dev version. you might want to switch back to master at this point, but if not you'll need to fully install dev
git checkout master might be all it takes to do that
acerrone
@acerrone
Feb 10 2017 06:18
ok thanks!
Tim Street
@tim2000s
Feb 10 2017 09:13
Running a new dev rig. Anyone recall where this error shows Temp refreshed
Could not parse input data: [TypeError: Cannot read property 'date' of undefined]
determine-basal://text/shell/enact/suggested.json
Matthias
@ceben80
Feb 10 2017 09:19
Damn didn't see that...
Tim Street
@tim2000s
Feb 10 2017 10:12
Fixed it. Forgot to update the cron. Really should PR that into the xDrip branch.
Matthias
@ceben80
Feb 10 2017 10:18
great Tim :+1:
Chris Oattes
@cjo20
Feb 10 2017 11:43
@jmcrawford what sort of case was it in? Was there any ventilation?
Matthias
@ceben80
Feb 10 2017 12:36
@scottleibrand new location for myopenapsdirectory is now /root/src/myopenaps - that's new under ~/srcor it's a bug in oref0-setup.sh :question:
fezulin
@fezulin
Feb 10 2017 12:47
@jmcrawford OMG - what happened to your Explorer Board?
Was it in a too small case (or box) and became to hot?
Tim Street
@tim2000s
Feb 10 2017 13:28
@ceben80 are you sure you weren't accidentally in src when you ran setup?
😉
Matthias
@ceben80
Feb 10 2017 13:31
New flash....didn't exist before
But maybe made a cd after installing oref0 dev before running the setup, seems so, but anyway easy to rm -rf and re-run
Tim Street
@tim2000s
Feb 10 2017 13:36
Yup
Matthias
@ceben80
Feb 10 2017 13:36
yes a cd to `/root was missing before
just make it new, quite easy @scottleibrand ignore my q above :wink:
stupid mistake :smile:
Thanks Tim for pointing me....
Tim Street
@tim2000s
Feb 10 2017 13:52
Been there myself 😉
Matthias
@ceben80
Feb 10 2017 14:06
:smile:
Matthias
@ceben80
Feb 10 2017 14:57

@scottleibrand is jqincluded in the standard OpenAPS setup or does it come with autotune?

I have a solution for EdisonVoltage parsing using jq

root@eddie-eb:~/myopenaps/monitor# cat edison-battery.json
{"batteryVoltage":3928, "battery":75}

root@eddie-eb:~/myopenaps/monitor# cat edison-battery.json | jq '."batteryVoltage"'
3928
Scott Leibrand
@scottleibrand
Feb 10 2017 15:03
jq is installed with lots of advanced features. Just need to add yours to the check.
Or we could just install it by default.
Matthias
@ceben80
Feb 10 2017 15:05
@scottleibrand that would be great, by default...I'll investigate for the "new" cron line regarding the PR, will comment once I have the complete line :wink:
gawkmight be another parsing option, but it's not installed, I think the best way is to use this jqparser
Scott Leibrand
@scottleibrand
Feb 10 2017 15:07
Yes, jq is much cleaner.
Matthias
@ceben80
Feb 10 2017 15:07
:+1:
kws1969
@kws1969
Feb 10 2017 15:59
Quick newbie question? On Edison explorer which port do I use to charge battery? Or is it better to unhook battery to charge ?
kws1969
@kws1969
Feb 10 2017 16:04
In other words is he Edison explorer like the Riley does it have a built in charger?
After having the Edison hooked to both cables all day on my laptop while flashing and setup my explorer didn't make it but 5 hours on a 1000 battery. Could this be because it's learning ?
Matthias
@ceben80
Feb 10 2017 16:13
@kws1969 you can use both of them, doesn't matter which port for charging
kws1969
@kws1969
Feb 10 2017 16:21
Awesome
jmcrawford
@jmcrawford
Feb 10 2017 16:21
@cjo20 @fezulin It was in one of these: http://www.thingiverse.com/thing:2020161
I don't think it was a ventilation issue, some kind of problem on the board. The battery was quite low - would it draw more power in that state? I know there is current limiting in the Lipo charging circuit, but I can't think of anything else.
kws1969
@kws1969
Feb 10 2017 16:23
When it's fully charged will the light go off like my Riley ?
jmcrawford
@jmcrawford
Feb 10 2017 16:25
It's been in that case for a couple of months with no issue. Not all flopping around where something could cause a short
Matthias
@ceben80
Feb 10 2017 16:25
but only when the rig is powerd down, you will see the light go off once the lipo is full
kws1969
@kws1969
Feb 10 2017 16:26
Oh ok.
Chris Oattes
@cjo20
Feb 10 2017 16:36
@jmcrawford It depends on what the voltage was. The chip should limit itself based on temperature.
kws1969
@kws1969
Feb 10 2017 16:44
Will it hurt or harm the explorer board to use it for charging?
Will the heat decay the board over time ?
Chris Oattes
@cjo20
Feb 10 2017 16:50
It should be ok, although jmcrawford seems to have been unlucky
kws1969
@kws1969
Feb 10 2017 16:53
I guess I'm being a worry wort but it takes so long to get a replacement I just wondered how y'all handled charging. Mine got pretty hot during flashing but today it seems pretty cool to touch
katie disimone
@Kdisimone
Feb 10 2017 16:56
@jmcrawford we've had two times where our Edison appears to have shut down based on temperature during charging overnight. Both times the battery was pretty low when we went to charge it. I wonder if it was the explorer board getting so hot that the Edison took the heat and shut down?
John Benjamin
@Bender1061
Feb 10 2017 16:56
@scottleibrand I think we should install jq by default, it's such a useful tool
Chris Oattes
@cjo20
Feb 10 2017 17:00
@kws1969 Yes, it will get hot. The chip itself should be ok up to 150C or so. It can get too hot to touch and still be ok.
kws1969
@kws1969
Feb 10 2017 17:01
Ok I'll quit worrying. Lol. Thank you so much.
Chris Oattes
@cjo20
Feb 10 2017 17:03
The highest charging current is early on in the charging cycle, so it generates most heat when the battery is low. The chip also slows down charging if it gets too hot. It's possible that when the battery is very low, it gets hot enough that the charging circuit virtually shuts down, which means the battery never gets charged enough.
Matthias
@ceben80
Feb 10 2017 17:10
@cjo20 correct me Chris, the max charging current is 250 mA for the EB, I find the charging current too weak, what do you think?
Scott Leibrand
@scottleibrand
Feb 10 2017 17:14
Max on all existing boards is 500mA, unless temp-limited. New boards will be 250mA, which will charge a dead 2000mAh battery in 8h.
@cjo20 if current were that low it wouldn't heat up much, so I doubt that's the issue.
@Kdisimone I suspect you are correct. That was the rationale for limiting it to 250mA.
Matthias Granberry
@mgranberry
Feb 10 2017 17:15
What kind of battery life do you get in practice with an EB? A day or two?
Assuming a 2000mAh battery
Matthias
@ceben80
Feb 10 2017 17:16
2000 around 13 hours
Scott Leibrand
@scottleibrand
Feb 10 2017 17:17
Up to 16 depending what's running
Matthias Granberry
@mgranberry
Feb 10 2017 17:18
That seems like awfully high power consumption. I wonder what's going on there.
kws1969
@kws1969
Feb 10 2017 17:23
Good info. 👍
Feeling allot better about the 2500 I just orders. 😎👍
Scott Leibrand
@scottleibrand
Feb 10 2017 17:28
@mgranberry lots of optimizations we know we could do: just need volunteers to help out
Matthias Granberry
@mgranberry
Feb 10 2017 17:35
@scottleibrand I'm still waiting on my EB, but I'm happy to help out on what I can. Is there a place where you're keeping a list?
kws1969
@kws1969
Feb 10 2017 17:36
So thankful for everyone's help and work that made all this possible. getting set up. So happy to be "live" finally. Happy dance. And thanks for putting up with all my questions. Lol
Jorge Aguilar
@jonahtaxt
Feb 10 2017 17:38
is this the right place to ask about autotune?
Matthias
@ceben80
Feb 10 2017 17:38
@jonahtaxt swap over to https://gitter.im/openaps/autotune :wink:
Jorge Aguilar
@jonahtaxt
Feb 10 2017 17:38
thanks
Matthias
@ceben80
Feb 10 2017 17:41
@scottleibrand what are you plans in terms of "lots of optimizations"? I you want something to test, give me a shout :wink:
kws1969
@kws1969
Feb 10 2017 17:42
I just want to mention something that threw me through a loop was when open asks which cgm you use. I kept putting sharable. Katie finally told me that I needed to be on G4. Hope this helps some newbie that's reading this today. 👍
This hung me up for 2 days and nights. Rookie mistake. 😞
Also think this is why my pi and TI stick never would work. 😭😂
kws1969
@kws1969
Feb 10 2017 17:49
Actually think this has been my problem for months not being able to get open to work. Feel so stupid
Scott Leibrand
@scottleibrand
Feb 10 2017 17:49
@ceben80 @mgranberry can one of you open an oref0 issue, and I'll add details there?
one thing we can do is move away from nested openaps aliases to a single shell script for each loop, as I've done in the smb branch...
Matthias
@ceben80
Feb 10 2017 17:50
@mgranberry would you like to open :wink: I am just busy with an oref0 PR
Matthias Granberry
@mgranberry
Feb 10 2017 17:51
I'll open one when I have a chance.
Matthias
@ceben80
Feb 10 2017 17:51
:+1:
Tim Street
@tim2000s
Feb 10 2017 18:14
Shell scripts instead of nested aliases. That's how I made my first Loop work 😳
Scott Leibrand
@scottleibrand
Feb 10 2017 18:18
Yeah, we'll have come full circle. :smile:
Aliases we're good for everyone doing things a bit differently. Now that everyone is using oref0-setup, a well-commented loop script would be better in many ways, including speed and power use (not spinning up python so many times)
Tim Street
@tim2000s
Feb 10 2017 18:24
Yes, and given smb battery consumption that makes sense.
Matthias Granberry
@mgranberry
Feb 10 2017 18:26
How much power does wifi consume? I guess I need to rig up a JST passthrough and see what's really drawing current.
Matthias Granberry
@mgranberry
Feb 10 2017 18:32
I just find it hard to believe that spawning Python is a significant power drain. I could believe that having to stay awake to pull pump info over the slow RF link is a problem.
Chris Oattes
@cjo20
Feb 10 2017 18:35
@mgranberry Each time you call openaps X, it spends about 8 seconds at about 120mA power draw figuring out all of the libraries it needs to include
So if you do something like openaps report invoke something/simple.json, that would take 0.1 seconds to run on its own, it takes over 8 seconds
Matthias Granberry
@mgranberry
Feb 10 2017 18:37
Fair enough
but 16h at 120mA ~= 2000mAh. It smells like something else to me, but I haven't looked at anything.
Chris Oattes
@cjo20
Feb 10 2017 18:40
The edison does'nt support proper power throttling, but it drops down to about 60mA when not running anything, and peaks at about 150mA or so when it's flat out
so if you can take out a minute of spawning python per loop...
Matthias Granberry
@mgranberry
Feb 10 2017 18:40
It seems like parallelizing the steps in the DAG would yield more fruit.
Scott Leibrand
@scottleibrand
Feb 10 2017 18:41
oref0-pump-loop.sh is the lowest hanging fruit, because I've already done it. :)
(in the smb branch)
Chris Oattes
@cjo20
Feb 10 2017 18:42
There are frequently parts that are inherently serial. You can do stuff like upload gluocse data to nightscout while running autosens / deteremine-basal
But I think that's the sort of level you should be looking to parallelise stuff. I think oref0-setup already manages that with multiple cron jobs to do different things
16h for 2000mA should definitely be possible. 20h isn't unreaasonable, depending on how often your loop runs
Tim Street
@tim2000s
Feb 10 2017 18:48
It does, but currently, we're seeing about 12-14hrs from 2000mAh.
Darrell Wright
@beached
Feb 10 2017 19:39
does cpufreq work on the edison?
Matthias Granberry
@mgranberry
Feb 10 2017 20:03
it looks like it is fixed at 500mhz
Darrell Wright
@beached
Feb 10 2017 20:09
In that case, the best bet I have seen for power saving is to get it completed as quickly as possible and then idle or sleep
Matthias Granberry
@mgranberry
Feb 10 2017 20:13
Or push work out onto the Quark MCU, but that's probably more pain than it's worth.
Darrell Wright
@beached
Feb 10 2017 20:34
to be blunt, most expectations of performance go out the door when using node.js/javascript. this means battery life goes down as the more you do the less battery time you get. It's a tradeoff though, dev time vs run time
Matthias
@ceben80
Feb 10 2017 21:43
@scottleibrand PR openaps/oref0#395 has been finalized and it's ready for review - thank you!
ejoe132
@ejoe132
Feb 10 2017 22:59
trying to set up my edison, do flashall.bat in command prompt, then it asks to reboot, and i lose my connection to putty, so i can watch it run in command prompt but cant in putty, is this an issue?
RedCyclist1
@RedCyclist1
Feb 10 2017 23:35
@ejoe132 I am not an expert but I did mine that way
Scott Leibrand
@scottleibrand
Feb 10 2017 23:41
@ejoe132 you should not lose your putty connection if you log in and reboot from the yocto command line
and if you do lose it, you should be able to re-plug the UART cable and open the putty serial connection back up to watch the flash
ejoe132
@ejoe132
Feb 10 2017 23:42
@RedCyclist1 how did you enter your wifi info? The walkthrough says "enter at the end" but the page is a bunch of squiggle lines coming down and I copy and pasted the structure then enter my own name and wifi password then did the test but it didnt work?
Scott Leibrand
@scottleibrand
Feb 10 2017 23:42
@ejoe132 if you flashed jubilinux properly and are editing the right file, it should already have a bunch of contents. the squiggle lines indicate the file you're editing is empty
ejoe132
@ejoe132
Feb 10 2017 23:42
@scottleibrand ok Ill try starting again, just unplug the UART cable when it asks to reboot?
Scott Leibrand
@scottleibrand
Feb 10 2017 23:43
before any of the flashing or rebooting, do you get a login prompt over UART?
ejoe132
@ejoe132
Feb 10 2017 23:43
@scottleibrand Maybe I did it wrong cause it just had maybe 10ish squiggle lines
Scott Leibrand
@scottleibrand
Feb 10 2017 23:43
ok, nevermind all that, let's see what state it's in now
ejoe132
@ejoe132
Feb 10 2017 23:44
@scottleibrand Im not sure what you mean? If I do a serial connection with putty it does ask for login
Scott Leibrand
@scottleibrand
Feb 10 2017 23:44
can you copy and paste your uname -a output?
ejoe132
@ejoe132
Feb 10 2017 23:44
yes doing it now
Linux edisonone 3.10.17-poky-edison+ #6 SMP PREEMPT Wed Mar 23 21:47:59 EDT 2016 i686 GNU/Linux
(edisonone is my assigned name)
Scott Leibrand
@scottleibrand
Feb 10 2017 23:47
ok, that's good. you (probably) flashed jubilinux correctly
ejoe132
@ejoe132
Feb 10 2017 23:48
@scottleibrand I believe it should be, or thats what I have downloaded that I flashed haha
Scott Leibrand
@scottleibrand
Feb 10 2017 23:48
sometimes a flash will fail and people will still have yocto and not realize it
and then move on to troubleshooting if you still don't get network after configuring those and rebooting
ejoe132
@ejoe132
Feb 10 2017 23:49
@scottleibrand Ok Ill start doing that again and hopefully get it to go
@scottleibrand So you have the block that says "after editing your file should look like.." do I want the last line there then next one to say INSERT (while in insert mode? mine has other stuff inbetween
Scott Leibrand
@scottleibrand
Feb 10 2017 23:53
if the other stuff all starts with # (the comment character) it doesn't matter
ejoe132
@ejoe132
Feb 10 2017 23:53
@scottleibrand it does, Ill leave it then
@scottleibrand So Im to the page where I enter or add my wifi name and password, still has my one twice that I entered before. Remove one and try to save it again?
Scott Leibrand
@scottleibrand
Feb 10 2017 23:57
just need to make sure that your network is in there correctly (once). how you do that is up to you
ejoe132
@ejoe132
Feb 10 2017 23:58
@scottleibrand And I dont need the quotes correct?