MCPcopy Create free account
hub / github.com/FastLED/FastLED / cleanup

Method cleanup

src/platforms/esp/32/drivers/parlio/parlio_engine.cpp.hpp:428–446  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

426}
427
428void ParlioEngine::cleanup() FL_NOEXCEPT {
429#ifdef FL_DEBUG
430 // Clean up debug task only - singleton remains alive
431 // This is called before DLL unload to properly join threads
432 if (mDebugTask.is_valid()) {
433 // Signal task to exit by setting flags to false
434 if (mIsrContext) {
435 mIsrContext->mTransmitting.store(false, fl::memory_order_release);
436 mIsrContext->mStreamComplete.store(false, fl::memory_order_release);
437 }
438 // Give task time to self-delete (task sleeps for 500ms)
439 if (mPeripheral) {
440 mPeripheral->delay(600);
441 }
442 // Cancel the task to release resources
443 mDebugTask.cancel();
444 }
445#endif
446}
447
448#ifdef FL_DEBUG
449//=============================================================================

Callers

nothing calls this directly

Calls 4

cancelMethod · 0.80
is_validMethod · 0.45
storeMethod · 0.45
delayMethod · 0.45

Tested by

no test coverage detected