FastLED 3.10.8
Loading...
Searching...
No Matches

◆ waitForReady()

bool fl::ChannelManager::waitForReady ( u32 timeoutMs = 1000)

Wait for all drivers to become READY.

Note
Polls drivers in a loop, calling async_run() and yielding with minimal delay
Uses time-based delays to avoid busy-waiting while allowing async tasks to run

Definition at line 563 of file manager.cpp.hpp.

563 {
564 bool ok = waitForCondition([this]() {
566 }, timeoutMs);
567 if (!ok) {
568 FL_ERROR("ChannelManager: Timeout occurred while waiting for READY state");
569 }
570 return ok;
571}
IChannelDriver::DriverState poll() FL_NO_EXCEPT
Poll all registered drivers and return aggregate state.
bool waitForCondition(Condition condition, u32 timeoutMs=1000) FL_NO_EXCEPT
Wait until a condition is met, with check-pump-delay logic.
#define FL_ERROR(...)
Definition log.h:373
Value state
Current driver state.
Definition driver.h:176
@ READY
Hardware idle; ready to accept new transmissions.
Definition driver.h:170

References FL_ERROR, fl::FL_NO_EXCEPT, poll(), fl::IChannelDriver::DriverState::READY, and waitForCondition().

Referenced by addDriverSlow(), clearAllDrivers(), onBeginFrame(), reset(), CFastLED::wait(), and CFastLED::wait().

+ Here is the call graph for this function:
+ Here is the caller graph for this function: