News:

;) This forum is the property of Proton software developers

Main Menu

Example code for fonts

Started by RGV250, Jun 11, 2021, 12:24 PM

Previous topic - Next topic

RGV250

Hi,
After a little trip (literally) to hospital I am back on the little round display I have been working on. I have converted the Arduino code for things like lines, circles and dots etc but when I got to the text etc it looked a nightmare and way to complicated for what I think it should be. Also I am not sure what they used to generate the fonts so I would be stuck with the example fonts.
What I am looking for is a font converter and an example of how to look up the data for the characters from the string I am writing.

Regards,
Bob
 

Craig

Hi Bob
I recently did some fonts for a EA Dog display using an ST7565R Driver Chip. I used Les's Proton Font Convertor and also an old Copy Of GLCD Font Creator
To Make the Font Tables.

Include "C:\Users\User\PDS\Includes DOG\ArialBold_8.Inc"

Print_At(ArialNarrow8,2,10,"FW Ver:  5.11",0)

StrN string2Print = Str$(Dec3 RSSI)                                                              ' convert number to string
Print_At(ArialBold_8,0,50,"RSi:" + Str string2Print + "     ",0
___________________________________________________________________

'Font Generated by GLCD Font Creator V1.0.1
'Copyright 2007 Pocket MicroTechnics
'http://www.pocketmt.com

'GLCD FontName : Arial10x11 (10 Wide x 11 High)
'GLCD FontSize : 10 x 11
'const Arial10x11 as byte[1995] = (

GoTo over_ArialBold_8
ArialBold_8:
CData  20,10,_
        $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char 
        $BE, $01, $BE, $01, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char !
        $0E, $00, $0E, $00, $00, $00, $0E, $00, $0E, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char "
        $C8, $01, $78, $00, $4E, $00, $C8, $01, $78, $00, $4E, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char #
        $9C, $00, $32, $01, $FF, $03, $32, $01, $E4, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char $
        $1E, $00, $12, $00, $9E, $01, $60, $00, $18, $00, $E6, $01, $20, $01, $E0, $01, $00, $00, $00, $00,_  ' Code for char %
        $C0, $00, $EC, $01, $3E, $01, $32, $01, $EE, $01, $CC, $01, $60, $01, $00, $00, $00, $00, $00, $00,_  ' Code for char &
        $0E, $00, $0E, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char '
        $F8, $00, $FC, $03, $06, $06, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char (
        $02, $06, $FC, $03, $F0, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char )
        $14, $00, $0E, $00, $14, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char *
        $20, $00, $20, $00, $F8, $00, $20, $00, $20, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char +
        $80, $05, $80, $03, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char ,
        $40, $00, $40, $00, $40, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char -
        $80, $01, $80, $01, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char .
        $80, $01, $78, $00, $06, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char /
        $FC, $00, $FE, $01, $02, $01, $FE, $01, $FC, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char 0
        $18, $00, $0C, $00, $FE, $01, $FE, $01, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char 1
        $84, $01, $C6, $01, $62, $01, $3E, $01, $1C, $01, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char 2
        $84, $00, $86, $01, $12, $01, $FE, $01, $EC, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char 3
        $60, $00, $58, $00, $44, $00, $FE, $01, $FE, $01, $40, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char 4
        $B8, $00, $9E, $01, $16, $01, $F2, $01, $E2, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char 5
        $FC, $00, $FE, $01, $12, $01, $F6, $01, $E4, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char 6
        $02, $00, $E2, $01, $FA, $01, $1E, $00, $06, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char 7
        $EC, $00, $FE, $01, $12, $01, $FE, $01, $EC, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char 8
        $9C, $00, $BE, $01, $22, $01, $FE, $01, $FC, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char 9
        $98, $01, $98, $01, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char :
        $98, $05, $98, $03, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char ;
        $30, $00, $30, $00, $48, $00, $48, $00, $84, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char <
        $50, $00, $50, $00, $50, $00, $50, $00, $50, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char =
        $84, $00, $48, $00, $48, $00, $30, $00, $30, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char >
        $00, $00, $04, $00, $A6, $01, $B2, $01, $1E, $00, $0C, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char ?
        $F0, $00, $0C, $03, $E4, $02, $1A, $05, $0A, $05, $8A, $05, $FA, $05, $1A, $05, $84, $02, $78, $02,_  ' Code for char @
        $C0, $01, $F8, $01, $7E, $00, $46, $00, $7E, $00, $F8, $01, $C0, $01, $00, $00, $00, $00, $00, $00,_  ' Code for char A
        $FE, $01, $FE, $01, $12, $01, $12, $01, $FE, $01, $EC, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char B
        $78, $00, $FC, $00, $86, $01, $02, $01, $02, $01, $86, $01, $84, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char C
        $FE, $01, $FE, $01, $02, $01, $02, $01, $FE, $01, $FC, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char D
        $FE, $01, $FE, $01, $12, $01, $12, $01, $12, $01, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char E
        $FE, $01, $FE, $01, $12, $00, $12, $00, $12, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char F
        $78, $00, $FC, $00, $86, $01, $02, $01, $22, $01, $E6, $01, $E4, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char G
        $FE, $01, $FE, $01, $10, $00, $10, $00, $FE, $01, $FE, $01, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char H
        $FE, $01, $FE, $01, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char I
        $80, $00, $80, $01, $00, $01, $FE, $01, $FE, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char J
        $FE, $01, $FE, $01, $30, $00, $7C, $00, $EE, $01, $82, $01, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char K
        $FE, $01, $FE, $01, $00, $01, $00, $01, $00, $01, $00, $01, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char L
        $FE, $01, $FE, $01, $1E, $00, $F8, $00, $C0, $01, $F8, $00, $1E, $00, $FE, $01, $FE, $01, $00, $00,_  ' Code for char M
        $FE, $01, $FE, $01, $18, $00, $60, $00, $FE, $01, $FE, $01, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char N
        $78, $00, $FC, $00, $86, $01, $02, $01, $86, $01, $FC, $00, $78, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char O
        $FE, $01, $FE, $01, $22, $00, $22, $00, $3E, $00, $1C, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char P
        $78, $00, $FC, $00, $86, $01, $42, $01, $86, $01, $FC, $01, $78, $02, $00, $00, $00, $00, $00, $00,_  ' Code for char Q
        $FE, $01, $FE, $01, $22, $00, $62, $00, $FE, $00, $9C, $01, $00, $01, $00, $00, $00, $00, $00, $00,_  ' Code for char R
        $9C, $00, $9E, $01, $32, $01, $32, $01, $E6, $01, $E4, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char S
        $02, $00, $02, $00, $FE, $01, $FE, $01, $02, $00, $02, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char T
        $FE, $00, $FE, $01, $00, $01, $00, $01, $FE, $01, $FE, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char U
        $06, $00, $7E, $00, $F8, $01, $80, $01, $F8, $01, $7E, $00, $06, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char V
        $7E, $00, $F8, $01, $C0, $01, $7C, $00, $0E, $00, $7C, $00, $C0, $01, $F8, $01, $7E, $00, $06, $00,_  ' Code for char W
        $86, $01, $CE, $01, $78, $00, $78, $00, $CE, $01, $86, $01, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char X
        $06, $00, $1E, $00, $F0, $01, $F0, $01, $1E, $00, $06, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char Y
        $82, $01, $C2, $01, $72, $01, $3A, $01, $0E, $01, $06, $01, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char Z
        $FE, $07, $FE, $07, $02, $04, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char [
        $06, $00, $78, $00, $80, $01, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char BackSlash
        $02, $04, $FE, $07, $FE, $07, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char ]
        $10, $00, $1C, $00, $06, $00, $1C, $00, $10, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char ^
        $00, $04, $00, $04, $00, $04, $00, $04, $00, $04, $00, $04, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char _
        $02, $00, $06, $00, $04, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char `
        $D0, $00, $E8, $01, $28, $01, $F8, $01, $F0, $01, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char a
        $FE, $01, $FE, $01, $08, $01, $08, $01, $F8, $01, $F0, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char b
        $F0, $00, $F8, $01, $08, $01, $98, $01, $90, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char c
        $F0, $00, $F8, $01, $08, $01, $08, $01, $FE, $01, $FE, $01, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char d
        $F0, $00, $F8, $01, $28, $01, $28, $01, $B8, $01, $B0, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char e
        $FC, $01, $FE, $01, $0A, $00, $02, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char f
        $F0, $02, $F8, $05, $08, $05, $08, $05, $F8, $07, $F8, $03, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char g
        $FE, $01, $FE, $01, $08, $00, $08, $00, $F8, $01, $F0, $01, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char h
        $FA, $01, $FA, $01, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char i
        $FA, $07, $FA, $03, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char j
        $FE, $01, $FE, $01, $60, $00, $F0, $00, $D8, $01, $08, $01, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char k
        $FE, $01, $FE, $01, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char l
        $F8, $01, $F8, $01, $08, $00, $08, $00, $F8, $01, $F8, $01, $08, $00, $08, $00, $F8, $01, $F0, $01,_  ' Code for char m
        $F8, $01, $F8, $01, $08, $00, $08, $00, $F8, $01, $F0, $01, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char n
        $F0, $00, $F8, $01, $08, $01, $08, $01, $F8, $01, $F0, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char o
        $F8, $07, $F8, $07, $08, $01, $08, $01, $F8, $01, $F0, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char p
        $F0, $00, $F8, $01, $08, $01, $08, $01, $F8, $07, $F8, $07, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char q
        $F8, $01, $F8, $01, $08, $00, $08, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_ ' Code for char r
        $B0, $00, $B8, $01, $68, $01, $68, $01, $D8, $01, $D0, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char s
        $FC, $00, $FE, $01, $08, $01, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char t
        $F8, $00, $F8, $01, $00, $01, $00, $01, $F8, $01, $F8, $01, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char u
        $78, $00, $F8, $01, $80, $01, $F8, $01, $78, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char v
        $38, $00, $F8, $01, $C0, $01, $F0, $00, $38, $00, $F0, $00, $C0, $01, $F8, $01, $38, $00, $00, $00,_  ' Code for char w
        $98, $01, $F8, $01, $60, $00, $F8, $01, $98, $01, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char x
        $78, $04, $F0, $07, $80, $03, $F0, $01, $78, $00, $08, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char y
        $88, $01, $C8, $01, $68, $01, $38, $01, $18, $01, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char z
        $FC, $03, $BE, $07, $02, $04, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char {
        $00, $00, $FE, $07, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char |
        $02, $04, $BE, $07, $FC, $03, $40, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00,_  ' Code for char }
        $20, $00, $10, $00, $10, $00, $20, $00, $10, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00   ' Code for char ~
        over_ArialBold_8:

____________________________________________________________________________________________________________________________________

Regards
Craig

RGV250

Hi Craig,
That helps, I think I need to know what happens with the Print_At command as well as I will have to do that. At the moment I am thinking it is beyond me.

Bob

Craig

#3
Hi Bob
Sorry i forgot to add in this fantastic Include File Written by Jes, file shows where the Print at command comes from etc.
This is for Pic24 and I have also Included Les's SPI_24.Inc File in my program. Jes had done a beautiful article on using
the ST7565R EA Dog Display which was on the old forum. I think I still have his whole article saved and Can post if you
need it.

Bob You Should maybe post what Driver and Display you are using and there might be others on the form which have already used it and
have a sample for you to look through.
Regards
Craig


'****************************************************************
'*  Name    : SPI DOG display .inc                              *
'*  Author  : [Jd Smith]                                        *
'*  Notice  : Copyright (c) 2011 [select VIEW...EDITOR OPTIONS] *
'*          : All Rights Reserved                               *
'*  Date    : 03/11/2014                                        *
'*  Version : 1.1                                               *
'*  Notes   : lots of help thank from barracks code             *                             
'*                                                             *
'****************************************************************

'******************************************displat text ********************************************
Dim index As Byte           'dim for column selecting
Dim lcd_page As Byte        'dim for page increments
Dim lcd_row As Byte
Dim page_index As Byte      'dim for the for next loop to clear pages in clear screen routine
Dim Lcd_column As Byte
Dim fontaddress As Word
Dim lcdstr As String * 25
Dim invert As Byte          'inverse bit for font
Dim Col_MSB As Byte         'column MSB part
Dim Col_LSB As Byte         'column LSB part
Dim xypos[2] As Byte
'****************************************** EADOG LCD PINS *****************************************
    Symbol CS = PORTB.6         'BROWN pin 40 cs         PORTB.11
    Symbol A0 = PORTB.7         'PURPLE pin 38 A0 PIN    PORTB.13
    Symbol RS = PORTB.5         'GREEN RS pin 39         PORTB.12
    Output PORTB.5              'RS PIN39               PORTB.12
   ' Symbol CS = PORTB.6     'PORTB.11 pin 40 cs,  pic pin RB22               ************************* 11/7/2020 *****************
   ' Symbol A0 = PORTB.7     'PORTB.13 pin 38 A0 PIN  pic pin RB24            ************************* 11/7/2020 *****************
   ' Symbol RS = PORTB.5     'PORTB.12 RS pin 39 , pic pin RB23               ************************* 11/7/2020 *****************
   ' Output PORTB.5          'PORTB.12 RS PIN39    pic pin RB23               ************************* 11/7/2020 *****************
'***************************************************************************************************

 $define Print_At (Pfont,PPageIndex, PLcdColumn, PStrLcdStr,pinvert) '
    fontaddress = pfont'
    lcd_page = PPageIndex '
    Lcd_column = PLcdColumn '
    lcdstr = PStrLcdStr '
    invert = pinvert'
    xpos(lcd_page) '
    ypos(Lcd_column)'
    SentChar(lcdstr)
   

GoTo over_subs
'***************************************************************************************************
'**************************************** SPI Inititasion ******************************************
'***************************************************************************************************
Proc SPI_Init()
    SPI2_Open(cSPI_MODE0 & cSEC_PRE_2_1 & cPRI_PRE_1_1, cSPI_ON & cSPI_IDLE_ON & cSPI_RX_OVFLOW_CLR)
    PPS_Output(cOut_Pin_RP3, cOut_Fn_SCK2OUT)         ' To SPI peripheral's clk pin 37   PPS_Output(cOut_Pin_RP14, cOut_Fn_SCK2OUT)            ************************* 11/7/2020 *****************
    PPS_Output(cOut_Pin_RP2, cOut_Fn_SDO2)            ' To SPI peripheral's SDO pin 38   PPS_Output(cOut_Pin_RP15, cOut_Fn_SDO2)            ************************* 11/7/2020 *****************
    High PORTB.3                                       ' BLUE  PORTB.14 Make the SCL/SCK pin output high  High PORTB.3 ************************* 11/7/2020 *****************
    High PORTB.2                                       ' WHITE PORTB.15 Make the SI/SDO  pin output high   High PORTB.2 ************************* 11/7/2020 *****************
   
'    PPS_Input(cIn_Pin_RP2, cIn_Fn_SDI2)                 ' SDI2 Data Input (SDI2)  Connected to RP2 (RB2)
'    PPS_Output(cOut_Pin_RP3, cOut_Fn_SCK2OUT)           ' SPI2 Clock Output Connected to RP3 (RB3)
'    PPS_Output(cOut_Pin_RP7, cOut_Fn_SDO2)              ' SPI2 Data Output Connected to RP7 (RB7)

'    High PORTB.3                                      ' PORTB.15 Make the SCK pin output high
'    High PORTB.7                                      ' PORTB.14 Make the SDO pin output high

    High CS                                            ' Make the CS pin output high
    Low RS                                             ' cycle the reset pin to clear LCD Ram
    DelayMS 200                                        ' cycle the reset pin to clear LCD Ram
    High RS                                            ' cycle the reset pin to clear LCD Ram
EndProc
'***************************************************************************************************
'******************************Initialise the DOG LCD **********************************************
'***************************************************************************************************
Proc DOG_Init()
 Dim index As Byte
 Dim lcd_temp As Byte
        Low A0                                         'set A0 so the LCD treats as a cmd         
        Clear CS                                       'Enable the SPI interface
    For index = 0 To 13                                '14 values require for LCD initialisation
        lcd_temp = CRead EADOGM12864 + index           'get each init value from  CTABLE
        SPI2_Write(lcd_temp)                           'Send the value as a command
    Next
        Set CS                                         'Disable the SPI interface 
EndProc
'***************************************************************************************************
Proc LCD_CLS()
Low A0                                      'prepare LCD for command send                                   
For page_index = 176 To 183                 '0-7 page.  See LCD it gives hex page row numbers
    Low CS                                  'select LCD
    SPI2_Write(page_index)                  'Send page address to LCD
    High CS                                 'deselect lcd
 Col_LSB = 0 & $0F                          'column address low nibble
 Col_MSB = (0 >> 4)| $10                    'column address high nibble + 010000
 Low A0                                     'pepare LCD for Command
 Low CS                                     'select LCD
 SPI2_Write(Col_LSB)                        'Send data to LCD
 SPI2_Write(Col_MSB)                        'Send data to LCD
 High CS                                    'deselect lcd

    High A0                                 'prepare LCD for data send
     For index = 0 To 131       ' 127       '128 columns              ORININAL VALUE 0 to 127 ***** 10/12/2020 ******* Doesn't Clear whole Display!!
        Low CS                              'select lcd
        SPI2_Write($00)                     ' turn all pixels off in each 128 columns
        High CS                             'de select lcd
     Next
       Low A0                               'LCD select command send
     Next page_index                        'increment to next row
EndProc
'***************************************************************************************************
Proc xpos(lcd_page As Byte), Byte
    lcd_row = lcd_page + 176
      Low A0                               'Low A0 set lcd to command byte
    Low CS
    SPI2_Write(lcd_row)                  'page address
    High CS
    High A0
    Result = lcd_page
EndProc

Proc ypos(lcd_col As Byte),Byte
    Col_LSB = Lcd_column & $0F            'logical "and" col and $0F ie col 100 = 01100100 & 00001111 = 00000100
    Col_MSB = (Lcd_column >> 4)| $10      'col shifted 4 bits to the right logical "or" 010000
    Low A0
    Low CS 
        SPI2_Write(Col_LSB)                                                       
        SPI2_Write(Col_MSB)
    High CS
    High A0
    Result =  lcd_col
EndProc



'************************* Sends double size char to LCD *******************************************
' i.e.   if databyte is the number 2,  which is ascii 50,,,, j=(50-48) *48  = 96
'        therefore the loop starts getting the font data from the 96th element in the cdata array
'        number 8 = 56 ,,,j=(56-48)* 48 = 384th element in array an so on
'*************************************************************************************************** 
Proc SentChar(lcdstr As String *25)
    Dim temp_page As Byte
    Dim databyte As Byte
    Dim Charpos As Byte         'Holds the position within the string
    Dim font_bytes As Byte
    Dim font_H As Byte
    Dim font_W As Byte
    Dim font_pages As Byte
    Dim i As Byte
    Dim j As Word
    Dim k As Byte

temp_page = lcd_page                             'hold starting page value
font_H = CRead fontaddress                       'height of font
font_W = CRead fontaddress +1                    'width of font
font_pages = (font_H/8)                          'number of pages in font
font_bytes = (font_pages * font_W)               'number of bytes in font

Charpos = 0                                      'set string pointer to first element in array
index = 0                                        'set page increment counter to zero
Repeat
    databyte = lcdstr[Charpos]                   'loads char into string
    j = (databyte-32) * font_bytes         '(databyte-32)      ' j = (databyte -46)  * font_bytes    goes to starting element of the chr in table     ****** 12/7/2020 ***********
    index = 0
  For i = 2 To font_bytes + 1                    'bytes in the char, i=2 is 3rd element ie the start
        databyte = CRead fontaddress + j + i     'inc through cread table
    High A0                                      'set LCD for Data
      Low CS                                       'enable LCD
       SPI2_Write(databyte)                        'Send data via SPI 1
      High CS                                      'disab;e LCD
    Low A0                                         'Set LCD back to command mode
   
If font_pages >1 Then                             'if font bigger than 8 pixels then
     Inc index                                    'counter to track lcd page   
        lcd_page = lcd_page +1                      'inc lcd page after each font byte
      xpos(lcd_page)
      ypos(Lcd_column)
     
       If index = font_pages Then                   'font page height
           lcd_page = temp_page                     'set page back to first page
           Lcd_column = Lcd_column +1               'advance one column
         xpos(lcd_page)
         ypos(Lcd_column)
         index = 0                                'reset page counter to zero
     EndIf     
EndIf     
  Next
  Inc Charpos                                     'step through array
  Until Charpos = Len(lcdstr)                     'jump out at end of text   
EndProc

over_subs:



EADOGM12864:                             
    CData As Byte   $40,_                          ' START LINE 0
                    $A0,_                          ' $A1,_      ' ADC reversed                                 *****24/11/2020****
                    $C8,_                          ' $C0,_      ' normal COM0~COM63 0xC8 reverses everything   *****24/11/2020****
                    $A6,_                          ' Display normal
                    $A2,_                          ' LCD bias set 1/9 (duty 1/65)
                    $2F,_                          ' Booster, regulator, Follower On
                    $F8,_                          ' Internal booster ratio x4
                    $00,_                          ' Internal booster ratio x4
                    $27,_                          ' 0x27   Contrast Set 
                    $81,_                          ' 0x81   Contrast Set 
                    $16,_                          ' 0x16 Contrast set
                    $AC,_                          ' Static indicator not set
                    $00,_                          ' Static indicator not set
                    $AF                            ' Display On
                   
                 


John Drew

Craig,
That article would be worth putting on the WIKI so it's not lost to the community.
John

RGV250

Hi Craig,
I have gone through it and I think I have what I need, I have a couple of questions you might be able to answer.

I cannot find anywhere these 2 bytes are used and wondered if they are something the font generator added for other compilers?
CData  20,10,_
I cannot see where font_bytes is declares, I can guess it is 20?
  j = (databyte-32) * font_bytes 
Do you have a copy of Les's font converter, I figure that would be the best for creating fonts for Proton/Positron.
I have a copy of GLCD font creator V1.0.1 but could not see how it creates the font without a lot of modification. I am a bit annoyed that I paid for it and then he sold out to ME.

Regards,
Bob

Craig

Hi Bob/John
 
I Have added Jes and Barak's Articles into the Code Example Section. I hope this helps to make a bit more sense.
The Font Convertor's Output CTable Must look like the the Tables that I Used otherwise they just give trouble, I also found that the basic Arial type fonts work best .
EA DOG Graphic Display 128x64_ST7565R Using SPI With Font Convertor.

Regards
Craig

John Drew


xvovanx

Hello!
I decided not to create a separate topic, but to continue here in the topic about fonts.
I have two fonts that fine work one at a time. I don't know how to correctly change the names of font tables into *.inc files so that both fonts can be loaded into one project and how can I print two lines on different fonts?

Include "Font_my.inc"
Include "Font_original.inc"

Print At 0,0,"Test123"    ' by original font  ???
Print At 2,0,"Test123"    ' by my font  ???


RGV250

#10
Hi,
I think you need to rename the Font_Table to Font_my and Font_Original or similar.

Then you need to select the font you want to use before printing, something like this.

Font = Font_my
Print At 0,0,"Test123"   

Font = Font_original
Print At 2,0,"Test123" 

That is something like how I did it in the past but not sure if it will work with that library.

Looking at post 2 it is done inline  Print_At(ArialNarrow8,2,10,"FW Ver:  5.11",0) so possibly  Print_At(Font_my,2,0,"Test123",0)

Bob

xvovanx

#11
Hi,
Unfortunately both options don't work  :-\
The compiler doesn't like the fact that the name doesn't contain the word Table.

xvovanx

#12
Hi!
I was never able to get the display to work with two different fonts  :'( . Font 0 prints, font 1 creates a black bar. The fonts work fine separately, but not together. I tried to rename the fonts in places, it is printed a different font, but still only Font 0.
I understand that font 2 is not loading. Why?
Attached is the *.bas program and simulation.

Pepe

#13
demo proteus working with 4 fonts
look post 17

RGV250

#14
Hi,
I didn't realise you were using a standard GLCD display, I thought you were using a special library.
I have found some very old code (around 2007) and it does not compile now so here is the bits that matter.

I had to add this to get it to compile, if I get time I will try to run it.
    Declare LCD_Type = KS0108 ' Use a KS0108 Graphic LC   
    Declare Internal_Font Off

The font file could be in INC flies but I just placed it at the end on the BAS file.
To print with a specific font I just called it first
DISPLAY_DISTANCE:       
    Print Font Arial_B__12
    Print At 48,81,Dec HOUR_Tens
    Print At 48,91,Dec HOUR_Units
    Print At 47,102, ":"
    Print At 48,107,Dec MINUTE_Tens
    Print At 48,117,Dec MINUTE_Units

DISPLAY_SPEED:   
    Print Font Arial____24
    Print At 19,26,Dec SPEED_Hundreds
    Else
    Print At 19,26, " "
    EndIf
    If SPEED > 9 Then
    Print At 19,46,Dec SPEED_Tens
    Else
    Print At 19,46, " "
    EndIf
    Print At 19,66,Dec SPEED_Units
   
DISPLAY_REVCOUNTER:
    Print Font ICONS
    Print At 20,110, "0" 'Oil warning
   
    ''''''''''''''''''''''''Print At 56,40, "7" 'Degree c
    ''''''''''''''''''''''''Print At 56,60, "8" 'High beam
    ''''''''''''''''''''''''Print At 56,80, "9" 'Dip beam
   

'!!!!!!!!!!!!!!!!!!  to be modified, remove bottom spaces.
'
' FONT information for  Arial  - Font Size 9 (Point Size 8.25)
'---------------------------------------------------------------------------------------------------'
'
'
' Pointers to the actual font table
'
Arial____8o25:-

CData     Word 9 ' Font is 9 High

CData     Arial____8o25_0,Arial____8o25_1,Arial____8o25_2,Arial____8o25_3,Arial____8o25_4,_
          Arial____8o25_5,Arial____8o25_6,Arial____8o25_7,Arial____8o25_8,Arial____8o25_9,_
          Arial____8o25_10,Arial____8o25_11,Arial____8o25_12,Arial____8o25_13,Arial____8o25_14,_
          Arial____8o25_15,Arial____8o25_16,Arial____8o25_17,Arial____8o25_18,Arial____8o25_19,_
          Arial____8o25_20,Arial____8o25_21,Arial____8o25_22,Arial____8o25_23,Arial____8o25_24,_
          Arial____8o25_25,Arial____8o25_26,Arial____8o25_27,Arial____8o25_28,Arial____8o25_29,_
          Arial____8o25_30,Arial____8o25_31,Arial____8o25_32,Arial____8o25_33,Arial____8o25_34,_
          Arial____8o25_35,Arial____8o25_36,Arial____8o25_37,Arial____8o25_38,Arial____8o25_39,_
          Arial____8o25_40,Arial____8o25_41,Arial____8o25_42,Arial____8o25_43,Arial____8o25_44,_
          Arial____8o25_45,Arial____8o25_46,Arial____8o25_47,Arial____8o25_48,Arial____8o25_49,_
          Arial____8o25_50,Arial____8o25_51,Arial____8o25_52,Arial____8o25_53,Arial____8o25_54,_
          Arial____8o25_55,Arial____8o25_56,Arial____8o25_57,Arial____8o25_58,Arial____8o25_59,_
          Arial____8o25_60,Arial____8o25_61,Arial____8o25_62,Arial____8o25_63,Arial____8o25_64,_
          Arial____8o25_65,Arial____8o25_66,Arial____8o25_67,Arial____8o25_68,Arial____8o25_69,_
          Arial____8o25_70,Arial____8o25_71,Arial____8o25_72,Arial____8o25_73,Arial____8o25_74,_
          Arial____8o25_75,Arial____8o25_76,Arial____8o25_77,Arial____8o25_78,Arial____8o25_79,_
          Arial____8o25_80,Arial____8o25_81,Arial____8o25_82,Arial____8o25_83,Arial____8o25_84,_
          Arial____8o25_85,Arial____8o25_86,Arial____8o25_87,Arial____8o25_88,Arial____8o25_89,_
          Arial____8o25_90,Arial____8o25_91,Arial____8o25_92,Arial____8o25_93,Arial____8o25_94,_
          Arial____8o25_95



' Font data

Arial____8o25_0:-
CData 2,0,0,0,0 ' Code for char   
Arial____8o25_1:-
CData 2,191,0,0,0 ' Code for char ! 
Arial____8o25_2:-
CData 4,7,0,0,0,7,0,0,0 ' Code for char " 
Arial____8o25_3:-
CData 6,228,0,60,0,231,0,60,0,39,0,0,0 ' Code for char # 
Arial____8o25_4:-
CData 6,70,0,137,0,255,1,137,0,114,0,0,0 ' Code for char $ 
Arial____8o25_5:-
CData 10,6,0,9,0,137,0,102,0,24,0,102,0,145,0,144,0,96,0,0,0 ' Code for char % 
Arial____8o25_6:-
CData 7,96,0,150,0,137,0,153,0,102,0,160,0,0,0 ' Code for char & 
Arial____8o25_7:-
CData 2,7,0,0,0 ' Code for char ' 
Arial____8o25_8:-
CData 4,252,0,2,1,1,2,0,0 ' Code for char ( 
Arial____8o25_9:-
CData 4,1,2,2,1,252,0,0,0 ' Code for char ) 
Arial____8o25_10:-
CData 4,10,0,7,0,10,0,0,0 ' Code for char * 
Arial____8o25_11:-
CData 6,16,0,16,0,124,0,16,0,16,0,0,0 ' Code for char + 
Arial____8o25_12:-
CData 2,128,3,0,0 ' Code for char , 
Arial____8o25_13:-
CData 4,32,0,32,0,32,0,0,0 ' Code for char - 
Arial____8o25_14:-
CData 2,128,0,0,0 ' Code for char . 
Arial____8o25_15:-
CData 4,192,0,60,0,3,0,0,0 ' Code for char / 
Arial____8o25_16:-
CData 6,126,0,129,0,129,0,129,0,126,0,0,0 ' Code for char 0 
Arial____8o25_17:-
CData 4,4,0,2,0,255,0,0,0 ' Code for char 1 
Arial____8o25_18:-
CData 6,130,0,193,0,161,0,145,0,142,0,0,0 ' Code for char 2 
Arial____8o25_19:-
CData 6,66,0,129,0,137,0,137,0,118,0,0,0 ' Code for char 3 
Arial____8o25_20:-
CData 6,48,0,44,0,34,0,255,0,32,0,0,0 ' Code for char 4 
Arial____8o25_21:-
CData 6,76,0,139,0,137,0,137,0,113,0,0,0 ' Code for char 5 
Arial____8o25_22:-
CData 6,126,0,137,0,137,0,137,0,114,0,0,0 ' Code for char 6 
Arial____8o25_23:-
CData 6,1,0,225,0,25,0,7,0,1,0,0,0 ' Code for char 7 
Arial____8o25_24:-
CData 6,118,0,137,0,137,0,137,0,118,0,0,0 ' Code for char 8 
Arial____8o25_25:-
CData 6,78,0,145,0,145,0,145,0,126,0,0,0 ' Code for char 9 
Arial____8o25_26:-
CData 2,132,0,0,0 ' Code for char : 
Arial____8o25_27:-
CData 2,132,3,0,0 ' Code for char ; 
Arial____8o25_28:-
CData 6,16,0,40,0,40,0,40,0,68,0,0,0 ' Code for char < 
Arial____8o25_29:-
CData 6,40,0,40,0,40,0,40,0,40,0,0,0 ' Code for char = 
Arial____8o25_30:-
CData 6,68,0,40,0,40,0,40,0,16,0,0,0 ' Code for char > 
Arial____8o25_31:-
CData 6,2,0,1,0,177,0,9,0,6,0,0,0 ' Code for char ? 
Arial____8o25_32:-
CData 11,248,0,6,1,114,2,137,2,133,2,69,2,249,2,141,2,66,2,60,1,0,0 ' Code for char @ 
Arial____8o25_33:-
CData 8,192,0,48,0,46,0,33,0,46,0,48,0,192,0,0,0 ' Code for char A 
Arial____8o25_34:-
CData 7,255,0,137,0,137,0,137,0,137,0,126,0,0,0 ' Code for char B 
Arial____8o25_35:-
CData 7,60,0,66,0,129,0,129,0,129,0,66,0,0,0 ' Code for char C 
Arial____8o25_36:-
CData 7,255,0,129,0,129,0,129,0,66,0,60,0,0,0 ' Code for char D 
Arial____8o25_37:-
CData 6,255,0,137,0,137,0,137,0,137,0,0,0 ' Code for char E 
Arial____8o25_38:-
CData 6,255,0,9,0,9,0,9,0,1,0,0,0 ' Code for char F 
Arial____8o25_39:-
CData 8,60,0,66,0,129,0,129,0,145,0,82,0,52,0,0,0 ' Code for char G 
Arial____8o25_40:-
CData 7,255,0,8,0,8,0,8,0,8,0,255,0,0,0 ' Code for char H 
Arial____8o25_41:-
CData 2,255,0,0,0 ' Code for char I 
Arial____8o25_42:-
CData 5,96,0,128,0,128,0,127,0,0,0 ' Code for char J 
Arial____8o25_43:-
CData 7,255,0,16,0,8,0,28,0,98,0,129,0,0,0 ' Code for char K 
Arial____8o25_44:-
CData 6,255,0,128,0,128,0,128,0,128,0,0,0 ' Code for char L 
Arial____8o25_45:-
CData 8,255,0,6,0,56,0,192,0,56,0,6,0,255,0,0,0 ' Code for char M 
Arial____8o25_46:-
CData 7,255,0,2,0,12,0,48,0,64,0,255,0,0,0 ' Code for char N 
Arial____8o25_47:-
CData 8,60,0,66,0,129,0,129,0,129,0,66,0,60,0,0,0 ' Code for char O 
Arial____8o25_48:-
CData 6,255,0,17,0,17,0,17,0,14,0,0,0 ' Code for char P 
Arial____8o25_49:-
CData 8,60,0,66,0,129,0,161,0,161,0,66,0,188,0,0,0 ' Code for char Q 
Arial____8o25_50:-
CData 7,255,0,9,0,9,0,25,0,105,0,134,0,0,0 ' Code for char R 
Arial____8o25_51:-
CData 7,70,0,137,0,137,0,145,0,145,0,98,0,0,0 ' Code for char S 
Arial____8o25_52:-
CData 6,1,0,1,0,255,0,1,0,1,0,0,0 ' Code for char T 
Arial____8o25_53:-
CData 7,127,0,128,0,128,0,128,0,128,0,127,0,0,0 ' Code for char U 
Arial____8o25_54:-
CData 8,3,0,12,0,48,0,192,0,48,0,12,0,3,0,0,0 ' Code for char V 
Arial____8o25_55:-
CData 11,60,0,192,0,48,0,14,0,1,0,14,0,48,0,192,0,60,0,3,0,0,0 ' Code for char W 
Arial____8o25_56:-
CData 7,129,0,102,0,24,0,24,0,102,0,129,0,0,0 ' Code for char X 
Arial____8o25_57:-
CData 8,1,0,6,0,8,0,240,0,8,0,6,0,1,0,0,0 ' Code for char Y 
Arial____8o25_58:-
CData 7,128,0,193,0,177,0,141,0,131,0,129,0,0,0 ' Code for char Z 
Arial____8o25_59:-
CData 3,255,3,1,2,0,0 ' Code for char [ 
Arial____8o25_60:-
CData 4,3,0,60,0,192,0,0,0 ' Code for char \ 
Arial____8o25_61:-
CData 3,1,2,255,3,0,0 ' Code for char ] 
Arial____8o25_62:-
CData 6,8,0,6,0,1,0,6,0,8,0,0,0 ' Code for char ^ 
Arial____8o25_63:-
CData 7,0,2,0,2,0,2,0,2,0,2,0,2,0,0 ' Code for char _ 
Arial____8o25_64:-
CData 3,1,0,2,0,0,0 ' Code for char ` 
Arial____8o25_65:-
CData 6,104,0,148,0,148,0,84,0,248,0,0,0 ' Code for char a 
Arial____8o25_66:-
CData 6,255,0,72,0,132,0,132,0,120,0,0,0 ' Code for char b 
Arial____8o25_67:-
CData 6,120,0,132,0,132,0,132,0,72,0,0,0 ' Code for char c 
Arial____8o25_68:-
CData 6,120,0,132,0,132,0,72,0,255,0,0,0 ' Code for char d 
Arial____8o25_69:-
CData 6,120,0,148,0,148,0,148,0,88,0,0,0 ' Code for char e 
Arial____8o25_70:-
CData 4,4,0,254,0,5,0,0,0 ' Code for char f 
Arial____8o25_71:-
CData 6,120,2,132,2,132,2,72,2,252,1,0,0 ' Code for char g 
Arial____8o25_72:-
CData 6,255,0,8,0,4,0,4,0,248,0,0,0 ' Code for char h 
Arial____8o25_73:-
CData 2,253,0,0,0 ' Code for char i 
Arial____8o25_74:-
CData 2,253,1,0,0 ' Code for char j 
Arial____8o25_75:-
CData 5,255,0,16,0,104,0,132,0,0,0 ' Code for char k 
Arial____8o25_76:-
CData 2,255,0,0,0 ' Code for char l 
Arial____8o25_77:-
CData 8,252,0,8,0,4,0,252,0,4,0,4,0,248,0,0,0 ' Code for char m 
Arial____8o25_78:-
CData 6,252,0,4,0,4,0,4,0,248,0,0,0 ' Code for char n 
Arial____8o25_79:-
CData 6,120,0,132,0,132,0,132,0,120,0,0,0 ' Code for char o 
Arial____8o25_80:-
CData 6,252,3,72,0,132,0,132,0,120,0,0,0 ' Code for char p 
Arial____8o25_81:-
CData 6,120,0,132,0,132,0,72,0,252,3,0,0 ' Code for char q 
Arial____8o25_82:-
CData 4,252,0,8,0,4,0,0,0 ' Code for char r 
Arial____8o25_83:-
CData 6,72,0,148,0,148,0,164,0,72,0,0,0 ' Code for char s 
Arial____8o25_84:-
CData 3,255,0,132,0,0,0 ' Code for char t 
Arial____8o25_85:-
CData 6,124,0,128,0,128,0,64,0,252,0,0,0 ' Code for char u 
Arial____8o25_86:-
CData 6,12,0,48,0,192,0,48,0,12,0,0,0 ' Code for char v 
Arial____8o25_87:-
CData 10,12,0,48,0,192,0,56,0,4,0,56,0,192,0,48,0,12,0,0,0 ' Code for char w 
Arial____8o25_88:-
CData 6,132,0,72,0,48,0,72,0,132,0,0,0 ' Code for char x 
Arial____8o25_89:-
CData 6,12,0,48,2,192,1,48,0,12,0,0,0 ' Code for char y 
Arial____8o25_90:-
CData 6,132,0,196,0,180,0,140,0,132,0,0,0 ' Code for char z 
Arial____8o25_91:-
CData 4,16,0,238,1,1,2,0,0 ' Code for char { 
Arial____8o25_92:-
CData 2,255,3,0,0 ' Code for char | 
Arial____8o25_93:-
CData 4,1,2,238,1,16,0,0,0 ' Code for char } 
Arial____8o25_94:-
CData 6,24,0,8,0,24,0,16,0,8,0,0,0 ' Code for char ~ 
Arial____8o25_95:-
CData 7,254,0,130,0,130,0,130,0,130,0,254,0,0,0 ' Code for char � 

'
' FONT information for  Arial  - Font Size 16 (Point Size 12) Bold
'---------------------------------------------------------------------------------------------------'
'
'
' Pointers to the actual font table
'
Arial_B__12:-

CData     Word 16 ' Font is 16 High

CData     Arial_B__12_0,Arial_B__12_1,Arial_B__12_2,Arial_B__12_3,Arial_B__12_4,Arial_B__12_5,_
          Arial_B__12_6,Arial_B__12_7,Arial_B__12_8,Arial_B__12_9,Arial_B__12_10,_
          Arial_B__12_11,Arial_B__12_12,Arial_B__12_13,Arial_B__12_14,Arial_B__12_15,_
          Arial_B__12_16,Arial_B__12_17,Arial_B__12_18,Arial_B__12_19,Arial_B__12_20,_
          Arial_B__12_21,Arial_B__12_22,Arial_B__12_23,Arial_B__12_24,Arial_B__12_25,_
          Arial_B__12_26,Arial_B__12_27,Arial_B__12_28,Arial_B__12_29,Arial_B__12_30,_
          Arial_B__12_31,Arial_B__12_32,Arial_B__12_33,Arial_B__12_34,Arial_B__12_35,_
          Arial_B__12_36,Arial_B__12_37,Arial_B__12_38,Arial_B__12_39,Arial_B__12_40,_
          Arial_B__12_41,Arial_B__12_42,Arial_B__12_43,Arial_B__12_44,Arial_B__12_45,_
          Arial_B__12_46,Arial_B__12_47,Arial_B__12_48,Arial_B__12_49,Arial_B__12_50,_
          Arial_B__12_51,Arial_B__12_52,Arial_B__12_53,Arial_B__12_54,Arial_B__12_55,_
          Arial_B__12_56,Arial_B__12_57,Arial_B__12_58,Arial_B__12_59,Arial_B__12_60,_
          Arial_B__12_61,Arial_B__12_62,Arial_B__12_63,Arial_B__12_64,Arial_B__12_65,_
          Arial_B__12_66,Arial_B__12_67,Arial_B__12_68,Arial_B__12_69,Arial_B__12_70,_
          Arial_B__12_71,Arial_B__12_72,Arial_B__12_73,Arial_B__12_74,Arial_B__12_75,_
          Arial_B__12_76,Arial_B__12_77,Arial_B__12_78,Arial_B__12_79,Arial_B__12_80,_
          Arial_B__12_81,Arial_B__12_82,Arial_B__12_83,Arial_B__12_84,Arial_B__12_85,_
          Arial_B__12_86,Arial_B__12_87,Arial_B__12_88,Arial_B__12_89,Arial_B__12_90,_
          Arial_B__12_91,Arial_B__12_92,Arial_B__12_93,Arial_B__12_94,Arial_B__12_95



' Font data

Arial_B__12_0:-
CData 2,0,0,0,0 ' Code for char   
Arial_B__12_1:-
CData 3,254,27,254,27,0,0 ' Code for char ! 
Arial_B__12_2:-
CData 7,30,0,30,0,0,0,0,0,30,0,30,0,0,0 ' Code for char " 
Arial_B__12_3:-
CData 8,48,31,248,31,254,7,62,31,248,31,254,7,62,3,0,0 ' Code for char # 
Arial_B__12_4:-
CData 8,60,6,126,30,230,28,255,63,198,25,142,31,140,15,0,0 ' Code for char $ 
Arial_B__12_5:-
CData 16,60,0,126,0,66,0,66,16,126,28,60,30,128,7,224,1,120,0,60,15,142,31,130,16,_
          128,16,128,31,0,15,0,0 ' Code for char % 
Arial_B__12_6:-
CData 12,0,15,156,15,254,28,246,24,230,25,246,31,190,31,28,15,128,31,128,31,0,8,0,_
          0 ' Code for char & 
Arial_B__12_7:-
CData 3,30,0,30,0,0,0 ' Code for char ' 
Arial_B__12_8:-
CData 5,240,31,252,127,30,240,2,128,0,0 ' Code for char ( 
Arial_B__12_9:-
CData 5,2,128,30,240,252,127,240,31,0,0 ' Code for char ) 
Arial_B__12_10:-
CData 6,20,0,28,0,14,0,28,0,20,0,0,0 ' Code for char * 
Arial_B__12_11:-
CData 9,192,0,192,0,192,0,248,7,248,7,192,0,192,0,192,0,0,0 ' Code for char + 
Arial_B__12_12:-
CData 3,0,216,0,120,0,0 ' Code for char , 
Arial_B__12_13:-
CData 5,0,3,0,3,0,3,0,3,0,0 ' Code for char - 
Arial_B__12_14:-
CData 3,0,24,0,24,0,0 ' Code for char . 
Arial_B__12_15:-
CData 5,0,30,248,31,254,7,30,0,0,0 ' Code for char / 
Arial_B__12_16:-
CData 9,248,7,252,15,14,28,6,24,6,24,14,28,252,15,248,7,0,0 ' Code for char 0 
Arial_B__12_17:-
CData 8,0,0,48,0,24,0,28,0,254,31,254,31,0,0,0,0,0,0 ' Code for char 1 
Arial_B__12_18:-
CData 9,24,24,28,28,14,30,6,31,134,27,206,25,252,24,124,24,0,0 ' Code for char 2 
Arial_B__12_19:-
CData 9,12,6,14,14,14,28,102,24,102,24,246,28,254,15,156,7,0,0 ' Code for char 3 
Arial_B__12_20:-
CData 9,0,7,128,7,224,6,120,6,28,6,254,31,254,31,0,6,0,0 ' Code for char 4 
Arial_B__12_21:-
CData 9,248,6,254,14,254,28,102,24,102,24,230,28,198,15,128,7,0,0 ' Code for char 5 
Arial_B__12_22:-
CData 9,248,7,252,15,238,28,102,24,102,24,230,28,206,15,140,7,0,0 ' Code for char 6 
Arial_B__12_23:-
CData 9,6,0,6,0,6,30,198,31,246,3,126,0,30,0,14,0,0,0 ' Code for char 7 
Arial_B__12_24:-
CData 9,60,15,254,15,238,29,198,24,198,24,238,29,254,15,60,15,0,0 ' Code for char 8 
Arial_B__12_25:-
CData 9,120,12,252,28,206,25,134,25,134,25,206,29,252,15,248,7,0,0 ' Code for char 9 
Arial_B__12_26:-
CData 3,48,24,48,24,0,0 ' Code for char : 
Arial_B__12_27:-
CData 3,48,216,48,120,0,0 ' Code for char ; 
Arial_B__12_28:-
CData 9,128,0,192,1,192,1,96,3,96,3,48,6,48,6,24,12,0,0 ' Code for char < 
Arial_B__12_29:-
CData 9,176,1,176,1,176,1,176,1,176,1,176,1,176,1,176,1,0,0 ' Code for char = 
Arial_B__12_30:-
CData 9,24,12,48,6,48,6,96,3,96,3,192,1,192,1,128,0,0,0 ' Code for char > 
Arial_B__12_31:-
CData 9,24,0,28,0,14,0,134,27,198,27,238,0,124,0,56,0,0,0 ' Code for char ? 
Arial_B__12_32:-
CData 16,192,31,240,63,120,120,156,239,236,223,254,220,54,152,54,152,118,158,230,_
          159,254,159,254,216,60,206,248,103,240,35,0,0 ' Code for char @ 
Arial_B__12_33:-
CData 12,0,24,0,31,224,15,252,3,62,3,14,3,62,3,252,3,224,15,0,31,0,24,0,0 ' Code for char A 
Arial_B__12_34:-
CData 11,254,31,254,31,198,24,198,24,198,24,198,24,238,24,254,29,252,31,0,15,0,0 ' Code for char B 
Arial_B__12_35:-
CData 11,240,3,252,15,30,30,14,28,6,24,6,24,6,24,14,28,28,14,8,4,0,0 ' Code for char C 
Arial_B__12_36:-
CData 11,254,31,254,31,6,24,6,24,6,24,6,24,14,28,30,30,252,15,240,3,0,0 ' Code for char D 
Arial_B__12_37:-
CData 10,254,31,254,31,198,24,198,24,198,24,198,24,198,24,198,24,198,24,0,0 ' Code for char E 
Arial_B__12_38:-
CData 9,254,31,254,31,198,0,198,0,198,0,198,0,198,0,6,0,0,0 ' Code for char F 
Arial_B__12_39:-
CData 11,240,3,252,15,28,14,14,28,6,24,134,25,134,25,142,29,156,15,136,15,0,0 ' Code for char G 
Arial_B__12_40:-
CData 11,254,31,254,31,192,0,192,0,192,0,192,0,192,0,192,0,254,31,254,31,0,0 ' Code for char H 
Arial_B__12_41:-
CData 3,254,31,254,31,0,0 ' Code for char I 
Arial_B__12_42:-
CData 9,0,6,0,14,0,28,0,24,0,24,0,28,254,15,254,7,0,0 ' Code for char J 
Arial_B__12_43:-
CData 11,254,31,254,31,128,1,192,0,112,0,248,1,220,3,14,15,6,30,2,24,0,0 ' Code for char K 
Arial_B__12_44:-
CData 9,254,31,254,31,0,24,0,24,0,24,0,24,0,24,0,24,0,0 ' Code for char L 
Arial_B__12_45:-
CData 12,254,31,254,31,62,0,252,1,224,31,0,31,224,31,252,1,62,0,254,31,254,31,0,0 ' Code for char M 
Arial_B__12_46:-
CData 11,254,31,254,31,30,0,56,0,224,0,192,3,0,7,0,30,254,31,254,31,0,0 ' Code for char N 
Arial_B__12_47:-
CData 11,240,3,252,15,30,30,14,28,6,24,6,24,14,28,28,30,252,15,240,3,0,0 ' Code for char O 
Arial_B__12_48:-
CData 10,254,31,254,31,198,0,198,0,198,0,198,0,238,0,126,0,124,0,0,0 ' Code for char P 
Arial_B__12_49:-
CData 11,240,3,252,15,30,30,14,24,6,26,6,30,14,28,30,30,252,63,240,55,0,0 ' Code for char Q 
Arial_B__12_50:-
CData 12,254,31,254,31,198,0,198,0,198,1,198,1,198,7,238,15,126,30,60,24,0,16,0,0 ' Code for char R 
Arial_B__12_51:-
CData 10,60,6,124,14,238,28,230,24,198,24,198,24,206,29,156,15,24,7,0,0 ' Code for char S 
Arial_B__12_52:-
CData 11,6,0,6,0,6,0,6,0,254,31,254,31,6,0,6,0,6,0,6,0,0,0 ' Code for char T 
Arial_B__12_53:-
CData 11,254,7,254,15,0,28,0,24,0,24,0,24,0,24,0,28,254,15,254,7,0,0 ' Code for char U 
Arial_B__12_54:-
CData 12,6,0,62,0,252,0,224,7,128,31,0,30,128,31,224,7,252,0,62,0,6,0,0,0 ' Code for char V 
Arial_B__12_55:-
CData 16,6,0,126,0,252,3,224,31,0,31,248,31,254,3,62,0,254,3,248,31,0,31,224,31,252,_
          3,126,0,6,0,0,0 ' Code for char W 
Arial_B__12_56:-
CData 10,6,24,14,28,60,15,240,3,224,1,240,3,60,15,14,28,6,24,0,0 ' Code for char X 
Arial_B__12_57:-
CData 11,6,0,14,0,60,0,112,0,224,31,224,31,112,0,60,0,14,0,6,0,0,0 ' Code for char Y 
Arial_B__12_58:-
CData 10,0,24,6,28,6,31,134,31,230,25,126,24,62,24,14,24,6,24,0,0 ' Code for char Z 
Arial_B__12_59:-
CData 5,254,255,254,255,6,192,6,192,0,0 ' Code for char [ 
Arial_B__12_60:-
CData 5,30,0,254,7,248,31,0,30,0,0 ' Code for char \ 
Arial_B__12_61:-
CData 5,6,192,6,192,254,255,254,255,0,0 ' Code for char ] 
Arial_B__12_62:-
CData 9,64,0,112,0,60,0,30,0,30,0,60,0,112,0,64,0,0,0 ' Code for char ^ 
Arial_B__12_63:-
CData 10,0,192,0,192,0,192,0,192,0,192,0,192,0,192,0,192,0,192,0,0 ' Code for char _ 
Arial_B__12_64:-
CData 4,2,0,6,0,4,0,0,0 ' Code for char ` 
Arial_B__12_65:-
CData 9,96,14,112,31,48,27,176,25,176,29,240,15,224,31,0,16,0,0 ' Code for char a 
Arial_B__12_66:-
CData 9,254,31,254,31,96,12,48,24,48,24,112,28,224,15,192,7,0,0 ' Code for char b 
Arial_B__12_67:-
CData 8,192,7,224,15,112,28,48,24,48,24,112,28,96,12,0,0 ' Code for char c 
Arial_B__12_68:-
CData 9,192,7,224,15,112,28,48,24,48,24,96,12,254,31,254,31,0,0 ' Code for char d 
Arial_B__12_69:-
CData 8,192,7,224,15,176,29,176,25,176,25,224,29,192,5,0,0 ' Code for char e 
Arial_B__12_70:-
CData 7,48,0,252,31,254,31,54,0,54,0,6,0,0,0 ' Code for char f 
Arial_B__12_71:-
CData 9,192,103,224,239,112,220,48,216,48,216,96,236,240,255,240,127,0,0 ' Code for char g 
Arial_B__12_72:-
CData 9,254,31,254,31,96,0,48,0,48,0,112,0,240,31,224,31,0,0 ' Code for char h 
Arial_B__12_73:-
CData 3,246,31,246,31,0,0 ' Code for char i 
Arial_B__12_74:-
CData 4,0,192,246,255,246,127,0,0 ' Code for char j 
Arial_B__12_75:-
CData 8,254,31,254,31,192,3,224,3,240,7,48,30,16,24,0,0 ' Code for char k 
Arial_B__12_76:-
CData 3,254,31,254,31,0,0 ' Code for char l 
Arial_B__12_77:-
CData 13,240,31,240,31,96,0,48,0,48,0,240,31,224,31,96,0,48,0,48,0,240,31,224,31,_
          0,0 ' Code for char m 
Arial_B__12_78:-
CData 9,240,31,240,31,96,0,48,0,48,0,112,0,240,31,224,31,0,0 ' Code for char n 
Arial_B__12_79:-
CData 9,192,7,224,15,112,28,48,24,48,24,112,28,224,15,192,7,0,0 ' Code for char o 
Arial_B__12_80:-
CData 9,240,255,240,255,96,12,48,24,48,24,112,28,224,15,192,7,0,0 ' Code for char p 
Arial_B__12_81:-
CData 9,192,7,224,15,112,28,48,24,48,24,112,12,240,255,240,255,0,0 ' Code for char q 
Arial_B__12_82:-
CData 6,240,31,240,31,112,0,48,0,48,0,0,0 ' Code for char r 
Arial_B__12_83:-
CData 8,224,12,240,29,176,25,176,27,176,27,112,31,96,15,0,0 ' Code for char s 
Arial_B__12_84:-
CData 6,48,0,252,31,254,31,48,24,48,24,0,0 ' Code for char t 
Arial_B__12_85:-
CData 9,240,15,240,31,0,28,0,24,0,24,0,12,240,31,240,31,0,0 ' Code for char u 
Arial_B__12_86:-
CData 8,112,0,240,3,192,31,0,30,192,31,240,3,112,0,0,0 ' Code for char v 
Arial_B__12_87:-
CData 14,112,0,240,3,224,31,0,30,192,31,240,7,240,0,240,7,192,31,0,30,224,31,240,_
          3,112,0,0,0 ' Code for char w 
Arial_B__12_88:-
CData 8,48,24,112,30,224,15,192,7,224,15,112,30,48,24,0,0 ' Code for char x 
Arial_B__12_89:-
CData 10,48,0,240,193,224,199,0,255,0,124,0,63,224,7,240,1,48,0,0,0 ' Code for char y 
Arial_B__12_90:-
CData 8,48,28,48,30,48,31,176,27,240,25,240,24,112,24,0,0 ' Code for char z 
Arial_B__12_91:-
CData 7,128,1,192,3,252,127,126,254,6,192,6,192,0,0 ' Code for char { 
Arial_B__12_92:-
CData 3,254,255,254,255,0,0 ' Code for char | 
Arial_B__12_93:-
CData 7,6,192,6,192,126,254,252,127,192,3,128,1,0,0 ' Code for char } 
Arial_B__12_94:-
CData 9,192,1,192,0,192,0,192,1,192,1,128,1,128,1,192,1,0,0 ' Code for char ~ 
Arial_B__12_95:-
CData 9,252,31,4,16,4,16,4,16,4,16,4,16,4,16,252,31,0,0 ' Code for char � 


'
' FONT information for  Arial  - (Point Size 24)
' Created as 4 bytes high in fontconverter then modified so spaces
' top and botton removed so it can be used by normal Pprint command
'---------------------------------------------------------------------------------------------------'
'
'
' Pointers to the actual font table
'
Arial____24:-

CData     Word 24 ' Font is 24 High (3 Bytes)

CData     Arial____24_0,Arial____24_1,Arial____24_2,Arial____24_3,Arial____24_4,Arial____24_5,_
          Arial____24_6,Arial____24_7,Arial____24_8,Arial____24_9,Arial____24_10,_
          Arial____24_11,Arial____24_12,Arial____24_13,Arial____24_14,Arial____24_15,_
          Arial____24_16,Arial____24_17,Arial____24_18,Arial____24_19,Arial____24_20,_
          Arial____24_21,Arial____24_22,Arial____24_23,Arial____24_24,Arial____24_25

' Font data

Arial____24_0:-
CData 16,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,_
          0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 ' Code for char " " 
   
Arial____24_1:-
Arial____24_2:-
Arial____24_3:-
Arial____24_4:-
Arial____24_5:-
Arial____24_6:-
Arial____24_7:-
Arial____24_8:-
Arial____24_9:-
Arial____24_10:-
Arial____24_11:-
Arial____24_12:-
Arial____24_13:-
Arial____24_14:-
Arial____24_15:-
Arial____24_16:-
CData 17,128,255,3,240,255,31,248,255,63,252,0,126,62,0,248,30,0,240,_
          14,0,224,14,0,224,14,0,224,14,0,224,30,0,240,62,0,248,252,0,_
          126,248,255,63,240,255,31,128,255,3,0,0,0,0 ' Code for char 0 
Arial____24_17:-
CData 16,0,0,0,0,0,0,0,0,0,192,1,0,192,1,0,224,1,0,224,0,0,112,0,0,120,0,0,252,255,255,_
          254,255,255,254,255,255,0,0,0,0,0,0,0,0,0,0,0,0,0 ' Code for char 1 
Arial____24_18:-
CData 16,96,0,224,120,0,240,124,0,248,60,0,252,30,0,238,14,0,231,14,128,_
          231,14,128,227,14,192,225,14,224,224,30,120,224,60,60,224,252,_
          31,224,248,15,224,224,3,224,0,0,0,0 ' Code for char 2 
Arial____24_19:-
CData 17,96,0,12,120,0,60,124,0,124,60,0,120,30,0,240,30,0,224,14,28,_
          224,14,28,224,14,28,224,14,30,224,30,30,240,60,63,112,252,127,_
          124,248,243,63,240,241,31,0,192,15,0,0,0,0 ' Code for char 3 
Arial____24_20:-
CData 17,0,128,7,0,192,7,0,240,7,0,248,7,0,60,7,0,31,7,128,7,7,192,_
          3,7,240,1,7,120,0,7,254,255,255,254,255,255,254,255,255,0,0,_
          7,0,0,7,0,0,7,0,0,0,0 ' Code for char 4 
Arial____24_21:-
CData 17,0,30,12,248,31,60,254,31,124,254,31,120,30,14,240,14,7,224,14,_
          7,224,14,7,224,14,7,224,14,7,224,14,15,240,14,15,112,14,62,_
          124,14,252,63,14,248,31,0,240,7,0,0,0,0 ' Code for char 5 
Arial____24_22:-
CData 17,128,255,3,224,255,31,240,255,63,248,121,124,60,28,120,30,28,240,_
          30,14,224,14,14,224,14,14,224,14,14,224,14,30,240,30,30,240,_
          60,60,124,124,252,63,120,248,31,96,224,15,0,0,0,0 ' Code for char 6 
Arial____24_23:-
CData 16,14,0,0,14,0,0,14,0,0,14,0,248,14,0,255,14,224,255,14,248,31,_
          14,252,1,14,63,0,142,15,0,238,3,0,254,0,0,126,0,0,30,0,0,_
          14,0,0,0,0,0,0 ' Code for char 7 
Arial____24_24:-
CData 17,0,192,15,240,225,63,248,243,63,252,119,120,62,63,240,30,62,240,_
          14,28,224,14,28,224,14,28,224,14,28,224,30,62,240,60,63,240,_
          252,119,120,248,243,63,240,225,63,0,192,15,0,0,0,0 ' Code for char 8 
Arial____24_25:-
CData 17,224,15,12,240,63,60,248,127,124,124,120,120,30,240,240,30,240,_
          224,14,224,224,14,224,224,14,224,224,14,224,240,30,112,240,_
          28,112,120,124,60,63,248,255,31,240,255,15,192,255,3,0,0,0,0 ' Code for char 9 



'
' CDATA for ICONS
' 0 = Oil warning
'---------------------------------------------------------------------------------------------------'
'
'
' Pointers to the actual font table
'
ICONS:-

CData     Word 8 ' ICONS 8 High

CData     ICON_0,ICON_1,ICON_2,ICON_3,ICON_4,_
          ICON_5,ICON_6,ICON_7,ICON_8,ICON_9,_
          ICON_10,ICON_11,ICON_12,ICON_13,ICON_14,_
          ICON_15,ICON_16,ICON_17,ICON_18,ICON_19,_
          ICON_20,ICON_21,ICON_22,ICON_23,ICON_24,_
          ICON_25,ICON_26,ICON_27


' ICON data

ICON_0:-
CData 16,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 ' Code for "space" 8 x 16 pixels   
ICON_1:-
ICON_2:-
ICON_3:-
ICON_4:-
ICON_5:-
ICON_6:-
ICON_7:-
ICON_8:-
ICON_9:-
ICON_10:-
ICON_11:-
ICON_12:-
ICON_13:-
ICON_14:-
ICON_15:-
ICON_16:-
CData 16,216,8,8,8,24,56,120,248,252,253,255,253,252,40,40,56,0 ' "0" - Code for Oil warning 
ICON_17:-
CData 4,4,0,2,0,255,0,0,0 ' Code for char 1 
ICON_18:-
CData 6,130,0,193,0,161,0,145,0,142,0,0,0 ' Code for char 2 
ICON_19:-
CData 6,66,0,129,0,137,0,137,0,118,0,0,0 ' Code for char 3 
ICON_20:-
CData 6,48,0,44,0,34,0,255,0,32,0,0,0 ' Code for char 4 
ICON_21:-
CData 6,76,0,139,0,137,0,137,0,113,0,0,0 ' Code for char 5 
ICON_22:-
CData 6,126,0,137,0,137,0,137,0,114,0,0,0 ' Code for char 6 
ICON_23:-
CData 14,6,15,9,15,6,0,0,62,127,65,65,65,103,38,0 ' "7" - Code for degree c 
ICON_24:-
CData 10,28,62,127,127,0,73,73,73,73,73,0 ' "8" - Code for High beam 
ICON_25:-
CData 10,28,62,127,127,0,73,146,36,72,144,0 ' "9" - Code for Dip beam
ICON_26:-
CData 1,255,0 ' ":" - Code for | used in bargraph 
ICON_27:-
CData 1,0,0 ' ";" - Code for " " used in bargraph   

RGV250

Just a thought, you have not posted your code?? but are you trying to use external fonts IE the INC files but have not declared it so it is using the internal one?

Bob

Pepe

#16
Another example

xvovanx

Thank you all so much for your help, special thanks to Pepe for correcting my fonts!  ;D