Office temperature monitoring #1904
Replies: 7 comments
-
Posted at 2017-01-04 by @gfwilliams That looks great - thanks for posting it up! |
Beta Was this translation helpful? Give feedback.
-
Posted at 2017-01-05 by AntiCat Great! Thank your for sharing. Have you considered using digitalPulse? |
Beta Was this translation helpful? Give feedback.
-
Posted at 2017-01-05 by koresar Wow. Haven't found it. Thanks. Will try it. |
Beta Was this translation helpful? Give feedback.
-
Posted at 2017-01-06 by ThomasVikström Very interesting, this was the first example I tried with to get started after the 'Hello world..'. Does the Puck know the date and time, or do you need to set it somehow? |
Beta Was this translation helpful? Give feedback.
-
Posted at 2017-01-06 by Fabio978 The Puck has its own RTC, and it's "synced" everytime you upload something from your pc. |
Beta Was this translation helpful? Give feedback.
-
Posted at 2017-01-07 by koresar
Yes it does, but not by default. One would need to turn the option On in the web IDE settings. For some reason it set Puck time to 0:22 am, whereas it's 11:22 am in my time zone currently. My puck came to me with the time set close to Unix epoch ~ For simplicity the code above assumes the Puck time zone is set to the local time (i.e. the local timezone is +00 hours). I did it with the setTime function. Here is how to get a value for the However, if you don't need the schedule feature, which relies on time, just remove lines 78-112. |
Beta Was this translation helpful? Give feedback.
-
Posted at 2017-01-07 by Fabio978 Yes, my "dirty workaround" was to add +1 hour in the code, more or less like you suggest, while creating the Date object. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Posted at 2017-01-04 by koresar
I bought Puck.js basically to make sure none in our office changes the aircon settings.
The below app
The app memory and CPU usage are optimized up to my knowledge of JS engines.
Below is the source code of the v1. The latest source code is hosted here.
Suggestions are very welcome.
Beta Was this translation helpful? Give feedback.
All reactions