@@ -22,9 +22,18 @@ Arduino_ESP32RGBPanel *rgbpanel = new Arduino_ESP32RGBPanel(
2222 );
2323
2424Arduino_RGB_Display *gfx = new Arduino_RGB_Display(
25+ // 2.1" 480x480 round display
2526 480 /* width */ , 480 /* height */ , rgbpanel, 0 /* rotation */ , true /* auto_flush */ ,
2627 expander, GFX_NOT_DEFINED /* RST */ , TL021WVC02_init_operations, sizeof (TL021WVC02_init_operations));
2728
29+ // 2.8" 480x480 round display
30+ // 480 /* width */, 480 /* height */, rgbpanel, 0 /* rotation */, true /* auto_flush */,
31+ // expander, GFX_NOT_DEFINED /* RST */, TL028WVC01_init_operations, sizeof(TL028WVC01_init_operations));
32+
33+ // 3.4" 480x480 square display
34+ // 480 /* width */, 480 /* height */, rgbpanel, 0 /* rotation */, true /* auto_flush */,
35+ // expander, GFX_NOT_DEFINED /* RST */, tl034wvs05_b1477a_init_operations, sizeof(tl034wvs05_b1477a_init_operations));
36+
2837uint16_t *colorWheel;
2938
3039void setup (void )
@@ -59,45 +68,11 @@ void setup(void)
5968
6069uint8_t allpins[] = {SS, SCK, MOSI, MISO, A1, A0};
6170
62- bool test = false ;
6371void loop ()
6472{
65- if (!test) {
66- gfx->draw16bitRGBBitmap (0 , 0 , colorWheel, 480 , 480 );
67- delay (100 );
68- return ;
69- }
70- Serial.println (" ** Test Display!" );
71- gfx->fillScreen (BLACK);
72- gfx->setTextSize (5 );
73- gfx->setTextColor (WHITE);
74- gfx->setTextWrap (false );
75- gfx->setCursor (100 , gfx->height () / 2 - 175 );
76- gfx->println (" Display OK!" );
77-
78- if (! TB.testpins (MOSI, A1, allpins, sizeof (allpins))) return ;
79- if (! TB.testpins (MISO, SS, allpins, sizeof (allpins))) return ;
80- if (! TB.testpins (SCK, A0, allpins, sizeof (allpins))) return ;
81- gfx->setCursor (100 , gfx->height () / 2 - 125 );
82- gfx->println (" GPIO OK!" );
83-
84- gfx->setCursor (100 , gfx->height () / 2 - 75 );
85- gfx->println (" I2C OK!" );
86-
87- gfx->setCursor (100 , gfx->height () / 2 - 25 );
88- gfx->setTextColor (RED);
89- gfx->println (" RED" );
90-
91- gfx->setCursor (100 , gfx->height () / 2 + 25 );
92- gfx->setTextColor (GREEN);
93- gfx->println (" GREEN" );
94-
95- gfx->setCursor (100 , gfx->height () / 2 + 75 );
96- gfx->setTextColor (BLUE);
97- gfx->println (" BLUE" );
98-
99- Serial.println (" ** TEST OK!" );
100- test = false ;
73+ gfx->draw16bitRGBBitmap (0 , 0 , colorWheel, 480 , 480 );
74+ delay (100 );
75+ return ;
10176}
10277
10378// https://chat.openai.com/share/8edee522-7875-444f-9fea-ae93a8dfa4ec
0 commit comments