WS2812 remove waits for RMT and SPI (#22617)

This commit is contained in:
s-hadinger 2024-12-09 22:45:23 +01:00 committed by GitHub
parent a12c934a4b
commit c1834bd898
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 0 additions and 12 deletions

View File

@ -186,12 +186,6 @@ extern "C" {
pixels_size = strip->PixelCount() * strip->PixelSize(); pixels_size = strip->PixelCount() * strip->PixelSize();
update_completed = strip->CanShow(); update_completed = strip->CanShow();
} }
// Wait for RMT/I2S to complete fixes distortion due to analogRead
// 1ms is needed for 96 bytes
if (!update_completed) {
SystemBusyDelay((pixels_size + 95) / 96);
}
} }
break; break;
case 3: // # 03 : CanShow void -> bool case 3: // # 03 : CanShow void -> bool

View File

@ -186,12 +186,6 @@ long wsmap(long x, long in_min, long in_max, long out_min, long out_max) {
void Ws2812LibStripShow(void) { void Ws2812LibStripShow(void) {
strip->Show(); strip->Show();
#if defined(USE_WS2812_DMA) || defined(USE_WS2812_RMT) || defined(USE_WS2812_I2S)
// Wait for DMA/RMT/I2S to complete fixes distortion due to analogRead
// delay((Settings->light_pixels >> 6) +1); // 256 / 64 = 4 +1 = 5
SystemBusyDelay( (Settings->light_pixels + 31) >> 5); // (256 + 32) / 32 = 8
#endif
} }
void Ws2812StripShow(void) void Ws2812StripShow(void)