📄 key.lst
字号:
HI-TECH Software PICC Macro Assembler V8.05PL1
Serial number: HCPIC-88888 Thu Dec 11 14:01:26 2008
Licensed to: ONE TWO
1 processor 16F688
2 opt pw 79
3 psect __Z88888RS_,global,delta=1
4 psect strings,global,class=STRING,delta=2
5 psect const1,local,class=CONST,delta=2
6 psect text2,local,class=CODE,delta=2
7 psect text5,local,class=CODE,delta=2
8 psect text6,local,class=CODE,delta=2
9 psect text7,local,class=CODE,delta=2
10 psect text8,local,class=CODE,delta=2
11 psect text9,local,class=CODE,delta=2
12 psect rbss_0,global,class=BANK0,space=1,delta=
+ 1
13 psect temp,global,ovrld,class=BANK0,space=1,de
+ lta=1
14 0000
15 0000
16 0000
17 0000
18 0000
19 0000
20 0000
21 0000
22 0000
23 0000
24
25 psect __Z88888RS_
26 0120
27 0120
28
29 psect const1
30 0054 0782 addwf 2
31 0055 _KEY_REPEAT_CTL
32 0055 3400 retlw 0
33 0056 340A retlw 10
34 0057 3400 retlw 0
35 0058 3458 retlw 88
36 0059 3402 retlw 2
37 005A 3401 retlw 1
38 005B 340F retlw 15
39 005C 3400 retlw 0
40 005D 34F4 retlw 244
41 005E 3401 retlw 1
42 005F 3402 retlw 2
43 0060 340F retlw 15
44 0061 3400 retlw 0
45 0062 34F4 retlw 244
46 0063 3401 retlw 1
47 0064 3403 retlw 3
48 0065 340F retlw 15
49 0066 3400 retlw 0
50 0067 34F4 retlw 244
51 0068 3401 retlw 1
52 0069 3404 retlw 4
53 006A 340F retlw 15
54 006B 3400 retlw 0
55 006C 34F4 retlw 244
56 006D 3401 retlw 1
57
58 psect text2
59 ;key.c: 43: void saveKeyCtlTime(void)
60 ;key.c: 44: {
61 063A _saveKeyCtlTime
62 ;key.c: 45: keyCtlBlock.sTime=loadSystemTime(6)
+ ;
63 063A 3006 movlw 6
64 063B 118A 22EF 118A fcall _loadSystemTime
65 063E 0870 movf btemp,w
66 063F 00B3 movwf _keyCtlBlock+9
67 0640 0871 movf btemp+1,w
68 0641 00B4 movwf _keyCtlBlock+10
69 0642 0872 movf btemp+2,w
70 0643 00B5 movwf _keyCtlBlock+11
71 0644 0873 movf btemp+3,w
72 0645 00B6 movwf _keyCtlBlock+12
73 ;key.c: 46: }
74 0646 0008 return
75 0647 _keyPortInput
76 ; _keyIn assigned to ?a_keyPortInput+0
77 0000 _keyPortInput$keyIn set ?a_keyPortInput
78 ;key.c: 17: unsigned int keyIn;
79 0647 0183 clrf 3 ;select bank 0
80 0648 0807 movf 7,w ;volatile
81 0649 00CF movwf ?a_keyPortInput
82 064A 01D0 clrf ?a_keyPortInput+1
83 ;key.c: 19: keyIn=((keyIn<<8)+PORTA)&0x3003;
84 064B 00F1 movwf btemp+1
85 064C 01F0 clrf btemp
86 064D 0870 movf btemp,w
87 064E 00D1 movwf ?a_keyPortInput+2
88 064F 0871 movf btemp+1,w
89 0650 00D2 movwf ?a_keyPortInput+3
90 0651 0805 movf 5,w ;volatile
91 0652 00F0 movwf btemp
92 0653 01F1 clrf btemp+1
93 0654 0851 movf ?a_keyPortInput+2,w
94 0655 07F0 addwf btemp
95 0656 1803 btfsc 3,0
96 0657 0AF1 incf btemp+1
97 0658 0852 movf ?a_keyPortInput+3,w
98 0659 07F1 addwf btemp+1
99 065A 3003 movlw 3
100 065B 0570 andwf btemp,w
101 065C 00CF movwf ?a_keyPortInput
102 065D 3030 movlw 48
103 065E 0571 andwf btemp+1,w
104 065F 00D0 movwf ?a_keyPortInput+1
105 ;key.c: 20: return(keyIn);
106 0660 00F1 movwf btemp+1
107 0661 084F movf ?a_keyPortInput,w
108 0662 00F0 movwf btemp
109 ;key.c: 21: }
110 0663 0008 return
111 0000
112 0664 _readKeyInput
113 ; _key assigned to ?a_readKeyInput+0
114 0000 _readKeyInput$key set ?a_readKeyInput
115 ; _input assigned to ?a_readKeyInput+1
116 0000 _readKeyInput$input set ?a_readKeyInput+1
117 ;key.c: 25: unsigned int input;
118 0664 2647 fcall _keyPortInput
119 0665 0870 movf btemp,w
120 0666 00CD movwf ?a_readKeyInput+1
121 0667 0871 movf btemp+1,w
122 0668 00CE movwf ?a_readKeyInput+2
123 ;key.c: 28: if (input ==0x3001)
124 0669 034D decf ?a_readKeyInput+1,w
125 066A 3030 movlw 48
126 066B 1903 btfsc 3,2
127 066C 064E xorwf ?a_readKeyInput+2,w
128 066D 1D03 btfss 3,2
129 066E 2E72 goto l7
130 ;key.c: 29: key=0x01;
131 066F 01CC clrf ?a_readKeyInput
132 0670 0ACC incf ?a_readKeyInput
133 ;key.c: 30: else if (input ==0x3002)
134 0671 2E98 goto l8
135 0672 l7
136 0672 084E movf ?a_readKeyInput+2,w
137 0673 3A30 xorlw 48
138 0674 3002 movlw 2
139 0675 1903 btfsc 3,2
140 0676 064D xorwf ?a_readKeyInput+1,w
141 0677 1D03 btfss 3,2
142 0678 2E7B goto l9
143 ;key.c: 31: key=0x02;
144 0679 3002 movlw 2
145 067A 2E97 goto L3
146 ;key.c: 32: else if (input ==0x2003)
147 067B l9
148 067B 084E movf ?a_readKeyInput+2,w
149 067C 3A20 xorlw 32
150 067D 3003 movlw 3
151 067E 1903 btfsc 3,2
152 067F 064D xorwf ?a_readKeyInput+1,w
153 0680 1D03 btfss 3,2
154 0681 2E84 goto l11
155 ;key.c: 33: key=0x03;
156 0682 3003 movlw 3
157 0683 2E97 goto L3
158 ;key.c: 34: else if (input ==0x1003)
159 0684 l11
160 0684 084E movf ?a_readKeyInput+2,w
161 0685 3A10 xorlw 16
162 0686 3003 movlw 3
163 0687 1903 btfsc 3,2
164 0688 064D xorwf ?a_readKeyInput+1,w
165 0689 1D03 btfss 3,2
166 068A 2E8D goto l13
167 ;key.c: 35: key=0x04;
168 068B 3004 movlw 4
169 068C 2E97 goto L3
170 ;key.c: 36: else if (input ==0x3003)
171 068D l13
172 068D 084E movf ?a_readKeyInput+2,w
173 068E 3A30 xorlw 48
174 068F 3003 movlw 3
175 0690 1903 btfsc 3,2
176 0691 064D xorwf ?a_readKeyInput+1,w
177 0692 1D03 btfss 3,2
178 0693 2E96 goto l15
179 ;key.c: 37: key=0x00;
180 0694 01CC clrf ?a_readKeyInput
181 ;key.c: 38: else key=0xFF;
182 0695 2E98 goto l8
183 0696 l15
184 0696 30FF movlw -1
185 0697 L3
186 0697 00CC movwf ?a_readKeyInput
187 0698 l8
188 ;key.c: 39: return (key);
189 0698 084C movf ?a_readKeyInput,w
190 ;key.c: 40: }
191 0699 0008 return
192 ;key.c: 48: unsigned char checkKeyRepeat(void)
193 ;key.c: 49: {
194 069A _checkKeyRepeat
195 ; _rd assigned to ?a_checkKeyRepeat+0
196 0000 _checkKeyRepeat$rd set ?a_checkKeyRepeat
197 ; _tRepeat assigned to ?a_checkKeyRepeat+1
198 0000 _checkKeyRepeat$tRepeat set ?a_checkKeyRepeat+1
199 ; _tDelay assigned to ?a_checkKeyRepeat+3
200 0000 _checkKeyRepeat$tDelay set ?a_checkKeyRepeat+3
201 ; _tStart assigned to ?a_checkKeyRepeat+5
202 0000 _checkKeyRepeat$tStart set ?a_checkKeyRepeat+5
203 ; _time assigned to ?a_checkKeyRepeat+9
204 0000 _checkKeyRepeat$time set ?a_checkKeyRepeat+9
205 ;key.c: 50: unsigned long time;
206 069A 0183 clrf 3 ;select bank 0
207 069B 01CC clrf ?a_checkKeyRepeat
208 ;key.c: 54: tDelay=(keyCtlBlock.pRepeatCtl)->tD
+ elay;
209 069C 0838 movf _keyCtlBlock+14,w
210 069D 3E03 addlw 3
211 069E 0084 movwf 4
212 069F 1383 bcf 3,7
213 06A0 0800 movf 0,w
214 06A1 00CF movwf ?a_checkKeyRepeat+3
215 06A2 0A84 incf 4
216 06A3 0800 movf 0,w
217 06A4 00D0 movwf ?a_checkKeyRepeat+4
218 ;key.c: 55: tRepeat=(keyCtlBlock.pRepeatCtl)->t
+ Repeat;
219 06A5 0A38 incf _keyCtlBlock+14,w
220 06A6 0084 movwf 4
221 06A7 0800 movf 0,w
222 06A8 00CD movwf ?a_checkKeyRepeat+1
223 06A9 0A84 incf 4
224 06AA 0800 movf 0,w
225 06AB 00CE movwf ?a_checkKeyRepeat+2
226 ;key.c: 56: tStart=keyCtlBlock.sTime;
227 06AC 0833 movf _keyCtlBlock+9,w
228 06AD 00D1 movwf ?a_checkKeyRepeat+5
229 06AE 0834 movf _keyCtlBlock+10,w
230 06AF 00D2 movwf ?a_checkKeyRepeat+6
231 06B0 0835 movf _keyCtlBlock+11,w
232 06B1 00D3 movwf ?a_checkKeyRepeat+7
233 06B2 0836 movf _keyCtlBlock+12,w
234 06B3 00D4 movwf ?a_checkKeyRepeat+8
235 ;key.c: 57: time=loadSystemTime(6);
236 06B4 3006 movlw 6
237 06B5 118A 22EF 118A fcall _loadSystemTime
238 06B8 0870 movf btemp,w
239 06B9 00D5 movwf ?a_checkKeyRepeat+9
240 06BA 0871 movf btemp+1,w
241 06BB 00D6 movwf ?a_checkKeyRepeat+10
242 06BC 0872 movf btemp+2,w
243 06BD 00D7 movwf ?a_checkKeyRepeat+11
244 06BE 0873 movf btemp+3,w
245 06BF 00D8 movwf ?a_checkKeyRepeat+12
246 ;key.c: 58: if (keyCtlBlock.repeat==1)
247 06C0 0B37 decfsz _keyCtlBlock+13,w
248 06C1 2F14 goto l19
249 ;key.c: 59: { time=time-tStart-tDelay;
250 06C2 084F movf ?a_checkKeyRepeat+3,w
251 06C3 00F4 movwf btemp+4
252 06C4 0850 movf ?a_checkKeyRepeat+4,w
253 06C5 00F5 movwf btemp+5
254 06C6 01F6 clrf btemp+6
255 06C7 01F7 clrf btemp+7
256 06C8 0851 movf ?a_checkKeyRepeat+5,w
257 06C9 0255 subwf ?a_checkKeyRepeat+9,w
258 06CA 00F0 movwf btemp
259 06CB 0856 movf ?a_checkKeyRepeat+10,w
260 06CC 00F1 movwf btemp+1
261 06CD 0852 movf ?a_checkKeyRepeat+6,w
262 06CE 1C03 btfss 3,0
263 06CF 0F52 incfsz ?a_checkKeyRepeat+6,w
264 06D0 02F1 subwf btemp+1
265 06D1 0857 movf ?a_checkKeyRepeat+11,w
266 06D2 00F2 movwf btemp+2
267 06D3 0853 movf ?a_checkKeyRepeat+7,w
268 06D4 1C03 btfss 3,0
269 06D5 0F53 incfsz ?a_checkKeyRepeat+7,w
270 06D6 02F2 subwf btemp+2
271 06D7 0858 movf ?a_checkKeyRepeat+12,w
272 06D8 00F3 movwf btemp+3
273 06D9 0854 movf ?a_checkKeyRepeat+8,w
274 06DA 1C03 btfss 3,0
275 06DB 0F54 incfsz ?a_checkKeyRepeat+8,w
276 06DC 02F3 subwf btemp+3
277 06DD 0874 movf btemp+4,w
278 06DE 0270 subwf btemp,w
279 06DF 00F8 movwf btemp+8
280 06E0 0871 movf btemp+1,w
281 06E1 00F9 movwf btemp+9
282 06E2 0875 movf btemp+5,w
283 06E3 1C03 btfss 3,0
284 06E4 0F75 incfsz btemp+5,w
285 06E5 02F9 subwf btemp+9
286 06E6 0872 movf btemp+2,w
287 06E7 00FA movwf btemp+10
288 06E8 0876 movf btemp+6,w
289 06E9 1C03 btfss 3,0
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -