Creating new fonts for Pokitto - part 2 - exporting from font editor to a C file

#1 Correct settings for export:

#2 Add information about the font (width, height, start character, only caps? (no = 0 or yes = 1)) to the first line of the array in the C file

original output:

const unsigned short Adventurer12x16[] = {
0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // Code for char
0x04, 0x00, 0x10, 0xFC, 0x1B, 0xFE, 0x0B, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // Code for char !
0x06, 0x02, 0x00, 0x1E, 0x00, 0x0E, 0x00, 0x02, 0x00, 0x1E, 0x00, 0x0E, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // Code for char "

modified for Pokitto:

const unsigned char fontAdventurer[] = {
12,16,32,0, // width, height, start character, only caps
0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // Code for char
0x04, 0x00, 0x10, 0xFC, 0x1B, 0xFE, 0x0B, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // Code for char !
0x06, 0x02, 0x00, 0x1E, 0x00, 0x0E, 0x00, 0x02, 0x00, 0x1E, 0x00, 0x0E, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // Code for char "

#3 Add your font file (I use .cpp to avoid name mangling problems) to the project

OPTIONAL:

#4 Add name of your font to PokittoFonts.h in the POKITTO_CORE directory

#ifndef POK_FONTS_H
#define POK_FONTS_H

#include “Pokitto_settings.h”

extern const unsigned char fontMini[];
extern const unsigned char fontDonut[];
extern const unsigned char fontDragon[];
extern const unsigned char fontKarateka[];
extern const unsigned char fontKoubit[];
extern const unsigned char fontRunes[];
extern const unsigned char fontTight[];
extern const unsigned char fontTiny[];
extern const unsigned char fontAdventurer[];
extern const unsigned char font5x7[];
extern const unsigned char font3x5[];
extern const unsigned char font3x3[];
extern const unsigned char fontMyCustomFont[];

1 Like

Followed the steps with Monoliko. You can get the .cpp file here

As I am a coding newbie, it would be awesome is someone could run in in an emulator to see if it works correctly. Thanks in advance!

I’ve follow the steps here and in part 1. Code compile successful but I get strange artifacts on rendering:

#include "PokittoFonts.h"
const unsigned char Consolas12x20[] = {
        12,20,32,0, // width, height, start character, only caps
        0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char
        0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xDF, 0x01, 0xF8, 0xDF, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char !
        0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF8, 0x00, 0x00, 0xF8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF8, 0x00, 0x00, 0xF8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char "
        0x0B, 0x00, 0x18, 0x00, 0x80, 0x19, 0x00, 0x80, 0xFD, 0x01, 0xF0, 0xFF, 0x01, 0x80, 0x19, 0x00, 0x80, 0x19, 0x00, 0x80, 0xFD, 0x01, 0xF0, 0xFF, 0x01, 0xF0, 0x1B, 0x00, 0x80, 0x19, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00,  // Code for char #
        0x0A, 0x00, 0x00, 0x00, 0xC0, 0xC1, 0x00, 0xE0, 0x83, 0x01, 0x30, 0x87, 0x01, 0x30, 0xFE, 0x07, 0xF0, 0xFF, 0x01, 0xFC, 0x8C, 0x01, 0x30, 0xCC, 0x01, 0x30, 0xF8, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char $
        0x0C, 0xF0, 0x00, 0x01, 0xF8, 0x81, 0x01, 0x98, 0xE1, 0x00, 0x98, 0x31, 0x00, 0xF8, 0x19, 0x00, 0xF0, 0x0E, 0x00, 0x00, 0xF3, 0x00, 0xC0, 0xF9, 0x01, 0x60, 0x98, 0x01, 0x30, 0x98, 0x01, 0x18, 0xF8, 0x01, 0x00, 0xF0, 0x00,  // Code for char %
        0x0C, 0x00, 0x00, 0x00, 0x00, 0x78, 0x00, 0xF0, 0xFC, 0x00, 0xF0, 0xC7, 0x01, 0x18, 0x87, 0x01, 0x18, 0x8F, 0x01, 0x18, 0x9D, 0x01, 0xF8, 0xF1, 0x00, 0xF0, 0xF0, 0x00, 0x00, 0xFC, 0x01, 0x00, 0x9C, 0x01, 0x00, 0x00, 0x01,  // Code for char &
        0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF8, 0x00, 0x00, 0xF8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char '
        0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7F, 0x00, 0xC0, 0xFF, 0x01, 0xE0, 0x80, 0x07, 0x38, 0x00, 0x0E, 0x1C, 0x00, 0x0C, 0x08, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char (
        0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x08, 0x1C, 0x00, 0x0C, 0x38, 0x00, 0x0E, 0xE0, 0x80, 0x03, 0xC0, 0xFF, 0x01, 0x00, 0x7F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char )
        0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x02, 0x00, 0x40, 0x01, 0x00, 0x40, 0x01, 0x00, 0xF8, 0x0F, 0x00, 0x40, 0x01, 0x00, 0x40, 0x01, 0x00, 0x20, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char *
        0x0B, 0x00, 0x00, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x0C, 0x00, 0xC0, 0xFF, 0x00, 0xC0, 0xFF, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x00, 0x00,  // Code for char +
        0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x08, 0x00, 0xC0, 0x0C, 0x00, 0xC0, 0x0F, 0x00, 0x80, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char ,
        0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char -
        0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xC0, 0x01, 0x00, 0xC0, 0x01, 0x00, 0xC0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char .
        0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x07, 0x00, 0xE0, 0x01, 0x00, 0x78, 0x00, 0x00, 0x1E, 0x00, 0xC0, 0x03, 0x00, 0xF0, 0x00, 0x00, 0x38, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char /
        0x0B, 0x00, 0x00, 0x00, 0x80, 0x3F, 0x00, 0xC0, 0xFF, 0x00, 0xE0, 0xF8, 0x00, 0x30, 0x8C, 0x01, 0x30, 0x8C, 0x01, 0x30, 0x86, 0x01, 0x30, 0x86, 0x01, 0xE0, 0xE3, 0x00, 0xE0, 0x7F, 0x00, 0x80, 0x3F, 0x00, 0x00, 0x00, 0x00,  // Code for char 0
        0x0A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xC0, 0x80, 0x01, 0x60, 0x80, 0x01, 0x20, 0x80, 0x01, 0xF0, 0xFF, 0x01, 0xF0, 0xFF, 0x01, 0x00, 0x80, 0x01, 0x00, 0x80, 0x01, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char 1
        0x0B, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x60, 0xC0, 0x01, 0x30, 0xE0, 0x01, 0x30, 0xB0, 0x01, 0x30, 0x98, 0x01, 0x70, 0x8C, 0x01, 0xE0, 0x87, 0x01, 0xC0, 0x83, 0x01, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00,  // Code for char 2
        0x0B, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x80, 0x01, 0x30, 0x80, 0x01, 0x30, 0x86, 0x01, 0x30, 0x86, 0x01, 0x30, 0x86, 0x01, 0x30, 0x87, 0x01, 0xE0, 0xCD, 0x00, 0xE0, 0xFD, 0x00, 0x00, 0x78, 0x00, 0x00, 0x00, 0x00,  // Code for char 3
        0x0B, 0x00, 0x38, 0x00, 0x00, 0x3C, 0x00, 0x00, 0x36, 0x00, 0x00, 0x33, 0x00, 0xC0, 0x31, 0x00, 0x60, 0x30, 0x00, 0x30, 0x30, 0x00, 0xF0, 0xFF, 0x01, 0xF0, 0xFF, 0x01, 0x00, 0x30, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00,  // Code for char 4
        0x0A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF0, 0x87, 0x01, 0xF0, 0x87, 0x01, 0x30, 0x86, 0x01, 0x30, 0x86, 0x01, 0x30, 0x86, 0x01, 0x30, 0xCE, 0x00, 0x30, 0xFC, 0x00, 0x00, 0x78, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char 5
        0x0A, 0x00, 0x00, 0x00, 0x00, 0x3F, 0x00, 0xC0, 0xFF, 0x00, 0xE0, 0xCC, 0x01, 0x60, 0x86, 0x01, 0x30, 0x86, 0x01, 0x30, 0x86, 0x01, 0x30, 0xCE, 0x01, 0x30, 0xFC, 0x00, 0x00, 0x78, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char 6
        0x0A, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x30, 0x00, 0x00, 0x30, 0x80, 0x01, 0x30, 0xE0, 0x01, 0x30, 0x78, 0x00, 0x30, 0x1E, 0x00, 0xB0, 0x07, 0x00, 0xF0, 0x01, 0x00, 0x70, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char 7
        0x0A, 0x00, 0x00, 0x00, 0xC0, 0x71, 0x00, 0xE0, 0xF9, 0x00, 0x30, 0x8F, 0x01, 0x30, 0x86, 0x01, 0x30, 0x86, 0x01, 0x30, 0x8E, 0x01, 0x30, 0x8F, 0x01, 0xE0, 0xF9, 0x00, 0xE0, 0x70, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char 8
        0x0A, 0x00, 0x00, 0x00, 0xC0, 0x03, 0x00, 0xE0, 0x87, 0x01, 0x70, 0x8E, 0x01, 0x30, 0x8C, 0x01, 0x30, 0x8C, 0x01, 0x30, 0xCC, 0x00, 0x70, 0xE6, 0x00, 0xE0, 0x7F, 0x00, 0x80, 0x1F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char 9
        0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xC3, 0x01, 0x80, 0xC3, 0x01, 0x80, 0xC3, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char :
        0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x08, 0x80, 0xC3, 0x0C, 0x80, 0xC3, 0x0F, 0x80, 0x83, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char ;
        0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x1E, 0x00, 0x00, 0x33, 0x00, 0x80, 0x61, 0x00, 0xC0, 0xC0, 0x00, 0x60, 0x80, 0x01, 0x40, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char <
        0x0A, 0x00, 0x00, 0x00, 0x00, 0x33, 0x00, 0x00, 0x33, 0x00, 0x00, 0x33, 0x00, 0x00, 0x33, 0x00, 0x00, 0x33, 0x00, 0x00, 0x33, 0x00, 0x00, 0x33, 0x00, 0x00, 0x33, 0x00, 0x00, 0x33, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char =
        0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x80, 0x00, 0x60, 0x80, 0x01, 0xC0, 0xC0, 0x00, 0x80, 0x61, 0x00, 0x00, 0x33, 0x00, 0x00, 0x1E, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char >
        0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x18, 0xDE, 0x01, 0x18, 0xDE, 0x01, 0x30, 0xC6, 0x01, 0xF0, 0x07, 0x00, 0xC0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char ?
        0x0B, 0x00, 0xFE, 0x03, 0x80, 0x03, 0x0E, 0x60, 0x78, 0x08, 0x10, 0xFE, 0x00, 0x18, 0xC7, 0x00, 0x08, 0xC3, 0x00, 0x08, 0xC3, 0x00, 0x08, 0x7F, 0x08, 0x18, 0xFF, 0x00, 0x30, 0xC0, 0x00, 0xC0, 0x3F, 0x00, 0x00, 0x00, 0x00,  // Code for char @
        0x0B, 0x00, 0xC0, 0x01, 0x00, 0xF0, 0x01, 0x00, 0x3E, 0x00, 0xC0, 0x37, 0x00, 0xF0, 0x30, 0x00, 0x10, 0x30, 0x00, 0xF0, 0x30, 0x00, 0xC0, 0x37, 0x00, 0x00, 0x3E, 0x00, 0x00, 0xF8, 0x01, 0x00, 0xC0, 0x01, 0x00, 0x00, 0x00,  // Code for char A
        0x0B, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF0, 0xFF, 0x01, 0xF0, 0xFF, 0x01, 0x30, 0x86, 0x01, 0x30, 0x86, 0x01, 0x30, 0x86, 0x01, 0x30, 0x86, 0x01, 0x30, 0xCF, 0x00, 0xE0, 0xFD, 0x00, 0xE0, 0x79, 0x00, 0x00, 0x00, 0x00,  // Code for char B
        0x0B, 0x00, 0x00, 0x00, 0x00, 0x3F, 0x00, 0xC0, 0x7F, 0x00, 0xE0, 0xE0, 0x00, 0x60, 0xC0, 0x01, 0x30, 0x80, 0x01, 0x30, 0x80, 0x01, 0x30, 0x80, 0x01, 0x30, 0x80, 0x01, 0x30, 0x80, 0x01, 0x60, 0xC0, 0x00, 0x00, 0x00, 0x00,  // Code for char C
        0x0B, 0x00, 0x00, 0x00, 0xF0, 0xFF, 0x01, 0xF0, 0xFF, 0x01, 0x30, 0x80, 0x01, 0x30, 0x80, 0x01, 0x30, 0x80, 0x01, 0x30, 0x80, 0x01, 0x70, 0xC0, 0x00, 0xE0, 0xE0, 0x00, 0xC0, 0x7F, 0x00, 0x80, 0x1F, 0x00, 0x00, 0x00, 0x00,  // Code for char D
        0x0A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF0, 0xFF, 0x01, 0xF0, 0xFF, 0x01, 0x30, 0x86, 0x01, 0x30, 0x86, 0x01, 0x30, 0x86, 0x01, 0x30, 0x86, 0x01, 0x30, 0x86, 0x01, 0x30, 0x86, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char E
        0x0A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF0, 0xFF, 0x01, 0xF0, 0xFF, 0x01, 0x30, 0x06, 0x00, 0x30, 0x06, 0x00, 0x30, 0x06, 0x00, 0x30, 0x06, 0x00, 0x30, 0x06, 0x00, 0x30, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char F
        0x0B, 0x00, 0x00, 0x00, 0x00, 0x3F, 0x00, 0xC0, 0x7F, 0x00, 0xE0, 0xE0, 0x00, 0x60, 0xC0, 0x01, 0x30, 0x80, 0x01, 0x30, 0x86, 0x01, 0x30, 0x86, 0x01, 0x30, 0x86, 0x01, 0x30, 0xFE, 0x01, 0x60, 0xFE, 0x00, 0x00, 0x00, 0x00,  // Code for char G
        0x0A, 0x00, 0x00, 0x00, 0xF0, 0xFF, 0x01, 0xF0, 0xFF, 0x01, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0xF0, 0xFF, 0x01, 0xF0, 0xFF, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char H
        0x0A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x80, 0x01, 0x30, 0x80, 0x01, 0x30, 0x80, 0x01, 0xF0, 0xFF, 0x01, 0xF0, 0xFF, 0x01, 0x30, 0x80, 0x01, 0x30, 0x80, 0x01, 0x30, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char I
        0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0xC0, 0x00, 0x30, 0x80, 0x01, 0x30, 0x80, 0x01, 0x30, 0x80, 0x01, 0x30, 0xC0, 0x01, 0xF0, 0xFF, 0x00, 0xF0, 0x7F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char J
        0x0A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF0, 0xFF, 0x01, 0xF0, 0xFF, 0x01, 0x00, 0x04, 0x00, 0x00, 0x1F, 0x00, 0xC0, 0x79, 0x00, 0xE0, 0xE0, 0x00, 0x30, 0xC0, 0x01, 0x10, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char K
        0x0A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF0, 0xFF, 0x01, 0xF0, 0xFF, 0x01, 0x00, 0x80, 0x01, 0x00, 0x80, 0x01, 0x00, 0x80, 0x01, 0x00, 0x80, 0x01, 0x00, 0x80, 0x01, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char L
        0x0C, 0x00, 0x00, 0x00, 0x00, 0xC0, 0x01, 0xF0, 0xFF, 0x01, 0x30, 0x00, 0x00, 0xE0, 0x03, 0x00, 0x00, 0x1E, 0x00, 0x00, 0x1C, 0x00, 0x80, 0x07, 0x00, 0xE0, 0x00, 0x00, 0x30, 0x00, 0x00, 0xF0, 0xFF, 0x01, 0x00, 0xF0, 0x01,  // Code for char M
        0x0A, 0x00, 0x00, 0x00, 0xF0, 0xFF, 0x01, 0xF0, 0xFF, 0x01, 0x70, 0x00, 0x00, 0xC0, 0x03, 0x00, 0x00, 0x0E, 0x00, 0x00, 0x78, 0x00, 0x00, 0xC0, 0x01, 0xF0, 0xFF, 0x01, 0xF0, 0xFF, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char N
        0x0B, 0x00, 0x00, 0x00, 0x80, 0x3F, 0x00, 0xC0, 0xFF, 0x00, 0xE0, 0xE0, 0x00, 0x30, 0x80, 0x01, 0x30, 0x80, 0x01, 0x30, 0x80, 0x01, 0x30, 0x80, 0x01, 0xE0, 0xE0, 0x00, 0xE0, 0x7F, 0x00, 0x80, 0x3F, 0x00, 0x00, 0x00, 0x00,  // Code for char O
        0x0B, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF0, 0xFF, 0x01, 0xF0, 0xFF, 0x01, 0x30, 0x0C, 0x00, 0x30, 0x0C, 0x00, 0x30, 0x0C, 0x00, 0x30, 0x0C, 0x00, 0x70, 0x06, 0x00, 0xE0, 0x07, 0x00, 0xC0, 0x03, 0x00, 0x00, 0x00, 0x00,  // Code for char P
        0x0C, 0x00, 0x00, 0x00, 0x00, 0x3F, 0x00, 0xC0, 0xFF, 0x00, 0xE0, 0xE0, 0x00, 0x70, 0xC0, 0x01, 0x30, 0x80, 0x07, 0x30, 0x80, 0x0F, 0x30, 0x80, 0x0D, 0x70, 0xC0, 0x09, 0xE0, 0xE0, 0x08, 0xC0, 0x7F, 0x08, 0x80, 0x3F, 0x0C,  // Code for char Q
        0x0B, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF0, 0xFF, 0x01, 0xF0, 0xFF, 0x01, 0x30, 0x0C, 0x00, 0x30, 0x0C, 0x00, 0x30, 0x1C, 0x00, 0x70, 0x36, 0x00, 0xE0, 0xF7, 0x00, 0xC0, 0xC3, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00,  // Code for char R
        0x0A, 0x00, 0x00, 0x00, 0xC0, 0xC1, 0x00, 0xE0, 0x83, 0x01, 0x30, 0x87, 0x01, 0x30, 0x86, 0x01, 0x30, 0x86, 0x01, 0x30, 0x8C, 0x01, 0x30, 0xCC, 0x01, 0x60, 0xF8, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char S
        0x0B, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x30, 0x00, 0x00, 0x30, 0x00, 0x00, 0x30, 0x00, 0x00, 0xF0, 0xFF, 0x01, 0xF0, 0xFF, 0x01, 0x30, 0x00, 0x00, 0x30, 0x00, 0x00, 0x30, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char T
        0x0B, 0x00, 0x00, 0x00, 0xF0, 0x7F, 0x00, 0xF0, 0xFF, 0x00, 0x00, 0xC0, 0x01, 0x00, 0x80, 0x01, 0x00, 0x80, 0x01, 0x00, 0x80, 0x01, 0x00, 0x80, 0x01, 0x00, 0xC0, 0x01, 0xF0, 0xFF, 0x00, 0xF0, 0x7F, 0x00, 0x00, 0x00, 0x00,  // Code for char U
        0x0C, 0x00, 0x00, 0x00, 0x70, 0x00, 0x00, 0xF0, 0x03, 0x00, 0x80, 0x0F, 0x00, 0x00, 0x7C, 0x00, 0x00, 0xF0, 0x01, 0x00, 0x80, 0x01, 0x00, 0xE0, 0x01, 0x00, 0x7C, 0x00, 0x80, 0x0F, 0x00, 0xF0, 0x01, 0x00, 0x70, 0x00, 0x00,  // Code for char V
        0x0B, 0x00, 0x00, 0x00, 0xF0, 0x07, 0x00, 0xF0, 0xFF, 0x01, 0x00, 0x80, 0x01, 0x00, 0x78, 0x00, 0x00, 0x0F, 0x00, 0x00, 0x0F, 0x00, 0x00, 0x78, 0x00, 0x00, 0xC0, 0x01, 0xF0, 0xFF, 0x01, 0xF0, 0x07, 0x00, 0x00, 0x00, 0x00,  // Code for char W
        0x0C, 0x00, 0x00, 0x01, 0x10, 0x80, 0x01, 0x30, 0xE0, 0x01, 0xF0, 0x70, 0x00, 0xC0, 0x3D, 0x00, 0x80, 0x0F, 0x00, 0x80, 0x0F, 0x00, 0xC0, 0x3D, 0x00, 0xE0, 0x70, 0x00, 0x30, 0xE0, 0x01, 0x10, 0x80, 0x01, 0x00, 0x00, 0x01,  // Code for char X
        0x0C, 0x10, 0x00, 0x00, 0x30, 0x00, 0x00, 0xE0, 0x00, 0x00, 0xC0, 0x03, 0x00, 0x00, 0x07, 0x00, 0x00, 0xFE, 0x01, 0x00, 0xFC, 0x01, 0x00, 0x07, 0x00, 0xC0, 0x03, 0x00, 0xE0, 0x00, 0x00, 0x30, 0x00, 0x00, 0x10, 0x00, 0x00,  // Code for char Y
        0x0B, 0x00, 0x00, 0x00, 0x30, 0x80, 0x01, 0x30, 0xC0, 0x01, 0x30, 0xF0, 0x01, 0x30, 0x98, 0x01, 0x30, 0x8E, 0x01, 0x30, 0x83, 0x01, 0xF0, 0x81, 0x01, 0x70, 0x80, 0x01, 0x30, 0x80, 0x01, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00,  // Code for char Z
        0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFC, 0xFF, 0x0F, 0xFC, 0xFF, 0x0F, 0x0C, 0x00, 0x08, 0x0C, 0x00, 0x08, 0x0C, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char [
        0x0A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x38, 0x00, 0x00, 0xE0, 0x01, 0x00, 0x80, 0x07, 0x00, 0x00, 0x1E, 0x00, 0x00, 0xF0, 0x00, 0x00, 0xC0, 0x03, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char BackSlash
        0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0C, 0x00, 0x08, 0x0C, 0x00, 0x08, 0x0C, 0x00, 0x08, 0xFC, 0xFF, 0x0F, 0xFC, 0xFF, 0x0F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char ]
        0x0A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x80, 0x07, 0x00, 0xE0, 0x00, 0x00, 0x30, 0x00, 0x00, 0x70, 0x00, 0x00, 0xC0, 0x01, 0x00, 0x00, 0x07, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char ^
        0x0C, 0x00, 0x00, 0x08, 0x00, 0x00, 0x08, 0x00, 0x00, 0x08, 0x00, 0x00, 0x08, 0x00, 0x00, 0x08, 0x00, 0x00, 0x08, 0x00, 0x00, 0x08, 0x00, 0x00, 0x08, 0x00, 0x00, 0x08, 0x00, 0x00, 0x08, 0x00, 0x00, 0x08, 0x00, 0x00, 0x08,  // Code for char _
        0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x1C, 0x00, 0x00, 0x18, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char `
        0x0A, 0x00, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0xF3, 0x01, 0x80, 0x99, 0x01, 0x80, 0x99, 0x01, 0x80, 0x99, 0x01, 0x80, 0x99, 0x01, 0x80, 0xD9, 0x00, 0x00, 0xFF, 0x01, 0x00, 0xFF, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char a
        0x0B, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0x00, 0xF8, 0xFF, 0x01, 0x00, 0x83, 0x01, 0x80, 0x81, 0x01, 0x80, 0x81, 0x01, 0x80, 0x81, 0x01, 0x80, 0xC3, 0x00, 0x00, 0xFF, 0x00, 0x00, 0x3E, 0x00, 0x00, 0x00, 0x00,  // Code for char b
        0x0A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7C, 0x00, 0x00, 0xFF, 0x00, 0x00, 0xC3, 0x01, 0x80, 0x81, 0x01, 0x80, 0x81, 0x01, 0x80, 0x81, 0x01, 0x80, 0x81, 0x01, 0x00, 0xC3, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char c
        0x0A, 0x00, 0x00, 0x00, 0x00, 0x7C, 0x00, 0x00, 0xFF, 0x00, 0x00, 0xC3, 0x01, 0x80, 0x81, 0x01, 0x80, 0x81, 0x01, 0x80, 0xC1, 0x01, 0x80, 0xC1, 0x00, 0xF8, 0xFF, 0x01, 0xF8, 0xFF, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char d
        0x0A, 0x00, 0x00, 0x00, 0x00, 0x7C, 0x00, 0x00, 0xFF, 0x00, 0x80, 0xDB, 0x01, 0x80, 0x99, 0x01, 0x80, 0x99, 0x01, 0x80, 0x99, 0x01, 0x80, 0x9B, 0x01, 0x00, 0x9F, 0x01, 0x00, 0x1E, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char e
        0x0B, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x03, 0x00, 0x00, 0x03, 0x00, 0xE0, 0xFF, 0x01, 0xF0, 0xFF, 0x01, 0x38, 0x03, 0x00, 0x18, 0x03, 0x00, 0x18, 0x03, 0x00, 0x18, 0x03, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char f
        0x0B, 0x00, 0x00, 0x00, 0x00, 0xC0, 0x0E, 0x00, 0xEE, 0x0E, 0x00, 0xBF, 0x09, 0x80, 0xB1, 0x09, 0x80, 0xB1, 0x09, 0x80, 0xB1, 0x09, 0x80, 0xB1, 0x09, 0x80, 0x9F, 0x09, 0x80, 0x8F, 0x0F, 0x80, 0x01, 0x07, 0x00, 0x00, 0x00,  // Code for char g
        0x0A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0x01, 0xF8, 0xFF, 0x01, 0x00, 0x03, 0x00, 0x80, 0x01, 0x00, 0x80, 0x01, 0x00, 0x80, 0x01, 0x00, 0x80, 0xFF, 0x01, 0x00, 0xFF, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char h
        0x0A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x81, 0x01, 0x80, 0x81, 0x01, 0x9C, 0x81, 0x01, 0x9C, 0xFF, 0x01, 0x9C, 0xFF, 0x01, 0x00, 0x80, 0x01, 0x00, 0x80, 0x01, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char i
        0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x0C, 0x80, 0x01, 0x08, 0x80, 0x01, 0x08, 0x80, 0x01, 0x08, 0x9C, 0x01, 0x08, 0x9C, 0xFF, 0x0F, 0x9C, 0xFF, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char j
        0x0B, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0x01, 0xF8, 0xFF, 0x01, 0x00, 0x08, 0x00, 0x00, 0x1C, 0x00, 0x00, 0x36, 0x00, 0x00, 0x63, 0x00, 0x80, 0xC1, 0x00, 0x80, 0x80, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00,  // Code for char k
        0x0A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x80, 0x01, 0x18, 0x80, 0x01, 0x18, 0x80, 0x01, 0xF8, 0xFF, 0x01, 0xF8, 0xFF, 0x01, 0x00, 0x80, 0x01, 0x00, 0x80, 0x01, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char l
        0x0B, 0x00, 0x00, 0x00, 0x80, 0xFF, 0x01, 0x80, 0xFF, 0x01, 0x00, 0x03, 0x00, 0x80, 0x01, 0x00, 0x80, 0xFF, 0x01, 0x00, 0xFF, 0x01, 0x00, 0x03, 0x00, 0x80, 0x01, 0x00, 0x80, 0xFF, 0x01, 0x00, 0xFF, 0x01, 0x00, 0x00, 0x00,  // Code for char m
        0x0A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xFF, 0x01, 0x80, 0xFF, 0x01, 0x00, 0x03, 0x00, 0x80, 0x01, 0x00, 0x80, 0x01, 0x00, 0x80, 0x01, 0x00, 0x80, 0xFF, 0x01, 0x00, 0xFF, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char n
        0x0B, 0x00, 0x00, 0x00, 0x00, 0x7C, 0x00, 0x00, 0xFF, 0x00, 0x00, 0xC3, 0x01, 0x80, 0x81, 0x01, 0x80, 0x81, 0x01, 0x80, 0x81, 0x01, 0x80, 0x81, 0x01, 0x80, 0xC3, 0x00, 0x00, 0xFF, 0x00, 0x00, 0x3E, 0x00, 0x00, 0x00, 0x00,  // Code for char o
        0x0B, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xFF, 0x0F, 0x80, 0xFF, 0x0F, 0x00, 0x83, 0x01, 0x80, 0x81, 0x01, 0x80, 0x81, 0x01, 0x80, 0x81, 0x01, 0x80, 0xC3, 0x00, 0x00, 0xFF, 0x00, 0x00, 0x3E, 0x00, 0x00, 0x00, 0x00,  // Code for char p
        0x0A, 0x00, 0x00, 0x00, 0x00, 0x7C, 0x00, 0x00, 0xFF, 0x00, 0x00, 0xC3, 0x01, 0x80, 0x81, 0x01, 0x80, 0x81, 0x01, 0x80, 0xC1, 0x01, 0x80, 0xC1, 0x00, 0x80, 0xFF, 0x0F, 0x80, 0xFF, 0x0F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char q
        0x0B, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xFF, 0x01, 0x80, 0xFF, 0x01, 0x00, 0x03, 0x00, 0x00, 0x03, 0x00, 0x80, 0x01, 0x00, 0x80, 0x01, 0x00, 0x80, 0x01, 0x00, 0x80, 0x07, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x00,  // Code for char r
        0x0A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xC7, 0x00, 0x00, 0x8F, 0x01, 0x80, 0x89, 0x01, 0x80, 0x99, 0x01, 0x80, 0x99, 0x01, 0x80, 0x91, 0x01, 0x00, 0xF3, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char s
        0x0A, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x80, 0x01, 0x00, 0x80, 0x01, 0x00, 0xF0, 0xFF, 0x00, 0xF0, 0xFF, 0x01, 0x80, 0x81, 0x01, 0x80, 0x81, 0x01, 0x80, 0x81, 0x01, 0x80, 0x81, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char t
        0x0A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xFF, 0x00, 0x80, 0xFF, 0x01, 0x00, 0x80, 0x01, 0x00, 0x80, 0x01, 0x00, 0x80, 0x01, 0x00, 0xC0, 0x00, 0x80, 0xFF, 0x01, 0x80, 0xFF, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char u
        0x0B, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, 0x80, 0x0F, 0x00, 0x00, 0x7C, 0x00, 0x00, 0xE0, 0x01, 0x00, 0x00, 0x01, 0x00, 0xE0, 0x01, 0x00, 0x3C, 0x00, 0x80, 0x0F, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00,  // Code for char v
        0x0A, 0x00, 0x00, 0x00, 0x80, 0x1F, 0x00, 0x00, 0xFE, 0x01, 0x00, 0x80, 0x01, 0x00, 0xF8, 0x00, 0x00, 0x06, 0x00, 0x00, 0x3C, 0x00, 0x00, 0xE0, 0x01, 0x00, 0x80, 0x01, 0x80, 0xFF, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char w
        0x0B, 0x00, 0x00, 0x00, 0x80, 0x00, 0x01, 0x80, 0x81, 0x01, 0x80, 0xC3, 0x01, 0x00, 0x6E, 0x00, 0x00, 0x3C, 0x00, 0x00, 0x3C, 0x00, 0x00, 0x7E, 0x00, 0x80, 0xC3, 0x01, 0x80, 0x81, 0x01, 0x80, 0x00, 0x01, 0x00, 0x00, 0x00,  // Code for char x
        0x0B, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x80, 0x03, 0x08, 0x80, 0x0F, 0x08, 0x00, 0x7C, 0x0C, 0x00, 0xE0, 0x0F, 0x00, 0x80, 0x07, 0x00, 0xE0, 0x00, 0x00, 0x3C, 0x00, 0x80, 0x0F, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00,  // Code for char y
        0x0A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x81, 0x01, 0x80, 0xC1, 0x01, 0x80, 0xE1, 0x01, 0x80, 0xB1, 0x01, 0x80, 0x89, 0x01, 0x80, 0x87, 0x01, 0x80, 0x83, 0x01, 0x80, 0x81, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char z
        0x0A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x1C, 0x00, 0xF0, 0xFF, 0x07, 0xF8, 0xF3, 0x0F, 0x1C, 0x00, 0x0C, 0x0C, 0x00, 0x08, 0x0C, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char {
        0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x0F, 0xFF, 0xFF, 0x0F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char |
        0x0A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0C, 0x00, 0x08, 0x0C, 0x00, 0x08, 0x1C, 0x00, 0x0C, 0xF8, 0xF3, 0x0F, 0xF0, 0xFF, 0x0F, 0x00, 0x0E, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // Code for char }
        0x0C, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x1E, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x00, 0x0E, 0x00, 0x00, 0x1C, 0x00, 0x00, 0x38, 0x00, 0x00, 0x30, 0x00, 0x00, 0x30, 0x00, 0x00, 0x3C, 0x00, 0x00, 0x0C, 0x00,  // Code for char ~
        0x04, 0xF0, 0xFF, 0x00, 0x10, 0x80, 0x00, 0x10, 0x80, 0x00, 0xF0, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00   // Code for char 
        };

Any suggestion?

After 3 years, I’m facing the same problem:

image

Any hit on what could be?

1 Like

Bit order of columns is inverted. You can choose the bit order when exporting

2 Likes

I really can’t see where in Mikro Elettronika this option is.

And I’m using the same version as the one in the guide post.

Sorry to bump the topic again @jonne , but I see no way to change bit order with GLCD Font Creator.

The font format itself is quite odd and I see no other way to generate this specific type of data as required by actual lib.

Let me try to remember what i did. I will try also.

1 Like

Maybe you run some kind of postscript on resulting header file?

Inverted meaning reversed?

If so, just throwing this function around all the values should suffice:

// Variables in constexpr functions are a C++14 feature.
// This could be rewritten to work in C++11 where variables
// in constexpr functions aren't allowed,
// but it would be a lot harder to read.
#if defined(__cplusplus) && (__cplusplus >= 201402L)
constexpr
#endif
unsigned char reverse_bits(unsigned char value)
{
	// Swap nibbles
	const unsigned char value0 = (((value & 0xF0) >> 4) | ((value & 0x0F) << 4));

	// Swap pairs
	const unsigned char value1 = (((value0 & 0xCC) >> 2) | ((value0 & 0x33) << 2));
	
	// Swap bits
	const unsigned char value2 = (((value1 & 0xAA) >> 1) | ((value1 & 0x55) << 1));
	
	return value2;
}

If the array itself is marked constexpr, then it’s (more or less) guaranteed that this function will be evaluated at compile time.

1 Like

Imho, waste of resources to reverse bits at runtime.

Would be better to make a python script to do it

Ah. I just.now read your proposal properly

Edit: no you cant do this because existing fonts would break. You’d have to implement this on the print level of PokittoLib

Surely it only needs to be done for the fonts in which the reversed bits are a problem, not all fonts?

If that’s not many, a simple regex replace from a text editor ought do the job easily.

(0x[0-9A-Za-z]+)bit_reverse($1)

It’s not as robust as writing a proper script, but if anyone wants a duct-tape solution for the time being, it should suffice. (I expect someone using Linux could turn that into a bash script that uses grep.)


@HomineLudens, does the following work for you?
(Assuming you’ve still got that old code from several comments ago.)

(I made this exactly as described, in about 30 seconds using a text editor’s regex replace tool.)

@Pharap your code have a typo (reverse_bits vs bit_reverse :smiley: ) but seems not to fix the problem:

So I made a test creating smaller font as suggested by @lucentbeam , and yes with small fonts all works as expected.

2 Likes

I am playing all the right notes, but not necessarily in the right order.

Considering how tired I was, I’m surprised that’s all that’s wrong with it to be honest.

They should all be reverse_bits since starting with a verb usually makes more sense. I’ve updated the gist.

Then there’s probably more to it than the bits being reversed.

I had a quick look at the code and from what I can tell, assuming what I’m looking at is the right function, there’s actually supposed to be 5 starter bytes: width, height, 2 that bufferChar is skipping over and then the ‘width in bytes’, whatever that means.

But that’s as far as I’ll be looking into it tonight.

1 Like