Skip to content

Commit

Permalink
Save BPM on each tick
Browse files Browse the repository at this point in the history
  • Loading branch information
lbussy committed Nov 28, 2020
1 parent 61d5a5d commit 4a0cc63
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 1 deletion.
1 change: 1 addition & 0 deletions src/bubbles.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ bool Bubbles::update()
bubAvg.push(lastBpm);
sampleSize = tempVesAvg.size();

saveBpm();
return true;
}

Expand Down
3 changes: 3 additions & 0 deletions src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -107,20 +107,23 @@ void loop()
urlTarget.detach();
urlTarget.attach(config.urltarget.freq * 60, setDoURLTarget);
config.urltarget.update = false;
saveConfig();
}
if (config.brewersfriend.update)
{
Log.notice(F("Resetting Brewer's Friend frequency timer to %l minutes." CR), config.brewersfriend.freq);
bfTimer.detach();
bfTimer.attach(config.brewersfriend.freq * 60, setDoBFTarget);
config.brewersfriend.update = false;
saveConfig();
}
if (config.brewfather.update)
{
Log.notice(F("Resetting Brewer's Friend frequency timer to %l minutes." CR), config.brewersfriend.freq);
bfTimer.detach();
bfTimer.attach(config.brewfather.freq * 60, setDoBrewfTarget);
config.brewfather.update = false;
saveConfig();
}
serialLoop();
yield();
Expand Down
1 change: 0 additions & 1 deletion src/webserver.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ SOFTWARE. */
#define USE_LITTLEFS
#endif

#include "resetreasons.h"
#include "wifihandler.h"
#include "execota.h"
#include "bubbles.h"
Expand Down

0 comments on commit 4a0cc63

Please sign in to comment.