|
FastLED 3.9.15
|
| bool autoResearchSetExclusiveDriverByName | ( | const char * | name | ) |
AutoResearch-style helper: set an exclusive driver by name.
| name | Driver name (case-sensitive — must match an IChannelDriver::getName() value) |
AutoResearch resolves driver names at runtime from RPC/JSON payloads, so it can't use the typed FastLED.setExclusiveDriver(fl::Bus) form. This wrapper forwards to ChannelManager::instance().setExclusiveDriverByName(name).
Precondition: The caller must already have enrolled every available driver via FastLED.enableAllDrivers() (typically once in setup()). This helper deliberately does NOT call enableAllDrivers() itself — calling it per-iteration in a discovery loop re-adds every driver each time, triggering ChannelManager's "Replacing existing driver" path and resetting state mid-test (#2469).
For built-in driver code that knows its driver at compile time, use FastLED.setExclusiveDriver(fl::Bus::X) instead (typo-safe).
Definition at line 27 of file AutoResearchHelpers.cpp.
References fl::ChannelManager::instance(), and fl::ChannelManager::setExclusiveDriverByName().
Referenced by autoresearch::maybeRegisterStubAutorun(), AutoResearchRemoteControl::registerFunctions(), AutoResearchRemoteControl::runSingleTestImpl(), and testDriver().
Here is the call graph for this function:
Here is the caller graph for this function: