freakent / node-red-contrib-sunevents

A node for node-red that generates events based on the position of the Sun at the appropriate time of day.
Apache License 2.0
15 stars 14 forks source link

No Output at all #12

Closed wuast94 closed 4 years ago

wuast94 commented 4 years ago

I have setup this node and put a debug node behind it to see the output. but nothing is there,

in logs i see calculations:

8 Jun 07:43:07 - [info] [sun events:SunsetEvents] Calculating sun event times for xx.xxxxxx, x.xxxxxx.
8 Jun 07:43:07 - [info] [sun events:SunsetEvents] [sunevents] Calculate today's remaining sunevents
8 Jun 07:43:07 - [info] [sun events:SunsetEvents] [sunevents] Calculating times for Mon Jun 08 2020 12:00:00 GMT+0200
8 Jun 07:43:07 - [info] [sun events:SunsetEvents] [sunevents] Times are { solarNoon: 2020-06-08T11:25:24.598Z,
nadir: 2020-06-07T23:25:24.598Z,
sunrise: 2020-06-08T03:01:28.155Z,
sunset: 2020-06-08T19:49:21.041Z,
sunriseEnd: 2020-06-08T03:06:11.587Z,
sunsetStart: 2020-06-08T19:44:37.609Z,
dawn: 2020-06-08T02:11:00.366Z,
dusk: 2020-06-08T20:39:48.830Z,
nauticalDawn: 2020-06-08T00:47:17.237Z,
nauticalDusk: 2020-06-08T22:03:31.959Z,
nightEnd: Invalid Date,
night: Invalid Date,
goldenHourEnd: 2020-06-08T03:57:55.670Z,
goldenHour: 2020-06-08T18:52:53.526Z }
8 Jun 07:43:07 - [info] [sun events:SunsetEvents] [sunevents] Ignoring 2020-06-08T01:25:24+02:00, nadir was Today at 1:25 AM, -6 hours ago
8 Jun 07:43:07 - [info] [sun events:SunsetEvents] [sunevents] Ignoring 2020-06-08T02:47:17+02:00, nauticalDawn was Today at 2:47 AM, -4 hours ago
8 Jun 07:43:07 - [info] [sun events:SunsetEvents] [sunevents] Ignoring 2020-06-08T04:11:00+02:00, dawn was Today at 4:11 AM, -3 hours ago
8 Jun 07:43:07 - [info] [sun events:SunsetEvents] [sunevents] Ignoring 2020-06-08T05:01:28+02:00, sunrise was Today at 5:01 AM, -2 hours ago
8 Jun 07:43:07 - [info] [sun events:SunsetEvents] [sunevents] Ignoring 2020-06-08T05:06:11+02:00, sunriseEnd was Today at 5:06 AM, -2 hours ago
8 Jun 07:43:07 - [info] [sun events:SunsetEvents] [sunevents] Ignoring 2020-06-08T05:57:55+02:00, goldenHourEnd was Today at 5:57 AM, -1 hours ago
8 Jun 07:43:07 - [info] [sun events:SunsetEvents] [sunevents] Emitting 2020-06-08T13:25:24+02:00, solarNoon Today at 1:25 PM in 5 hours
8 Jun 07:43:07 - [info] [sun events:SunsetEvents] [sunevents] Ignoring Invalid date, night was Invalid date, NaN hours ago
8 Jun 07:43:07 - [info] [sun events:SunsetEvents] [sunevents] Emitting 2020-06-08T20:52:53+02:00, goldenHour Today at 8:52 PM in 13 hours
8 Jun 07:43:07 - [info] [sun events:SunsetEvents] [sunevents] Ignoring Invalid date, nightEnd was Invalid date, NaN hours ago
8 Jun 07:43:07 - [info] [sun events:SunsetEvents] [sunevents] Emitting 2020-06-08T21:44:37+02:00, sunsetStart Today at 9:44 PM in 14 hours
8 Jun 07:43:07 - [info] [sun events:SunsetEvents] [sunevents] Emitting 2020-06-08T21:49:21+02:00, sunset Today at 9:49 PM in 14 hours
8 Jun 07:43:07 - [info] [sun events:SunsetEvents] [sunevents] Emitting 2020-06-08T22:39:48+02:00, dusk Today at 10:39 PM in 14 hours
8 Jun 07:43:07 - [info] [sun events:SunsetEvents] [sunevents] Emitting 2020-06-09T00:03:31+02:00, nauticalDusk Tomorrow at 12:03 AM in 16 hours
8 Jun 07:43:07 - [info] [sun events:SunsetEvents] [sunevents] Started job to calculate sunevents for tomorrow onwards 2020-06-08T22:00:00.000Z
8 Jun 07:43:07 - [info] Gestartete geänderte Nodes
freakent commented 4 years ago

Based on when you started this, the first event would be Solar Noon at 1:25pm (the log is telling you what events it will emit and at what times). Did you wait until that time?

I have never seen invalid dates before. Is your time zone set correctly on your OS?

wuast94 commented 4 years ago

oh ok dont know that an output just triggerd when the event time is reached. is there a chance to implement something that outputs on node change ? or manually trigger an output ? would be nice to have it to work on an automation

freakent commented 4 years ago

If you want to test your setup without waiting, click the “make hours seem like minutes” check box.