While attempting to display a sample of a font on the screen I discovered you cannot directly show characters above 127 with the drawString command. For example:
A couple of characters are shown here (I believe these are 0xC2 and 0xC3 which are specifically managed in DefaultFontTableLookup), but the rest are blank. However if I copy/paste text into my code they seem to show up correctly. This is likely due to differences between ASCII and UTF-8 management, but I don't know enough about how UTF-8 characters work to reliably determine the difference in what the user is requesting.
My solution to this problem was to add a new function to OLEDDisplay.cpp to display specific chars.
Now in the example above you can replace the drawString line with:
display.drawChar(j*8+3, i*10, (char)c);
and all of the upper characters from 128-255 can be displayed individually on the screen.
Maybe someone with more knowledge of the subject will be able to find a better solution, but this should work without breaking any existing functionality.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
While attempting to display a sample of a font on the screen I discovered you cannot directly show characters above 127 with the drawString command. For example:
A couple of characters are shown here (I believe these are 0xC2 and 0xC3 which are specifically managed in DefaultFontTableLookup), but the rest are blank. However if I copy/paste text into my code they seem to show up correctly. This is likely due to differences between ASCII and UTF-8 management, but I don't know enough about how UTF-8 characters work to reliably determine the difference in what the user is requesting.
My solution to this problem was to add a new function to OLEDDisplay.cpp to display specific chars.
To OLEDDisplay.h I added this line:
Now in the example above you can replace the drawString line with:
display.drawChar(j*8+3, i*10, (char)c);
and all of the upper characters from 128-255 can be displayed individually on the screen.Maybe someone with more knowledge of the subject will be able to find a better solution, but this should work without breaking any existing functionality.