microsoft / pxt-neopixel

A Neo-Pixel package for pxt-microbit
https://makecode.microbit.org/pkg/microsoft/pxt-neopixel
MIT License
58 stars 141 forks source link

Incorrect values returned from the power() method #60

Open microbit-robert opened 2 years ago

microbit-robert commented 2 years ago

The values returned from the power() method appear to rise too rapidly as LEDs are successively lit. This value also tops out well before all LEDs in a strip have been lit.

Please see the serial output in this example: https://makecode.microbit.org/31482-02041-35523-64723

ledoffset is defined inside the power() method but never used. I presume that this variable should be used in the following line: p += this.buf[i + j]; as observed elsewhere in the code?