FirstPixelBitCleanup

The first bit on some esp8266 will get elongated, this change has shown
to cause this to be fixed.
This commit is contained in:
Makuna
2015-05-28 11:22:05 -07:00
parent 4746c35db4
commit 503c7e3d7b

View File

@@ -90,6 +90,9 @@ static inline void send_pixels_800(uint8_t* pixels, uint8_t* end, uint8_t pin)
uint8_t subpix;
uint32_t cyclesStart;
// this set low will help cleanup the first bit
GPIO_REG_WRITE(GPIO_OUT_W1TC_ADDRESS, pinRegister);
cyclesStart = ESP.getCycleCount() + CYCLES_800;
while (pixels < end)
{
@@ -140,6 +143,9 @@ static inline void send_pixels_400(uint8_t* pixels, uint8_t* end, uint8_t pin)
uint8_t subpix;
uint32_t cyclesStart;
// this set low will help cleanup the first bit
GPIO_REG_WRITE(GPIO_OUT_W1TC_ADDRESS, pinRegister);
cyclesStart = ESP.getCycleCount() + CYCLES_400;
while (pixels < end)
{