Giter VIP home page Giter VIP logo

komfovent-c6-metrics's Introduction

Komfovent C6 metrics

A Node.js server that exposes status and metrics of the Komfovent C6M ventilation unit.

Overview

sequenceDiagram
    participant A as Prometheus<br>(Local)
    participant B as Komfovent C6 metrics Agent<br>(This repo, Local)
    participant C as Komfovent ventilation unit<br>(Local)
    box rgb(33,66,99) External Network
    participant D as Prometheus Cloud
    participant E as Grafana Cloud
    end

    loop Scrape every 15 secs
        A->>+B: GET /metrics
        B->>+C: Read registers<br>(Modbus TCP)
        C-->>-B: temperature, air flow, etc.
        B->>B: Process with Prometheus metrics
        B-->>-A: metrics
        A-->>D: remote write
    end
    E->>D: Query
    D-->>E: Result
    E->>E: Rendering Dashboard
Loading

Getting Started

cd prometheus

# Open the docker-compose.yaml file and modify MODBUS_TCP_IP and MODBUS_TCP_PORT appropriately."

# Set up `remote_write` Prometheus config to send metric data to a remote system.

# Run
docker compose up -d

Grafana Dashboard

Import the dashboards stored in JSON format within the Grafana directory, and modify the datasources.

For Developers

Getting Started

export MODBUS_TCP_IP=<Your device IP>
export MODBUS_TCP_PORT=<Your device Port>
export SERVER_PORT=<Server Port>

npm run build
node ./dist/index.js

APIs

  • GET /metrics: An API that returns various ventilation unit metrics as Prometheus format.
  • GET /info: An API that returns various ventilation unit metrics as JSON format.

Build

docker buildx create --use
docker buildx build --platform=linux/arm/v7,linux/arm64,linux/amd64 -t wokim/komfovent-c6-metrics:latest --target release --push .
docker buildx build --platform=linux/arm/v7,linux/arm64,linux/amd64 -t wokim/komfovent-c6-metrics:0.0.1 --target release --push .

komfovent-c6-metrics's People

Contributors

wokim avatar

Stargazers

loomingsight avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.