|
ESPHome 2026.11.0-dev
|
Leaves a stretch of the current loop pass out of the blocking warning. More...
#include <application.h>
Public Member Functions | |
| UnavoidableBlockingScope () | |
| ~UnavoidableBlockingScope () | |
| UnavoidableBlockingScope (const UnavoidableBlockingScope &)=delete | |
| UnavoidableBlockingScope & | operator= (const UnavoidableBlockingScope &)=delete |
Leaves a stretch of the current loop pass out of the blocking warning.
Only for work that cannot be made shorter or split across passes: radio bring-up, a first network connect, a key generation. Work that could be cached, deferred, polled or turned into a state machine stays outside, so the warning keeps finding it.
Affects only work timed by LoopBlockingGuard: loop() and scheduler callbacks, not setup(). Main loop task only. The watchdog is not fed, so pair long work with watchdog::WatchdogManager. Scopes may nest. Afterwards App.get_loop_component_start_time() can be earlier than a millis() read taken before the scope; time the work with millis() at both ends.
UnavoidableBlockingScope scope; this->generate_key_();
Definition at line 651 of file application.h.
|
inline |
Definition at line 653 of file application.h.
|
inline |
Definition at line 654 of file application.h.
|
delete |
|
delete |