sdm2mqtt/grafana/dashboard.json

1002 lines
26 KiB
JSON
Raw Permalink Normal View History

{
"annotations": {
"list": [
{
"builtIn": 1,
"datasource": {
"type": "grafana",
"uid": "-- Grafana --"
},
"enable": true,
"hide": true,
"iconColor": "rgba(0, 211, 255, 1)",
"name": "Annotations & Alerts",
"type": "dashboard"
}
]
},
"editable": true,
"fiscalYearStartMonth": 0,
"graphTooltip": 2,
"id": 3,
"links": [],
"liveNow": true,
"panels": [
{
"datasource": {
"type": "influxdb",
"uid": "bdoon42i61rlse"
},
"fieldConfig": {
"defaults": {
"color": {
"mode": "thresholds"
},
"decimals": 3,
"displayName": "${__field.labels['phase']}",
"mappings": [],
"thresholds": {
"mode": "absolute",
"steps": [
{
"color": "dark-blue",
"value": null
}
]
},
"unit": "watth"
},
"overrides": []
},
"gridPos": {
"h": 4,
"w": 10,
"x": 0,
"y": 0
},
"id": 10,
"options": {
"colorMode": "value",
"graphMode": "area",
"justifyMode": "auto",
"orientation": "vertical",
"reduceOptions": {
"calcs": [
"lastNotNull"
],
"fields": "",
"values": false
},
"showPercentChange": false,
"textMode": "auto",
"wideLayout": true
},
"pluginVersion": "11.0.0",
"targets": [
{
"datasource": {
"type": "influxdb",
"uid": "bdoon42i61rlse"
},
"query": "// v.windowPeriod is a variable referring to the current optimized window period (currently: $interval)\nbase = from(bucket: \"telegraf/autogen\")\n |> range(start: v.timeRangeStart, stop: v.timeRangeStop)\n |> filter(fn: (r) => (\n r[\"_measurement\"] == \"camp_power\" and exists r.phase and r[\"_field\"] == \"total\"))\n\nvfirst = base\n |> first()\n\nvlast = base\n |> last()\n\nunion(tables: [vfirst, vlast])\n |> difference()\n |> group(columns: [\"phase\"])\n |> sum()",
"refId": "A"
}
],
"title": "Used Energy per Phase",
"transparent": true,
"type": "stat"
},
{
"datasource": {
"type": "influxdb",
"uid": "bdoon42i61rlse"
},
"gridPos": {
"h": 4,
"w": 4,
"x": 12,
"y": 0
},
"id": 13,
"options": {
"code": {
"language": "plaintext",
"showLineNumbers": false,
"showMiniMap": false
},
"content": "<img src=\"https://vviki.vvoid.camp/_media/wiki:logo.png\" height=\"100%\" />",
"mode": "html"
},
"pluginVersion": "11.0.0",
"transparent": true,
"type": "text"
},
{
"datasource": {
"type": "influxdb",
"uid": "bdoon42i61rlse"
},
"fieldConfig": {
"defaults": {
"color": {
"mode": "thresholds"
},
"decimals": 3,
"displayName": "Sum",
"mappings": [],
"thresholds": {
"mode": "absolute",
"steps": [
{
"color": "dark-blue",
"value": null
}
]
},
"unit": "watth"
},
"overrides": []
},
"gridPos": {
"h": 4,
"w": 3,
"x": 18,
"y": 0
},
"id": 11,
"options": {
"colorMode": "value",
"graphMode": "area",
"justifyMode": "auto",
"orientation": "auto",
"reduceOptions": {
"calcs": [
"lastNotNull"
],
"fields": "",
"values": false
},
"showPercentChange": false,
"textMode": "auto",
"wideLayout": true
},
"pluginVersion": "11.0.0",
"targets": [
{
"datasource": {
"type": "influxdb",
"uid": "bdoon42i61rlse"
},
"query": "// v.windowPeriod is a variable referring to the current optimized window period (currently: $interval)\nbase = from(bucket: \"telegraf/autogen\")\n |> range(start: v.timeRangeStart, stop: v.timeRangeStop)\n |> filter(fn: (r) => (\n r[\"_measurement\"] == \"camp_power\" and exists r.phase and r[\"_field\"] == \"total\"))\n\nvfirst = base\n |> first()\n\nvlast = base\n |> last()\n\nunion(tables: [vfirst, vlast])\n |> difference()\n |> group(columns: [\"mac\"])\n |> sum()",
"refId": "A"
}
],
"title": "Used Energy Total",
"transparent": true,
"type": "stat"
},
{
"datasource": {
"type": "influxdb",
"uid": "bdoon42i61rlse"
},
"fieldConfig": {
"defaults": {
"color": {
"mode": "thresholds"
},
"decimals": 2,
"displayName": "Sum",
"mappings": [],
"thresholds": {
"mode": "absolute",
"steps": [
{
"color": "dark-blue",
"value": null
}
]
},
"unit": "currencyEUR"
},
"overrides": []
},
"gridPos": {
"h": 4,
"w": 3,
"x": 21,
"y": 0
},
"id": 12,
"options": {
"colorMode": "value",
"graphMode": "area",
"justifyMode": "auto",
"orientation": "auto",
"reduceOptions": {
"calcs": [
"lastNotNull"
],
"fields": "",
"values": false
},
"showPercentChange": false,
"textMode": "auto",
"wideLayout": true
},
"pluginVersion": "11.0.0",
"targets": [
{
"datasource": {
"type": "influxdb",
"uid": "bdoon42i61rlse"
},
"query": "// v.windowPeriod is a variable referring to the current optimized window period (currently: $interval)\nbase = from(bucket: \"telegraf/autogen\")\n |> range(start: v.timeRangeStart, stop: v.timeRangeStop)\n |> filter(fn: (r) => (\n r[\"_measurement\"] == \"camp_power\" and exists r.phase and r[\"_field\"] == \"total\"))\n\nvfirst = base\n |> first()\n\nvlast = base\n |> last()\n\nunion(tables: [vfirst, vlast])\n |> difference()\n |> group(columns: [\"mac\"])\n |> sum()\n |> map(fn: (r) => ({r with _value: r._value * ${energy_cost:float} / 1000.0}))",
"refId": "A"
}
],
"title": "Energy Approximated Cost",
"transparent": true,
"type": "stat"
},
{
"datasource": {
"type": "influxdb",
"uid": "bdoon42i61rlse"
},
"fieldConfig": {
"defaults": {
"color": {
"mode": "thresholds"
},
"displayName": "${__field.labels['phase']}",
"fieldMinMax": false,
"mappings": [],
"max": 70,
"min": 0,
"thresholds": {
"mode": "absolute",
"steps": [
{
"color": "green",
"value": null
},
{
"color": "orange",
"value": 40
},
{
"color": "red",
"value": 45
},
{
"color": "dark-purple",
"value": 50
}
]
},
"unit": "amp"
},
"overrides": []
},
"gridPos": {
"h": 7,
"w": 24,
"x": 0,
"y": 4
},
"id": 2,
"options": {
"displayMode": "lcd",
"maxVizHeight": 300,
"minVizHeight": 16,
"minVizWidth": 8,
"namePlacement": "top",
"orientation": "horizontal",
"reduceOptions": {
"calcs": [
"lastNotNull"
],
"fields": "",
"values": false
},
"showUnfilled": true,
"sizing": "auto",
"text": {},
"valueMode": "color"
},
"pluginVersion": "11.0.0",
"targets": [
{
"datasource": {
"type": "influxdb",
"uid": "bdoon42i61rlse"
},
"query": "from(bucket: \"telegraf/autogen\")\n |> range(start: v.timeRangeStart, stop:v.timeRangeStop)\n |> filter(fn: (r) =>\n r._measurement == \"camp_power\" and\n r._field == \"current\"\n )\n |> aggregateWindow(every: v.windowPeriod, fn: last)\n |> group(columns: [\"phase\"])",
"refId": "A"
}
],
"title": "Ampere per Phase",
"transparent": true,
"type": "bargauge"
},
{
"datasource": {
"type": "influxdb",
"uid": "bdoon42i61rlse"
},
"fieldConfig": {
"defaults": {
"color": {
"mode": "thresholds"
},
"displayName": "${__field.labels['phase']}",
"mappings": [],
"max": 300,
"min": 150,
"thresholds": {
"mode": "absolute",
"steps": [
{
"color": "red",
"value": null
},
{
"color": "orange",
"value": 190
},
{
"color": "green",
"value": 215
},
{
"color": "orange",
"value": 250
},
{
"color": "red",
"value": 265
}
]
},
"unit": "volt"
},
"overrides": []
},
"gridPos": {
"h": 4,
"w": 11,
"x": 0,
"y": 11
},
"id": 3,
"options": {
"minVizHeight": 75,
"minVizWidth": 75,
"orientation": "auto",
"reduceOptions": {
"calcs": [
"lastNotNull"
],
"fields": "",
"values": false
},
"showThresholdLabels": false,
"showThresholdMarkers": true,
"sizing": "auto"
},
"pluginVersion": "11.0.0",
"targets": [
{
"datasource": {
"type": "influxdb",
"uid": "bdoon42i61rlse"
},
"query": "from(bucket: \"telegraf/autogen\")\n |> range(start: v.timeRangeStart, stop:v.timeRangeStop)\n |> filter(fn: (r) =>\n r._measurement == \"camp_power\" and\n r._field == \"voltage\"\n )\n |> aggregateWindow(every: 1h, fn: last)\n |> group(columns: [\"phase\"])\n |> yield(name: \"voltage\")",
"refId": "A"
}
],
"title": "Voltage",
"transparent": true,
"type": "gauge"
},
{
"datasource": {
"type": "influxdb",
"uid": "bdoon42i61rlse"
},
"fieldConfig": {
"defaults": {
"color": {
"mode": "thresholds"
},
"displayName": "${__field.labels['phase']}",
"mappings": [],
"max": 1,
"min": 0,
"thresholds": {
"mode": "absolute",
"steps": [
{
"color": "red",
"value": null
},
{
"color": "orange",
"value": 0.5
},
{
"color": "green",
"value": 0.9
}
]
},
"unit": "percentunit"
},
"overrides": []
},
"gridPos": {
"h": 4,
"w": 10,
"x": 11,
"y": 11
},
"id": 7,
"options": {
"minVizHeight": 75,
"minVizWidth": 75,
"orientation": "auto",
"reduceOptions": {
"calcs": [
"lastNotNull"
],
"fields": "",
"values": false
},
"showThresholdLabels": false,
"showThresholdMarkers": true,
"sizing": "auto"
},
"pluginVersion": "11.0.0",
"targets": [
{
"datasource": {
"type": "influxdb",
"uid": "bdoon42i61rlse"
},
"query": "from(bucket: \"telegraf/autogen\")\n |> range(start: v.timeRangeStart, stop:v.timeRangeStop)\n |> filter(fn: (r) =>\n r._measurement == \"camp_power\" and\n r._field == \"pf\"\n )\n |> aggregateWindow(every: 1h, fn: last)\n |> group(columns: [\"phase\"])\n |> yield(name: \"pf\")",
"refId": "A"
}
],
"title": "Powerfactor",
"transparent": true,
"type": "gauge"
},
{
"datasource": {
"type": "influxdb",
"uid": "bdoon42i61rlse"
},
"fieldConfig": {
"defaults": {
"color": {
"mode": "thresholds"
},
"displayName": "Hz",
"mappings": [],
"max": 51.25,
"min": 48.8,
"thresholds": {
"mode": "absolute",
"steps": [
{
"color": "red",
"value": null
},
{
"color": "orange",
"value": 47.5
},
{
"color": "yellow",
"value": 49.8
},
{
"color": "green",
"value": 49.95
},
{
"color": "yellow",
"value": 50.05
},
{
"color": "red",
"value": 50.2
}
]
},
"unit": "rothz"
},
"overrides": []
},
"gridPos": {
"h": 4,
"w": 3,
"x": 21,
"y": 11
},
"id": 8,
"options": {
"minVizHeight": 75,
"minVizWidth": 75,
"orientation": "auto",
"reduceOptions": {
"calcs": [
"lastNotNull"
],
"fields": "",
"values": false
},
"showThresholdLabels": false,
"showThresholdMarkers": true,
"sizing": "auto"
},
"pluginVersion": "11.0.0",
"targets": [
{
"datasource": {
"type": "influxdb",
"uid": "bdoon42i61rlse"
},
"query": "from(bucket: \"telegraf/autogen\")\n |> range(start: v.timeRangeStart, stop:v.timeRangeStop)\n |> filter(fn: (r) =>\n r._measurement == \"sdm\" and\n r.name == \"Vorzelt\" and\n r._field == \"Frequency\"\n )\n |> aggregateWindow(every: v.windowPeriod, fn: last)\n |> yield(name: \"Hz\")",
"refId": "A"
}
],
"title": "Frequency",
"transparent": true,
"type": "gauge"
},
{
"collapsed": false,
"gridPos": {
"h": 1,
"w": 24,
"x": 0,
"y": 15
},
"id": 4,
"panels": [],
"title": "Historical",
"type": "row"
},
{
"datasource": {
"type": "influxdb",
"uid": "bdoon42i61rlse"
},
"description": "",
"fieldConfig": {
"defaults": {
"color": {
"mode": "palette-classic"
},
"custom": {
"axisBorderShow": false,
"axisCenteredZero": false,
"axisColorMode": "text",
"axisLabel": "",
"axisPlacement": "auto",
"barAlignment": 0,
"drawStyle": "line",
"fillOpacity": 0,
"gradientMode": "none",
"hideFrom": {
"legend": false,
"tooltip": false,
"viz": false
},
"insertNulls": false,
"lineInterpolation": "linear",
"lineWidth": 1,
"pointSize": 5,
"scaleDistribution": {
"type": "linear"
},
"showPoints": "auto",
"spanNulls": 3600000,
"stacking": {
"group": "A",
"mode": "none"
},
"thresholdsStyle": {
"mode": "area"
}
},
"mappings": [],
"thresholds": {
"mode": "absolute",
"steps": [
{
"color": "transparent",
"value": null
},
{
"color": "red",
"value": 50
}
]
},
"unit": "amp"
},
"overrides": []
},
"gridPos": {
"h": 8,
"w": 24,
"x": 0,
"y": 16
},
"id": 6,
"options": {
"legend": {
"calcs": [
"lastNotNull",
"min",
"max"
],
"displayMode": "table",
"placement": "bottom",
"showLegend": true
},
"tooltip": {
"maxHeight": 600,
"mode": "single",
"sort": "none"
}
},
"targets": [
{
"datasource": {
"type": "influxdb",
"uid": "bdoon42i61rlse"
},
"query": "from(bucket: \"telegraf/autogen\")\n |> range(start: v.timeRangeStart, stop:v.timeRangeStop)\n |> filter(fn: (r) =>\n r._measurement == \"camp_power\" and\n r._field == \"current\"\n )\n |> group(columns: [\"phase\"])\n |> aggregateWindow(every: v.windowPeriod, fn: mean)\n |> yield(name: \"current\")",
"refId": "A"
}
],
"title": "Amperage per Phase",
"type": "timeseries"
},
{
"datasource": {
"type": "influxdb",
"uid": "bdoon42i61rlse"
},
"description": "Available voltage from utility company",
"fieldConfig": {
"defaults": {
"color": {
"mode": "palette-classic"
},
"custom": {
"axisBorderShow": false,
"axisCenteredZero": false,
"axisColorMode": "text",
"axisLabel": "",
"axisPlacement": "auto",
"barAlignment": 0,
"drawStyle": "line",
"fillOpacity": 0,
"gradientMode": "none",
"hideFrom": {
"legend": false,
"tooltip": false,
"viz": false
},
"insertNulls": false,
"lineInterpolation": "linear",
"lineWidth": 1,
"pointSize": 5,
"scaleDistribution": {
"type": "linear"
},
"showPoints": "auto",
"spanNulls": 3600000,
"stacking": {
"group": "A",
"mode": "none"
},
"thresholdsStyle": {
"mode": "off"
}
},
"mappings": [],
"thresholds": {
"mode": "absolute",
"steps": [
{
"color": "green",
"value": null
}
]
},
"unit": "volt"
},
"overrides": []
},
"gridPos": {
"h": 8,
"w": 24,
"x": 0,
"y": 24
},
"id": 1,
"options": {
"legend": {
"calcs": [
"lastNotNull",
"min",
"max"
],
"displayMode": "table",
"placement": "bottom",
"showLegend": true
},
"tooltip": {
"maxHeight": 600,
"mode": "single",
"sort": "none"
}
},
"targets": [
{
"datasource": {
"type": "influxdb",
"uid": "bdoon42i61rlse"
},
"query": "from(bucket: \"telegraf/autogen\")\n |> range(start: v.timeRangeStart, stop:v.timeRangeStop)\n |> filter(fn: (r) =>\n r._measurement == \"camp_power\" and\n r._field == \"voltage\"\n )\n |> group(columns: [\"phase\"])\n |> aggregateWindow(every: v.windowPeriod, fn: mean)\n |> yield(name: \"voltage\")",
"refId": "A"
}
],
"title": "Grid Voltage",
"type": "timeseries"
},
{
"datasource": {
"type": "influxdb",
"uid": "bdoon42i61rlse"
},
"description": "",
"fieldConfig": {
"defaults": {
"color": {
"mode": "palette-classic"
},
"custom": {
"axisBorderShow": false,
"axisCenteredZero": false,
"axisColorMode": "text",
"axisLabel": "",
"axisPlacement": "auto",
"barAlignment": 0,
"drawStyle": "line",
"fillOpacity": 0,
"gradientMode": "none",
"hideFrom": {
"legend": false,
"tooltip": false,
"viz": false
},
"insertNulls": false,
"lineInterpolation": "linear",
"lineWidth": 1,
"pointSize": 5,
"scaleDistribution": {
"type": "linear"
},
"showPoints": "auto",
"spanNulls": 3600000,
"stacking": {
"group": "A",
"mode": "none"
},
"thresholdsStyle": {
"mode": "off"
}
},
"mappings": [],
"thresholds": {
"mode": "absolute",
"steps": [
{
"color": "green"
},
{
"color": "red",
"value": 80
}
]
},
"unit": "watt"
},
"overrides": []
},
"gridPos": {
"h": 8,
"w": 24,
"x": 0,
"y": 32
},
"id": 5,
"options": {
"legend": {
"calcs": [
"lastNotNull",
"min",
"max"
],
"displayMode": "table",
"placement": "bottom",
"showLegend": true
},
"tooltip": {
"maxHeight": 600,
"mode": "single",
"sort": "none"
}
},
"targets": [
{
"datasource": {
"type": "influxdb",
"uid": "bdoon42i61rlse"
},
"query": "from(bucket: \"telegraf/autogen\")\n |> range(start: v.timeRangeStart, stop:v.timeRangeStop)\n |> filter(fn: (r) =>\n r._measurement == \"camp_power\" and\n r._field == \"power\"\n )\n |> group(columns: [\"phase\"])\n |> aggregateWindow(every: v.windowPeriod, fn: mean)\n |> yield(name: \"power\")",
"refId": "A"
}
],
"title": "Power draw",
"type": "timeseries"
},
{
"datasource": {
"type": "influxdb",
"uid": "bdoon42i61rlse"
},
"description": "",
"fieldConfig": {
"defaults": {
"color": {
"mode": "palette-classic"
},
"custom": {
"axisBorderShow": false,
"axisCenteredZero": false,
"axisColorMode": "text",
"axisLabel": "",
"axisPlacement": "auto",
"barAlignment": 0,
"drawStyle": "line",
"fillOpacity": 0,
"gradientMode": "none",
"hideFrom": {
"legend": false,
"tooltip": false,
"viz": false
},
"insertNulls": false,
"lineInterpolation": "linear",
"lineWidth": 1,
"pointSize": 5,
"scaleDistribution": {
"type": "linear"
},
"showPoints": "auto",
"spanNulls": 3600000,
"stacking": {
"group": "A",
"mode": "none"
},
"thresholdsStyle": {
"mode": "area"
}
},
"mappings": [],
"thresholds": {
"mode": "absolute",
"steps": [
{
"color": "transparent"
},
{
"color": "red",
"value": 50
}
]
},
"unit": "amp"
},
"overrides": []
},
"gridPos": {
"h": 8,
"w": 24,
"x": 0,
"y": 40
},
"id": 9,
"options": {
"legend": {
"calcs": [
"lastNotNull",
"min",
"max"
],
"displayMode": "table",
"placement": "bottom",
"showLegend": true
},
"tooltip": {
"maxHeight": 600,
"mode": "single",
"sort": "none"
}
},
"targets": [
{
"datasource": {
"type": "influxdb",
"uid": "bdoon42i61rlse"
},
"query": "from(bucket: \"telegraf/autogen\")\n |> range(start: v.timeRangeStart, stop:v.timeRangeStop)\n |> filter(fn: (r) =>\n r._measurement == \"sdm\" and\n r._field =~ /L[123]_Current$/\n )\n |> group(columns: [\"name\", \"_field\"])\n |> aggregateWindow(every: v.windowPeriod, fn: mean)\n |> yield(name: \"current\")",
"refId": "A"
}
],
"title": "Amperage per Phase",
"type": "timeseries"
}
],
"schemaVersion": 39,
"tags": [],
"templating": {
"list": [
{
"current": {
"selected": false,
"text": "0.27",
"value": "0.27"
},
"hide": 0,
"label": "Arbeitspreis kWh",
"name": "energy_cost",
"options": [
{
"selected": true,
"text": "0.27",
"value": "0.27"
}
],
"query": "0.27",
"skipUrlSync": false,
"type": "textbox"
}
]
},
"time": {
"from": "2024-06-13T18:58:04.114Z",
"to": "2024-06-16T13:55:48.659Z"
},
"timeRangeUpdatedDuringEditOrView": false,
"timepicker": {
"refresh_intervals": [
"5s",
"10s"
]
},
"timezone": "browser",
"title": "Camp Power",
"uid": "cdooob979frwge",
"version": 39,
"weekStart": ""
}