user32820: I have edited the adafruit ST7735 library so that it supports esp-32.I made some edits in Adafruit_ST7735.h file. which are as follows.

The code works fine but I had expected the screen to work faster with esp-32(due to higher processing power) but it does not do that.
I checked the time for fill screen operation for esp-32 and arduin mega. They come out to be almost the same. (around 0.12 seconds). Can anyone explain why this is happening and can I increase the speed?

user4143: The ST7735 uses SPI to communicate. It will always be slow compared to parallel connected screens.
The fact that you appear to be using bitbanged SPI (manually toggling IO pins) makes it even slower.
The fastest you will be able to get with that screen will be to use hardware SPI instead (which most likely limits which pins you can use - I am not familiar with the ESP32 though) but that will still be somewhat slow.
If you want really high speed screen updates then you will need a parallel interface screen, ideally a 16-bit parallel interface screen. However, for that you need around 20 IO pins to drive it.

32820: <p>I have edited the adafruit ST7735 library so that it supports esp-32.I made some edits in Adafruit_ST7735.h file. which are as follows.</p>

<p><a href="https://i.stack.imgur.com/Q3A9Z.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/Q3A9Z.png" alt="the definitions for esp32 should be added as in the picture bellow"></a></p>

<p>The code works fine but I had expected the screen to work faster with esp-32(due to higher processing power) but it does not do that.</p>

<p>I checked the time for fill screen operation for esp-32 and arduin mega. They come out to be almost the same. (around 0.12 seconds). Can anyone explain why this is happening and can I increase the speed?</p>
 4143: <p>The ST7735 uses SPI to communicate. It will always be slow compared to parallel connected screens.</p>

<p>The fact that you appear to be using bitbanged SPI (manually toggling IO pins) makes it even slower.</p>

<p>The fastest you will be able to get with that screen will be to use hardware SPI instead (which most likely limits which pins you can use - I am not familiar with the ESP32 though) but that will still be somewhat slow.</p>

<p>If you want really high speed screen updates then you will need a parallel interface screen, ideally a 16-bit parallel interface screen. However, for that you need around 20 IO pins to drive it.</p>
