Grafana dashboard: PDMA - OEE Equipamento
Description: PDMA OEE equipment dashboard


{
  "__inputs": [
    {
      "name": "DS_INFLUXDB",
      "label": "InfluxDB",
      "description": "",
      "type": "datasource",
      "pluginId": "influxdb",
      "pluginName": "InfluxDB"
    }
  ],
  "__requires": [
    {
      "type": "panel",
      "id": "bargauge",
      "name": "Bar Gauge",
      "version": ""
    },
    {
      "type": "grafana",
      "id": "grafana",
      "name": "Grafana",
      "version": "6.4.2"
    },
    {
      "type": "datasource",
      "id": "influxdb",
      "name": "InfluxDB",
      "version": "1.0.0"
    },
    {
      "type": "panel",
      "id": "singlestat",
      "name": "Singlestat",
      "version": ""
    },
    {
      "type": "panel",
      "id": "text",
      "name": "Text",
      "version": ""
    }
  ],
  "annotations": {
    "list": [
      {
        "builtIn": 1,
        "datasource": "-- Grafana --",
        "enable": true,
        "hide": true,
        "iconColor": "rgba(0, 211, 255, 1)",
        "name": "Annotations & Alerts",
        "type": "dashboard"
      }
    ]
  },
  "description": "PDMA OEE equipment dashboard",
  "editable": true,
  "gnetId": 15836,
  "graphTooltip": 0,
  "id": null,
  "iteration": 1591410077895,
  "links": [],
  "panels": [
    {
      "cacheTimeout": null,
      "colorBackground": false,
      "colorValue": false,
      "colors": [
        "#C4162A",
        "#FA6400",
        "#37872D"
      ],
      "datasource": "${DS_INFLUXDB}",
      "format": "none",
      "gauge": {
        "maxValue": 100,
        "minValue": 0,
        "show": false,
        "thresholdLabels": false,
        "thresholdMarkers": true
      },
      "gridPos": {
        "h": 4,
        "w": 8,
        "x": 0,
        "y": 0
      },
      "id": 2,
      "interval": null,
      "links": [],
      "mappingType": 1,
      "mappingTypes": [
        {
          "name": "value to text",
          "value": 1
        },
        {
          "name": "range to text",
          "value": 2
        }
      ],
      "maxDataPoints": 100,
      "nullPointMode": "connected",
      "nullText": null,
      "options": {},
      "pluginVersion": "6.2.3",
      "postfix": "",
      "postfixFontSize": "50%",
      "prefix": "",
      "prefixFontSize": "50%",
      "rangeMaps": [
        {
          "from": "null",
          "text": "N/A",
          "to": "null"
        }
      ],
      "sparkline": {
        "fillColor": "rgba(31, 118, 189, 0.18)",
        "full": false,
        "lineColor": "rgb(31, 120, 193)",
        "show": false
      },
      "tableColumn": "",
      "targets": [
        {
          "groupBy": [],
          "measurement": "sensor_data_2",
          "orderByTime": "ASC",
          "policy": "default",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "sum"
              }
            ]
          ],
          "tags": [
            {
              "key": "gateway_mac",
              "operator": "=~",
              "value": "/^$gateway_mac$/"
            },
            {
              "condition": "AND",
              "key": "gateway_name",
              "operator": "=~",
              "value": "/^$gateway_name$/"
            },
            {
              "condition": "AND",
              "key": "sensor_mac",
              "operator": "=~",
              "value": "/^$pma_sensor_mac$/"
            },
            {
              "condition": "AND",
              "key": "sensor_name",
              "operator": "=~",
              "value": "/^$pma_sensor_name$/"
            },
            {
              "condition": "AND",
              "key": "alias",
              "operator": "=~",
              "value": "/^$produced_parts$/"
            }
          ]
        }
      ],
      "thresholds": "300,500",
      "timeFrom": null,
      "timeShift": null,
      "title": "Peças produzidas",
      "type": "singlestat",
      "valueFontSize": "80%",
      "valueMaps": [
        {
          "op": "=",
          "text": "N/A",
          "value": "null"
        }
      ],
      "valueName": "current"
    },
    {
      "cacheTimeout": null,
      "colorBackground": true,
      "colorValue": false,
      "colors": [
        "#37872D",
        "#37872D",
        "#37872D"
      ],
      "datasource": "${DS_INFLUXDB}",
      "format": "none",
      "gauge": {
        "maxValue": 100,
        "minValue": 0,
        "show": false,
        "thresholdLabels": false,
        "thresholdMarkers": true
      },
      "gridPos": {
        "h": 4,
        "w": 8,
        "x": 8,
        "y": 0
      },
      "id": 4,
      "interval": null,
      "links": [],
      "mappingType": 1,
      "mappingTypes": [
        {
          "name": "value to text",
          "value": 1
        },
        {
          "name": "range to text",
          "value": 2
        }
      ],
      "maxDataPoints": 100,
      "nullPointMode": "connected",
      "nullText": null,
      "options": {},
      "pluginVersion": "6.2.3",
      "postfix": "",
      "postfixFontSize": "50%",
      "prefix": "",
      "prefixFontSize": "50%",
      "rangeMaps": [
        {
          "from": "null",
          "text": "N/A",
          "to": "null"
        }
      ],
      "sparkline": {
        "fillColor": "rgba(31, 118, 189, 0.18)",
        "full": false,
        "lineColor": "rgb(31, 120, 193)",
        "show": false
      },
      "tableColumn": "",
      "targets": [
        {
          "groupBy": [],
          "measurement": "sensor_data_2",
          "orderByTime": "ASC",
          "policy": "default",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "sum"
              }
            ]
          ],
          "tags": [
            {
              "key": "gateway_mac",
              "operator": "=~",
              "value": "/^$gateway_mac$/"
            },
            {
              "condition": "AND",
              "key": "gateway_name",
              "operator": "=~",
              "value": "/^$gateway_name$/"
            },
            {
              "condition": "AND",
              "key": "sensor_mac",
              "operator": "=~",
              "value": "/^$pma_sensor_mac$/"
            },
            {
              "condition": "AND",
              "key": "sensor_name",
              "operator": "=~",
              "value": "/^$pma_sensor_name$/"
            },
            {
              "condition": "AND",
              "key": "alias",
              "operator": "=~",
              "value": "/^$good_parts$/"
            }
          ]
        }
      ],
      "thresholds": "",
      "timeFrom": null,
      "timeShift": null,
      "title": "Peças boas",
      "type": "singlestat",
      "valueFontSize": "80%",
      "valueMaps": [
        {
          "op": "=",
          "text": "N/A",
          "value": "null"
        }
      ],
      "valueName": "current"
    },
    {
      "cacheTimeout": null,
      "colorBackground": true,
      "colorValue": false,
      "colors": [
        "#C4162A",
        "#C4162A",
        "#C4162A"
      ],
      "datasource": "${DS_INFLUXDB}",
      "format": "none",
      "gauge": {
        "maxValue": 100,
        "minValue": 0,
        "show": false,
        "thresholdLabels": false,
        "thresholdMarkers": true
      },
      "gridPos": {
        "h": 4,
        "w": 8,
        "x": 16,
        "y": 0
      },
      "id": 6,
      "interval": null,
      "links": [],
      "mappingType": 1,
      "mappingTypes": [
        {
          "name": "value to text",
          "value": 1
        },
        {
          "name": "range to text",
          "value": 2
        }
      ],
      "maxDataPoints": 100,
      "nullPointMode": "connected",
      "nullText": null,
      "options": {},
      "pluginVersion": "6.2.3",
      "postfix": "",
      "postfixFontSize": "50%",
      "prefix": "",
      "prefixFontSize": "50%",
      "rangeMaps": [
        {
          "from": "null",
          "text": "N/A",
          "to": "null"
        }
      ],
      "sparkline": {
        "fillColor": "rgba(31, 118, 189, 0.18)",
        "full": false,
        "lineColor": "rgb(31, 120, 193)",
        "show": false
      },
      "tableColumn": "",
      "targets": [
        {
          "groupBy": [],
          "measurement": "sensor_data_2",
          "orderByTime": "ASC",
          "policy": "default",
          "query": "SELECT sum(\"current_phase_1\")  - (sum(\"current_phase_1\") / 1.5) FROM \"sensor_data_1\" WHERE $timeFilter GROUP BY time($__interval) fill(null)",
          "rawQuery": false,
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "sum"
              }
            ]
          ],
          "tags": [
            {
              "key": "gateway_mac",
              "operator": "=~",
              "value": "/^$gateway_mac$/"
            },
            {
              "condition": "AND",
              "key": "gateway_name",
              "operator": "=~",
              "value": "/^$gateway_name$/"
            },
            {
              "condition": "AND",
              "key": "sensor_mac",
              "operator": "=~",
              "value": "/^$pma_sensor_mac$/"
            },
            {
              "condition": "AND",
              "key": "sensor_name",
              "operator": "=~",
              "value": "/^$pma_sensor_name$/"
            },
            {
              "condition": "AND",
              "key": "alias",
              "operator": "=~",
              "value": "/^$defective_parts$/"
            }
          ]
        }
      ],
      "thresholds": "",
      "timeFrom": null,
      "timeShift": null,
      "title": "Peças refugadas",
      "type": "singlestat",
      "valueFontSize": "80%",
      "valueMaps": [
        {
          "op": "=",
          "text": "N/A",
          "value": "null"
        }
      ],
      "valueName": "current"
    },
    {
      "datasource": "${DS_INFLUXDB}",
      "gridPos": {
        "h": 9,
        "w": 16,
        "x": 0,
        "y": 4
      },
      "id": 8,
      "links": [],
      "options": {
        "displayMode": "lcd",
        "fieldOptions": {
          "calcs": [
            "last"
          ],
          "defaults": {
            "mappings": [],
            "max": 150,
            "min": 0,
            "thresholds": [
              {
                "color": "dark-red",
                "value": null
              },
              {
                "color": "yellow",
                "value": 80
              },
              {
                "color": "dark-green",
                "value": 90
              },
              {
                "color": "yellow",
                "value": 110
              },
              {
                "color": "dark-red",
                "value": 120
              }
            ],
            "unit": "percent"
          },
          "override": {},
          "values": false
        },
        "orientation": "horizontal"
      },
      "pluginVersion": "6.4.2",
      "targets": [
        {
          "alias": "Disponibilidade",
          "groupBy": [
            {
              "params": [
                "$__interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "measurement": "sensor_data_2",
          "orderByTime": "ASC",
          "policy": "default",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "sum"
              }
            ]
          ],
          "tags": [
            {
              "key": "gateway_mac",
              "operator": "=~",
              "value": "/^$gateway_mac$/"
            },
            {
              "condition": "AND",
              "key": "gateway_name",
              "operator": "=~",
              "value": "/^$gateway_name$/"
            },
            {
              "condition": "AND",
              "key": "sensor_mac",
              "operator": "=~",
              "value": "/^$pma_sensor_mac$/"
            },
            {
              "condition": "AND",
              "key": "sensor_name",
              "operator": "=~",
              "value": "/^$pma_sensor_name$/"
            }
          ]
        },
        {
          "alias": "Eficiência",
          "groupBy": [
            {
              "params": [
                "$__interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "measurement": "sensor_data_2",
          "orderByTime": "ASC",
          "policy": "default",
          "refId": "B",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "sum"
              }
            ]
          ],
          "tags": [
            {
              "key": "gateway_mac",
              "operator": "=~",
              "value": "/^$gateway_mac$/"
            },
            {
              "condition": "AND",
              "key": "gateway_name",
              "operator": "=~",
              "value": "/^$gateway_name$/"
            },
            {
              "condition": "AND",
              "key": "sensor_mac",
              "operator": "=~",
              "value": "/^$pma_sensor_mac$/"
            },
            {
              "condition": "AND",
              "key": "sensor_name",
              "operator": "=~",
              "value": "/^$pma_sensor_name$/"
            }
          ]
        },
        {
          "alias": "Qualidade",
          "groupBy": [
            {
              "params": [
                "$__interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "measurement": "sensor_data_2",
          "orderByTime": "ASC",
          "policy": "default",
          "query": "SELECT (sum(\"value\")  - ($d01 - $d02)) / $d02 * 100 FROM \"sensor_data_2\" WHERE (\"gateway_mac\" =~ /^$Gateway$/ AND \"alias\" = 'd02') AND $timeFilter",
          "rawQuery": false,
          "refId": "C",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "sum"
              }
            ]
          ],
          "tags": [
            {
              "key": "gateway_mac",
              "operator": "=~",
              "value": "/^$gateway_mac$/"
            },
            {
              "condition": "AND",
              "key": "gateway_name",
              "operator": "=~",
              "value": "/^$gateway_name$/"
            },
            {
              "condition": "AND",
              "key": "sensor_mac",
              "operator": "=~",
              "value": "/^$pma_sensor_mac$/"
            },
            {
              "condition": "AND",
              "key": "sensor_name",
              "operator": "=~",
              "value": "/^$pma_sensor_name$/"
            }
          ]
        },
        {
          "alias": "OEE",
          "groupBy": [
            {
              "params": [
                "$__interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "measurement": "sensor_data_2",
          "orderByTime": "ASC",
          "policy": "default",
          "refId": "D",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "sum"
              }
            ]
          ],
          "tags": [
            {
              "key": "gateway_mac",
              "operator": "=~",
              "value": "/^$gateway_mac$/"
            },
            {
              "condition": "AND",
              "key": "gateway_name",
              "operator": "=~",
              "value": "/^$gateway_name$/"
            },
            {
              "condition": "AND",
              "key": "sensor_mac",
              "operator": "=~",
              "value": "/^$pma_sensor_mac$/"
            },
            {
              "condition": "AND",
              "key": "sensor_name",
              "operator": "=~",
              "value": "/^$pma_sensor_name$/"
            }
          ]
        }
      ],
      "timeFrom": null,
      "timeShift": null,
      "title": "Overall Equipment Effectiveness (OEE) - Eficiência global do equipamento",
      "transparent": true,
      "type": "bargauge"
    },
    {
      "content": "- Disponibilidade: Mede o quanto o equipamento está realmente disponível para produção\n  - (tempo operacional) / (tempo programado)\n- Eficiência: Mede se o equipamento está produzindo as peças na quantidade adequada\n  - (__tempo necessário__ para produção de _n_ peças) / (__tempo gasto__ para produção de _n_ peças)\n- Qualidade: Mede o quanto de peças boas estão sendo produzidas\n  - ((quantidade de peças produzidas) - (quantidade de peças refugadas)) / (quantidade de peças produzidas)\n- OEE: Disponibilidade X Performance X Qualidade",
      "datasource": "${DS_INFLUXDB}",
      "description": "",
      "gridPos": {
        "h": 9,
        "w": 8,
        "x": 16,
        "y": 4
      },
      "id": 10,
      "links": [],
      "mode": "markdown",
      "options": {},
      "timeFrom": null,
      "timeShift": null,
      "title": "OEE legenda",
      "transparent": true,
      "type": "text"
    }
  ],
  "schemaVersion": 20,
  "style": "dark",
  "tags": [],
  "templating": {
    "list": [
      {
        "allValue": null,
        "current": {},
        "datasource": "${DS_INFLUXDB}",
        "definition": "SHOW TAG VALUES WITH KEY = \"gateway_name\"",
        "hide": 0,
        "includeAll": true,
        "label": null,
        "multi": true,
        "name": "gateway_name",
        "options": [],
        "query": "SHOW TAG VALUES WITH KEY = \"gateway_name\"",
        "refresh": 2,
        "regex": "",
        "skipUrlSync": false,
        "sort": 0,
        "tagValuesQuery": "",
        "tags": [],
        "tagsQuery": "",
        "type": "query",
        "useTags": false
      },
      {
        "allValue": null,
        "current": {},
        "datasource": "${DS_INFLUXDB}",
        "definition": "SHOW TAG VALUES WITH KEY = \"gateway_mac\" WHERE \"gateway_name\" =~ /^$gateway_name$/",
        "hide": 0,
        "includeAll": true,
        "label": null,
        "multi": true,
        "name": "gateway_mac",
        "options": [],
        "query": "SHOW TAG VALUES WITH KEY = \"gateway_mac\" WHERE \"gateway_name\" =~ /^$gateway_name$/",
        "refresh": 2,
        "regex": "",
        "skipUrlSync": false,
        "sort": 0,
        "tagValuesQuery": "",
        "tags": [],
        "tagsQuery": "",
        "type": "query",
        "useTags": false
      },
      {
        "allValue": null,
        "current": {},
        "datasource": "${DS_INFLUXDB}",
        "definition": "SHOW TAG VALUES FROM \"sensor_data_2\" WITH KEY = \"sensor_name\" WHERE \"gateway_mac\" =~ /^$gateway_mac$/",
        "hide": 0,
        "includeAll": true,
        "label": null,
        "multi": true,
        "name": "pma_sensor_name",
        "options": [],
        "query": "SHOW TAG VALUES FROM \"sensor_data_2\" WITH KEY = \"sensor_name\" WHERE \"gateway_mac\" =~ /^$gateway_mac$/",
        "refresh": 2,
        "regex": "",
        "skipUrlSync": false,
        "sort": 0,
        "tagValuesQuery": "",
        "tags": [],
        "tagsQuery": "",
        "type": "query",
        "useTags": false
      },
      {
        "allValue": null,
        "current": {},
        "datasource": "${DS_INFLUXDB}",
        "definition": "SHOW TAG VALUES FROM \"sensor_data_2\" WITH KEY = \"sensor_mac\" WHERE \"gateway_mac\" =~ /^$gateway_mac$/ AND \"sensor_name\" =~ /^$pma_sensor_name$/",
        "hide": 0,
        "includeAll": true,
        "label": null,
        "multi": true,
        "name": "pma_sensor_mac",
        "options": [],
        "query": "SHOW TAG VALUES FROM \"sensor_data_2\" WITH KEY = \"sensor_mac\" WHERE \"gateway_mac\" =~ /^$gateway_mac$/ AND \"sensor_name\" =~ /^$pma_sensor_name$/",
        "refresh": 2,
        "regex": "",
        "skipUrlSync": false,
        "sort": 0,
        "tagValuesQuery": "",
        "tags": [],
        "tagsQuery": "",
        "type": "query",
        "useTags": false
      },
      {
        "allValue": null,
        "current": {},
        "datasource": "${DS_INFLUXDB}",
        "definition": "SHOW TAG VALUES FROM \"sensor_data_2\" WITH KEY = \"alias\" WHERE \"gateway_mac\" =~ /^$gateway_mac$/ AND \"sensor_mac\" =~ /^$pma_sensor_mac$/",
        "hide": 0,
        "includeAll": true,
        "label": null,
        "multi": true,
        "name": "produced_parts",
        "options": [],
        "query": "SHOW TAG VALUES FROM \"sensor_data_2\" WITH KEY = \"alias\" WHERE \"gateway_mac\" =~ /^$gateway_mac$/ AND \"sensor_mac\" =~ /^$pma_sensor_mac$/",
        "refresh": 2,
        "regex": "",
        "skipUrlSync": false,
        "sort": 0,
        "tagValuesQuery": "",
        "tags": [],
        "tagsQuery": "",
        "type": "query",
        "useTags": false
      },
      {
        "allValue": null,
        "current": {},
        "datasource": "${DS_INFLUXDB}",
        "definition": "SHOW TAG VALUES FROM \"sensor_data_2\" WITH KEY = \"alias\" WHERE \"gateway_mac\" =~ /^$gateway_mac$/ AND \"sensor_mac\" =~ /^$pma_sensor_mac$/",
        "hide": 0,
        "includeAll": true,
        "label": null,
        "multi": true,
        "name": "good_parts",
        "options": [],
        "query": "SHOW TAG VALUES FROM \"sensor_data_2\" WITH KEY = \"alias\" WHERE \"gateway_mac\" =~ /^$gateway_mac$/ AND \"sensor_mac\" =~ /^$pma_sensor_mac$/",
        "refresh": 2,
        "regex": "",
        "skipUrlSync": false,
        "sort": 0,
        "tagValuesQuery": "",
        "tags": [],
        "tagsQuery": "",
        "type": "query",
        "useTags": false
      },
      {
        "allValue": null,
        "current": {},
        "datasource": "${DS_INFLUXDB}",
        "definition": "SHOW TAG VALUES FROM \"sensor_data_2\" WITH KEY = \"alias\" WHERE \"gateway_mac\" =~ /^$gateway_mac$/ AND \"sensor_mac\" =~ /^$pma_sensor_mac$/",
        "hide": 0,
        "includeAll": true,
        "label": null,
        "multi": true,
        "name": "defective_parts",
        "options": [],
        "query": "SHOW TAG VALUES FROM \"sensor_data_2\" WITH KEY = \"alias\" WHERE \"gateway_mac\" =~ /^$gateway_mac$/ AND \"sensor_mac\" =~ /^$pma_sensor_mac$/",
        "refresh": 2,
        "regex": "",
        "skipUrlSync": false,
        "sort": 0,
        "tagValuesQuery": "",
        "tags": [],
        "tagsQuery": "",
        "type": "query",
        "useTags": false
      }
    ]
  },
  "time": {
    "from": "now/M",
    "to": "now/M"
  },
  "timepicker": {
    "refresh_intervals": [
      "5s",
      "10s",
      "30s",
      "1m",
      "5m",
      "15m",
      "30m",
      "1h",
      "2h",
      "1d"
    ],
    "time_options": [
      "5m",
      "15m",
      "1h",
      "6h",
      "12h",
      "24h",
      "2d",
      "7d",
      "30d"
    ]
  },
  "timezone": "",
  "title": "PDMA - OEE Equipamento",
  "uid": "4V7P6K0Zz",
  "version": 1
}