@brief Default priority assigned to a `Bus` when registered with the manager. Higher = preferred. The function is `constexpr` so callers can use it in constant expressions if needed. Buses without a registered priority fall back to 0.
| 36 | /// constant expressions if needed. Buses without a registered priority fall |
| 37 | /// back to 0. |
| 38 | constexpr int default_bus_priority(Bus b) FL_NOEXCEPT { |
| 39 | // FORCE-style overrides (FASTLED_ESP32_FORCE_*) are intentionally not |
| 40 | // applied here -- the legacy initChannelDrivers() retains its own |
| 41 | // priority-bumping logic for backward compatibility. This table is the |
| 42 | // baseline used by the new enableDrivers<>() opt-in API. |
| 43 | return |
| 44 | b == Bus::I2S_SPI ? 10 : |
| 45 | b == Bus::LCD_SPI ? 10 : |
| 46 | b == Bus::PARLIO ? 4 : |
| 47 | b == Bus::LCD_RGB ? 3 : |
| 48 | b == Bus::RMT ? 2 : |
| 49 | b == Bus::LCD_CLOCKLESS ? 2 : |
| 50 | b == Bus::I2S ? 1 : |
| 51 | b == Bus::FLEX_IO ? 1 : |
| 52 | b == Bus::OBJECT_FLED ? 1 : |
| 53 | b == Bus::SPI ? 0 : |
| 54 | b == Bus::BIT_BANG ? 0 : |
| 55 | b == Bus::STUB ? 0 : |
| 56 | b == Bus::UART ? -1 : |
| 57 | 0; |
| 58 | } |
| 59 | |
| 60 | } // namespace fl |
| 61 |
no outgoing calls
no test coverage detected