The ESP8266 SPI implementation has a 'writePattern' function that
writes a repeating sequence (in this case a solid colour) to the SPI
port. This fills up the FIFO and increases the bus utilisation.
Using this for clearing the screen cuts the demo run time from 4721 ms
to 3601 ms. Also using this for the fast lines cuts the run time to
3424 ms.
Signed-off-by: Michael Hope <mlhx@google.com>
If the hardware supports it, send 16 bits at a time. This is
worthwhile on chips that have a FIFO like the ESP8266 as it cuts the
demo render time from 6083 ms to 4721 ms.
Signed-off-by: Michael Hope <mlhx@google.com>
Refactor the chip and data pins to generic functions. Add support for
controlling CS and RS via the standard digitalWrite() functions. Add
support for hardware SPI only devices.
Signed-off-by: Michael Hope <mlhx@google.com>