📄 i2c.lst
字号:
HI-TECH Software PICC-18 Macro Assembler V9.50PL3
Fri Aug 31 09:58:38 2007
1 processor 18F2520
2 opt pw 80
3 psect text,global,reloc=2,class=CODE,delta=1
4 psect temp,global,ovrld,common,class=COMRAM,spa
+ ce=1,delta=1
5 psect intsave_regs,global,class=BIGRAM,space=1,
+ delta=1
6 000000
7 000000
8 000000
9 000000
10 000000
11 000000
12 000000
13 000000
14 000000
15 000000
16 000000
17 000000
18 000000
19 000000
20 000000
21 000000
22 000000
23 000000
24 000000
25 000000
26 000000
27 000000
28 000000
29 000000
30 000000
31 000000
32 000000
33 000000
34 000000
35 000000
36 000000
37 000000
38 000000
39 000000
40 000000
41 000000
42 000000
43 000000
44 000000
45 000000
46 000000
47 000000
48 000000
49 000000
50 000000
51 000000
52 000000
53 000000
54 000000
55 000000
56 000000
57 000000
58 000000
59 000000
60 000000
61 000000
62 000000
63 000000
64 000000
65 000000
66 000000
67 000000
68 000000
69 000000
70 000000
71 000000
72 000000
73 000000
74 000000
75 000000
76 000000
77 000000
78 000000
79 000000
80 000000
81 000000
82 000000
83 000000
84 000000
85 000000
86 000000
87 000000
88 000000
89 000000
90 000000
91 000000
92 000000
93 000000
94 000000
95
96 psect text
97 007732 _I2C_Initial:
98 ; param _n assigned to ?_data_check+4
99 000000 _data_check$n set ?_data_check+4
100 ; param _Data_CHK assigned to ?_data_check
+ +2
101 000000 _data_check$Data_CHK set ?_data_check+2
102 ; param _Data_REF assigned to ?_data_check
+ +0
103 000000 _data_check$Data_REF set ?_data_check
104 ; _clrda assigned to ?a_I2C_CLR+2
105 000000 _I2C_CLR$clrda set ?a_I2C_CLR+2
106 ; _a assigned to ?a_I2C_CLR+0
107 000000 _I2C_CLR$a set ?a_I2C_CLR
108 ; param _len assigned to ?_writePage24AA64
+ +4
109 000000 _writePage24AA64$len set ?_writePage24AA64+4
110 ; param _wrpa_p assigned to ?_writePage24A
+ A64+2
111 000000 _writePage24AA64$wrpa_p set ?_writePage24AA64+2
112 ; param _addr assigned to ?_writePage24AA6
+ 4+0
113 000000 _writePage24AA64$addr set ?_writePage24AA64
114 ; _i assigned to ?a_readPage24AA64+0
115 000000 _readPage24AA64$i set ?a_readPage24AA64
116 ; param _len assigned to ?_readPage24AA64+
+ 4
117 000000 _readPage24AA64$len set ?_readPage24AA64+4
118 ; param _repa_p assigned to ?_readPage24AA
+ 64+2
119 000000 _readPage24AA64$repa_p set ?_readPage24AA64+2
120 ; param _addr assigned to ?_readPage24AA64
+ +0
121 000000 _readPage24AA64$addr set ?_readPage24AA64
122 ; param _wrby_p assigned to ?_writeByte24A
+ A64+2
123 000000 _writeByte24AA64$wrby_p set ?_writeByte24AA64+2
124 ; param _addr assigned to ?_writeByte24AA6
+ 4+0
125 000000 _writeByte24AA64$addr set ?_writeByte24AA64
126 ; param _reby_p assigned to ?_readByte24AA
+ 64+2
127 000000 _readByte24AA64$reby_p set ?_readByte24AA64+2
128 ; param _addr assigned to ?_readByte24AA64
+ +0
129 000000 _readByte24AA64$addr set ?_readByte24AA64
130 ; param _nValue assigned to ?_Delay_us+0
131 000000 _Delay_us$nValue set ?_Delay_us
132 000000
133 ;I2C.c: 5: void I2C_Initial( void )
134 007732 9694 bcf 3988,3,c ;volatile
135 ;I2C.c: 9: I2C_Set_sck_low();
136 007734 D81A call _I2C_Set_sck_low ;wreg free
137 ;I2C.c: 10: I2C_STOP();
138 007736 D883 call _I2C_STOP ;wreg free
139 007738 D0BB goto L5
140 ;I2C.c: 11: Delay_ms(10);
141 ;I2C.c: 12: return;
142 ;I2C.c: 13: }
143 00773A _I2C_Set_sda_high:
144 000000
145 ;I2C.c: 14: void I2C_Set_sda_high( void )
146 00773A 9894 bcf 3988,4,c ;volatile
147 ;I2C.c: 19: PORTC=(pc_out|= 0B00010000);
148 00773C 0105 movlb _pc_out shr (0+8)
149 00773E 89F1 bsf _pc_out& (0+255),4,b
150 007740 C5F1 FF82 movff _pc_out,3970 ;volatile
151 ;I2C.c: 20: asm(" nop");
152 007744 F000 nop ;#
153 ;I2C.c: 21: asm(" nop");
154 007746 F000 nop ;#
155 ;I2C.c: 22: return;
156 007748 0012 return
157 ;I2C.c: 23: }
158 00774A _I2C_Set_sda_low:
159 000000
160 ;I2C.c: 24: void I2C_Set_sda_low ( void )
161 00774A 9894 bcf 3988,4,c ;volatile
162 ;I2C.c: 29: PORTC=(pc_out&= ~0B00010000);
163 00774C 0105 movlb _pc_out shr (0+8)
164 00774E 99F1 bcf _pc_out& (0+255),4,b
165 007750 C5F1 FF82 movff _pc_out,3970 ;volatile
166 ;I2C.c: 31: asm(" nop");
167 007754 F000 nop ;#
168 ;I2C.c: 32: asm(" nop");
169 007756 F000 nop ;#
170 ;I2C.c: 33: return;
171 007758 0012 return
172 ;I2C.c: 34: }
173 00775A _I2C_Set_sck_high:
174 000000
175 ;I2C.c: 35: void I2C_Set_sck_high( void )
176 00775A 9694 bcf 3988,3,c ;volatile
177 ;I2C.c: 40: PORTC =(pc_out|= 0B00001000);
178 00775C 0105 movlb _pc_out shr (0+8)
179 00775E 87F1 bsf _pc_out& (0+255),3,b
180 007760 C5F1 FF82 movff _pc_out,3970 ;volatile
181 ;I2C.c: 42: asm(" nop");
182 007764 F000 nop ;#
183 ;I2C.c: 43: asm(" nop");
184 007766 F000 nop ;#
185 ;I2C.c: 44: return;
186 007768 0012 return
187 ;I2C.c: 45: }
188 00776A _I2C_Set_sck_low:
189 000000
190 ;I2C.c: 46: void I2C_Set_sck_low ( void )
191 00776A 9694 bcf 3988,3,c ;volatile
192 ;I2C.c: 51: PORTC =(pc_out&= ~0B00001000);
193 00776C 0105 movlb _pc_out shr (0+8)
194 00776E 97F1 bcf _pc_out& (0+255),3,b
195 007770 C5F1 FF82 movff _pc_out,3970 ;volatile
196 ;I2C.c: 53: asm(" nop");
197 007774 F000 nop ;#
198 ;I2C.c: 54: asm(" nop");
199 007776 F000 nop ;#
200 ;I2C.c: 55: return;
201 007778 0012 return
202 ;I2C.c: 56: }
203 00777A _I2C_GetACK:
204 000000
205 ;I2C.c: 57: int I2C_GetACK(void)
206 00777A 6AF3 clrf prodl,c
207 00777C 6AF4 clrf prodh,c
208 ;I2C.c: 60: int j;
209 00777E F000 nop ;#
210 ;I2C.c: 63: asm(" nop");
211 007780 F000 nop ;#
212 ;I2C.c: 64: I2C_Set_sck_low();
213 007782 DFF3 call _I2C_Set_sck_low ;wreg free
214 ;I2C.c: 65: for(j = 30;j > 0;j--);
215 007784 0E1E movlw 30
216 007786 6EF3 movwf prodl,c
217 007788 6AF4 clrf prodh,c
218 00778A l7:
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -