I want to use custom font in my application, and I'm following this App Note "BRT_AN_014_FT81X_Simple_PIC_Library_Examples".
In the section 6.2, I got a little confused, when it calculate the raw data address, why the value is negative?
(Address of data in RAM_G) + (Metric Block size) – (32 characters worth of (stride * height))
1000 + 148 – (32*(3*25))
= 1000 + 148 – 2400
= -1252
and then -1252 is fed to BITMAP_SOURCE
API_LIB_BeginCoProList();
API_CMD_DLSTART();
API_CLEAR_COLOR_RGB(0, 0, 0);
API_CLEAR(1,1,1);
API_BITMAP_HANDLE(14);
API_BITMAP_SOURCE(-1252);
API_BITMAP_LAYOUT(L1,3,25);
API_BITMAP_SIZE(NEAREST, BORDER, BORDER, 18,25);
The BITMAP_SOURCE command has 22-bit address as parameter, so -1252 will be 0x3FFB1C after clipped to 22-bit address.
But the RAM_G on FT81x device only from 0x000000 to 0x0FFFFF, it's out of range.
Can help me understand this?
Another thing is, after we set the custom font, and we want to call CMD_TEXT or CMD_NUMBER and use the custom font,
do the character that we use must be included in the converted character in our font?
For example i call CMD_TEXT with text string "abc", but my custom font is in UTF-8 format and i don't have 'a', 'b', 'c' in the converted font index, will it work?
Thank you