Skip to content

Commit

Permalink
Fix push button callbacks
Browse files Browse the repository at this point in the history
(cherry picked from commit cfec13f71d8ab3e780338a2dd968a32d672634a0)
  • Loading branch information
mathieucarbou committed Aug 5, 2024
1 parent ab8336c commit 5f565be
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/Website.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -194,13 +194,13 @@ void YaSolR::WebsiteClass::initLayout() {

_boolConfig(_debugMode, KEY_ENABLE_DEBUG);

_energyReset.attachCallback([](int32_t value) {
_energyReset.attachCallback([]() {
jsy.resetEnergy();
pzemO1.resetEnergy();
pzemO2.resetEnergy();
});
_reset.attachCallback([](int32_t value) { resetTask.resume(); });
_restart.attachCallback([](int32_t value) { restartTask.resume(); });
_reset.attachCallback([]() { resetTask.resume(); });
_restart.attachCallback([]() { restartTask.resume(); });

// network (config)

Expand Down Expand Up @@ -409,7 +409,7 @@ void YaSolR::WebsiteClass::initLayout() {
_pidDTermHistory.setTab(&_pidTab);
_pidReset.setTab(&_pidTab);

_pidReset.attachCallback([this](int32_t value) {
_pidReset.attachCallback([this]() {
resetPID();
updatePID();
});
Expand Down

0 comments on commit 5f565be

Please sign in to comment.