You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Simply using Font size 1 crashes everything. Repeatedly. All I need to do is switch to font size 2 and the crashes stop. This makes no sense to me and I can't even trace it it. The farthest I get is the decodeUTF8 section of code but just calling that alone causes the crash...so I'm stuck.
I should also note the tft.print() causes the same crash...
So basically, I cannot use Font size 1 without crashing my devices here. The strange thing is that this was not a problem until recently. Maybe it is caused by an update from espressif? I'm not sure. Either wayt, the decodeUtf8 function is purely a TFT_eSPI function. I even added the following null checks to the top of the functions to see if it would help:
uint16_t TFT_eSPI::decodeUTF8(uint8_t c)
{
if (NULL == c) return 0; //ADDED THIS
AND
uint16_t TFT_eSPI::decodeUTF8(uint8_t *buf, uint16_t *index, uint16_t remaining)
{
if (NULL == &buf) return 0; //ADDED THIS
...sadly, it does not. I'm currently stuck and am running out of ideas. My current idea is to search for another very small font to include and use it instead to bypass this issue.
Again, if I change tft.drawString(disp, 0, 0, 1); to tft.drawString(disp, 0, 0, 2);, the crash no longer happens. Also, If try even something simpler like tft.drawString(d"Test", 0, 0, 1); it STILL crashes. 😢
Any other ideas or thoughts would be greatly appreciated. :)
The text was updated successfully, but these errors were encountered:
As an aside, I am now using FreeFont FM9 without incident here in the same code with no crashes. I still just don't get it; if font 1 was somehow not compiled with the program, it should crash immediately. Instead, it actually works(shows the text!)...for an indeterminate amount of time, before creating it's own untimely demise.
Simply using Font size 1 crashes everything. Repeatedly. All I need to do is switch to font size 2 and the crashes stop. This makes no sense to me and I can't even trace it it. The farthest I get is the decodeUTF8 section of code but just calling that alone causes the crash...so I'm stuck.
I should also note the tft.print() causes the same crash...
MC: ESP32 S3 N16R8
TFT: 9341 w.8" with touch (XPT 2046)
Here's my setup for the 9431 TFT:
And here's the psuedo code I used to test this:
This is the error that I get. Mind you, this does not happen every time but I have tried on multiple MCU's all with the same result now:
Ignoring line numbers for main(because I basically bypassed thousands of lines of code to narrow this down), here's the backtrace:
So basically, I cannot use Font size 1 without crashing my devices here. The strange thing is that this was not a problem until recently. Maybe it is caused by an update from espressif? I'm not sure. Either wayt, the decodeUtf8 function is purely a TFT_eSPI function. I even added the following null checks to the top of the functions to see if it would help:
AND
...sadly, it does not. I'm currently stuck and am running out of ideas. My current idea is to search for another very small font to include and use it instead to bypass this issue.
Again, if I change
tft.drawString(disp, 0, 0, 1);
totft.drawString(disp, 0, 0, 2);
, the crash no longer happens. Also, If try even something simpler liketft.drawString(d"Test", 0, 0, 1);
it STILL crashes. 😢Any other ideas or thoughts would be greatly appreciated. :)
The text was updated successfully, but these errors were encountered: