📄 func.lst
字号:
C51 COMPILER V7.06 FUNC 01/02/2000 11:14:26 PAGE 1
C51 COMPILER V7.06, COMPILATION OF MODULE FUNC
OBJECT MODULE PLACED IN Func.OBJ
COMPILER INVOKED BY: d:\Keil\C51\BIN\C51.EXE Func.c LARGE OPTIMIZE(0,SPEED) BROWSE DEBUG OBJECTEXTEND
stmt level source
1 #include "Func.h"
2
3 char* itoa(unsigned int value, char* buf,unsigned char radix)
4 {
5 1 unsigned int i;
6 1 char* ptr;
7 1 char* temphold;
8 1
9 1 temphold = buf;
10 1 ptr = buf + 12;
11 1 *--ptr = 0; // Insert NULL char
12 1
13 1 do
14 1 {
15 2 // First create string in reverse order
16 2 i = (value % radix) + 0x30;
17 2 if(i > 0x39)
18 2 {
19 3 i += 7;
20 3 }
21 2 *--ptr = i;
22 2 value = value / radix;
23 2 } while(value != 0);
24 1
25 1 // Next, move the string 6 places to the left
26 1 // Include NULL character
27 1 for( ; (*buf++ = *ptr++); )
28 1 {
29 2 ;
30 2 }
31 1 return(temphold);
32 1 }
33
34 char* ltoa(unsigned long value, char* buf,unsigned char radix)
35 {
36 1 unsigned char i;
37 1 char* ptr;
38 1 char* temphold;
39 1
40 1 temphold = buf;
41 1 ptr = buf + 12;
42 1 *--ptr = 0; // Insert NULL char
43 1
44 1 do
45 1 {
46 2 // First create string in reverse order
47 2 i = (value % radix) + 0x30;
48 2 if(i > 0x39)
49 2 {
50 3 i += 7;
51 3 }
52 2 *--ptr = i;
53 2 value = value / radix;
54 2 } while(value != 0);
55 1
C51 COMPILER V7.06 FUNC 01/02/2000 11:14:26 PAGE 2
56 1 // Next, move the string 6 places to the left
57 1 // Include NULL character
58 1 for( ; (*buf++ = *ptr++); )
59 1 {
60 2 ;
61 2 }
62 1 return(temphold);
63 1 }
MODULE INFORMATION: STATIC OVERLAYABLE
CODE SIZE = 598 ----
CONSTANT SIZE = ---- ----
XDATA SIZE = 29 ----
PDATA SIZE = ---- ----
DATA SIZE = ---- ----
IDATA SIZE = ---- ----
BIT SIZE = ---- ----
END OF MODULE INFORMATION.
C51 COMPILATION COMPLETE. 0 WARNING(S), 0 ERROR(S)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -