Motor de Búsqueda de Datasheet de Componentes Electrónicos
Selected language     Spanish  ▼

Delete All


Preview PDF Download HTML

AN2687 Datasheet(PDF) 10 Page - STMicroelectronics

No. de Pieza. AN2687
Descripción  STM8S20xxx LCD software driver
Descarga  22 Pages
Scroll/Zoom Zoom In 100% Zoom Out
Fabricante  STMICROELECTRONICS [STMicroelectronics]
Página de inicio

AN2687 Datasheet(HTML) 10 Page - STMicroelectronics

Zoom Inzoom in Zoom Outzoom out
 10 / 22 page
background image
Example of a quadruplex LCD driver with STM8
Doc ID 14296 Rev 1
Example of a quadruplex LCD driver with STM8
The following example describes a drive for a quadruplex mode (4 COM) LCD using the
STM8S20xxx (QFP64 package 10 × 10 mm). The only external components needed for
driving the LCD are eight resistors (refer to Figure 5). The resistor value of 470 k
 is used to
reach a low current consumption.
One I/O port per segment and one I/O port for each COM line are needed to drive the LCD.
In our example, to drive a quadruplex LCD that has 128 segments (with 32 segment lines
and 4 COM lines) 36 I/O ports are required.
In the example program, the PG0-PG7, PE0-PE7, PD0-PD7 and PB0-PB7 port pins are
connected to the 32 segment lines and are used to generate the segment signals. As PE1
and PE2 are true open drain I/Os (I2C alternate function), two 10 k
 pull-up resistors have
been added.
Port G segments control the display of LCD digits 1 and 2, port E segments control digits 3
and 4, port D segments controls digits 5 and 6 and port B segments control the display of
LCD digits 7 and 8.
Ports PC4 through PC7 are connected to the 4 COM lines (COM 4, 3, 2 and 1, respectively)
and are used to generate the COM signals.
The LCD driver consists of:
one initialization function (LCD_ON) that correctly configures the required I/Os and the
Timer 2 resource (to get the 2 real-time clock interrupts) for the first method, or the
AWU mode one for the second method.
one display function (LCD_Display) that enables the user to easily enter the string of
characters (8 characters maximum) to be displayed on the 8-digit LCD screen.
one LCD RAM part that contains the coding of the numbers or letters to be displayed
on the LCD (refer to Table 1). This LCD RAM table is filled automatically each time
function is called, depending on the characters composing the string to
a generic.h file containing:
the different possible configurations in terms of numbers of COM and SEG (one
configuration has to be selected, knowing that the default configuration is 4 COM
and 32 SEG)
the clock (HSI with one possible prescaler or LSI)
the values put in the Timer 2 compare and autoreload registers depending on the
chosen LCD frame rate for the first method
the letter and number constant coding tables which are contained in the lcd.c file.
The file can be easily modified by the user depending on the LCD type used.
When the LSI clock is used, in order to speed up the I/O toggling execution, the program
switches to the HSI clock, and returns to the LSI clock once this is done.
For more information regarding the software architecture, please refer to the lcd_awu.pdf
and lcd_timer2.pdf files attached with the source codes in the zip file associated with
this application note.

Html Pages

1  2  3  4  5  6  7  8  9  10  11  12  13  14  15  16  17  18  19  20  21  22 

Datasheet Download

Enlace URL

Privacy Policy
Does ALLDATASHEET help your business so far?  [ DONATE ]  

Todo acerca de Alldatasheet   |   Publicidad   |   Contáctenos   |   Política de Privacidad   |   Favorito   |   Intercambio de Enlaces   |   Lista de Fabricantes
All Rights Reserved©

Mirror Sites
English :  |   English :  |   Chinese :  |   German :  |   Japanese :
Russian :  |   Korean :  |   Spanish :  |   French :  |   Italian :
Portuguese :  |   Polish :  |   Vietnamese :