dynamic.1.name=cpu_frequency
dynamic.1.source=/sys/devices/system/cpu/cpu0/cpufreq/cpuinfo_cur_freq
dynamic.1.regexp=(.*)
dynamic.1.postprocess=sprintf("%.3f", $1/1000000)
dynamic.1.rrd=GAUGE

dynamic.2.name=load1,load5,load15
dynamic.2.source=/proc/loadavg
dynamic.2.regexp=^(\S+)\s(\S+)\s(\S+)
dynamic.2.postprocess=
dynamic.2.rrd=GAUGE

dynamic.3.name=scaling_governor
dynamic.3.source=/sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
dynamic.3.regexp=(.*)
dynamic.3.postprocess=
dynamic.3.rrd=

dynamic.4.name=cpu_count
dynamic.4.source=grep -c processor /proc/cpuinfo
dynamic.4.regexp=(.*)
dynamic.4.postprocess=
dynamic.4.rrd=GAUGE

#dynamic.5.name=disktemp
#dynamic.5.source=/usr/sbin/smartctl -a /dev/sda | /usr/bin/awk -F" " '/Temperature_Celsius/ {print $10}'
#dynamic.5.regexp=(.*)
#dynamic.5.postprocess=
#dynamic.5.rrd=GAUGE

dynamic.5.name=vcorevoltage
dynamic.5.source=/sys/class/regulator/regulator.2/microvolts
dynamic.5.regexp=(.*)
dynamic.5.postprocess=sprintf("%.2f", $1/1000000)
dynamic.5.rrd=GAUGE

dynamic.6.name=soctemp
dynamic.6.source=/sys/devices/virtual/thermal/thermal_zone0/temp
dynamic.6.regexp=(.*)
dynamic.6.postprocess=
dynamic.6.rrd=GAUGE

dynamic.7.name=coolingstate
dynamic.7.source=/sys/devices/virtual/thermal/cooling_device0/cur_state
dynamic.7.regexp=(.*)
dynamic.7.postprocess=
dynamic.7.rrd=GAUGE

dynamic.8.name=coolinglimit
dynamic.8.source=/sys/devices/soc.0/cpu_budget_cool.16/roomage
dynamic.8.regexp=(.*)
dynamic.8.postprocess=
dynamic.8.rrd=

dynamic.9.name=batterycapacity
dynamic.9.source=/sys/class/power_supply/battery/capacity
dynamic.9.regexp=(.*)
dynamic.9.postprocess=
dynamic.9.rrd=GAUGE

dynamic.10.name=batteryvoltage
dynamic.10.source=/sys/class/power_supply/battery/voltage_now
dynamic.10.regexp=(.*)
dynamic.10.postprocess=sprintf("%.3f", $1/1000000)
dynamic.10.rrd=GAUGE

dynamic.11.name=batterycurrent
dynamic.11.source=/sys/class/power_supply/battery/current_now
dynamic.11.regexp=(.*)
dynamic.11.postprocess=sprintf("%.3f", $1/1000000)
dynamic.11.rrd=GAUGE

dynamic.12.name=pmictemp
dynamic.12.source=/sys/class/axppower/ic_temp
dynamic.12.regexp=(.*)
dynamic.12.postprocess=
dynamic.12.rrd=GAUGE

dynamic.13.name=batterydrain
dynamic.13.source=/sys/class/axppower/power_sply
dynamic.13.regexp=(.*)
dynamic.13.postprocess=sprintf("%.3f", $1/1000000)
dynamic.13.rrd=GAUGE

dynamic.14.name=gpu_frequency
dynamic.14.source=/sys/devices/1c40000.gpu/dvfs/manual
dynamic.14.regexp=^(\S+)
dynamic.14.postprocess=
dynamic.14.rrd=

dynamic.15.name=gputemp
dynamic.15.source=awk '{print $6}' < /sys/devices/1c40000.gpu/dvfs/tempctrl
dynamic.15.regexp=(.*)
dynamic.15.postprocess=
dynamic.15.rrd=

dynamic.16.name=gpuvoltage
dynamic.16.source=/sys/devices/1c40000.gpu/dvfs/voltage
dynamic.16.regexp=^(\S+)
dynamic.16.postprocess=sprintf("%.2f", $1/1000)
dynamic.16.rrd=

web.status.1.content.1.name=CPU/GPU
web.status.1.content.1.icon=cpu.png
web.status.1.content.1.line.1=JustGageBar("Load", "1min", 0, data.load1, 3, 100, 80)+" "+JustGageBar("Load", "5min", 0, data.load5, 3, 100, 80)+" "+JustGageBar("Load", "15min", 0, data.load15, 3, 100, 80)
web.status.1.content.1.line.2="CPU frequency: <b>" + data.cpu_frequency + " GHz</b> &nbsp;(" + data.coolinglimit + ")"
web.status.1.content.1.line.3="Governor: <b>" + data.scaling_governor + "</b> &nbsp;Active CPU cores: <b>" + data.cpu_count + "</b> &nbsp;Vcore: <b>" + data.vcorevoltage + "V</b>"
web.status.1.content.1.line.4="GPU frequency: <b>" + data.gpu_frequency + " MHz</b> &nbsp;GPU voltage: <b>" + data.gpuvoltage + "V</b>"

web.status.1.content.2.name=Temperature
web.status.1.content.2.icon=cpu_temp.png
web.status.1.content.2.line.1=JustGageBar("CPU", "°C",0, data.soctemp , 100,100,80,percentColors,50,70)+" "+JustGageBar("GPU", "°C",0, data.gputemp , 100,100,80,percentColors,50,70)+" "+JustGageBar("PMIC", "°C",0, data.pmictemp , 100,100,80,percentColors,60,80)+" "+JustGageBar("Cooling State", "",0, data.coolingstate , 7,100,80,percentColors,1,2)

web.status.1.content.3.name=Battery
web.status.1.content.3.icon=pmu.png
web.status.1.content.3.line.1=JustGageBar("Battery capacity", "%", 0, data.batterycapacity, 100,100,80,percentColors,100,100)+" "+JustGageBar("Battery voltage", "V", 0, data.batteryvoltage, 5,100,80,percentColors,100,100)+" "+JustGageBar("Battery current", "A", -3, data.batterycurrent, 3,100,80,percentColors,100,100)+" "+JustGageBar("Battery drain", "W", 0, data.batterydrain, 15,100,80,percentColors,6,9)

web.statistics.1.content.1.name=Load / Clockspeeds / Temperature
web.statistics.1.content.1.graph.1=load1
web.statistics.1.content.1.graph.2=load5
web.statistics.1.content.1.graph.3=load15
web.statistics.1.content.1.graph.4=cpu_frequency
web.statistics.1.content.1.graph.5=cpu_count
web.statistics.1.content.1.graph.6=coolingstate
web.statistics.1.content.1.graph.7=soctemp
web.statistics.1.content.1.graph.8=vcorevoltage
web.statistics.1.content.1.graph.9=batterycapacity
web.statistics.1.content.1.graph.10=batteryvoltage
web.statistics.1.content.1.graph.11=batterycurrent
web.statistics.1.content.1.graph.12=pmictemp
web.statistics.1.content.1.graph.13=batterydrain
web.statistics.1.content.1.ds_graph_options.load1.label=Load 1 min
web.statistics.1.content.1.ds_graph_options.load5.label=Load 5 min
web.statistics.1.content.1.ds_graph_options.load15.label=Load 15 min
web.statistics.1.content.1.ds_graph_options.cpu_frequency.label=CPU Clock speed (GHz)
web.statistics.1.content.1.ds_graph_options.cpu_frequency.yaxis=2
web.statistics.1.content.1.ds_graph_options.cpu_count.label=Active CPUs
web.statistics.1.content.1.ds_graph_options.cpu_count.yaxis=2
web.statistics.1.content.1.ds_graph_options.soctemp.label=SoC temp (°C)
web.statistics.1.content.1.ds_graph_options.pmictemp.label=PMIC temp (°C)
web.statistics.1.content.1.ds_graph_options.vcorevoltage.label=Vcore (V)
web.statistics.1.content.1.ds_graph_options.vcorevoltage.yaxis=2
web.statistics.1.content.1.ds_graph_options.coolingstate.label=Cooling State
web.statistics.1.content.1.ds_graph_options.coolingstate.yaxis=2
web.statistics.1.content.1.ds_graph_options.batterycapacity.label=Battery capacity
web.statistics.1.content.1.ds_graph_options.batteryvoltage.label=Battery voltage
web.statistics.1.content.1.ds_graph_options.batteryvoltage.yaxis=2
web.statistics.1.content.1.ds_graph_options.batterycurrent.label=Battery current
web.statistics.1.content.1.ds_graph_options.batterycurrent.yaxis=2
web.statistics.1.content.1.ds_graph_options.batterydrain.label=Battery drain
web.statistics.1.content.1.ds_graph_options.batterydrain.yaxis=2
web.statistics.1.content.1.graph_options.y1axis={ position: "left", min: 35, max: 75 }
web.statistics.1.content.1.graph_options.y2axis={ position: "right" }
