Issue with ESP32 and ST7798V display

Here is a suggestion, modify your "Adafruit ST7735 and ST7789 Library" as follow:

in Adafruit_ST7735_and_ST7789_Library/Adafruit_ST77xx.h add:

#define ST77XX_MADCTL_BGR 0x08
#define ST77XX_MADCTL_MH 0x04

(for instance below the #define ST77XX_MADCTL_RGB 0x00)

in Adafruit_ST7735_and_ST7789_Library/Adafruit_ST7789.cpp go to the method void Adafruit_ST7789::setRotation() and increase the case number (from 3) to 4 :

rotation = m & 4; // can't be higher than 4

then add the following case:

  case 4:
    madctl = ST77XX_MADCTL_MY | ST77XX_MADCTL_MH | ST77XX_MADCTL_BGR;
    _xstart = _colstart;
    _ystart = _rowstart;
    _width = windowWidth;
    _height = windowHeight;
    break;

in your sketch code in the setup() function, just after the tft.init() call add:

tft.invertDisplay(false);
tft.setRotation(4);

Thank you anaudesigns! The library mods solved my problem. I was driving a 2.8" TFT SPI 240x320 v1.2 display with an ESP32-C3 Super mini and Adafruit TFT_SS7789 driver and had the same mirrored images (and text) problem. I also had to set the tft.invertDisplay() to false.
I had been using the same display with the ILI9341 driver on a Nano with no problems, but that driver refused to allow setting the SPI clocking frequency (stubbornly stuck at 40MHz so the clock was a beautiful sine-wave). I've easily changed the clock divider with several other drivers but not with the ILI9341. Anyway, the ILI9341 test programs I already had for another display work fine except for the mirror image, but now you've given me the fix for that. Thanks again.

Take a look at how i used my aliepress 320 x 240 ST7789 with the "Adafruit ST7735 and ST7789 Library" and "TFT_eSPI Library"....also i used it with an ESP32 S3. Worked perfectly fine.