   1              		.syntax unified
   2              		.cpu cortex-m3
   3              		.fpu softvfp
   4              		.eabi_attribute 20, 1
   5              		.eabi_attribute 21, 1
   6              		.eabi_attribute 23, 3
   7              		.eabi_attribute 24, 1
   8              		.eabi_attribute 25, 1
   9              		.eabi_attribute 26, 1
  10              		.eabi_attribute 30, 4
  11              		.eabi_attribute 34, 1
  12              		.eabi_attribute 18, 4
  13              		.thumb
  14              		.syntax unified
  15              		.file	"liquid_crystal.c"
  16              		.text
  17              	.Ltext0:
  18              		.cfi_sections	.debug_frame
  19              		.section	.text.lcd_command,"ax",%progbits
  20              		.align	1
  21              		.thumb
  22              		.thumb_func
  24              	lcd_command:
  25              	.LFB2:
  26              		.file 1 "uc_libc_dev/display/liquid_crystal.c"
   1:uc_libc_dev/display/liquid_crystal.c **** // Tipo de acesso: GPIO ou I2C usando o pcf8574.
   2:uc_libc_dev/display/liquid_crystal.c **** //	Para o pcf8574 a comunicação é 4 bits e consideramos que as seguintes ligações:
   3:uc_libc_dev/display/liquid_crystal.c **** //		P0: LCD_D4
   4:uc_libc_dev/display/liquid_crystal.c **** //		P1: LCD_D5
   5:uc_libc_dev/display/liquid_crystal.c **** //		P2: LCD_D6
   6:uc_libc_dev/display/liquid_crystal.c **** //		P3: LCD_D7
   7:uc_libc_dev/display/liquid_crystal.c **** //		P4: LCD_RS
   8:uc_libc_dev/display/liquid_crystal.c **** //		P5: LCD_RW
   9:uc_libc_dev/display/liquid_crystal.c **** //		P6: LCD_E
  10:uc_libc_dev/display/liquid_crystal.c **** 
  11:uc_libc_dev/display/liquid_crystal.c **** // O módulo display é fabricado com um controlador de exibição.
  12:uc_libc_dev/display/liquid_crystal.c **** // Este controlador tem dois registradores:	um registrador de instrução (IR) e um registrador de da
  13:uc_libc_dev/display/liquid_crystal.c **** // O registrador IR armazena os comandos, tal como limpar o display, fazer um shift e entre outros 
  14:uc_libc_dev/display/liquid_crystal.c **** // O registrador DR armazena temporiaramente o dado que vai ser escrito na DDRAM/CGRAM, ou lido del
  15:uc_libc_dev/display/liquid_crystal.c **** 
  16:uc_libc_dev/display/liquid_crystal.c **** // RS RW Operação
  17:uc_libc_dev/display/liquid_crystal.c **** // 0  0  Envia um comando para o display.
  18:uc_libc_dev/display/liquid_crystal.c **** // 0  1  Lê o flag de ocupado (BF=DB7) e o endereço de contagem (AC=DB[6:0]) de acesso a DDRAM/CGRA
  19:uc_libc_dev/display/liquid_crystal.c **** // 1  0  Escreve dado contido no registrador DR para DDRAM/CGRAM.
  20:uc_libc_dev/display/liquid_crystal.c **** // 1  1  Lê o dado DDRAM/CGRAM para o DR.
  21:uc_libc_dev/display/liquid_crystal.c **** 
  22:uc_libc_dev/display/liquid_crystal.c **** // DDRAM: memória de dados de exibição.
  23:uc_libc_dev/display/liquid_crystal.c **** //	Esta DDRAM é usada para armazenar os dados de exibição. O valor escrito nessa memória é um apont
  24:uc_libc_dev/display/liquid_crystal.c **** //
  25:uc_libc_dev/display/liquid_crystal.c **** //		Apontador para o CGROM e CGRAM (addr 0 a 7)
  26:uc_libc_dev/display/liquid_crystal.c **** // 		Linha	LCD	16 colunas	LCD	20 colunas
  27:uc_libc_dev/display/liquid_crystal.c **** // 		1 		00 - 15 		00 - 19
  28:uc_libc_dev/display/liquid_crystal.c **** // 		2 		20 - 35			20 - 39
  29:uc_libc_dev/display/liquid_crystal.c **** // 		3		64 - 79			64 - 83
  30:uc_libc_dev/display/liquid_crystal.c **** // 		4       84 - 99  		84 - 103
  31:uc_libc_dev/display/liquid_crystal.c **** 
  32:uc_libc_dev/display/liquid_crystal.c **** // CGROM: Memória ROM dos caracteres. Contém os bits da formação de cada caractere. Valores fixos d
  33:uc_libc_dev/display/liquid_crystal.c **** //	O endereço de cada caractere corresponde o seus respectivo valor ASCII
  34:uc_libc_dev/display/liquid_crystal.c **** 
  35:uc_libc_dev/display/liquid_crystal.c **** // CGRAM: Memória de caracteres personalizados
  36:uc_libc_dev/display/liquid_crystal.c **** //	Essa memória podemos construir novos caracteres a serem exibidas no display.
  37:uc_libc_dev/display/liquid_crystal.c **** //	Para caracteres 5×8 pontos podemos salvar até oito padrões, e para 5×10 pontos podemos salvar so
  38:uc_libc_dev/display/liquid_crystal.c **** //	Os endereços de acesso a esses caractres são entre 0 a 8.
  39:uc_libc_dev/display/liquid_crystal.c **** 
  40:uc_libc_dev/display/liquid_crystal.c **** // Registrador de acesso a DDRAM/CGRAM
  41:uc_libc_dev/display/liquid_crystal.c **** // 	O endereço (reg AC) é incrementado automaticamente após escrever ou ler o dados das memórias
  42:uc_libc_dev/display/liquid_crystal.c **** 
  43:uc_libc_dev/display/liquid_crystal.c **** // INSTRUÇÕES
  44:uc_libc_dev/display/liquid_crystal.c **** // RS RW | D7  D6  D5  D4  D3  D2  D1  D0
  45:uc_libc_dev/display/liquid_crystal.c **** // 0  0  | 0   0   0   0   0   0   0   1 		Clear Display: Limpa o display e zera o contador de ende
  46:uc_libc_dev/display/liquid_crystal.c **** // 0  0  | 0   0   0   0   0   0   1   - 		Return Home: Zera o contador de endereços da DDRAM, faz 
  47:uc_libc_dev/display/liquid_crystal.c **** // 0  0  | 0   0   0   0   0   1   ID  SF 		Entry Mode Set: Define a direção de movimento do cursor
  48:uc_libc_dev/display/liquid_crystal.c **** //		 											ID: 0 – decrementa, 1 – incrementa contador de endereços
  49:uc_libc_dev/display/liquid_crystal.c **** //		 											SF: 0 – não acompanha, 1 – acompanha o delocamento do display
  50:uc_libc_dev/display/liquid_crystal.c **** // 0  0  | 0   0   0   0   1   DA  CA  BL 		Definições diversas
  51:uc_libc_dev/display/liquid_crystal.c **** //													DA: 0 – desliga, 1 – liga display
  52:uc_libc_dev/display/liquid_crystal.c **** //													CA: BL
  53:uc_libc_dev/display/liquid_crystal.c **** //													0	0	Desliga cursor
  54:uc_libc_dev/display/liquid_crystal.c **** //													0	1	Cursor OVR (Cursor cheio)
  55:uc_libc_dev/display/liquid_crystal.c **** //													1	0	Cursor INS (Cursor underline)
  56:uc_libc_dev/display/liquid_crystal.c **** //													1	1	Cursor piscando ( alternando entre OVR e INS)
  57:uc_libc_dev/display/liquid_crystal.c **** // 0  0  | 0   0   0   1   SC  RL  -   - 		Movimento de caracteres e cursor no display sem alterar 
  58:uc_libc_dev/display/liquid_crystal.c **** //													SC: 0 – move o cursor, 1 – desloca os caracteres
  59:uc_libc_dev/display/liquid_crystal.c **** //													RL: 0 – desloca para a esquerda, 1 – desloca para a direita
  60:uc_libc_dev/display/liquid_crystal.c **** // 0  0  | 0   0   1   DL  NL  FC  -   - 		Function Set: Define o comprimento de dados da interface
  61:uc_libc_dev/display/liquid_crystal.c **** //													DL: 0 – 4-bits, 1 – 8-bits
  62:uc_libc_dev/display/liquid_crystal.c **** //													NL: 0 – 1 linha, 1 – 2 linhas
  63:uc_libc_dev/display/liquid_crystal.c **** //													FC: 0 – matriz 5x7, 1 – matriz 5x10
  64:uc_libc_dev/display/liquid_crystal.c **** // 0  0  | 0   1   A5  A4  A3  A2  A1  A0 		Set CGRAM Addrress: Armazena o endereço especificado no
  65:uc_libc_dev/display/liquid_crystal.c **** // 0  0  | 1   A6  A5  A4  A3  A2  A1  A0 		Set CGRAM Addrress: Armazena o endereço especificado no
  66:uc_libc_dev/display/liquid_crystal.c **** // 0  1  | BF  A6  A5  A4  A3  A2  A1  A0       Read Busy Flag and register address DDRAM/CGRAM
  67:uc_libc_dev/display/liquid_crystal.c **** // 1  0  | D7  D6  D5  D4  D3  D2  D1  D0		Escreve dado do DR para a DDRAM ou CGRAM
  68:uc_libc_dev/display/liquid_crystal.c **** // 1  1  | D7  D6  D5  D4  D3  D2  D1  D0		Lê dado DDRAM ou CGRAM para o DR
  69:uc_libc_dev/display/liquid_crystal.c **** 
  70:uc_libc_dev/display/liquid_crystal.c **** // TEMPOS
  71:uc_libc_dev/display/liquid_crystal.c **** // Esperar 40ms após ligar display antes de começar enviar os comandos.
  72:uc_libc_dev/display/liquid_crystal.c **** // Comandos 0x01 e 0x02 levam para ser processado 1.64ms os demais 40us
  73:uc_libc_dev/display/liquid_crystal.c **** 
  74:uc_libc_dev/display/liquid_crystal.c **** #include "liquid_crystal.h"
  75:uc_libc_dev/display/liquid_crystal.c **** 
  76:uc_libc_dev/display/liquid_crystal.c **** u8 _row_offsets[4];
  77:uc_libc_dev/display/liquid_crystal.c **** u8 _numlines;
  78:uc_libc_dev/display/liquid_crystal.c **** u8 _displaycontrol;
  79:uc_libc_dev/display/liquid_crystal.c **** u8 _displaymode;
  80:uc_libc_dev/display/liquid_crystal.c **** u8 _displayfunction;
  81:uc_libc_dev/display/liquid_crystal.c **** 
  82:uc_libc_dev/display/liquid_crystal.c **** // espera até o display estiver desocupado
  83:uc_libc_dev/display/liquid_crystal.c **** static void lcd_busy(void)	{
  84:uc_libc_dev/display/liquid_crystal.c **** 	while (lcd_read_command() & 0x80); // Se bit 7 for 1 sinaliza display está ocupado
  85:uc_libc_dev/display/liquid_crystal.c **** }
  86:uc_libc_dev/display/liquid_crystal.c **** 
  87:uc_libc_dev/display/liquid_crystal.c **** static void lcd_SetRowOffsets(int row0, int row1, int row2, int row3) {
  88:uc_libc_dev/display/liquid_crystal.c ****   	_row_offsets[0] = row0;
  89:uc_libc_dev/display/liquid_crystal.c ****   	_row_offsets[1] = row1;
  90:uc_libc_dev/display/liquid_crystal.c ****   	_row_offsets[2] = row2;
  91:uc_libc_dev/display/liquid_crystal.c ****   	_row_offsets[3] = row3;
  92:uc_libc_dev/display/liquid_crystal.c **** }
  93:uc_libc_dev/display/liquid_crystal.c **** 
  94:uc_libc_dev/display/liquid_crystal.c **** static inline void lcd_command(u8 command) {
  27              		.loc 1 94 0
  28              		.cfi_startproc
  29              		@ args = 0, pretend = 0, frame = 0
  30              		@ frame_needed = 0, uses_anonymous_args = 0
  31              	.LVL0:
  32 0000 10B5     		push	{r4, lr}
  33              	.LCFI0:
  34              		.cfi_def_cfa_offset 8
  35              		.cfi_offset 4, -8
  36              		.cfi_offset 14, -4
  37 0002 0446     		mov	r4, r0
  38              	.LVL1:
  39              	.L2:
  40              	.LBB6:
  41              	.LBB7:
  84:uc_libc_dev/display/liquid_crystal.c **** }
  42              		.loc 1 84 0
  43 0004 0020     		movs	r0, #0
  44 0006 FFF7FEFF 		bl	lcd_read
  45              	.LVL2:
  46 000a 0306     		lsls	r3, r0, #24
  47 000c FAD4     		bmi	.L2
  48              	.LBE7:
  49              	.LBE6:
  95:uc_libc_dev/display/liquid_crystal.c ****   	lcd_busy();
  96:uc_libc_dev/display/liquid_crystal.c **** 	lcd_write_command(command);
  50              		.loc 1 96 0
  51 000e 2046     		mov	r0, r4
  97:uc_libc_dev/display/liquid_crystal.c **** }
  52              		.loc 1 97 0
  53 0010 BDE81040 		pop	{r4, lr}
  54              	.LCFI1:
  55              		.cfi_restore 14
  56              		.cfi_restore 4
  57              		.cfi_def_cfa_offset 0
  96:uc_libc_dev/display/liquid_crystal.c **** }
  58              		.loc 1 96 0
  59 0014 0021     		movs	r1, #0
  60 0016 FFF7FEBF 		b	lcd_write
  61              	.LVL3:
  62              		.cfi_endproc
  63              	.LFE2:
  65              		.section	.text.lcd_PutChar,"ax",%progbits
  66              		.align	1
  67              		.global	lcd_PutChar
  68              		.thumb
  69              		.thumb_func
  71              	lcd_PutChar:
  72              	.LFB19:
  98:uc_libc_dev/display/liquid_crystal.c **** 
  99:uc_libc_dev/display/liquid_crystal.c **** // Inicializa o display
 100:uc_libc_dev/display/liquid_crystal.c **** // parametros:
 101:uc_libc_dev/display/liquid_crystal.c **** //	cols: Número de colunas do LCD
 102:uc_libc_dev/display/liquid_crystal.c **** //	lines: Número de linhas do LCD
 103:uc_libc_dev/display/liquid_crystal.c **** //  dotsize: Tamanho da fonte em pontos: LCD_5x8DOTS ou LCD_5x10DOTS
 104:uc_libc_dev/display/liquid_crystal.c **** void lcd_Init(u8 cols, u8 lines, u8 dotsize) {
 105:uc_libc_dev/display/liquid_crystal.c **** 	#if (LCD_CONNECTION == LCD_CONNECTION_PCF8574)
 106:uc_libc_dev/display/liquid_crystal.c **** 	_displayfunction = LCD_4BIT_MODE | LCD_1LINE | dotsize;
 107:uc_libc_dev/display/liquid_crystal.c **** 	#elif (LCD_CONNECTION == LCD_CONNECTION_GPIO_4BITS)
 108:uc_libc_dev/display/liquid_crystal.c **** 	lcd_config_ports();
 109:uc_libc_dev/display/liquid_crystal.c **** 	_displayfunction = LCD_4BIT_MODE | LCD_1LINE | dotsize;
 110:uc_libc_dev/display/liquid_crystal.c **** 	#elif (LCD_CONNECTION == LCD_CONNECTION_GPIO_8BITS)
 111:uc_libc_dev/display/liquid_crystal.c **** 	lcd_config_ports();
 112:uc_libc_dev/display/liquid_crystal.c **** 	_displayfunction = LCD_8BIT_MODE | LCD_1LINE | dotsize;
 113:uc_libc_dev/display/liquid_crystal.c **** 	#endif
 114:uc_libc_dev/display/liquid_crystal.c **** 
 115:uc_libc_dev/display/liquid_crystal.c ****   	if (lines > 1) _displayfunction |= LCD_2LINE;
 116:uc_libc_dev/display/liquid_crystal.c ****   	_numlines = lines;
 117:uc_libc_dev/display/liquid_crystal.c **** 
 118:uc_libc_dev/display/liquid_crystal.c ****   	lcd_SetRowOffsets(0x00, 0x40, 0x00 + cols, 0x40 + cols);
 119:uc_libc_dev/display/liquid_crystal.c **** 
 120:uc_libc_dev/display/liquid_crystal.c ****   	// for some 1 line displays you can select a 10 pixel high font
 121:uc_libc_dev/display/liquid_crystal.c ****   	if ((dotsize != LCD_5x8DOTS) && (lines == 1)) _displayfunction |= LCD_5x10DOTS;
 122:uc_libc_dev/display/liquid_crystal.c **** 
 123:uc_libc_dev/display/liquid_crystal.c ****   	// SEE PAGE 45/46 FOR INITIALIZATION SPECIFICATION!
 124:uc_libc_dev/display/liquid_crystal.c ****   	// according to datasheet, we need at least 40ms after power rises above 2.7V
 125:uc_libc_dev/display/liquid_crystal.c ****   	// before sending commands. CPU can turn on way before 4.5V so we'll wait 50
 126:uc_libc_dev/display/liquid_crystal.c ****   	delay_ms(LCD_DELAY_INIT);
 127:uc_libc_dev/display/liquid_crystal.c **** 
 128:uc_libc_dev/display/liquid_crystal.c ****     // this is according to the hitachi HD44780 datasheet
 129:uc_libc_dev/display/liquid_crystal.c ****     // page 45 figure 23
 130:uc_libc_dev/display/liquid_crystal.c ****     // Send function set command sequence
 131:uc_libc_dev/display/liquid_crystal.c **** 	lcd_write_init(0x30);	// Function set (Interface is 8 bits long.)
 132:uc_libc_dev/display/liquid_crystal.c ****     delay_ms(5);  				// wait more than 4.1ms
 133:uc_libc_dev/display/liquid_crystal.c **** 	lcd_write_init(0x30);	// Function set (Interface is 8 bits long.)
 134:uc_libc_dev/display/liquid_crystal.c **** 	delay_us(150);				// wait more than 100us
 135:uc_libc_dev/display/liquid_crystal.c **** 	lcd_write_init(0x30);	// Function set (Interface is 8 bits long.)
 136:uc_libc_dev/display/liquid_crystal.c **** 
 137:uc_libc_dev/display/liquid_crystal.c **** 	#if (LCD_CONNECTION == LCD_CONNECTION_PCF8574) || (LCD_CONNECTION == LCD_CONNECTION_GPIO_4BITS)
 138:uc_libc_dev/display/liquid_crystal.c **** 	lcd_write_init(LCD_FUNCTION_SET | LCD_4BIT_MODE);
 139:uc_libc_dev/display/liquid_crystal.c **** 	#endif
 140:uc_libc_dev/display/liquid_crystal.c **** 
 141:uc_libc_dev/display/liquid_crystal.c **** 	// finally, set # lines, font size, etc.
 142:uc_libc_dev/display/liquid_crystal.c **** 	lcd_command(LCD_FUNCTION_SET | _displayfunction);
 143:uc_libc_dev/display/liquid_crystal.c **** 
 144:uc_libc_dev/display/liquid_crystal.c ****   	// turn the display on with no cursor or blinking default
 145:uc_libc_dev/display/liquid_crystal.c ****   	_displaycontrol = LCD_DISPLAY_ON | LCD_CURSOR_OFF | LCD_BLINK_OFF;
 146:uc_libc_dev/display/liquid_crystal.c ****   	lcd_Display();
 147:uc_libc_dev/display/liquid_crystal.c **** 
 148:uc_libc_dev/display/liquid_crystal.c ****   	// clear it off
 149:uc_libc_dev/display/liquid_crystal.c ****   	lcd_Clear();
 150:uc_libc_dev/display/liquid_crystal.c **** 
 151:uc_libc_dev/display/liquid_crystal.c ****   	// Initialize to default text direction (for romance languages)
 152:uc_libc_dev/display/liquid_crystal.c ****   	_displaymode = LCD_ENTRY_LEFT | LCD_ENTRY_SHIFT_DECREMENT;
 153:uc_libc_dev/display/liquid_crystal.c ****   	// set the entry mode
 154:uc_libc_dev/display/liquid_crystal.c ****   	lcd_command(LCD_ENTRY_MODE_SET | _displaymode);
 155:uc_libc_dev/display/liquid_crystal.c **** }
 156:uc_libc_dev/display/liquid_crystal.c **** 
 157:uc_libc_dev/display/liquid_crystal.c **** void lcd_Clear(void) {
 158:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_CLEAR_DISPLAY);  // clear display, set cursor position to zero
 159:uc_libc_dev/display/liquid_crystal.c ****   delay_ms(LCD_DELAY_HOME);  // this command takes a long time!
 160:uc_libc_dev/display/liquid_crystal.c **** }
 161:uc_libc_dev/display/liquid_crystal.c **** 
 162:uc_libc_dev/display/liquid_crystal.c **** void lcd_Home(void) {
 163:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_RETURN_HOME);  // set cursor position to zero
 164:uc_libc_dev/display/liquid_crystal.c ****   delay_ms(LCD_DELAY_HOME);  	// this command takes a long time!
 165:uc_libc_dev/display/liquid_crystal.c **** }
 166:uc_libc_dev/display/liquid_crystal.c **** 
 167:uc_libc_dev/display/liquid_crystal.c **** void lcd_SetCursor(u8 col, u8 row) {
 168:uc_libc_dev/display/liquid_crystal.c ****   const uint max_lines = sizeof(_row_offsets) / sizeof(*_row_offsets);
 169:uc_libc_dev/display/liquid_crystal.c ****   if ( row >= max_lines ) row = max_lines - 1;    // we count rows starting w/0
 170:uc_libc_dev/display/liquid_crystal.c ****   if ( row >= _numlines ) row = _numlines - 1;    // we count rows starting w/0
 171:uc_libc_dev/display/liquid_crystal.c **** 
 172:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_SET_DDRAM_ADDR | (col + _row_offsets[row]));
 173:uc_libc_dev/display/liquid_crystal.c **** }
 174:uc_libc_dev/display/liquid_crystal.c **** 
 175:uc_libc_dev/display/liquid_crystal.c **** // Turn the display on/off (quickly)
 176:uc_libc_dev/display/liquid_crystal.c **** void lcd_NoDisplay(void) {
 177:uc_libc_dev/display/liquid_crystal.c ****   _displaycontrol &= ~LCD_DISPLAY_ON;
 178:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_DISPLAY_CONTROL | _displaycontrol);
 179:uc_libc_dev/display/liquid_crystal.c **** }
 180:uc_libc_dev/display/liquid_crystal.c **** 
 181:uc_libc_dev/display/liquid_crystal.c **** void lcd_Display(void) {
 182:uc_libc_dev/display/liquid_crystal.c ****   _displaycontrol |= LCD_DISPLAY_ON;
 183:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_DISPLAY_CONTROL | _displaycontrol);
 184:uc_libc_dev/display/liquid_crystal.c **** }
 185:uc_libc_dev/display/liquid_crystal.c **** 
 186:uc_libc_dev/display/liquid_crystal.c **** // Turns the underline cursor on/off
 187:uc_libc_dev/display/liquid_crystal.c **** void lcd_NoCursor(void) {
 188:uc_libc_dev/display/liquid_crystal.c ****   _displaycontrol &= ~LCD_CURSOR_ON;
 189:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_DISPLAY_CONTROL | _displaycontrol);
 190:uc_libc_dev/display/liquid_crystal.c **** }
 191:uc_libc_dev/display/liquid_crystal.c **** 
 192:uc_libc_dev/display/liquid_crystal.c **** // TODO colocar cursor(on/off) e para outras funções também
 193:uc_libc_dev/display/liquid_crystal.c **** void lcd_Cursor(void) {
 194:uc_libc_dev/display/liquid_crystal.c ****   _displaycontrol |= LCD_CURSOR_ON;
 195:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_DISPLAY_CONTROL | _displaycontrol);
 196:uc_libc_dev/display/liquid_crystal.c **** }
 197:uc_libc_dev/display/liquid_crystal.c **** 
 198:uc_libc_dev/display/liquid_crystal.c **** // desliga o cursor
 199:uc_libc_dev/display/liquid_crystal.c **** void lcd_NoBlink(void) {
 200:uc_libc_dev/display/liquid_crystal.c ****   _displaycontrol &= ~LCD_BLINK_ON;
 201:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_DISPLAY_CONTROL | _displaycontrol);
 202:uc_libc_dev/display/liquid_crystal.c **** }
 203:uc_libc_dev/display/liquid_crystal.c **** 
 204:uc_libc_dev/display/liquid_crystal.c **** // Pisca o cursor
 205:uc_libc_dev/display/liquid_crystal.c **** void lcd_Blink(void) {
 206:uc_libc_dev/display/liquid_crystal.c ****   _displaycontrol |= LCD_BLINK_ON;
 207:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_DISPLAY_CONTROL | _displaycontrol);
 208:uc_libc_dev/display/liquid_crystal.c **** }
 209:uc_libc_dev/display/liquid_crystal.c **** 
 210:uc_libc_dev/display/liquid_crystal.c **** // These commands scroll the display without changing the RAM
 211:uc_libc_dev/display/liquid_crystal.c **** void lcd_ScrollDisplayLeft(void) {
 212:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_CURSOR_SHIFT | LCD_DISPLAY_MOVE | LCD_MOVE_LEFT);
 213:uc_libc_dev/display/liquid_crystal.c **** }
 214:uc_libc_dev/display/liquid_crystal.c **** 
 215:uc_libc_dev/display/liquid_crystal.c **** void lcd_ScrollDisplayRight(void) {
 216:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_CURSOR_SHIFT | LCD_DISPLAY_MOVE | LCD_MOVE_RIGHT);
 217:uc_libc_dev/display/liquid_crystal.c **** }
 218:uc_libc_dev/display/liquid_crystal.c **** 
 219:uc_libc_dev/display/liquid_crystal.c **** // This is for text that flows Left to Right
 220:uc_libc_dev/display/liquid_crystal.c **** void lcd_LeftToRight(void) {
 221:uc_libc_dev/display/liquid_crystal.c ****   _displaymode |= LCD_ENTRY_LEFT;
 222:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_ENTRY_MODE_SET | _displaymode);
 223:uc_libc_dev/display/liquid_crystal.c **** }
 224:uc_libc_dev/display/liquid_crystal.c **** 
 225:uc_libc_dev/display/liquid_crystal.c **** // This is for text that flows Right to Left
 226:uc_libc_dev/display/liquid_crystal.c **** void lcd_RightToLeft(void) {
 227:uc_libc_dev/display/liquid_crystal.c ****   _displaymode &= ~LCD_ENTRY_LEFT;
 228:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_ENTRY_MODE_SET | _displaymode);
 229:uc_libc_dev/display/liquid_crystal.c **** }
 230:uc_libc_dev/display/liquid_crystal.c **** 
 231:uc_libc_dev/display/liquid_crystal.c **** // This will 'right justify' text from the cursor
 232:uc_libc_dev/display/liquid_crystal.c **** void lcd_AutoScroll(void) {
 233:uc_libc_dev/display/liquid_crystal.c ****   _displaymode |= LCD_ENTRY_SHIFT_INCREMENT;
 234:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_ENTRY_MODE_SET | _displaymode);
 235:uc_libc_dev/display/liquid_crystal.c **** }
 236:uc_libc_dev/display/liquid_crystal.c **** 
 237:uc_libc_dev/display/liquid_crystal.c **** // This will 'left justify' text from the cursor
 238:uc_libc_dev/display/liquid_crystal.c **** void lcd_NoAutoScroll(void) {
 239:uc_libc_dev/display/liquid_crystal.c ****   _displaymode &= ~LCD_ENTRY_SHIFT_INCREMENT;
 240:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_ENTRY_MODE_SET | _displaymode);
 241:uc_libc_dev/display/liquid_crystal.c **** }
 242:uc_libc_dev/display/liquid_crystal.c **** 
 243:uc_libc_dev/display/liquid_crystal.c **** // Imprime um caractere no display, no endereço atual da DDRAM apontado pelo reg AC.
 244:uc_libc_dev/display/liquid_crystal.c **** //	O reg AC é incrementado automaticamente
 245:uc_libc_dev/display/liquid_crystal.c **** // Esta função também é usada pelo rprintf
 246:uc_libc_dev/display/liquid_crystal.c **** int lcd_PutChar(n16 ch) {
  73              		.loc 1 246 0
  74              		.cfi_startproc
  75              		@ args = 0, pretend = 0, frame = 0
  76              		@ frame_needed = 0, uses_anonymous_args = 0
  77              	.LVL4:
  78 0000 10B5     		push	{r4, lr}
  79              	.LCFI2:
  80              		.cfi_def_cfa_offset 8
  81              		.cfi_offset 4, -8
  82              		.cfi_offset 14, -4
  83 0002 0446     		mov	r4, r0
  84              	.LVL5:
  85              	.L6:
  86              	.LBB10:
  87              	.LBB11:
  84:uc_libc_dev/display/liquid_crystal.c **** }
  88              		.loc 1 84 0
  89 0004 0020     		movs	r0, #0
  90 0006 FFF7FEFF 		bl	lcd_read
  91              	.LVL6:
  92 000a 0306     		lsls	r3, r0, #24
  93 000c FAD4     		bmi	.L6
  94              	.LBE11:
  95              	.LBE10:
 247:uc_libc_dev/display/liquid_crystal.c **** 	lcd_busy();
 248:uc_libc_dev/display/liquid_crystal.c **** 	lcd_write_data((u8)ch);
  96              		.loc 1 248 0
  97 000e E0B2     		uxtb	r0, r4
  98 0010 0121     		movs	r1, #1
  99 0012 FFF7FEFF 		bl	lcd_write
 100              	.LVL7:
 249:uc_libc_dev/display/liquid_crystal.c **** 	return (int)ch;												// Retorna com o caractere a ser TX
 250:uc_libc_dev/display/liquid_crystal.c **** }
 101              		.loc 1 250 0
 102 0016 2046     		mov	r0, r4
 103 0018 10BD     		pop	{r4, pc}
 104              		.cfi_endproc
 105              	.LFE19:
 107              		.section	.text.lcd_Clear,"ax",%progbits
 108              		.align	1
 109              		.global	lcd_Clear
 110              		.thumb
 111              		.thumb_func
 113              	lcd_Clear:
 114              	.LFB4:
 157:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_CLEAR_DISPLAY);  // clear display, set cursor position to zero
 115              		.loc 1 157 0
 116              		.cfi_startproc
 117              		@ args = 0, pretend = 0, frame = 0
 118              		@ frame_needed = 0, uses_anonymous_args = 0
 119 0000 08B5     		push	{r3, lr}
 120              	.LCFI3:
 121              		.cfi_def_cfa_offset 8
 122              		.cfi_offset 3, -8
 123              		.cfi_offset 14, -4
 158:uc_libc_dev/display/liquid_crystal.c ****   delay_ms(LCD_DELAY_HOME);  // this command takes a long time!
 124              		.loc 1 158 0
 125 0002 0120     		movs	r0, #1
 126 0004 FFF7FEFF 		bl	lcd_command
 127              	.LVL8:
 160:uc_libc_dev/display/liquid_crystal.c **** 
 128              		.loc 1 160 0
 129 0008 BDE80840 		pop	{r3, lr}
 130              	.LCFI4:
 131              		.cfi_restore 14
 132              		.cfi_restore 3
 133              		.cfi_def_cfa_offset 0
 159:uc_libc_dev/display/liquid_crystal.c **** }
 134              		.loc 1 159 0
 135 000c 0148     		ldr	r0, .L9
 136 000e FFF7FEBF 		b	delay
 137              	.LVL9:
 138              	.L10:
 139 0012 00BF     		.align	2
 140              	.L9:
 141 0014 D0010100 		.word	66000
 142              		.cfi_endproc
 143              	.LFE4:
 145              		.section	.text.lcd_Home,"ax",%progbits
 146              		.align	1
 147              		.global	lcd_Home
 148              		.thumb
 149              		.thumb_func
 151              	lcd_Home:
 152              	.LFB5:
 162:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_RETURN_HOME);  // set cursor position to zero
 153              		.loc 1 162 0
 154              		.cfi_startproc
 155              		@ args = 0, pretend = 0, frame = 0
 156              		@ frame_needed = 0, uses_anonymous_args = 0
 157 0000 08B5     		push	{r3, lr}
 158              	.LCFI5:
 159              		.cfi_def_cfa_offset 8
 160              		.cfi_offset 3, -8
 161              		.cfi_offset 14, -4
 163:uc_libc_dev/display/liquid_crystal.c ****   delay_ms(LCD_DELAY_HOME);  	// this command takes a long time!
 162              		.loc 1 163 0
 163 0002 0220     		movs	r0, #2
 164 0004 FFF7FEFF 		bl	lcd_command
 165              	.LVL10:
 165:uc_libc_dev/display/liquid_crystal.c **** 
 166              		.loc 1 165 0
 167 0008 BDE80840 		pop	{r3, lr}
 168              	.LCFI6:
 169              		.cfi_restore 14
 170              		.cfi_restore 3
 171              		.cfi_def_cfa_offset 0
 164:uc_libc_dev/display/liquid_crystal.c **** }
 172              		.loc 1 164 0
 173 000c 0148     		ldr	r0, .L12
 174 000e FFF7FEBF 		b	delay
 175              	.LVL11:
 176              	.L13:
 177 0012 00BF     		.align	2
 178              	.L12:
 179 0014 D0010100 		.word	66000
 180              		.cfi_endproc
 181              	.LFE5:
 183              		.section	.text.lcd_SetCursor,"ax",%progbits
 184              		.align	1
 185              		.global	lcd_SetCursor
 186              		.thumb
 187              		.thumb_func
 189              	lcd_SetCursor:
 190              	.LFB6:
 167:uc_libc_dev/display/liquid_crystal.c ****   const uint max_lines = sizeof(_row_offsets) / sizeof(*_row_offsets);
 191              		.loc 1 167 0
 192              		.cfi_startproc
 193              		@ args = 0, pretend = 0, frame = 0
 194              		@ frame_needed = 0, uses_anonymous_args = 0
 195              		@ link register save eliminated.
 196              	.LVL12:
 170:uc_libc_dev/display/liquid_crystal.c **** 
 197              		.loc 1 170 0
 198 0000 084B     		ldr	r3, .L16
 199 0002 0329     		cmp	r1, #3
 200 0004 1B78     		ldrb	r3, [r3]	@ zero_extendqisi2
 201 0006 28BF     		it	cs
 202 0008 0321     		movcs	r1, #3
 203              	.LVL13:
 204 000a 8B42     		cmp	r3, r1
 205 000c 9CBF     		itt	ls
 206 000e 03F1FF33 		addls	r3, r3, #-1
 207 0012 D9B2     		uxtbls	r1, r3
 208              	.LVL14:
 172:uc_libc_dev/display/liquid_crystal.c **** }
 209              		.loc 1 172 0
 210 0014 044B     		ldr	r3, .L16+4
 211 0016 5B5C     		ldrb	r3, [r3, r1]	@ zero_extendqisi2
 212 0018 1844     		add	r0, r0, r3
 213              	.LVL15:
 214 001a 60F07F00 		orn	r0, r0, #127
 215 001e C0B2     		uxtb	r0, r0
 216 0020 FFF7FEBF 		b	lcd_command
 217              	.LVL16:
 218              	.L17:
 219              		.align	2
 220              	.L16:
 221 0024 00000000 		.word	_numlines
 222 0028 00000000 		.word	_row_offsets
 223              		.cfi_endproc
 224              	.LFE6:
 226              		.section	.text.lcd_NoDisplay,"ax",%progbits
 227              		.align	1
 228              		.global	lcd_NoDisplay
 229              		.thumb
 230              		.thumb_func
 232              	lcd_NoDisplay:
 233              	.LFB7:
 176:uc_libc_dev/display/liquid_crystal.c ****   _displaycontrol &= ~LCD_DISPLAY_ON;
 234              		.loc 1 176 0
 235              		.cfi_startproc
 236              		@ args = 0, pretend = 0, frame = 0
 237              		@ frame_needed = 0, uses_anonymous_args = 0
 238              		@ link register save eliminated.
 177:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_DISPLAY_CONTROL | _displaycontrol);
 239              		.loc 1 177 0
 240 0000 044B     		ldr	r3, .L19
 241 0002 1878     		ldrb	r0, [r3]	@ zero_extendqisi2
 242 0004 00F0FB00 		and	r0, r0, #251
 243 0008 1870     		strb	r0, [r3]
 178:uc_libc_dev/display/liquid_crystal.c **** }
 244              		.loc 1 178 0
 245 000a 40F00800 		orr	r0, r0, #8
 246 000e FFF7FEBF 		b	lcd_command
 247              	.LVL17:
 248              	.L20:
 249 0012 00BF     		.align	2
 250              	.L19:
 251 0014 00000000 		.word	_displaycontrol
 252              		.cfi_endproc
 253              	.LFE7:
 255              		.section	.text.lcd_Display,"ax",%progbits
 256              		.align	1
 257              		.global	lcd_Display
 258              		.thumb
 259              		.thumb_func
 261              	lcd_Display:
 262              	.LFB8:
 181:uc_libc_dev/display/liquid_crystal.c ****   _displaycontrol |= LCD_DISPLAY_ON;
 263              		.loc 1 181 0
 264              		.cfi_startproc
 265              		@ args = 0, pretend = 0, frame = 0
 266              		@ frame_needed = 0, uses_anonymous_args = 0
 267              		@ link register save eliminated.
 182:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_DISPLAY_CONTROL | _displaycontrol);
 268              		.loc 1 182 0
 269 0000 044B     		ldr	r3, .L22
 270 0002 1878     		ldrb	r0, [r3]	@ zero_extendqisi2
 271 0004 40F00402 		orr	r2, r0, #4
 183:uc_libc_dev/display/liquid_crystal.c **** }
 272              		.loc 1 183 0
 273 0008 40F00C00 		orr	r0, r0, #12
 182:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_DISPLAY_CONTROL | _displaycontrol);
 274              		.loc 1 182 0
 275 000c 1A70     		strb	r2, [r3]
 183:uc_libc_dev/display/liquid_crystal.c **** }
 276              		.loc 1 183 0
 277 000e FFF7FEBF 		b	lcd_command
 278              	.LVL18:
 279              	.L23:
 280 0012 00BF     		.align	2
 281              	.L22:
 282 0014 00000000 		.word	_displaycontrol
 283              		.cfi_endproc
 284              	.LFE8:
 286              		.section	.text.lcd_Init,"ax",%progbits
 287              		.align	1
 288              		.global	lcd_Init
 289              		.thumb
 290              		.thumb_func
 292              	lcd_Init:
 293              	.LFB3:
 104:uc_libc_dev/display/liquid_crystal.c **** 	#if (LCD_CONNECTION == LCD_CONNECTION_PCF8574)
 294              		.loc 1 104 0
 295              		.cfi_startproc
 296              		@ args = 0, pretend = 0, frame = 0
 297              		@ frame_needed = 0, uses_anonymous_args = 0
 298              	.LVL19:
 299 0000 F8B5     		push	{r3, r4, r5, r6, r7, lr}
 300              	.LCFI7:
 301              		.cfi_def_cfa_offset 24
 302              		.cfi_offset 3, -24
 303              		.cfi_offset 4, -20
 304              		.cfi_offset 5, -16
 305              		.cfi_offset 6, -12
 306              		.cfi_offset 7, -8
 307              		.cfi_offset 14, -4
 104:uc_libc_dev/display/liquid_crystal.c **** 	#if (LCD_CONNECTION == LCD_CONNECTION_PCF8574)
 308              		.loc 1 104 0
 309 0002 0E46     		mov	r6, r1
 310 0004 1746     		mov	r7, r2
 311 0006 0546     		mov	r5, r0
 111:uc_libc_dev/display/liquid_crystal.c **** 	_displayfunction = LCD_8BIT_MODE | LCD_1LINE | dotsize;
 312              		.loc 1 111 0
 313 0008 FFF7FEFF 		bl	lcd_config_ports
 314              	.LVL20:
 315 000c 214C     		ldr	r4, .L32
 115:uc_libc_dev/display/liquid_crystal.c ****   	_numlines = lines;
 316              		.loc 1 115 0
 317 000e 012E     		cmp	r6, #1
 112:uc_libc_dev/display/liquid_crystal.c **** 	#endif
 318              		.loc 1 112 0
 319 0010 94BF     		ite	ls
 320 0012 47F01003 		orrls	r3, r7, #16
 115:uc_libc_dev/display/liquid_crystal.c ****   	_numlines = lines;
 321              		.loc 1 115 0
 322 0016 47F01803 		orrhi	r3, r7, #24
 323 001a 2370     		strb	r3, [r4]
 116:uc_libc_dev/display/liquid_crystal.c **** 
 324              		.loc 1 116 0
 325 001c 1E4B     		ldr	r3, .L32+4
 326              	.LBB12:
 327              	.LBB13:
  88:uc_libc_dev/display/liquid_crystal.c ****   	_row_offsets[1] = row1;
 328              		.loc 1 88 0
 329 001e 0022     		movs	r2, #0
 330              	.LBE13:
 331              	.LBE12:
 116:uc_libc_dev/display/liquid_crystal.c **** 
 332              		.loc 1 116 0
 333 0020 1E70     		strb	r6, [r3]
 334              	.LVL21:
 335              	.LBB15:
 336              	.LBB14:
  88:uc_libc_dev/display/liquid_crystal.c ****   	_row_offsets[1] = row1;
 337              		.loc 1 88 0
 338 0022 1E4B     		ldr	r3, .L32+8
 339 0024 1A70     		strb	r2, [r3]
  89:uc_libc_dev/display/liquid_crystal.c ****   	_row_offsets[2] = row2;
 340              		.loc 1 89 0
 341 0026 4022     		movs	r2, #64
  90:uc_libc_dev/display/liquid_crystal.c ****   	_row_offsets[3] = row3;
 342              		.loc 1 90 0
 343 0028 9D70     		strb	r5, [r3, #2]
  91:uc_libc_dev/display/liquid_crystal.c **** }
 344              		.loc 1 91 0
 345 002a 1544     		add	r5, r5, r2
 346              	.LVL22:
  89:uc_libc_dev/display/liquid_crystal.c ****   	_row_offsets[2] = row2;
 347              		.loc 1 89 0
 348 002c 5A70     		strb	r2, [r3, #1]
  91:uc_libc_dev/display/liquid_crystal.c **** }
 349              		.loc 1 91 0
 350 002e DD70     		strb	r5, [r3, #3]
 351              	.LVL23:
 352              	.LBE14:
 353              	.LBE15:
 121:uc_libc_dev/display/liquid_crystal.c **** 
 354              		.loc 1 121 0
 355 0030 2FB1     		cbz	r7, .L27
 121:uc_libc_dev/display/liquid_crystal.c **** 
 356              		.loc 1 121 0 is_stmt 0 discriminator 1
 357 0032 012E     		cmp	r6, #1
 358 0034 02BF     		ittt	eq
 359 0036 2378     		ldrbeq	r3, [r4]	@ zero_extendqisi2
 360 0038 43F00403 		orreq	r3, r3, #4
 361 003c 2370     		strbeq	r3, [r4]
 362              	.L27:
 126:uc_libc_dev/display/liquid_crystal.c **** 
 363              		.loc 1 126 0 is_stmt 1
 364 003e 1848     		ldr	r0, .L32+12
 365 0040 FFF7FEFF 		bl	delay
 366              	.LVL24:
 131:uc_libc_dev/display/liquid_crystal.c ****     delay_ms(5);  				// wait more than 4.1ms
 367              		.loc 1 131 0
 368 0044 0021     		movs	r1, #0
 369 0046 3020     		movs	r0, #48
 370 0048 FFF7FEFF 		bl	lcd_write
 371              	.LVL25:
 132:uc_libc_dev/display/liquid_crystal.c **** 	lcd_write_init(0x30);	// Function set (Interface is 8 bits long.)
 372              		.loc 1 132 0
 373 004c 1548     		ldr	r0, .L32+16
 374 004e FFF7FEFF 		bl	delay
 375              	.LVL26:
 133:uc_libc_dev/display/liquid_crystal.c **** 	delay_us(150);				// wait more than 100us
 376              		.loc 1 133 0
 377 0052 0021     		movs	r1, #0
 378 0054 3020     		movs	r0, #48
 379 0056 FFF7FEFF 		bl	lcd_write
 380              	.LVL27:
 134:uc_libc_dev/display/liquid_crystal.c **** 	lcd_write_init(0x30);	// Function set (Interface is 8 bits long.)
 381              		.loc 1 134 0
 382 005a 41F28830 		movw	r0, #5000
 383 005e FFF7FEFF 		bl	delay
 384              	.LVL28:
 135:uc_libc_dev/display/liquid_crystal.c **** 
 385              		.loc 1 135 0
 386 0062 0021     		movs	r1, #0
 387 0064 3020     		movs	r0, #48
 388 0066 FFF7FEFF 		bl	lcd_write
 389              	.LVL29:
 142:uc_libc_dev/display/liquid_crystal.c **** 
 390              		.loc 1 142 0
 391 006a 2078     		ldrb	r0, [r4]	@ zero_extendqisi2
 392 006c 40F02000 		orr	r0, r0, #32
 393 0070 FFF7FEFF 		bl	lcd_command
 394              	.LVL30:
 145:uc_libc_dev/display/liquid_crystal.c ****   	lcd_Display();
 395              		.loc 1 145 0
 396 0074 0C4B     		ldr	r3, .L32+20
 397 0076 0422     		movs	r2, #4
 398 0078 1A70     		strb	r2, [r3]
 146:uc_libc_dev/display/liquid_crystal.c **** 
 399              		.loc 1 146 0
 400 007a FFF7FEFF 		bl	lcd_Display
 401              	.LVL31:
 149:uc_libc_dev/display/liquid_crystal.c **** 
 402              		.loc 1 149 0
 403 007e FFF7FEFF 		bl	lcd_Clear
 404              	.LVL32:
 152:uc_libc_dev/display/liquid_crystal.c ****   	// set the entry mode
 405              		.loc 1 152 0
 406 0082 0A4B     		ldr	r3, .L32+24
 407 0084 0222     		movs	r2, #2
 408 0086 1A70     		strb	r2, [r3]
 154:uc_libc_dev/display/liquid_crystal.c **** }
 409              		.loc 1 154 0
 410 0088 0620     		movs	r0, #6
 155:uc_libc_dev/display/liquid_crystal.c **** 
 411              		.loc 1 155 0
 412 008a BDE8F840 		pop	{r3, r4, r5, r6, r7, lr}
 413              	.LCFI8:
 414              		.cfi_restore 14
 415              		.cfi_restore 7
 416              		.cfi_restore 6
 417              		.cfi_restore 5
 418              		.cfi_restore 4
 419              		.cfi_restore 3
 420              		.cfi_def_cfa_offset 0
 154:uc_libc_dev/display/liquid_crystal.c **** }
 421              		.loc 1 154 0
 422 008e FFF7FEBF 		b	lcd_command
 423              	.LVL33:
 424              	.L33:
 425 0092 00BF     		.align	2
 426              	.L32:
 427 0094 00000000 		.word	_displayfunction
 428 0098 00000000 		.word	_numlines
 429 009c 00000000 		.word	_row_offsets
 430 00a0 90290A00 		.word	666000
 431 00a4 70880200 		.word	166000
 432 00a8 00000000 		.word	_displaycontrol
 433 00ac 00000000 		.word	_displaymode
 434              		.cfi_endproc
 435              	.LFE3:
 437              		.section	.text.lcd_NoCursor,"ax",%progbits
 438              		.align	1
 439              		.global	lcd_NoCursor
 440              		.thumb
 441              		.thumb_func
 443              	lcd_NoCursor:
 444              	.LFB9:
 187:uc_libc_dev/display/liquid_crystal.c ****   _displaycontrol &= ~LCD_CURSOR_ON;
 445              		.loc 1 187 0
 446              		.cfi_startproc
 447              		@ args = 0, pretend = 0, frame = 0
 448              		@ frame_needed = 0, uses_anonymous_args = 0
 449              		@ link register save eliminated.
 188:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_DISPLAY_CONTROL | _displaycontrol);
 450              		.loc 1 188 0
 451 0000 044B     		ldr	r3, .L35
 452 0002 1878     		ldrb	r0, [r3]	@ zero_extendqisi2
 453 0004 00F0FD00 		and	r0, r0, #253
 454 0008 1870     		strb	r0, [r3]
 189:uc_libc_dev/display/liquid_crystal.c **** }
 455              		.loc 1 189 0
 456 000a 40F00800 		orr	r0, r0, #8
 457 000e FFF7FEBF 		b	lcd_command
 458              	.LVL34:
 459              	.L36:
 460 0012 00BF     		.align	2
 461              	.L35:
 462 0014 00000000 		.word	_displaycontrol
 463              		.cfi_endproc
 464              	.LFE9:
 466              		.section	.text.lcd_Cursor,"ax",%progbits
 467              		.align	1
 468              		.global	lcd_Cursor
 469              		.thumb
 470              		.thumb_func
 472              	lcd_Cursor:
 473              	.LFB10:
 193:uc_libc_dev/display/liquid_crystal.c ****   _displaycontrol |= LCD_CURSOR_ON;
 474              		.loc 1 193 0
 475              		.cfi_startproc
 476              		@ args = 0, pretend = 0, frame = 0
 477              		@ frame_needed = 0, uses_anonymous_args = 0
 478              		@ link register save eliminated.
 194:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_DISPLAY_CONTROL | _displaycontrol);
 479              		.loc 1 194 0
 480 0000 044B     		ldr	r3, .L38
 481 0002 1878     		ldrb	r0, [r3]	@ zero_extendqisi2
 482 0004 40F00202 		orr	r2, r0, #2
 195:uc_libc_dev/display/liquid_crystal.c **** }
 483              		.loc 1 195 0
 484 0008 40F00A00 		orr	r0, r0, #10
 194:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_DISPLAY_CONTROL | _displaycontrol);
 485              		.loc 1 194 0
 486 000c 1A70     		strb	r2, [r3]
 195:uc_libc_dev/display/liquid_crystal.c **** }
 487              		.loc 1 195 0
 488 000e FFF7FEBF 		b	lcd_command
 489              	.LVL35:
 490              	.L39:
 491 0012 00BF     		.align	2
 492              	.L38:
 493 0014 00000000 		.word	_displaycontrol
 494              		.cfi_endproc
 495              	.LFE10:
 497              		.section	.text.lcd_NoBlink,"ax",%progbits
 498              		.align	1
 499              		.global	lcd_NoBlink
 500              		.thumb
 501              		.thumb_func
 503              	lcd_NoBlink:
 504              	.LFB11:
 199:uc_libc_dev/display/liquid_crystal.c ****   _displaycontrol &= ~LCD_BLINK_ON;
 505              		.loc 1 199 0
 506              		.cfi_startproc
 507              		@ args = 0, pretend = 0, frame = 0
 508              		@ frame_needed = 0, uses_anonymous_args = 0
 509              		@ link register save eliminated.
 200:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_DISPLAY_CONTROL | _displaycontrol);
 510              		.loc 1 200 0
 511 0000 044B     		ldr	r3, .L41
 512 0002 1878     		ldrb	r0, [r3]	@ zero_extendqisi2
 513 0004 00F0FE00 		and	r0, r0, #254
 514 0008 1870     		strb	r0, [r3]
 201:uc_libc_dev/display/liquid_crystal.c **** }
 515              		.loc 1 201 0
 516 000a 40F00800 		orr	r0, r0, #8
 517 000e FFF7FEBF 		b	lcd_command
 518              	.LVL36:
 519              	.L42:
 520 0012 00BF     		.align	2
 521              	.L41:
 522 0014 00000000 		.word	_displaycontrol
 523              		.cfi_endproc
 524              	.LFE11:
 526              		.section	.text.lcd_Blink,"ax",%progbits
 527              		.align	1
 528              		.global	lcd_Blink
 529              		.thumb
 530              		.thumb_func
 532              	lcd_Blink:
 533              	.LFB12:
 205:uc_libc_dev/display/liquid_crystal.c ****   _displaycontrol |= LCD_BLINK_ON;
 534              		.loc 1 205 0
 535              		.cfi_startproc
 536              		@ args = 0, pretend = 0, frame = 0
 537              		@ frame_needed = 0, uses_anonymous_args = 0
 538              		@ link register save eliminated.
 206:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_DISPLAY_CONTROL | _displaycontrol);
 539              		.loc 1 206 0
 540 0000 044B     		ldr	r3, .L44
 541 0002 1878     		ldrb	r0, [r3]	@ zero_extendqisi2
 542 0004 40F00102 		orr	r2, r0, #1
 207:uc_libc_dev/display/liquid_crystal.c **** }
 543              		.loc 1 207 0
 544 0008 40F00900 		orr	r0, r0, #9
 206:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_DISPLAY_CONTROL | _displaycontrol);
 545              		.loc 1 206 0
 546 000c 1A70     		strb	r2, [r3]
 207:uc_libc_dev/display/liquid_crystal.c **** }
 547              		.loc 1 207 0
 548 000e FFF7FEBF 		b	lcd_command
 549              	.LVL37:
 550              	.L45:
 551 0012 00BF     		.align	2
 552              	.L44:
 553 0014 00000000 		.word	_displaycontrol
 554              		.cfi_endproc
 555              	.LFE12:
 557              		.section	.text.lcd_ScrollDisplayLeft,"ax",%progbits
 558              		.align	1
 559              		.global	lcd_ScrollDisplayLeft
 560              		.thumb
 561              		.thumb_func
 563              	lcd_ScrollDisplayLeft:
 564              	.LFB13:
 211:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_CURSOR_SHIFT | LCD_DISPLAY_MOVE | LCD_MOVE_LEFT);
 565              		.loc 1 211 0
 566              		.cfi_startproc
 567              		@ args = 0, pretend = 0, frame = 0
 568              		@ frame_needed = 0, uses_anonymous_args = 0
 569              		@ link register save eliminated.
 212:uc_libc_dev/display/liquid_crystal.c **** }
 570              		.loc 1 212 0
 571 0000 1820     		movs	r0, #24
 572 0002 FFF7FEBF 		b	lcd_command
 573              	.LVL38:
 574              		.cfi_endproc
 575              	.LFE13:
 577              		.section	.text.lcd_ScrollDisplayRight,"ax",%progbits
 578              		.align	1
 579              		.global	lcd_ScrollDisplayRight
 580              		.thumb
 581              		.thumb_func
 583              	lcd_ScrollDisplayRight:
 584              	.LFB14:
 215:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_CURSOR_SHIFT | LCD_DISPLAY_MOVE | LCD_MOVE_RIGHT);
 585              		.loc 1 215 0
 586              		.cfi_startproc
 587              		@ args = 0, pretend = 0, frame = 0
 588              		@ frame_needed = 0, uses_anonymous_args = 0
 589              		@ link register save eliminated.
 216:uc_libc_dev/display/liquid_crystal.c **** }
 590              		.loc 1 216 0
 591 0000 1C20     		movs	r0, #28
 592 0002 FFF7FEBF 		b	lcd_command
 593              	.LVL39:
 594              		.cfi_endproc
 595              	.LFE14:
 597              		.section	.text.lcd_LeftToRight,"ax",%progbits
 598              		.align	1
 599              		.global	lcd_LeftToRight
 600              		.thumb
 601              		.thumb_func
 603              	lcd_LeftToRight:
 604              	.LFB15:
 220:uc_libc_dev/display/liquid_crystal.c ****   _displaymode |= LCD_ENTRY_LEFT;
 605              		.loc 1 220 0
 606              		.cfi_startproc
 607              		@ args = 0, pretend = 0, frame = 0
 608              		@ frame_needed = 0, uses_anonymous_args = 0
 609              		@ link register save eliminated.
 221:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_ENTRY_MODE_SET | _displaymode);
 610              		.loc 1 221 0
 611 0000 044B     		ldr	r3, .L49
 612 0002 1878     		ldrb	r0, [r3]	@ zero_extendqisi2
 613 0004 40F00202 		orr	r2, r0, #2
 222:uc_libc_dev/display/liquid_crystal.c **** }
 614              		.loc 1 222 0
 615 0008 40F00600 		orr	r0, r0, #6
 221:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_ENTRY_MODE_SET | _displaymode);
 616              		.loc 1 221 0
 617 000c 1A70     		strb	r2, [r3]
 222:uc_libc_dev/display/liquid_crystal.c **** }
 618              		.loc 1 222 0
 619 000e FFF7FEBF 		b	lcd_command
 620              	.LVL40:
 621              	.L50:
 622 0012 00BF     		.align	2
 623              	.L49:
 624 0014 00000000 		.word	_displaymode
 625              		.cfi_endproc
 626              	.LFE15:
 628              		.section	.text.lcd_RightToLeft,"ax",%progbits
 629              		.align	1
 630              		.global	lcd_RightToLeft
 631              		.thumb
 632              		.thumb_func
 634              	lcd_RightToLeft:
 635              	.LFB16:
 226:uc_libc_dev/display/liquid_crystal.c ****   _displaymode &= ~LCD_ENTRY_LEFT;
 636              		.loc 1 226 0
 637              		.cfi_startproc
 638              		@ args = 0, pretend = 0, frame = 0
 639              		@ frame_needed = 0, uses_anonymous_args = 0
 640              		@ link register save eliminated.
 227:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_ENTRY_MODE_SET | _displaymode);
 641              		.loc 1 227 0
 642 0000 044B     		ldr	r3, .L52
 643 0002 1878     		ldrb	r0, [r3]	@ zero_extendqisi2
 644 0004 00F0FD00 		and	r0, r0, #253
 645 0008 1870     		strb	r0, [r3]
 228:uc_libc_dev/display/liquid_crystal.c **** }
 646              		.loc 1 228 0
 647 000a 40F00400 		orr	r0, r0, #4
 648 000e FFF7FEBF 		b	lcd_command
 649              	.LVL41:
 650              	.L53:
 651 0012 00BF     		.align	2
 652              	.L52:
 653 0014 00000000 		.word	_displaymode
 654              		.cfi_endproc
 655              	.LFE16:
 657              		.section	.text.lcd_AutoScroll,"ax",%progbits
 658              		.align	1
 659              		.global	lcd_AutoScroll
 660              		.thumb
 661              		.thumb_func
 663              	lcd_AutoScroll:
 664              	.LFB17:
 232:uc_libc_dev/display/liquid_crystal.c ****   _displaymode |= LCD_ENTRY_SHIFT_INCREMENT;
 665              		.loc 1 232 0
 666              		.cfi_startproc
 667              		@ args = 0, pretend = 0, frame = 0
 668              		@ frame_needed = 0, uses_anonymous_args = 0
 669              		@ link register save eliminated.
 233:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_ENTRY_MODE_SET | _displaymode);
 670              		.loc 1 233 0
 671 0000 044B     		ldr	r3, .L55
 672 0002 1878     		ldrb	r0, [r3]	@ zero_extendqisi2
 673 0004 40F00102 		orr	r2, r0, #1
 234:uc_libc_dev/display/liquid_crystal.c **** }
 674              		.loc 1 234 0
 675 0008 40F00500 		orr	r0, r0, #5
 233:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_ENTRY_MODE_SET | _displaymode);
 676              		.loc 1 233 0
 677 000c 1A70     		strb	r2, [r3]
 234:uc_libc_dev/display/liquid_crystal.c **** }
 678              		.loc 1 234 0
 679 000e FFF7FEBF 		b	lcd_command
 680              	.LVL42:
 681              	.L56:
 682 0012 00BF     		.align	2
 683              	.L55:
 684 0014 00000000 		.word	_displaymode
 685              		.cfi_endproc
 686              	.LFE17:
 688              		.section	.text.lcd_NoAutoScroll,"ax",%progbits
 689              		.align	1
 690              		.global	lcd_NoAutoScroll
 691              		.thumb
 692              		.thumb_func
 694              	lcd_NoAutoScroll:
 695              	.LFB18:
 238:uc_libc_dev/display/liquid_crystal.c ****   _displaymode &= ~LCD_ENTRY_SHIFT_INCREMENT;
 696              		.loc 1 238 0
 697              		.cfi_startproc
 698              		@ args = 0, pretend = 0, frame = 0
 699              		@ frame_needed = 0, uses_anonymous_args = 0
 700              		@ link register save eliminated.
 239:uc_libc_dev/display/liquid_crystal.c ****   lcd_command(LCD_ENTRY_MODE_SET | _displaymode);
 701              		.loc 1 239 0
 702 0000 044B     		ldr	r3, .L58
 703 0002 1878     		ldrb	r0, [r3]	@ zero_extendqisi2
 704 0004 00F0FE00 		and	r0, r0, #254
 705 0008 1870     		strb	r0, [r3]
 240:uc_libc_dev/display/liquid_crystal.c **** }
 706              		.loc 1 240 0
 707 000a 40F00400 		orr	r0, r0, #4
 708 000e FFF7FEBF 		b	lcd_command
 709              	.LVL43:
 710              	.L59:
 711 0012 00BF     		.align	2
 712              	.L58:
 713 0014 00000000 		.word	_displaymode
 714              		.cfi_endproc
 715              	.LFE18:
 717              		.section	.text.lcd_CreateChar,"ax",%progbits
 718              		.align	1
 719              		.global	lcd_CreateChar
 720              		.thumb
 721              		.thumb_func
 723              	lcd_CreateChar:
 724              	.LFB20:
 251:uc_libc_dev/display/liquid_crystal.c **** 
 252:uc_libc_dev/display/liquid_crystal.c **** // Salva caracteres personalizados nas posições 0 a 7 da memória CGRAM que serão acessadas
 253:uc_libc_dev/display/liquid_crystal.c **** //	escrevendo valores de 0 a 7 na DDRAM
 254:uc_libc_dev/display/liquid_crystal.c **** // Paramêtros:
 255:uc_libc_dev/display/liquid_crystal.c **** //	location: Endereço CGRAM. Valores de 0 a 7
 256:uc_libc_dev/display/liquid_crystal.c **** //	charmap: Ponteiro para o vetor de 8 posições que constitui a formação do novo caractere
 257:uc_libc_dev/display/liquid_crystal.c **** void lcd_CreateChar(u8 location, u8 charmap[]) {
 725              		.loc 1 257 0
 726              		.cfi_startproc
 727              		@ args = 0, pretend = 0, frame = 0
 728              		@ frame_needed = 0, uses_anonymous_args = 0
 729              	.LVL44:
 730 0000 70B5     		push	{r4, r5, r6, lr}
 731              	.LCFI9:
 732              		.cfi_def_cfa_offset 16
 733              		.cfi_offset 4, -16
 734              		.cfi_offset 5, -12
 735              		.cfi_offset 6, -8
 736              		.cfi_offset 14, -4
 737              		.loc 1 257 0
 738 0002 0446     		mov	r4, r0
 258:uc_libc_dev/display/liquid_crystal.c **** 	u8 addr = lcd_read_command() & 0x7F; // pega o endereço da DDRAM atual
 739              		.loc 1 258 0
 740 0004 0020     		movs	r0, #0
 741              	.LVL45:
 257:uc_libc_dev/display/liquid_crystal.c **** 	u8 addr = lcd_read_command() & 0x7F; // pega o endereço da DDRAM atual
 742              		.loc 1 257 0
 743 0006 0D46     		mov	r5, r1
 744              		.loc 1 258 0
 745 0008 FFF7FEFF 		bl	lcd_read
 746              	.LVL46:
 747 000c 00F07F06 		and	r6, r0, #127
 748              	.LVL47:
 259:uc_libc_dev/display/liquid_crystal.c **** 
 260:uc_libc_dev/display/liquid_crystal.c **** 	location &= 0x7; // we only have 8 locations 0-7
 261:uc_libc_dev/display/liquid_crystal.c ****   	lcd_command(LCD_SET_CGRAM_ADDR | (location << 3)); // ajusta o endereço deslocando sempre oito b
 749              		.loc 1 261 0
 750 0010 04F00700 		and	r0, r4, #7
 751 0014 C000     		lsls	r0, r0, #3
 752 0016 40F04000 		orr	r0, r0, #64
 753 001a FFF7FEFF 		bl	lcd_command
 754              	.LVL48:
 755 001e 6C1E     		subs	r4, r5, #1
 756              	.LVL49:
 757 0020 0735     		adds	r5, r5, #7
 758              	.LVL50:
 759              	.L61:
 262:uc_libc_dev/display/liquid_crystal.c ****   	uint i;	for (i=0; i<8; i++) lcd_PutChar(charmap[i]);
 760              		.loc 1 262 0 discriminator 3
 761 0022 14F8010F 		ldrb	r0, [r4, #1]!	@ zero_extendqisi2
 762              	.LVL51:
 763 0026 FFF7FEFF 		bl	lcd_PutChar
 764              	.LVL52:
 765 002a AC42     		cmp	r4, r5
 766 002c F9D1     		bne	.L61
 263:uc_libc_dev/display/liquid_crystal.c **** 
 264:uc_libc_dev/display/liquid_crystal.c ****   	lcd_command(LCD_SET_DDRAM_ADDR | addr); // atualiza o endereço DDRAM e instrui o LCD a trablhar 
 767              		.loc 1 264 0
 768 002e 46F08000 		orr	r0, r6, #128
 265:uc_libc_dev/display/liquid_crystal.c **** }
 769              		.loc 1 265 0
 770 0032 BDE87040 		pop	{r4, r5, r6, lr}
 771              	.LCFI10:
 772              		.cfi_restore 14
 773              		.cfi_restore 6
 774              		.cfi_restore 5
 775              		.cfi_restore 4
 776              		.cfi_def_cfa_offset 0
 777              	.LVL53:
 264:uc_libc_dev/display/liquid_crystal.c **** }
 778              		.loc 1 264 0
 779 0036 FFF7FEBF 		b	lcd_command
 780              	.LVL54:
 781              		.cfi_endproc
 782              	.LFE20:
 784              		.section	.text.lcd_printfInit,"ax",%progbits
 785              		.align	1
 786              		.global	lcd_printfInit
 787              		.thumb
 788              		.thumb_func
 790              	lcd_printfInit:
 791              	.LFB21:
 266:uc_libc_dev/display/liquid_crystal.c **** 
 267:uc_libc_dev/display/liquid_crystal.c **** 
 268:uc_libc_dev/display/liquid_crystal.c **** #if (LCD_USE_PRINTF == pdON)
 269:uc_libc_dev/display/liquid_crystal.c **** #include "stdio_uc.h"
 270:uc_libc_dev/display/liquid_crystal.c **** static uint devicePrintf = 0;
 271:uc_libc_dev/display/liquid_crystal.c **** u8 _cols;
 272:uc_libc_dev/display/liquid_crystal.c **** void lcd_printfInit(uint cols, uint dev) {
 792              		.loc 1 272 0
 793              		.cfi_startproc
 794              		@ args = 0, pretend = 0, frame = 0
 795              		@ frame_needed = 0, uses_anonymous_args = 0
 796              		@ link register save eliminated.
 797              	.LVL55:
 798              		.loc 1 272 0
 799 0000 0B46     		mov	r3, r1
 273:uc_libc_dev/display/liquid_crystal.c **** 	_cols = cols;
 800              		.loc 1 273 0
 801 0002 044A     		ldr	r2, .L64
 802 0004 1070     		strb	r0, [r2]
 274:uc_libc_dev/display/liquid_crystal.c **** 	devicePrintf = dev;
 803              		.loc 1 274 0
 804 0006 044A     		ldr	r2, .L64+4
 275:uc_libc_dev/display/liquid_crystal.c **** 	rprintf_RegisterDev(dev, lcd_PutChar);								// Anexa a função ao printf
 805              		.loc 1 275 0
 806 0008 D8B2     		uxtb	r0, r3
 807              	.LVL56:
 274:uc_libc_dev/display/liquid_crystal.c **** 	devicePrintf = dev;
 808              		.loc 1 274 0
 809 000a 1160     		str	r1, [r2]
 810              		.loc 1 275 0
 811 000c 0349     		ldr	r1, .L64+8
 812              	.LVL57:
 813 000e FFF7FEBF 		b	rprintf_RegisterDev
 814              	.LVL58:
 815              	.L65:
 816 0012 00BF     		.align	2
 817              	.L64:
 818 0014 00000000 		.word	_cols
 819 0018 00000000 		.word	.LANCHOR0
 820 001c 00000000 		.word	lcd_PutChar
 821              		.cfi_endproc
 822              	.LFE21:
 824              		.section	.text.lcd_printf,"ax",%progbits
 825              		.align	1
 826              		.global	lcd_printf
 827              		.thumb
 828              		.thumb_func
 830              	lcd_printf:
 831              	.LFB22:
 276:uc_libc_dev/display/liquid_crystal.c **** }
 277:uc_libc_dev/display/liquid_crystal.c **** 
 278:uc_libc_dev/display/liquid_crystal.c **** // faz o mesmo que rprintf, porém acrescenta espaços vazios para preencher toda a linha,
 279:uc_libc_dev/display/liquid_crystal.c **** //	apagando os caracteres impressos anteriormente
 280:uc_libc_dev/display/liquid_crystal.c **** void lcd_printf(const cpchar fmt, ...) {
 832              		.loc 1 280 0
 833              		.cfi_startproc
 834              		@ args = 4, pretend = 16, frame = 88
 835              		@ frame_needed = 0, uses_anonymous_args = 1
 836              	.LVL59:
 837 0000 0FB4     		push	{r0, r1, r2, r3}
 838              	.LCFI11:
 839              		.cfi_def_cfa_offset 16
 840              		.cfi_offset 0, -16
 841              		.cfi_offset 1, -12
 842              		.cfi_offset 2, -8
 843              		.cfi_offset 3, -4
 844 0002 10B5     		push	{r4, lr}
 845              	.LCFI12:
 846              		.cfi_def_cfa_offset 24
 847              		.cfi_offset 4, -24
 848              		.cfi_offset 14, -20
 849 0004 96B0     		sub	sp, sp, #88
 850              	.LCFI13:
 851              		.cfi_def_cfa_offset 112
 852              		.loc 1 280 0
 853 0006 18AA     		add	r2, sp, #96
 854 0008 52F8041B 		ldr	r1, [r2], #4
 281:uc_libc_dev/display/liquid_crystal.c **** 	string s;
 282:uc_libc_dev/display/liquid_crystal.c **** 	tPrint output;
 283:uc_libc_dev/display/liquid_crystal.c **** 
 284:uc_libc_dev/display/liquid_crystal.c **** 	output.device = 0;
 855              		.loc 1 284 0
 856 000c 0023     		movs	r3, #0
 857 000e 8DF81430 		strb	r3, [sp, #20]
 285:uc_libc_dev/display/liquid_crystal.c **** 	output.buf = s;					// Sinaliza qual buffer para armazenar a formatação de string. Também sinaliza
 858              		.loc 1 285 0
 859 0012 06AC     		add	r4, sp, #24
 286:uc_libc_dev/display/liquid_crystal.c **** 	output.isSformat = 1;			// Sinaliza que é um sformat
 860              		.loc 1 286 0
 861 0014 0123     		movs	r3, #1
 287:uc_libc_dev/display/liquid_crystal.c **** 
 288:uc_libc_dev/display/liquid_crystal.c **** 	va_list args;					// Cria var para captura de argumentos (fmt) no stack da chamada de função
 289:uc_libc_dev/display/liquid_crystal.c **** 	va_start(args, fmt);			// Captura os argumentos após fmt
 290:uc_libc_dev/display/liquid_crystal.c **** 	doprint(&output, fmt, args);	// Faz a formatação da string com ftm e args e manda imprimir
 862              		.loc 1 290 0
 863 0016 02A8     		add	r0, sp, #8
 286:uc_libc_dev/display/liquid_crystal.c **** 	output.isSformat = 1;			// Sinaliza que é um sformat
 864              		.loc 1 286 0
 865 0018 8DF81330 		strb	r3, [sp, #19]
 289:uc_libc_dev/display/liquid_crystal.c **** 	doprint(&output, fmt, args);	// Faz a formatação da string com ftm e args e manda imprimir
 866              		.loc 1 289 0
 867 001c 0192     		str	r2, [sp, #4]
 285:uc_libc_dev/display/liquid_crystal.c **** 	output.isSformat = 1;			// Sinaliza que é um sformat
 868              		.loc 1 285 0
 869 001e 0294     		str	r4, [sp, #8]
 870              		.loc 1 290 0
 871 0020 FFF7FEFF 		bl	doprint
 872              	.LVL60:
 291:uc_libc_dev/display/liquid_crystal.c **** 	va_end(args);					// Desmonta args
 292:uc_libc_dev/display/liquid_crystal.c **** 
 293:uc_libc_dev/display/liquid_crystal.c **** 	uint len = strlen(s);
 873              		.loc 1 293 0
 874 0024 2046     		mov	r0, r4
 875 0026 FFF7FEFF 		bl	strlen
 876              	.LVL61:
 294:uc_libc_dev/display/liquid_crystal.c **** 	uint x; for (x=len;x<_cols;x++) s[x]=' ';
 877              		.loc 1 294 0
 878 002a 094B     		ldr	r3, .L70
 879 002c 2022     		movs	r2, #32
 880 002e 1B78     		ldrb	r3, [r3]	@ zero_extendqisi2
 881              	.LVL62:
 882              	.L67:
 883              		.loc 1 294 0 is_stmt 0 discriminator 1
 884 0030 9842     		cmp	r0, r3
 885 0032 02D2     		bcs	.L69
 886              		.loc 1 294 0 discriminator 3
 887 0034 2254     		strb	r2, [r4, r0]
 888 0036 0130     		adds	r0, r0, #1
 889              	.LVL63:
 890 0038 FAE7     		b	.L67
 891              	.L69:
 295:uc_libc_dev/display/liquid_crystal.c **** 	rprintf(devicePrintf, "%s", s);
 892              		.loc 1 295 0 is_stmt 1
 893 003a 064B     		ldr	r3, .L70+4
 894 003c 2246     		mov	r2, r4
 895 003e 0649     		ldr	r1, .L70+8
 896 0040 1878     		ldrb	r0, [r3]	@ zero_extendqisi2
 897              	.LVL64:
 898 0042 FFF7FEFF 		bl	rprintf
 899              	.LVL65:
 296:uc_libc_dev/display/liquid_crystal.c **** }
 900              		.loc 1 296 0
 901 0046 16B0     		add	sp, sp, #88
 902              	.LCFI14:
 903              		.cfi_def_cfa_offset 24
 904              		@ sp needed
 905 0048 BDE81040 		pop	{r4, lr}
 906              	.LCFI15:
 907              		.cfi_restore 14
 908              		.cfi_restore 4
 909              		.cfi_def_cfa_offset 16
 910 004c 04B0     		add	sp, sp, #16
 911              	.LCFI16:
 912              		.cfi_restore 3
 913              		.cfi_restore 2
 914              		.cfi_restore 1
 915              		.cfi_restore 0
 916              		.cfi_def_cfa_offset 0
 917 004e 7047     		bx	lr
 918              	.L71:
 919              		.align	2
 920              	.L70:
 921 0050 00000000 		.word	_cols
 922 0054 00000000 		.word	.LANCHOR0
 923 0058 00000000 		.word	.LC0
 924              		.cfi_endproc
 925              	.LFE22:
 927              		.comm	_cols,1,1
 928              		.comm	_displayfunction,1,1
 929              		.comm	_displaymode,1,1
 930              		.comm	_displaycontrol,1,1
 931              		.comm	_numlines,1,1
 932              		.comm	_row_offsets,4,1
 933              		.section	.rodata.str1.1,"aMS",%progbits,1
 934              	.LC0:
 935 0000 257300   		.ascii	"%s\000"
 936              		.section	.bss.devicePrintf,"aw",%nobits
 937              		.align	2
 938              		.set	.LANCHOR0,. + 0
 941              	devicePrintf:
 942 0000 00000000 		.space	4
 943              		.text
 944              	.Letext0:
 945              		.file 2 "uc_libc_dev/_libdef/uc_libdefs.h"
 946              		.file 3 "d:\\cc\\arm-yagarto-5.4.2016q3\\lib\\gcc\\arm-none-eabi\\5.4.1\\include\\stdarg.h"
 947              		.file 4 "uc_libc_dev/stdio/stdio_uc.h"
 948              		.file 5 "uc_libc_dev/display/portable/arm_lpc/lcd_drv.h"
 949              		.file 6 "uc_libc_dev/_arch/arm_lpc/timer/delay.h"
 950              		.file 7 "d:\\cc\\arm-yagarto-5.4.2016q3\\arm-none-eabi\\include\\string.h"
 951              		.file 8 "<built-in>"
DEFINED SYMBOLS
                            *ABS*:00000000 liquid_crystal.c
D:\_temp\_windows\ccioVP2g.s:20     .text.lcd_command:00000000 $t
D:\_temp\_windows\ccioVP2g.s:24     .text.lcd_command:00000000 lcd_command
D:\_temp\_windows\ccioVP2g.s:66     .text.lcd_PutChar:00000000 $t
D:\_temp\_windows\ccioVP2g.s:71     .text.lcd_PutChar:00000000 lcd_PutChar
D:\_temp\_windows\ccioVP2g.s:108    .text.lcd_Clear:00000000 $t
D:\_temp\_windows\ccioVP2g.s:113    .text.lcd_Clear:00000000 lcd_Clear
D:\_temp\_windows\ccioVP2g.s:141    .text.lcd_Clear:00000014 $d
D:\_temp\_windows\ccioVP2g.s:146    .text.lcd_Home:00000000 $t
D:\_temp\_windows\ccioVP2g.s:151    .text.lcd_Home:00000000 lcd_Home
D:\_temp\_windows\ccioVP2g.s:179    .text.lcd_Home:00000014 $d
D:\_temp\_windows\ccioVP2g.s:184    .text.lcd_SetCursor:00000000 $t
D:\_temp\_windows\ccioVP2g.s:189    .text.lcd_SetCursor:00000000 lcd_SetCursor
D:\_temp\_windows\ccioVP2g.s:221    .text.lcd_SetCursor:00000024 $d
                            *COM*:00000001 _numlines
                            *COM*:00000004 _row_offsets
D:\_temp\_windows\ccioVP2g.s:227    .text.lcd_NoDisplay:00000000 $t
D:\_temp\_windows\ccioVP2g.s:232    .text.lcd_NoDisplay:00000000 lcd_NoDisplay
D:\_temp\_windows\ccioVP2g.s:251    .text.lcd_NoDisplay:00000014 $d
                            *COM*:00000001 _displaycontrol
D:\_temp\_windows\ccioVP2g.s:256    .text.lcd_Display:00000000 $t
D:\_temp\_windows\ccioVP2g.s:261    .text.lcd_Display:00000000 lcd_Display
D:\_temp\_windows\ccioVP2g.s:282    .text.lcd_Display:00000014 $d
D:\_temp\_windows\ccioVP2g.s:287    .text.lcd_Init:00000000 $t
D:\_temp\_windows\ccioVP2g.s:292    .text.lcd_Init:00000000 lcd_Init
D:\_temp\_windows\ccioVP2g.s:427    .text.lcd_Init:00000094 $d
                            *COM*:00000001 _displayfunction
                            *COM*:00000001 _displaymode
D:\_temp\_windows\ccioVP2g.s:438    .text.lcd_NoCursor:00000000 $t
D:\_temp\_windows\ccioVP2g.s:443    .text.lcd_NoCursor:00000000 lcd_NoCursor
D:\_temp\_windows\ccioVP2g.s:462    .text.lcd_NoCursor:00000014 $d
D:\_temp\_windows\ccioVP2g.s:467    .text.lcd_Cursor:00000000 $t
D:\_temp\_windows\ccioVP2g.s:472    .text.lcd_Cursor:00000000 lcd_Cursor
D:\_temp\_windows\ccioVP2g.s:493    .text.lcd_Cursor:00000014 $d
D:\_temp\_windows\ccioVP2g.s:498    .text.lcd_NoBlink:00000000 $t
D:\_temp\_windows\ccioVP2g.s:503    .text.lcd_NoBlink:00000000 lcd_NoBlink
D:\_temp\_windows\ccioVP2g.s:522    .text.lcd_NoBlink:00000014 $d
D:\_temp\_windows\ccioVP2g.s:527    .text.lcd_Blink:00000000 $t
D:\_temp\_windows\ccioVP2g.s:532    .text.lcd_Blink:00000000 lcd_Blink
D:\_temp\_windows\ccioVP2g.s:553    .text.lcd_Blink:00000014 $d
D:\_temp\_windows\ccioVP2g.s:558    .text.lcd_ScrollDisplayLeft:00000000 $t
D:\_temp\_windows\ccioVP2g.s:563    .text.lcd_ScrollDisplayLeft:00000000 lcd_ScrollDisplayLeft
D:\_temp\_windows\ccioVP2g.s:578    .text.lcd_ScrollDisplayRight:00000000 $t
D:\_temp\_windows\ccioVP2g.s:583    .text.lcd_ScrollDisplayRight:00000000 lcd_ScrollDisplayRight
D:\_temp\_windows\ccioVP2g.s:598    .text.lcd_LeftToRight:00000000 $t
D:\_temp\_windows\ccioVP2g.s:603    .text.lcd_LeftToRight:00000000 lcd_LeftToRight
D:\_temp\_windows\ccioVP2g.s:624    .text.lcd_LeftToRight:00000014 $d
D:\_temp\_windows\ccioVP2g.s:629    .text.lcd_RightToLeft:00000000 $t
D:\_temp\_windows\ccioVP2g.s:634    .text.lcd_RightToLeft:00000000 lcd_RightToLeft
D:\_temp\_windows\ccioVP2g.s:653    .text.lcd_RightToLeft:00000014 $d
D:\_temp\_windows\ccioVP2g.s:658    .text.lcd_AutoScroll:00000000 $t
D:\_temp\_windows\ccioVP2g.s:663    .text.lcd_AutoScroll:00000000 lcd_AutoScroll
D:\_temp\_windows\ccioVP2g.s:684    .text.lcd_AutoScroll:00000014 $d
D:\_temp\_windows\ccioVP2g.s:689    .text.lcd_NoAutoScroll:00000000 $t
D:\_temp\_windows\ccioVP2g.s:694    .text.lcd_NoAutoScroll:00000000 lcd_NoAutoScroll
D:\_temp\_windows\ccioVP2g.s:713    .text.lcd_NoAutoScroll:00000014 $d
D:\_temp\_windows\ccioVP2g.s:718    .text.lcd_CreateChar:00000000 $t
D:\_temp\_windows\ccioVP2g.s:723    .text.lcd_CreateChar:00000000 lcd_CreateChar
D:\_temp\_windows\ccioVP2g.s:785    .text.lcd_printfInit:00000000 $t
D:\_temp\_windows\ccioVP2g.s:790    .text.lcd_printfInit:00000000 lcd_printfInit
D:\_temp\_windows\ccioVP2g.s:818    .text.lcd_printfInit:00000014 $d
                            *COM*:00000001 _cols
D:\_temp\_windows\ccioVP2g.s:825    .text.lcd_printf:00000000 $t
D:\_temp\_windows\ccioVP2g.s:830    .text.lcd_printf:00000000 lcd_printf
D:\_temp\_windows\ccioVP2g.s:921    .text.lcd_printf:00000050 $d
D:\_temp\_windows\ccioVP2g.s:937    .bss.devicePrintf:00000000 $d
D:\_temp\_windows\ccioVP2g.s:941    .bss.devicePrintf:00000000 devicePrintf
                     .debug_frame:00000010 $d

UNDEFINED SYMBOLS
lcd_read
lcd_write
delay
lcd_config_ports
rprintf_RegisterDev
doprint
strlen
rprintf
