# Error-circular - where is this coming from?

**URL:** <https://discourse.nodered.org/t/error-circular-where-is-this-coming-from/7114>\
**Category:** General\
**Created:** [21 January 2019 20:37 UTC](https://discourse.nodered.org/t/error-circular-where-is-this-coming-from/7114 "2019-01-21T20:37:23Z")\
**Posts on this page:** 1\
**Showing post:** 19

<div class="post-metadata">

**Author:** ![Andrei](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/andrei/32/10446_2.png) [@Andrei](https://discourse.nodered.org/u/Andrei)\
**Post date:** [23 January 2019 01:44 UTC](https://discourse.nodered.org/t/error-circular-where-is-this-coming-from/7114/19 "2019-01-23T01:44:57Z")

</div>

> [@hazymat](#):
>
> surprised nobody else made a really simple delay based number fader like this

Indeed, I could not find a node or flow in Node-RED library that address this need.

The subject of dimming light has already been discussed once in our forum and people provided a lot of insights and suggestions.

> [@PCF9685 Dimmen slow](https://discourse.nodered.org/t/pcf9685-dimmen-slow/2731/7):
>
> I've solved a similar problem using my node-red-contrib-dsm node. I'd post the flow if requested.

This smoothing problem resembles somewhat the capabilities that [CSS give us](https://www.w3schools.com/css/css3_transitions.asp) to "ease" transitions.

It is feasible to build a solution without using timer functions (setTimeout , setInterval) since the smoothing factor depends only on the time elapsed since the beginning of the fading (only subtracting current time from the start time). Plenty of smoothing functions can be created based on [easing functions](https://easings.net/en) or [bezier curves](https://www.premiumbeat.com/blog/how-to-use-bezier-curves/).

---

_[View the full topic](https://discourse.nodered.org/t/error-circular-where-is-this-coming-from/7114)._
