Skip to content

Commit

Permalink
Remove reboot and mDNS reset
Browse files Browse the repository at this point in the history
  • Loading branch information
lbussy committed Mar 31, 2020
1 parent 137ff8c commit 9ae6871
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 32 deletions.
20 changes: 0 additions & 20 deletions src/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -176,26 +176,6 @@ SOFTWARE. */
//
//////////////////////////////////////////////////////////////////////////

//////////////////////////////////////////////////////////////////////////
//
// Reset mDNS to help the connectiviy issues
//
#ifndef MDNSTIMER
#define MDNSTIMER 3600
#endif
//
//////////////////////////////////////////////////////////////////////////

//////////////////////////////////////////////////////////////////////////
//
// Reboot timer
//
#ifndef REBOOTTIMER
#define REBOOTTIMER 86400
#endif
//
//////////////////////////////////////////////////////////////////////////

//////////////////////////////////////////////////////////////////////////
//
// Default Bubble name
Expand Down
15 changes: 3 additions & 12 deletions src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -62,11 +62,11 @@ void loop() {
Ticker getThatVersion;
doPoll();
getThatVersion.attach(60, doPoll);
Bubbles *bubble = Bubbles::getInstance();

// Bubble loop to create 60 second readings
Ticker bubUpdate;
bubUpdate.attach(BUBLOOP, [bubble](){ bubble->update(); });
bubbles.update();
bubUpdate.attach(BUBLOOP, setDoBubUpdate);

// Target timer
Ticker urlTarget;
Expand All @@ -76,19 +76,10 @@ void loop() {
Ticker bfTimer;
bfTimer.attach(config.brewersfriend.freq * 60, setDoBFTarget);

// Brewer's friend timer
// Brewfather timer
Ticker brewfTimer;
brewfTimer.attach(config.brewfather.freq * 60, setDoBrewfTarget);

// mDNS Reset Timer - Helps avoid the host not found issues
Ticker mDNSTimer;
mDNSTimer.attach(MDNSTIMER, mdnsreset);

// Reboot timer - I wish controllers could be counted on to be more
// stable but at least it only takes a few seconds.
Ticker rebootTimer;
rebootTimer.attach(REBOOTTIMER, reboot);

while (true) {
// Handle semaphores - No radio work in a Ticker!
tickerLoop();
Expand Down

0 comments on commit 9ae6871

Please sign in to comment.