📄 lcdp8666.txt
字号:
; generated by ARM C/C++ Compiler with , RVCT4.0 [Build 524] for uVision
; commandline ArmCC [--split_sections --debug -c --asm --interleave -o.\Obj\lcdp8666.o --depend=.\Obj\lcdp8666.d --device=DARMSTM --apcs=interwork -O3 -I..\..\include -I..\..\..\FWLib\library\inc -I..\..\..\USBLib\library\inc -I..\..\Config -I..\..\GUI\Core -I..\..\GUI\Font -I..\..\GUI\ConvertColor -I..\..\GUI\AntiAlias -I..\..\GUI\ConvertMono -I..\..\GUI\JPEG -I..\..\GUI\MemDev -I..\..\GUI\MultiLayer -I..\..\GUI\Widget -I..\..\GUI\WM -IC:\Keil\ARM\INC\ST\STM32F10x ..\..\GUI\ConvertColor\LCDP8666.c]
THUMB
AREA ||i.LCD_Color2Index_8666||, CODE, READONLY, ALIGN=1
LCD_Color2Index_8666 PROC
;;;56 */
;;;57 unsigned LCD_Color2Index_8666(LCD_COLOR Color) {
000000 b2c1 UXTB r1,r0
;;;58 int r,g,b,Index;
;;;59 r = Color&255;
;;;60 g = (Color>>8)&255;
000002 f3c02207 UBFX r2,r0,#8,#8
000006 b510 PUSH {r4,lr} ;57
;;;61 b = Color>>16;
000008 0c00 LSRS r0,r0,#16
;;;62 /* Check if image is a gray scale ... */
;;;63 if ((r==g) && (g==b)) {
00000a 4291 CMP r1,r2
00000c d107 BNE |L1.30|
00000e 4282 CMP r2,r0
000010 d105 BNE |L1.30|
;;;64 return 120+ (r+8)/17; /* Convert into colors from 120 - 135*/
000012 3108 ADDS r1,r1,#8
000014 2011 MOVS r0,#0x11
000016 fb91f0f0 SDIV r0,r1,r0
00001a 3078 ADDS r0,r0,#0x78
|L1.28|
;;;65 }
;;;66 /* Convert into the 6*6*6 colors ... */
;;;67 r = (r*5+127)/255;
;;;68 g = (g*5+127)/255;
;;;69 b = (b*5+127)/255;
;;;70 Index = r+6*g+36*b;
;;;71 return (Index<108) ? Index : Index+40;
;;;72 }
00001c bd10 POP {r4,pc}
|L1.30|
00001e 23ff MOVS r3,#0xff ;67
000020 eb010181 ADD r1,r1,r1,LSL #2 ;67
000024 317f ADDS r1,r1,#0x7f ;67
000026 fb91f4f3 SDIV r4,r1,r3 ;67
00002a eb020182 ADD r1,r2,r2,LSL #2 ;68
00002e 317f ADDS r1,r1,#0x7f ;68
000030 eb000080 ADD r0,r0,r0,LSL #2 ;69
000034 fb91f1f3 SDIV r1,r1,r3 ;68
000038 307f ADDS r0,r0,#0x7f ;69
00003a fb90f0f3 SDIV r0,r0,r3 ;69
00003e eb010141 ADD r1,r1,r1,LSL #1 ;70
000042 eb040141 ADD r1,r4,r1,LSL #1 ;70
000046 eb0000c0 ADD r0,r0,r0,LSL #3 ;70
00004a eb010080 ADD r0,r1,r0,LSL #2 ;70
00004e 286c CMP r0,#0x6c ;71
000050 dbe4 BLT |L1.28|
000052 3028 ADDS r0,r0,#0x28 ;71
000054 bd10 POP {r4,pc}
;;;73
ENDP
AREA ||i.LCD_GetIndexMask_8666||, CODE, READONLY, ALIGN=1
LCD_GetIndexMask_8666 PROC
;;;99 */
;;;100 unsigned LCD_GetIndexMask_8666(void) {
000000 20ff MOVS r0,#0xff
;;;101 return 0xff;
;;;102 }
000002 4770 BX lr
;;;103
ENDP
AREA ||i.LCD_Index2Color_8666||, CODE, READONLY, ALIGN=1
LCD_Index2Color_8666 PROC
;;;77 */
;;;78 LCD_COLOR LCD_Index2Color_8666(int Index) {
000000 b510 PUSH {r4,lr}
;;;79 unsigned int r,g;
;;;80 U32 b;
;;;81 /* 16 Gray scale range ? */
;;;82 if ((Index>=120) && (Index<136)) {
000002 f1a00178 SUB r1,r0,#0x78
000006 2910 CMP r1,#0x10
000008 d206 BCS |L3.24|
;;;83 return (U32)0x111111 * (U32)(Index-120);
00000a eb011001 ADD r0,r1,r1,LSL #4
00000e eb002001 ADD r0,r0,r1,LSL #8
000012 eb003000 ADD r0,r0,r0,LSL #12
;;;84 }
;;;85 if (Index>=108) {
;;;86 if (Index<148)
;;;87 return 0; /* Black for illegal indices */
;;;88 Index -= 40;
;;;89 }
;;;90 r = (Index%6)*(255/5);
;;;91 g = ((Index/6)%6)*(255/5);
;;;92 b = (Index/36)*(255/5);
;;;93 return r+(g<<8)+((U32)b<<16);
;;;94 }
000016 bd10 POP {r4,pc}
|L3.24|
000018 286c CMP r0,#0x6c ;85
00001a db04 BLT |L3.38|
00001c 2894 CMP r0,#0x94 ;86
00001e da01 BGE |L3.36|
000020 2000 MOVS r0,#0 ;87
000022 bd10 POP {r4,pc}
|L3.36|
000024 3828 SUBS r0,r0,#0x28 ;88
|L3.38|
000026 2106 MOVS r1,#6 ;90
000028 fb90f2f1 SDIV r2,r0,r1 ;90
00002c fb92f4f1 SDIV r4,r2,r1 ;91
000030 fb010312 MLS r3,r1,r2,r0 ;90
000034 fb012114 MLS r1,r1,r4,r2 ;91
000038 2224 MOVS r2,#0x24 ;92
00003a fb90f0f2 SDIV r0,r0,r2 ;92
00003e eb031303 ADD r3,r3,r3,LSL #4 ;90
000042 eb011101 ADD r1,r1,r1,LSL #4 ;91
000046 eb030343 ADD r3,r3,r3,LSL #1 ;90
00004a eb010141 ADD r1,r1,r1,LSL #1 ;91
00004e eb001000 ADD r0,r0,r0,LSL #4 ;92
000052 eb000040 ADD r0,r0,r0,LSL #1 ;92
000056 eb032101 ADD r1,r3,r1,LSL #8 ;93
00005a eb014000 ADD r0,r1,r0,LSL #16 ;93
00005e bd10 POP {r4,pc}
;;;95
ENDP
AREA ||.constdata||, DATA, READONLY, ALIGN=2
LCD_API_ColorConv_8666
DCD LCD_Color2Index_8666
DCD LCD_Index2Color_8666
DCD LCD_GetIndexMask_8666
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -