I've had this issue with both a Arduino Leo and an A-Star 32U4 Prime SV.
Have attached the code.
The code displays a face and text on a SSD1306 OLED 128x64 screen thru the i2C bus. It is based on some C code I wrote for the TI CC3200 many years ago that is still working on those platforms.
The issue is, if I activate the text section and the eyes section of the code at the same time the process shows random pixels on the screen, locks up the process and breaks the bootloader port. I can run one or the other without a problem, but they won't run at the same time.
The forum supports code tags. Please take some time to read the sticky posts at the top of every forum subsection on how to properly ask questions and post the things members need to understand the problem you’re trying to solve.
Thanks for the reply. I tried using strlen and it still breaks.
The text processing function handles the \0 array ending anyway.Plus the text code runs, except when the eyes code is included.
I even wrote another quick sketch that randomly positions the text on the screen in the loop section and it runs as expected.
The "code breaking the bootloader port" seems to be a "feature" of the whole system.
I've seen posts and solutions starting several years ago to the present, on almost all the boards.
I am just starting out playing around with the Arduino platforms, though I've been writing code in C for RTOS for embedded systems for decades.
Any other suggestions are welcome.