Chat freely about anything...
User avatar
By Sirquil
#78216 Early stage of testing "Furnace_Monitor.ino" sketch.

First; I can track accumulated minutes daily, accumulated minutes monthly, and yearly, problem arises when I reset accumulated minutes for current month to zero. Total accumulated minutes for year also resets

Normal operation; minutes accumate for every push of button in the 4N25 Opto Isolator schematic Upon newDay function occurring, Serial Monitor displays totals for day, month, and year. Totals are also available on LAN for viewing. Since newday would only occurs every 24 hours; I have implemented a counter to call newDay function.

William
Attachments
Project file, schematic, Serial Monitor output, Warning; consult HVAC professional.
(42.19 KiB) Downloaded 6 times
User avatar
By McChubby007
#78218 This is a forum about esp8266, not a general programming forum. Is there something specific about the esp8266 for which you have a question or issue related to this. For instance, you wouldn't call up Ford to ask them to help with your local traffic light not working properly, would you.
User avatar
By schufti
#78220 I dare say he seeks help on why he looses yearly total when clearing monthly minutes ?
As he implemented it on an esp8266 with arduino esp8266 core and probably wants to publish it as user project later on (as he allready did with an other project) why not ask here?

If you had a bad day and are not in the mood to help - you're definitely posting in the wrong forum ...
User avatar
By Sirquil
#78223 Thank you schufti.

Think I have resolved the issue tonight by using the readYear function after clearing the totalMonth to zero.

I was challenged by a friend to find a way to monitor his furnace on-time minutes and to provide a web interface. This is what I have so far...

Every time furnace runs --elapsed time is logged to "Total Minutes for Day." "Total Time for MONTH" and "Total Minutes for Year" ar; only update once when newDay function is called. This is being done to minimize write cycles. If DATE from "GetDateTime" function equals days from numberDays function, then "Total Minutes for the MONTH gets reset to zero.

Still have some debugging left with the web interface.

After 23 revisions; needed a second set of eyes and a little encouragement. Thank you.

Update 09/15/2018:

Version 24 fixed and testing further over a few days; as newDay function only runs at 23:59:58. Simulation runs correct.

William
Attachments
Version 24 of project file. Fixed issue with "Total minutes for Year."
(7.92 KiB) Downloaded 2 times