beautypg.com

4 displaying text, 1 general, 2 writing text to the display – Matrix Orbital GLK12232-25-SM Legacy User Manual

Page 15: 3 text commands

background image

4 Displaying Text

This chapter describes the various text-display commands in detail.

4.1 General

Text is displayed on the GLK12232-25-SM using fonts saved in its internal flash memory. The display

is supplied with a 5x7 font installed. If this is suitable, there will be no need to install any other fonts.

4.2 Writing Text to the Display

When the display receives a character, it displays that character at the position currently defined. The next

character sent to the module then advances to the following position on the display. Characters are drawn

using the currently selected font, and only characters defined in the current font are processed. Characters

which are not defined by the current font are ignored, thus the positioning is not advanced for the next

character.

The position where text is to be displayed, is a single pixel location stored in the display’s volatile

memory and maintained internally by the display’s firmware. It can be manually manipulated with two

commands;

1.

Set current text position (254 71 [col] [row]) positions the characters using a text oriented coordinate

system, dividing the display into character cells.

2.

Set text cursor-pixel values (254 121 [x][y]) Sets text cursor to position (x,y), where x and y are in

pixels. Value is top left corner of next text character. This positions the character at a specific pixel,

allowing ’fine grained’ control when needed.

4.3 Text Commands

In this section commands are identified by their names and decimal values.

4.3.1 Auto Scroll On (254 81)

When auto scrolling is on, it causes the display to shift the entire display’s contents up to make room for

a new line of text when the text reaches the scroll position defined by the "Set font metrics" command in the

display memory (normally the bottom right character position - default value for the GLK12232-25-SM is

64).

4.3.2 Auto Scroll Off (254 82)

When auto scrolling is disabled, text will wrap to the top left corner of the display area. Existing graphics

or text in the display area are not erased before text is placed. When using proportional fonts without auto

Matrix Orbital

GLK12232-25-SM

11