Skip to content

Instantly share code, notes, and snippets.

@bfaloona

bfaloona/openaps-lp-01.2016Jun16.txt Secret

Last active Jun 16, 2016
Embed
What would you like to do?
pi@openaps-lp:~/openaps-lp-01 $ oref0 env
PATH=/home/pi/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/games:/usr/games
XDG_SESSION_ID=c3
NIGHTSCOUT_HOST=https://nightscout-lp.herokuapp.com
SHELL=/bin/bash
TERM=xterm-256color
SSH_CLIENT=10.0.0.221 54273 22
SSH_TTY=/dev/pts/0
USER=pi
LS_COLORS=rs=0:di=01;34:ln=01;36:mh=00:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:su=37;41:sg=30;43:ca=30;41:tw=30;42:ow=34;42:st=37;44:ex=01;32:*.tar=01;31:*.tgz=01;31:*.arc=01;31:*.arj=01;31:*.taz=01;31:*.lha=01;31:*.lz4=01;31:*.lzh=01;31:*.lzma=01;31:*.tlz=01;31:*.txz=01;31:*.tzo=01;31:*.t7z=01;31:*.zip=01;31:*.z=01;31:*.Z=01;31:*.dz=01;31:*.gz=01;31:*.lrz=01;31:*.lz=01;31:*.lzo=01;31:*.xz=01;31:*.bz2=01;31:*.bz=01;31:*.tbz=01;31:*.tbz2=01;31:*.tz=01;31:*.deb=01;31:*.rpm=01;31:*.jar=01;31:*.war=01;31:*.ear=01;31:*.sar=01;31:*.rar=01;31:*.alz=01;31:*.ace=01;31:*.zoo=01;31:*.cpio=01;31:*.7z=01;31:*.rz=01;31:*.cab=01;31:*.jpg=01;35:*.jpeg=01;35:*.gif=01;35:*.bmp=01;35:*.pbm=01;35:*.pgm=01;35:*.ppm=01;35:*.tga=01;35:*.xbm=01;35:*.xpm=01;35:*.tif=01;35:*.tiff=01;35:*.png=01;35:*.svg=01;35:*.svgz=01;35:*.mng=01;35:*.pcx=01;35:*.mov=01;35:*.mpg=01;35:*.mpeg=01;35:*.m2v=01;35:*.mkv=01;35:*.webm=01;35:*.ogm=01;35:*.mp4=01;35:*.m4v=01;35:*.mp4v=01;35:*.vob=01;35:*.qt=01;35:*.nuv=01;35:*.wmv=01;35:*.asf=01;35:*.rm=01;35:*.rmvb=01;35:*.flc=01;35:*.avi=01;35:*.fli=01;35:*.flv=01;35:*.gl=01;35:*.dl=01;35:*.xcf=01;35:*.xwd=01;35:*.yuv=01;35:*.cgm=01;35:*.emf=01;35:*.axv=01;35:*.anx=01;35:*.ogv=01;35:*.ogx=01;35:*.aac=00;36:*.au=00;36:*.flac=00;36:*.m4a=00;36:*.mid=00;36:*.midi=00;36:*.mka=00;36:*.mp3=00;36:*.mpc=00;36:*.ogg=00;36:*.ra=00;36:*.wav=00;36:*.axa=00;36:*.oga=00;36:*.spx=00;36:*.xspf=00;36:
API_SECRET=...
PATH=/home/pi/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/games:/usr/games
MAIL=/var/mail/pi
PWD=/home/pi/openaps-lp-01
LANG=en_GB.UTF-8
HOME=/home/pi
SHLVL=2
LOGNAME=pi
SSH_CONNECTION=10.0.0.221 54273 10.0.0.161 22
XDG_RUNTIME_DIR=/run/user/1000
_=/usr/bin/env
pi@openaps-lp:~/openaps-lp-01 $ openaps device show
process://oref0/oref0/
process://get-profile/oref0/get-profile
process://calculate-iob/oref0/calculate-iob
process://determine-basal/oref0/determine-basal
process://tz/None/None
units://units
process://ns/ns-status/
process://curl/bash/-c "curl -s https://nightscout-lp.herokuapp.com/api/v1/entries.json | json -e 'this.glucose = this.sgv'"
process://detect-sensitivity/oref0/detect-sensitivity
medtronic://pump
pi@openaps-lp:~/openaps-lp-01 $ cat openaps.ini
[alias]
rm-warmup = ! bash -c "rm -f model.json monitor/clock.json > /dev/null"
warmup = report invoke model.json raw-pump/clock-raw.json monitor/clock.json
fail-warmup = ! bash -c "echo PREFLIGHT FAIL; exit 1"
preflight = ! bash -c "(openaps rm-warmup; echo PREFLIGHT ) && openaps warmup 2>&1 >/dev/null && grep -q T monitor/clock.json && echo PREFLIGHT OK || openaps fail-warmup"
monitor-cgm = report invoke monitor/glucose.json
monitor-pump-history = report invoke raw-pump/pump-history-raw.json monitor/pump-history.json
get-basal-status = report invoke monitor/temp-basal-status.json
get-pump-details = report invoke monitor/reservoir.json monitor/status.json monitor/battery.json
get-settings = report invoke raw-pump/bg-targets-raw.json settings/bg-targets.json raw-pump/insulin-sensitivities-raw.json settings/insulin-sensitivities.json raw-pump/selected-basal-profile.json raw-pump/settings.json settings/selected-basal-profile.json settings/settings.json
gather-pump-data = ! bash -c "openaps get-basal-status; openaps get-pump-details; openaps monitor-pump-history; openaps get-settings"
gather-clean-data = ! bash -c "openaps monitor-cgm && openaps gather-pump-data"
do-oref0 = report invoke oref0-monitor/profile.json oref0-monitor/iob.json oref0-predict/oref0.json
enact-oref0 = report invoke oref0-enacted/enacted-temp-basal.json
do-everything = ! bash -c "(openaps preflight && openaps gather-clean-data && openaps do-oref0 && openaps enact-oref0); openaps report-nightscout"
report-nightscout = report invoke nightscout/preflight.json nightscout/recent-treatments.json nightscout/uploaded.json nightscout/recent-missing-entries.json nightscout/uploaded-entries.json
[vendor "openapscontrib.timezones"]
path = .
module = openapscontrib.timezones
[device "oref0"]
vendor = openaps.vendors.process
extra = oref0.ini
[device "get-profile"]
vendor = openaps.vendors.process
extra = get-profile.ini
[device "calculate-iob"]
vendor = openaps.vendors.process
extra = calculate-iob.ini
[device "determine-basal"]
vendor = openaps.vendors.process
extra = determine-basal.ini
[device "tz"]
vendor = openaps.vendors.process
extra = tz.ini
[device "units"]
vendor = openaps.vendors.units
extra = units.ini
[report "settings/settings.json"]
device = oref0
use = shell
reporter = JSON
remainder = copy-fresher raw-pump/settings.json
json_default = True
[report "raw-pump/bg-targets-raw.json"]
device = pump
use = read_bg_targets
reporter = JSON
[report "settings/bg-targets.json"]
device = units
to = mg/dL
use = bg_targets
input = raw-pump/bg-targets-raw.json
reporter = JSON
[report "raw-pump/insulin-sensitivities-raw.json"]
device = pump
use = read_insulin_sensitivities
reporter = JSON
[report "settings/insulin-sensitivities.json"]
device = units
to = mg/dL
use = insulin_sensitivities
input = raw-pump/insulin-sensitivities-raw.json
reporter = JSON
[report "settings/selected-basal-profile.json"]
device = oref0
use = shell
reporter = JSON
remainder = copy-fresher raw-pump/selected-basal-profile.json
json_default = True
[report "raw-pump/clock-raw.json"]
device = pump
use = read_clock
reporter = JSON
[report "monitor/clock.json"]
use = clock
reporter = JSON
astimezone = False
date = None
adjust = missing
timezone = PDT
device = tz
input = raw-pump/clock-raw.json
[report "monitor/temp-basal-status.json"]
device = pump
use = read_temp_basal
reporter = JSON
[report "raw-pump/pump-history-raw.json"]
hours = 8.0
device = pump
use = iter_pump_hours
reporter = JSON
[report "monitor/pump-history.json"]
use = rezone
reporter = JSON
astimezone = False
date = timestamp dateString start_at end_at created_at
adjust = missing
timezone = PDT
device = tz
input = raw-pump/pump-history-raw.json
[report "model.json"]
device = pump
use = model
reporter = JSON
[report "monitor/reservoir.json"]
device = pump
use = reservoir
reporter = JSON
[report "monitor/status.json"]
device = pump
use = read_status
reporter = JSON
[report "monitor/battery.json"]
device = pump
use = read_battery_status
reporter = JSON
[report "oref0-monitor/profile.json"]
insulin-sensitivities = settings/insulin-sensitivities.json
use = shell
settings = settings/settings.json
reporter = text
json_default = True
device = get-profile
bg-targets = settings/bg-targets.json
basal-profile = settings/selected-basal-profile.json
max-iob = max-iob.json
remainder =
[report "oref0-monitor/iob.json"]
use = shell
clock = monitor/clock.json
reporter = text
json_default = True
pump-history = monitor/pump-history.json
oref0-profile = oref0-monitor/profile.json
device = calculate-iob
remainder =
[report "oref0-predict/oref0.json"]
use = shell
temp-basal = monitor/temp-basal-status.json
oref0-iob = oref0-monitor/iob.json
reporter = text
json_default = True
oref0-profile = oref0-monitor/profile.json
device = determine-basal
remainder =
glucose = monitor/glucose.json
[report "oref0-enacted/enacted-temp-basal.json"]
device = pump
input = oref0-predict/oref0.json
use = set_temp_basal
reporter = JSON
[report "raw-pump/settings.json"]
device = pump
use = read_settings
reporter = JSON
[report "raw-pump/selected-basal-profile.json"]
device = pump
use = read_selected_basal_profile
reporter = JSON
[report "raw-pump/temp-basal-status.json"]
device = pump
use = read_temp_basal
reporter = JSON
[report "raw-pump/reservoir.json"]
device = pump
use = reservoir
reporter = JSON
[report "raw-pump/status.json"]
device = pump
use = read_status
reporter = JSON
[report "raw-pump/battery.json"]
device = pump
use = read_battery_status
reporter = JSON
[device "ns"]
vendor = openaps.vendors.process
extra = ns.ini
[report "nightscout/recent-treatments.json"]
oper = format-recent-history-treatments
use = shell
reporter = JSON
json_default = True
device = ns
remainder = monitor/pump-history.json model.json
[report "nightscout/uploaded.json"]
oper = upload-non-empty-treatments
use = shell
reporter = JSON
json_default = True
device = ns
remainder = nightscout/recent-treatments.json
[report "monitor/glucose.json"]
device = curl
use = shell
reporter = text
[report "nightscout/recent-missing-entries.json"]
oper = format-recent-type
use = shell
reporter = JSON
json_default = True
device = ns
remainder = tz entries monitor/glucose.json
[report "nightscout/uploaded-entries.json"]
oper = upload
use = shell
reporter = JSON
json_default = True
device = ns
remainder = entries.json nightscout/recent-missing-entries.json
[report "nightscout/preflight.json"]
oper = preflight
use = shell
reporter = JSON
json_default = True
device = ns
remainder =
[device "curl"]
fields =
cmd = bash
vendor = openaps.vendors.process
args = -c "curl -s https://nightscout-lp.herokuapp.com/api/v1/entries.json | json -e 'this.glucose = this.sgv'"
[device "detect-sensitivity"]
vendor = openaps.vendors.process
extra = detect-sensitivity.ini
[device "pump"]
vendor = openaps.vendors.medtronic
extra = pump.ini
pi@openaps-lp:~/openaps-lp-01 $ openaps use pump read_clock
Traceback (most recent call last):
File "/usr/local/bin/openaps-use", line 4, in <module>
__import__('pkg_resources').run_script('openaps==0.1.5', 'openaps-use')
File "/usr/local/lib/python2.7/dist-packages/setuptools-23.0.0-py2.7.egg/pkg_resources/__init__.py", line 719, in run_script
File "/usr/local/lib/python2.7/dist-packages/setuptools-23.0.0-py2.7.egg/pkg_resources/__init__.py", line 1504, in run_script
File "/usr/local/lib/python2.7/dist-packages/openaps-0.1.5-py2.7.egg/EGG-INFO/scripts/openaps-use", line 63, in <module>
app( )
File "/usr/local/lib/python2.7/dist-packages/openaps-0.1.5-py2.7.egg/openaps/cli/__init__.py", line 47, in __call__
self.configure_parser(self.parser)
File "/usr/local/lib/python2.7/dist-packages/openaps-0.1.5-py2.7.egg/EGG-INFO/scripts/openaps-use", line 40, in configure_parser
self.configure_devices( )
File "/usr/local/lib/python2.7/dist-packages/openaps-0.1.5-py2.7.egg/EGG-INFO/scripts/openaps-use", line 44, in configure_devices
self.commands.configure_commands(self.parser)
File "/usr/local/lib/python2.7/dist-packages/openaps-0.1.5-py2.7.egg/openaps/cli/commandmapapp.py", line 40, in configure_commands
self.makeSubcommand(ctx)
File "/usr/local/lib/python2.7/dist-packages/openaps-0.1.5-py2.7.egg/openaps/cli/commandmapapp.py", line 51, in makeSubcommand
parser = app.configure_subparser(self.subparsers)
File "/usr/local/lib/python2.7/dist-packages/openaps-0.1.5-py2.7.egg/openaps/cli/subcommand.py", line 43, in configure_subparser
self.setup_application( )
File "/usr/local/lib/python2.7/dist-packages/openaps-0.1.5-py2.7.egg/openaps/uses/__init__.py", line 90, in setup_application
self.method.configure_commands(self.parser)
File "/usr/local/lib/python2.7/dist-packages/openaps-0.1.5-py2.7.egg/openaps/cli/commandmapapp.py", line 40, in configure_commands
self.makeSubcommand(ctx)
File "/usr/local/lib/python2.7/dist-packages/openaps-0.1.5-py2.7.egg/openaps/cli/commandmapapp.py", line 51, in makeSubcommand
parser = app.configure_subparser(self.subparsers)
File "/usr/local/lib/python2.7/dist-packages/openaps-0.1.5-py2.7.egg/openaps/cli/subcommand.py", line 43, in configure_subparser
self.setup_application( )
File "/usr/local/lib/python2.7/dist-packages/openaps-0.1.5-py2.7.egg/openaps/uses/__init__.py", line 27, in setup_application
super(DeviceUsageTask, self).setup_application( )
File "/usr/local/lib/python2.7/dist-packages/openaps-0.1.5-py2.7.egg/openaps/cli/subcommand.py", line 19, in setup_application
getattr(self.method, 'configure_app', self._no_op_setup)(self, self.parser)
File "/usr/local/lib/python2.7/dist-packages/openaps-0.1.5-py2.7.egg/openaps/vendors/process.py", line 79, in configure_app
self.fields = self.device.get('fields').strip( ).split(' ')
AttributeError: 'NoneType' object has no attribute 'strip'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment