Subversion Repositories svnkaklik

Rev

Rev 410 | Go to most recent revision | Details | Last modification | View Log

Rev Author Line No. Line
6 kaklik 1
CCS PCM C Compiler, Version 3.245, 27853               10-VI-06 10:23
2
 
3
               Filename: D:\KAKLIK\programy\PIC_C\mereni\geiger\geiger.lst
4
 
5
               ROM used: 346 words (8%)
6
                         Largest free fragment is 2048
7
               RAM used: 10 (6%) at main() level
8
                         19 (11%) worst case
9
               Stack:    2 locations
10
 
11
*
12
0000:  MOVLW  00
13
0001:  MOVWF  0A
14
0002:  GOTO   0E1
15
0003:  NOP
16
.................... #include "D:\KAKLIK\programy\PIC_C\mereni\geiger\geiger.h" 
17
.................... #include <16F88.h> 
18
.................... //////// Standard Header file for the PIC16F88 device //////////////// 
19
.................... #device PIC16F88 
20
.................... #list 
21
....................  
22
.................... #device adc=8 
23
....................  
24
.................... #FUSES NOWDT                 	//No Watch Dog Timer 
25
.................... #FUSES HS                    	//High speed Osc (> 4mhz) 
26
.................... #FUSES NOPUT                 	//No Power Up Timer 
27
.................... #FUSES MCLR                  	//Master Clear pin enabled 
28
.................... #FUSES NOBROWNOUT            	//No brownout reset 
29
.................... #FUSES NOLVP                 	//No low voltage prgming, B3(PIC16) or B5(PIC18) used for I/O 
30
.................... #FUSES NOCPD                 	//No EE protection 
31
.................... #FUSES NOWRT                 	//Program memory not write protected 
32
.................... #FUSES NODEBUG               	//No Debug mode for ICD 
33
.................... #FUSES NOPROTECT             	//Code not protected from reading 
34
.................... #FUSES NOFCMEN               	//Fail-safe clock monitor disabled 
35
.................... #FUSES NOIESO                 //Internal External Switch Over mode disabled 
36
....................  
37
.................... #use delay(clock=20000000) 
38
00CD:  MOVLW  24
39
00CE:  MOVWF  04
40
00CF:  MOVF   00,W
41
00D0:  BTFSC  03.2
42
00D1:  GOTO   0DF
43
00D2:  MOVLW  06
44
00D3:  MOVWF  78
45
00D4:  CLRF   77
46
00D5:  DECFSZ 77,F
47
00D6:  GOTO   0D5
48
00D7:  DECFSZ 78,F
49
00D8:  GOTO   0D4
50
00D9:  MOVLW  7B
51
00DA:  MOVWF  77
52
00DB:  DECFSZ 77,F
53
00DC:  GOTO   0DB
54
00DD:  DECFSZ 00,F
55
00DE:  GOTO   0D2
56
00DF:  BCF    0A.3
57
00E0:  GOTO   156 (RETURN)
58
.................... #use rs232(baud=9600,parity=N,xmit=PIN_B3,rcv=PIN_B5,bits=8) 
59
*
60
0004:  BSF    03.5
61
0005:  BCF    06.3
62
0006:  BCF    03.5
63
0007:  BCF    06.3
64
0008:  MOVLW  08
65
0009:  MOVWF  78
66
000A:  NOP
67
000B:  NOP
68
000C:  NOP
69
000D:  BSF    78.7
70
000E:  GOTO   01E
71
000F:  BCF    78.7
72
0010:  RRF    2E,F
73
0011:  BTFSC  03.0
74
0012:  BSF    06.3
75
0013:  BTFSS  03.0
76
0014:  BCF    06.3
77
0015:  BSF    78.6
78
0016:  GOTO   01E
79
0017:  BCF    78.6
80
0018:  DECFSZ 78,F
81
0019:  GOTO   010
82
001A:  NOP
83
001B:  NOP
84
001C:  NOP
85
001D:  BSF    06.3
86
001E:  MOVLW  A7
87
001F:  MOVWF  04
88
0020:  DECFSZ 04,F
89
0021:  GOTO   020
90
0022:  NOP
91
0023:  NOP
92
0024:  BTFSC  78.7
93
0025:  GOTO   00F
94
0026:  BTFSC  78.6
95
0027:  GOTO   017
96
0028:  RETLW  00
97
....................  
98
....................  
99
....................  
100
....................  
101
.................... void main() 
102
.................... { 
103
*
104
00E1:  CLRF   04
105
00E2:  MOVLW  1F
106
00E3:  ANDWF  03,F
107
00E4:  BSF    03.5
108
00E5:  BCF    06.3
109
00E6:  BCF    03.5
110
00E7:  BSF    06.3
111
00E8:  BSF    03.5
112
00E9:  BCF    1F.4
113
00EA:  BCF    1F.5
114
00EB:  MOVF   1B,W
115
00EC:  ANDLW  80
116
00ED:  MOVWF  1B
117
00EE:  MOVLW  07
118
00EF:  MOVWF  1C
119
....................    unsigned int16 n; 
120
....................     
121
....................    setup_adc_ports(NO_ANALOGS|VSS_VDD); 
122
00F0:  BCF    1F.4
123
00F1:  BCF    1F.5
124
00F2:  MOVF   1B,W
125
00F3:  ANDLW  80
126
00F4:  MOVWF  1B
127
....................    setup_adc(ADC_OFF); 
128
00F5:  BCF    03.5
129
00F6:  BCF    1F.0
130
....................    setup_spi(FALSE); 
131
00F7:  BCF    14.5
132
00F8:  BSF    03.5
133
00F9:  BCF    06.2
134
00FA:  BSF    06.1
135
00FB:  BCF    06.4
136
00FC:  MOVLW  00
137
00FD:  BCF    03.5
138
00FE:  MOVWF  14
139
00FF:  BSF    03.5
140
0100:  MOVWF  14
141
....................    setup_timer_0(RTCC_EXT_H_TO_L|RTCC_DIV_1); 
142
0101:  MOVF   01,W
143
0102:  ANDLW  C7
144
0103:  IORLW  38
145
0104:  MOVWF  01
146
....................    setup_timer_1(T1_DISABLED|T1_DIV_BY_1); 
147
0105:  BCF    03.5
148
0106:  CLRF   10
149
....................    setup_timer_2(T2_DISABLED,0,1); 
150
0107:  MOVLW  00
151
0108:  MOVWF  78
152
0109:  MOVWF  12
153
010A:  MOVLW  00
154
010B:  BSF    03.5
155
010C:  MOVWF  12
156
....................    setup_ccp1(CCP_OFF); 
157
010D:  BSF    06.0
158
010E:  BCF    03.5
159
010F:  CLRF   17
160
0110:  CLRF   17
161
....................    setup_comparator(A0_A2_A1_A2_OUT_ON_A3_A4); 
162
0111:  MOVLW  06
163
0112:  BSF    03.5
164
0113:  MOVWF  1C
165
0114:  MOVF   05,W
166
0115:  IORLW  07
167
0116:  ANDLW  E7
168
0117:  MOVWF  05
169
0118:  MOVLW  10
170
0119:  MOVWF  77
171
011A:  DECFSZ 77,F
172
011B:  GOTO   11A
173
011C:  NOP
174
011D:  MOVF   1C,W
175
011E:  BCF    03.5
176
011F:  BCF    0D.6
177
....................    setup_vref(VREF_LOW|1|VREF_A2); 
178
0120:  MOVLW  E1
179
0121:  BSF    03.5
180
0122:  MOVWF  1D
181
0123:  BSF    05.2
182
....................    setup_oscillator(False); 
183
0124:  CLRF   0F
184
0125:  MOVF   0F,W
185
....................     
186
....................    n=0; 
187
0126:  BCF    03.5
188
0127:  CLRF   22
189
0128:  CLRF   21
190
....................    set_timer0(0); 
191
0129:  CLRF   01
192
....................    While(true) 
193
....................    { 
194
....................       printf("%Lu0, %u\n\r", n++, get_timer0());      
195
012A:  MOVF   22,W
196
012B:  MOVWF  7A
197
012C:  MOVF   21,W
198
012D:  INCF   21,F
199
012E:  BTFSC  03.2
200
012F:  INCF   22,F
201
0130:  MOVWF  23
202
0131:  MOVF   7A,W
203
0132:  MOVWF  24
204
0133:  MOVF   01,W
205
0134:  MOVWF  25
206
0135:  MOVLW  10
207
0136:  MOVWF  04
208
0137:  MOVF   24,W
209
0138:  MOVWF  27
210
0139:  MOVF   23,W
211
013A:  MOVWF  26
212
013B:  GOTO   029
213
013C:  MOVLW  30
214
013D:  MOVWF  2E
215
013E:  CALL   004
216
013F:  MOVLW  2C
217
0140:  MOVWF  2E
218
0141:  CALL   004
219
0142:  MOVLW  20
220
0143:  MOVWF  2E
221
0144:  CALL   004
222
0145:  MOVF   25,W
223
0146:  MOVWF  26
224
0147:  MOVLW  1B
225
0148:  MOVWF  27
226
0149:  GOTO   097
227
014A:  MOVLW  0A
228
014B:  MOVWF  2E
229
014C:  CALL   004
230
014D:  MOVLW  0D
231
014E:  MOVWF  2E
232
014F:  CALL   004
233
....................       set_timer0(0); 
234
0150:  CLRF   01
235
....................       Delay_ms(10000); 
236
0151:  MOVLW  28
237
0152:  MOVWF  23
238
0153:  MOVLW  FA
239
0154:  MOVWF  24
240
0155:  GOTO   0CD
241
0156:  DECFSZ 23,F
242
0157:  GOTO   153
243
....................    } 
244
0158:  GOTO   12A
245
.................... } 
246
0159:  SLEEP
247
 
248
Configuration Fuses:
249
   Word  1: 3F2A   HS NOWDT NOPUT MCLR NOBROWNOUT NOLVP NOCPD NOWRT NODEBUG CCPB0 NOPROTECT
250
   Word  2: 3FFC   NOFCMEN NOIESO