Coder Social home page Coder Social logo

hardillb / node-red-contrib-circadian-light Goto Github PK

View Code? Open in Web Editor NEW

This project forked from tyrrellsystems/node-red-contrib-circadian-light

0.0 2.0 0.0 12 KB

A node to track the prosition of the sun and output a % of height for the day

License: Apache License 2.0

HTML 63.74% JavaScript 36.26%

node-red-contrib-circadian-light's Introduction

A Node-RED node to calculate circadian lighting levels

Install

npm install node-red-contrib-circadian-light

Usage

You set your lat/lon and the reporting interval and then the node outputs a message with the current position of the sun and its % of maximum daily height:

{
  "azimuth": 0.36900883056765676, 
  "altitude": 0.36796818774968365, 
  "percent": 89.8566247170534 
}

Where azimuth is the position of the Sun in radians (direction along the horizon, measured from south to west), e.g. 0 is south and Math.PI * 3/4 is northwest.

altitude is the height of the Sun above the horizon in radians. Where 0 is at the horizon and PI/2 is directly overhead.

percent is how close the Sun is to its highest position of the day, so 0% is at sun rise and 100% will be the highest point the sun reaches for the given position and day.

node-red-contrib-circadian-light's People

Contributors

hardillb avatar dceejay 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.