M5GFX icon indicating copy to clipboard operation
M5GFX copied to clipboard

M5 core ink display show dimmer content

Open linxcow opened this issue 2 years ago • 2 comments

I've written an app on the coreink using M5GFX that displays data on the screen.

Sometimes if i press te powerbutton or wakeup from sleep the black pixels go briefly dark and display the same data a bit dimmer.

It seems the refresh process sometimes behaves oddly with some weird result. Sometimes during the last step in the refresh process the contents of the display gets a bit dimmer. ( see picture) I tried the 4 different edp modes but all with the same endresults (sometimes good sometimes dim)

afbeelding

What could be the problem? Do i need to disable M5 eink when using M5GFX like this :

 M5.begin(false , true , true);

or shouldnt it matter?

            display.begin();
            display.setEpdMode(epd_mode_t::epd_fastest);
              
            display.startWrite();
            display.fillScreen(TFT_WHITE);
            display.setTextColor(TFT_BLACK);
            
            display.setFont(&fonts::FreeMonoBold18pt7b);
            display.drawString(ipStr, 1,10);
            
            char batStr[32] = { '\0' }; // initialize with all zeroes
            sprintf(batStr,"B:%.3fV" ,getBatVoltage() ); 
            display.drawString(batStr, 5,50);
          
            char counterStr[32] = { '\0' }; // initialize with all zeroes
            sprintf(counterStr,"%05d" , esp_random() % 99999 ); 
            display.setFont(&fonts::DejaVu56);
            display.drawString(counterStr, 5,100);
          
            display.setFont(&fonts::FreeMonoBold12pt7b);
            display.drawString("Rain & cloudy", 5,170);
            
            display.endWrite();
            delay(250);   // Give Serial.print statements time to show stuff in monitor
            M5.shutdown(120);

linxcow avatar Aug 19 '23 12:08 linxcow

Hello, @linxcow Please try using the powerSaveOn function before using shutdown.

display.powerSaveOn();
delay(250);   // Give Serial.print statements time to show stuff in monitor
M5.shutdown(120);

lovyan03 avatar Aug 20 '23 01:08 lovyan03

Thank you , I have tried your suggestion and for the moment the problem doesnt occur anymore.

Can you explain what could have been going on?

linxcow avatar Aug 20 '23 10:08 linxcow