FastLED 3.9.15
Loading...
Searching...
No Matches

◆ waitForReady()

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

Wait for driver to become READY.

Parameters
timeoutMsOptional timeout in milliseconds (0 = no timeout)
Returns
true if driver became READY, false if timeout occurred

Definition at line 63 of file driver.cpp.hpp.

63 {
64 // wait until the driver is in a READY state.
65 bool ok = waitForCondition([this]() {
66 auto state = poll();
68 }, timeoutMs);
69 return ok;
70}
TestState state
bool waitForCondition(Condition condition, u32 timeoutMs=1000) FL_NOEXCEPT
virtual DriverState poll() FL_NOEXCEPT=0
Query driver state and perform maintenance.
@ READY
Hardware idle; ready to accept new transmissions.
Definition driver.h:167

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

Referenced by canHandle(), and waitDone().

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