GithubHelp home page GithubHelp logo

Comments (3)

florianbeer avatar florianbeer commented on July 29, 2024

I wasn't aware that Netatmo could switch to non-metric units. That's nice :)

To center the station name I have the following HTML snippet in my panel:

<div style="height:100%;display:flex;justify-content:center;align-items:center;">
<h1 style="font-size:300%;font-weight:bold;">$Station</h1>
</div>

from grafana-netatmo.

dkozinn avatar dkozinn commented on July 29, 2024

You can't actually switch the device to non-metric units, but I modified the query to have some math built in to do the conversions:
SELECT "value" *3.28084 FROM "altitude" WHERE ("station" =~ /^$Station$/) AND $timeFilter

I'm using the same HTML as you to try to get that centered, and I just can't figure out why it's not working for me. I've set up a simple web page with that exact code and it does seem to work. I'll have to use something like Chrome developer tools to figure out what's going on. What version of Grafana are you using? I'm on 7.1.

What I've started doing is to use your work as a basis for my own dashboard. I've got rain & wind modules, and the repeating template didn't work for those. I decided that instead of using templates, I'd create separate rows for each type of module. That way I can show wind speed & direction, and so on. It's very much a work in progress. I'm also going to move what I think of as the device status info (battery state, rf state) to a separate dashboard since things were getting crowded.

As the result of this, one things that does change is that my queries now look for a (case-insensitive) string specific to that module. For example, here's the outdoor temperature query:

SELECT last("value") *1.8+32 FROM "temperature" WHERE ("module" =~ /(?i)outdoor/ AND "station" =~ /^$Station$/) AND $timeFilter GROUP BY time(5m), "module", "station" fill(previous)

The only downside to what I've done is that it is somewhat more specific in the requirements compared to what you've done. Specifically, for my dashboard the indoor module has to have "indoor" as part of it's name, and "outdoor", "rain", "wind" for those modules. It also no longer would handle multiple indoor modules. (Although of course those could be added manually).

When I (eventually) finish I will probably make it available with credit given you to for the inspiration, and thank you again.

from grafana-netatmo.

florianbeer avatar florianbeer commented on July 29, 2024

Nice, maybe you could create a fork incorporating your non-metric and rain & wind changes.

from grafana-netatmo.

Related Issues (13)

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.