sajattack / st7735-lcd-rs

Rust library for displays using the ST7735 driver
https://docs.rs/st7735-lcd
MIT License
37 stars 28 forks source link

Accelerate rectangle and image drawing #9

Closed TheZoq2 closed 4 years ago

TheZoq2 commented 4 years ago

The library had quite a bit of overhead from the set_pixel calls. This uses the faster method of specifying an area and then sending all the pixels in sequence.

Some benchmarks show a speed increase of ~20 times on an stm32f103

I'm not sure what a good buffer size is. 32 seems to give a nice speed improvement, but I imagine it becoming slightly faster with higher buffer sizes, at the cost of more RAM of course

sajattack commented 4 years ago

Thanks!