1 |
CCS PCM C Compiler, Version 4.106, 47914 01-II-14 20:13 |
1 |
CCS PCM C Compiler, Version 4.106, 47914 04-II-14 11:45 |
2 |
|
2 |
|
3 |
Filename: Z:\home\kaklik\svn\svnMLAB\Designs\Measuring_instruments\RMDS01C\SW\PIC887\main.lst |
3 |
Filename: Z:\home\kaklik\svn\svnMLAB\Designs\Measuring_instruments\RMDS01C\SW\PIC16F887\main.lst |
4 |
|
4 |
|
5 |
ROM used: 786 words (10%) |
5 |
ROM used: 984 words (12%) |
6 |
Largest free fragment is 2048 |
6 |
Largest free fragment is 2048 |
7 |
RAM used: 67 (18%) at main() level |
7 |
RAM used: 43 (12%) at main() level |
8 |
80 (22%) worst case |
8 |
96 (26%) worst case |
9 |
Stack: 2 worst case (1 in main + 1 for interrupts) |
9 |
Stack: 3 worst case (1 in main + 2 for interrupts) |
10 |
|
10 |
|
11 |
* |
11 |
* |
12 |
0000: MOVLW 02 |
12 |
0000: MOVLW 03 |
13 |
0001: MOVWF 0A |
13 |
0001: MOVWF 0A |
14 |
0002: GOTO 21C |
14 |
0002: GOTO 332 |
15 |
0003: NOP |
15 |
0003: NOP |
16 |
0004: MOVWF 7F |
16 |
0004: MOVWF 7F |
17 |
0005: SWAPF 03,W |
17 |
0005: SWAPF 03,W |
18 |
0006: CLRF 03 |
18 |
0006: CLRF 03 |
19 |
0007: MOVWF 21 |
19 |
0007: MOVWF 21 |
20 |
0008: MOVF 0A,W |
20 |
0008: MOVF 0A,W |
21 |
0009: MOVWF 20 |
21 |
0009: MOVWF 20 |
22 |
000A: CLRF 0A |
22 |
000A: CLRF 0A |
23 |
000B: MOVF 04,W |
23 |
000B: MOVF 04,W |
24 |
000C: MOVWF 22 |
24 |
000C: MOVWF 22 |
25 |
000D: MOVF 77,W |
25 |
000D: MOVF 77,W |
26 |
000E: MOVWF 23 |
26 |
000E: MOVWF 23 |
27 |
000F: MOVF 78,W |
27 |
000F: MOVF 78,W |
28 |
0010: MOVWF 24 |
28 |
0010: MOVWF 24 |
29 |
0011: MOVF 79,W |
29 |
0011: MOVF 79,W |
30 |
0012: MOVWF 25 |
30 |
0012: MOVWF 25 |
31 |
0013: MOVF 7A,W |
31 |
0013: MOVF 7A,W |
32 |
0014: MOVWF 26 |
32 |
0014: MOVWF 26 |
33 |
0015: BCF 03.7 |
33 |
0015: BCF 03.7 |
34 |
0016: BCF 03.5 |
34 |
0016: BCF 03.5 |
- |
|
35 |
0017: BTFSS 0B.4 |
- |
|
36 |
0018: GOTO 01B |
- |
|
37 |
0019: BTFSC 0B.1 |
- |
|
38 |
001A: GOTO 038 |
35 |
0017: MOVLW 8C |
39 |
001B: MOVLW 8C |
36 |
0018: MOVWF 04 |
40 |
001C: MOVWF 04 |
37 |
0019: BTFSS 00.1 |
41 |
001D: BTFSS 00.0 |
38 |
001A: GOTO 01D |
42 |
001E: GOTO 021 |
39 |
001B: BTFSC 0C.1 |
43 |
001F: BTFSC 0C.0 |
40 |
001C: GOTO 034 |
44 |
0020: GOTO 03B |
41 |
001D: MOVLW 8C |
45 |
0021: MOVLW 8C |
42 |
001E: MOVWF 04 |
46 |
0022: MOVWF 04 |
43 |
001F: BTFSS 00.3 |
47 |
0023: BTFSS 00.3 |
44 |
0020: GOTO 023 |
48 |
0024: GOTO 027 |
45 |
0021: BTFSC 0C.3 |
49 |
0025: BTFSC 0C.3 |
46 |
0022: GOTO 037 |
50 |
0026: GOTO 03E |
47 |
0023: MOVF 22,W |
51 |
0027: MOVF 22,W |
48 |
0024: MOVWF 04 |
52 |
0028: MOVWF 04 |
49 |
0025: MOVF 23,W |
53 |
0029: MOVF 23,W |
50 |
0026: MOVWF 77 |
54 |
002A: MOVWF 77 |
51 |
0027: MOVF 24,W |
55 |
002B: MOVF 24,W |
52 |
0028: MOVWF 78 |
56 |
002C: MOVWF 78 |
53 |
0029: MOVF 25,W |
57 |
002D: MOVF 25,W |
54 |
002A: MOVWF 79 |
58 |
002E: MOVWF 79 |
55 |
002B: MOVF 26,W |
59 |
002F: MOVF 26,W |
56 |
002C: MOVWF 7A |
60 |
0030: MOVWF 7A |
57 |
002D: MOVF 20,W |
61 |
0031: MOVF 20,W |
58 |
002E: MOVWF 0A |
62 |
0032: MOVWF 0A |
59 |
002F: SWAPF 21,W |
63 |
0033: SWAPF 21,W |
60 |
0030: MOVWF 03 |
64 |
0034: MOVWF 03 |
61 |
0031: SWAPF 7F,F |
65 |
0035: SWAPF 7F,F |
62 |
0032: SWAPF 7F,W |
66 |
0036: SWAPF 7F,W |
63 |
0033: RETFIE |
67 |
0037: RETFIE |
- |
|
68 |
0038: BCF 0A.3 |
- |
|
69 |
0039: BCF 0A.4 |
- |
|
70 |
003A: GOTO 145 |
64 |
0034: BCF 0A.3 |
71 |
003B: BCF 0A.3 |
65 |
0035: BCF 0A.4 |
72 |
003C: BCF 0A.4 |
66 |
0036: GOTO 0B0 |
73 |
003D: GOTO 2C6 |
67 |
0037: BCF 0A.3 |
74 |
003E: BCF 0A.3 |
68 |
0038: BCF 0A.4 |
75 |
003F: BCF 0A.4 |
69 |
0039: GOTO 066 |
76 |
0040: GOTO 06D |
70 |
.................... #include "main.h" |
77 |
.................... #include "main.h" |
71 |
.................... #include <16F887.h> |
78 |
.................... #include <16F887.h> |
72 |
.................... //////// Standard Header file for the PIC16F887 device //////////////// |
79 |
.................... //////// Standard Header file for the PIC16F887 device //////////////// |
73 |
.................... #device PIC16F887 |
80 |
.................... #device PIC16F887 |
74 |
.................... #list |
81 |
.................... #list |
75 |
.................... |
82 |
.................... |
76 |
.................... #device adc=8 |
83 |
.................... #device adc=8 |
77 |
.................... |
84 |
.................... |
78 |
.................... #FUSES NOWDT //No Watch Dog Timer |
85 |
.................... #FUSES NOWDT //No Watch Dog Timer |
79 |
.................... #FUSES HS //High speed Osc (> 4mhz for PCM/PCH) (>10mhz for PCD) |
86 |
.................... #FUSES HS //High speed Osc (> 4mhz for PCM/PCH) (>10mhz for PCD) |
80 |
.................... #FUSES NOPUT //No Power Up Timer |
87 |
.................... #FUSES NOPUT //No Power Up Timer |
81 |
.................... #FUSES MCLR //Master Clear pin enabled |
88 |
.................... #FUSES MCLR //Master Clear pin enabled |
82 |
.................... #FUSES NOPROTECT //Code not protected from reading |
89 |
.................... #FUSES NOPROTECT //Code not protected from reading |
83 |
.................... #FUSES NOCPD //No EE protection |
90 |
.................... #FUSES NOCPD //No EE protection |
84 |
.................... #FUSES NOBROWNOUT //No brownout reset |
91 |
.................... #FUSES NOBROWNOUT //No brownout reset |
85 |
.................... #FUSES IESO //Internal External Switch Over mode enabled |
92 |
.................... #FUSES IESO //Internal External Switch Over mode enabled |
86 |
.................... #FUSES FCMEN //Fail-safe clock monitor enabled |
93 |
.................... #FUSES FCMEN //Fail-safe clock monitor enabled |
87 |
.................... #FUSES NOLVP //No low voltage prgming, B3(PIC16) or B5(PIC18) used for I/O |
94 |
.................... #FUSES NOLVP //No low voltage prgming, B3(PIC16) or B5(PIC18) used for I/O |
88 |
.................... #FUSES NODEBUG //No Debug mode for ICD |
95 |
.................... #FUSES NODEBUG //No Debug mode for ICD |
89 |
.................... #FUSES NOWRT //Program memory not write protected |
96 |
.................... #FUSES NOWRT //Program memory not write protected |
90 |
.................... #FUSES BORV40 //Brownout reset at 4.0V |
97 |
.................... #FUSES BORV40 //Brownout reset at 4.0V |
91 |
.................... |
98 |
.................... |
92 |
.................... #use delay(clock=20000000) |
99 |
.................... #use delay(clock=20000000) |
93 |
* |
100 |
* |
94 |
00DC: MOVLW 5F |
101 |
02D2: MOVLW 47 |
95 |
00DD: MOVWF 04 |
102 |
02D3: MOVWF 04 |
96 |
00DE: BCF 03.7 |
103 |
02D4: BCF 03.7 |
97 |
00DF: MOVF 00,W |
104 |
02D5: MOVF 00,W |
98 |
00E0: BTFSC 03.2 |
105 |
02D6: BTFSC 03.2 |
99 |
00E1: GOTO 0EF |
106 |
02D7: GOTO 2E5 |
100 |
00E2: MOVLW 06 |
107 |
02D8: MOVLW 06 |
101 |
00E3: MOVWF 78 |
108 |
02D9: MOVWF 78 |
102 |
00E4: CLRF 77 |
109 |
02DA: CLRF 77 |
103 |
00E5: DECFSZ 77,F |
110 |
02DB: DECFSZ 77,F |
104 |
00E6: GOTO 0E5 |
111 |
02DC: GOTO 2DB |
105 |
00E7: DECFSZ 78,F |
112 |
02DD: DECFSZ 78,F |
106 |
00E8: GOTO 0E4 |
113 |
02DE: GOTO 2DA |
107 |
00E9: MOVLW 7B |
114 |
02DF: MOVLW 7B |
108 |
00EA: MOVWF 77 |
115 |
02E0: MOVWF 77 |
109 |
00EB: DECFSZ 77,F |
116 |
02E1: DECFSZ 77,F |
110 |
00EC: GOTO 0EB |
117 |
02E2: GOTO 2E1 |
111 |
00ED: DECFSZ 00,F |
118 |
02E3: DECFSZ 00,F |
112 |
00EE: GOTO 0E2 |
- |
|
113 |
00EF: RETURN |
- |
|
114 |
* |
- |
|
115 |
013A: MOVLW 03 |
- |
|
116 |
013B: SUBWF 5F,F |
- |
|
117 |
013C: BTFSS 03.0 |
- |
|
118 |
013D: GOTO 148 |
- |
|
119 |
013E: MOVLW 5F |
- |
|
120 |
013F: MOVWF 04 |
- |
|
121 |
0140: BCF 03.7 |
- |
|
122 |
0141: MOVF 00,W |
- |
|
123 |
0142: BTFSC 03.2 |
- |
|
124 |
0143: GOTO 148 |
- |
|
125 |
0144: GOTO 146 |
119 |
02E4: GOTO 2D8 |
126 |
0145: GOTO 146 |
- |
|
127 |
0146: DECFSZ 00,F |
- |
|
128 |
0147: GOTO 145 |
- |
|
129 |
0148: BCF 0A.3 |
120 |
02E5: BCF 0A.3 |
130 |
0149: BCF 0A.4 |
121 |
02E6: BCF 0A.4 |
131 |
014A: GOTO 2C1 (RETURN) |
122 |
02E7: GOTO 3B7 (RETURN) |
132 |
.................... #use rs232(baud=9600,parity=N,xmit=PIN_C6,rcv=PIN_C7,bits=8,errors) |
123 |
.................... #use rs232(baud=9600,parity=N,xmit=PIN_C6,rcv=PIN_C7,bits=8,errors) |
133 |
.................... |
124 |
.................... |
134 |
.................... //NOTE: Must declare MASTER before SLAVE, i2c_isr_state() returns 0 |
125 |
.................... //NOTE: Must declare MASTER before SLAVE, i2c_isr_state() returns 0 |
135 |
.................... // when MASTER is the most recent #use i2c |
126 |
.................... // when MASTER is the most recent #use i2c |
136 |
.................... //#use i2c(MASTER, sda=PIN_C1, scl=PIN_C0, stream=I2CM) |
127 |
.................... //#use i2c(MASTER, sda=PIN_C1, scl=PIN_C0, stream=I2CM) |
137 |
.................... #use i2c(SLAVE, Fast, sda=PIN_C4, scl=PIN_C3, force_hw, address=0xA0) |
128 |
.................... #use i2c(SLAVE, Fast, sda=PIN_C4, scl=PIN_C3, force_hw, address=0xA0) |
138 |
* |
129 |
* |
139 |
00A1: MOVF 6A,W |
130 |
00AC: MOVF 4C,W |
140 |
00A2: MOVWF 13 |
131 |
00AD: MOVWF 13 |
141 |
00A3: BSF 14.4 |
132 |
00AE: BSF 14.4 |
142 |
00A4: BCF 0C.3 |
133 |
00AF: BCF 0C.3 |
143 |
00A5: BSF 03.5 |
134 |
00B0: BSF 03.5 |
144 |
00A6: BTFSC 14.0 |
135 |
00B1: BTFSC 14.0 |
145 |
00A7: GOTO 0A6 |
136 |
00B2: GOTO 0B1 |
146 |
00A8: CLRF 78 |
137 |
00B3: CLRF 78 |
147 |
00A9: BCF 03.5 |
138 |
00B4: BCF 03.5 |
148 |
00AA: BTFSC 14.4 |
139 |
00B5: BTFSC 14.4 |
149 |
00AB: INCF 78,F |
140 |
00B6: INCF 78,F |
- |
|
141 |
.................... |
- |
|
142 |
.................... |
- |
|
143 |
.................... |
- |
|
144 |
.................... #include <string.h> |
- |
|
145 |
.................... //////////////////////////////////////////////////////////////////////////// |
- |
|
146 |
.................... //// (C) Copyright 1996,2008 Custom Computer Services //// |
- |
|
147 |
.................... //// This source code may only be used by licensed users of the CCS C //// |
- |
|
148 |
.................... //// compiler. This source code may only be distributed to other //// |
- |
|
149 |
.................... //// licensed users of the CCS C compiler. No other use, reproduction //// |
- |
|
150 |
.................... //// or distribution is permitted without written permission. //// |
- |
|
151 |
.................... //// Derivative programs created using this software in object code //// |
- |
|
152 |
.................... //// form are not restricted in any way. //// |
- |
|
153 |
.................... //////////////////////////////////////////////////////////////////////////// |
- |
|
154 |
.................... |
- |
|
155 |
.................... #ifndef _STRING |
- |
|
156 |
.................... #define _STRING |
- |
|
157 |
.................... #include <stddef.h> |
- |
|
158 |
.................... /////////////////////////////////////////////////////////////////////////// |
- |
|
159 |
.................... //// (C) Copyright 1996,2003 Custom Computer Services //// |
- |
|
160 |
.................... //// This source code may only be used by licensed users of the CCS C //// |
- |
|
161 |
.................... //// compiler. This source code may only be distributed to other //// |
- |
|
162 |
.................... //// licensed users of the CCS C compiler. No other use, reproduction //// |
- |
|
163 |
.................... //// or distribution is permitted without written permission. //// |
- |
|
164 |
.................... //// Derivative programs created using this software in object code //// |
- |
|
165 |
.................... //// form are not restricted in any way. //// |
- |
|
166 |
.................... /////////////////////////////////////////////////////////////////////////// |
- |
|
167 |
.................... |
- |
|
168 |
.................... #ifndef _STDDEF |
- |
|
169 |
.................... |
- |
|
170 |
.................... #define _STDDEF |
- |
|
171 |
.................... |
- |
|
172 |
.................... #if sizeof(unsigned int8 *)==1 |
- |
|
173 |
.................... #define ptrdiff_t unsigned int8 |
- |
|
174 |
.................... #else |
- |
|
175 |
.................... #define ptrdiff_t unsigned int16 |
- |
|
176 |
.................... #endif |
- |
|
177 |
.................... |
- |
|
178 |
.................... #define size_t unsigned int8 |
- |
|
179 |
.................... #define wchar_t char |
- |
|
180 |
.................... #define NULL 0 |
- |
|
181 |
.................... |
- |
|
182 |
.................... #define offsetof(s,f) (offsetofbit(s,f)/8) |
- |
|
183 |
.................... |
- |
|
184 |
.................... #endif |
- |
|
185 |
.................... |
- |
|
186 |
.................... #include <ctype.h> |
- |
|
187 |
.................... //////////////////////////////////////////////////////////////////////////// |
- |
|
188 |
.................... //// (C) Copyright 1996,2003 Custom Computer Services //// |
- |
|
189 |
.................... //// This source code may only be used by licensed users of the CCS C //// |
- |
|
190 |
.................... //// compiler. This source code may only be distributed to other //// |
- |
|
191 |
.................... //// licensed users of the CCS C compiler. No other use, reproduction //// |
- |
|
192 |
.................... //// or distribution is permitted without written permission. //// |
- |
|
193 |
.................... //// Derivative programs created using this software in object code //// |
- |
|
194 |
.................... //// form are not restricted in any way. //// |
- |
|
195 |
.................... //////////////////////////////////////////////////////////////////////////// |
- |
|
196 |
.................... |
- |
|
197 |
.................... #ifndef _CTYPE |
- |
|
198 |
.................... #define _CTYPE |
- |
|
199 |
.................... |
- |
|
200 |
.................... #define islower(x) isamong(x,"abcdefghijklmnopqrstuvwxyz") |
- |
|
201 |
.................... #define isupper(x) isamong(x,"ABCDEFGHIJKLMNOPQRSTUVWXYZ") |
- |
|
202 |
.................... #define isalnum(x) isamong(x,"0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz") |
- |
|
203 |
.................... #define isalpha(x) isamong(x,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz") |
- |
|
204 |
.................... #define isdigit(x) isamong(x,"0123456789") |
- |
|
205 |
.................... #define isspace(x) ((x)==' ') |
- |
|
206 |
.................... #define isxdigit(x) isamong(x,"0123456789ABCDEFabcdef") |
- |
|
207 |
.................... #define iscntrl(x) ((x)<' ') |
- |
|
208 |
.................... #define isprint(x) ((x)>=' ') |
- |
|
209 |
.................... #define isgraph(x) ((x)>' ') |
- |
|
210 |
.................... #define ispunct(x) (((x)>' ')&&!isalnum(x)) |
- |
|
211 |
.................... |
- |
|
212 |
.................... #endif |
- |
|
213 |
.................... |
- |
|
214 |
.................... |
- |
|
215 |
.................... |
- |
|
216 |
.................... |
- |
|
217 |
.................... |
- |
|
218 |
.................... ////////////////////////////////////////////// |
- |
|
219 |
.................... //// Uncomment the following define to //// |
- |
|
220 |
.................... //// allow some functions to use a //// |
- |
|
221 |
.................... //// quicker algorithm, but use more ROM //// |
- |
|
222 |
.................... //// //// |
- |
|
223 |
.................... //// #define FASTER_BUT_MORE_ROM //// |
- |
|
224 |
.................... ////////////////////////////////////////////// |
- |
|
225 |
.................... |
- |
|
226 |
.................... |
- |
|
227 |
.................... |
- |
|
228 |
.................... /*Copying functions*/ |
- |
|
229 |
.................... /* standard template: |
- |
|
230 |
.................... void *memmove(void *s1, void *s2, size_t n). |
- |
|
231 |
.................... Copies max of n characters safely (not following ending '\0') |
- |
|
232 |
.................... from s2 in s1; if s2 has less than n characters, appends 0 */ |
- |
|
233 |
.................... |
- |
|
234 |
.................... char *memmove(void *s1,char *s2,size_t n) |
- |
|
235 |
.................... { |
- |
|
236 |
.................... char *sc1; |
- |
|
237 |
.................... char *sc2; |
- |
|
238 |
.................... sc1=s1; |
- |
|
239 |
.................... sc2=s2; |
- |
|
240 |
.................... if(sc2<sc1 && sc1 <sc2 +n) |
- |
|
241 |
.................... for(sc1+=n,sc2+=n;0<n;--n) |
- |
|
242 |
.................... *--sc1=*--sc2; |
- |
|
243 |
.................... else |
- |
|
244 |
.................... for(;0<n;--n) |
- |
|
245 |
.................... *sc1++=*sc2++; |
- |
|
246 |
.................... return s1; |
- |
|
247 |
.................... } |
- |
|
248 |
.................... |
- |
|
249 |
.................... /* Standard template: char *strcpy(char *s1, const char *s2) |
- |
|
250 |
.................... copies the string s2 including the null character to s1. |
- |
|
251 |
.................... This is a compiler built in to handle the different address |
- |
|
252 |
.................... spaces */ |
- |
|
253 |
.................... |
- |
|
254 |
.................... #define strcopy strcpy |
- |
|
255 |
.................... |
- |
|
256 |
.................... /* standard template: |
- |
|
257 |
.................... char *strncpy(char *s1, const char *s2, size_t n). |
- |
|
258 |
.................... Copies max of n characters (not following ending '\0') |
- |
|
259 |
.................... from s2 in s1; if s2 has less than n characters, appends 0 */ |
- |
|
260 |
.................... |
- |
|
261 |
.................... char *strncpy(char *s1, char *s2, size_t n) |
- |
|
262 |
.................... { |
- |
|
263 |
.................... char *s; |
- |
|
264 |
.................... |
- |
|
265 |
.................... for (s = s1; n > 0 && *s2 != '\0'; n--) |
- |
|
266 |
* |
- |
|
267 |
0101: MOVF 63,W |
- |
|
268 |
0102: MOVWF 68 |
- |
|
269 |
0103: MOVF 62,W |
- |
|
270 |
0104: MOVWF 67 |
- |
|
271 |
0105: MOVF 66,F |
- |
|
272 |
0106: BTFSC 03.2 |
- |
|
273 |
0107: GOTO 130 |
- |
|
274 |
0108: MOVF 65,W |
- |
|
275 |
0109: MOVWF 7A |
- |
|
276 |
010A: MOVF 64,W |
- |
|
277 |
010B: MOVWF 04 |
- |
|
278 |
010C: BCF 03.7 |
- |
|
279 |
010D: BTFSC 7A.0 |
- |
|
280 |
010E: BSF 03.7 |
- |
|
281 |
010F: MOVF 00,F |
- |
|
282 |
0110: BTFSC 03.2 |
- |
|
283 |
0111: GOTO 130 |
- |
|
284 |
.................... *s++ = *s2++; |
- |
|
285 |
0112: MOVF 68,W |
- |
|
286 |
0113: MOVWF 7A |
- |
|
287 |
0114: MOVF 67,W |
- |
|
288 |
0115: INCF 67,F |
- |
|
289 |
0116: BTFSC 03.2 |
- |
|
290 |
0117: INCF 68,F |
- |
|
291 |
0118: MOVWF 69 |
- |
|
292 |
0119: MOVF 7A,W |
- |
|
293 |
011A: MOVWF 6A |
- |
|
294 |
011B: MOVF 65,W |
- |
|
295 |
011C: MOVWF 7A |
- |
|
296 |
011D: MOVF 64,W |
- |
|
297 |
011E: INCF 64,F |
- |
|
298 |
011F: BTFSC 03.2 |
- |
|
299 |
0120: INCF 65,F |
- |
|
300 |
0121: MOVWF 04 |
- |
|
301 |
0122: BCF 03.7 |
- |
|
302 |
0123: BTFSC 7A.0 |
- |
|
303 |
0124: BSF 03.7 |
- |
|
304 |
0125: MOVF 00,W |
- |
|
305 |
0126: MOVWF 6B |
- |
|
306 |
0127: MOVF 69,W |
- |
|
307 |
0128: MOVWF 04 |
- |
|
308 |
0129: BCF 03.7 |
- |
|
309 |
012A: BTFSC 6A.0 |
- |
|
310 |
012B: BSF 03.7 |
- |
|
311 |
012C: MOVF 6B,W |
- |
|
312 |
012D: MOVWF 00 |
- |
|
313 |
012E: DECF 66,F |
- |
|
314 |
012F: GOTO 105 |
- |
|
315 |
.................... for (; n > 0; n--) |
- |
|
316 |
0130: MOVF 66,F |
- |
|
317 |
0131: BTFSC 03.2 |
- |
|
318 |
0132: GOTO 140 |
- |
|
319 |
.................... *s++ = '\0'; |
- |
|
320 |
0133: MOVF 68,W |
- |
|
321 |
0134: MOVWF 7A |
- |
|
322 |
0135: MOVF 67,W |
- |
|
323 |
0136: INCF 67,F |
- |
|
324 |
0137: BTFSC 03.2 |
- |
|
325 |
0138: INCF 68,F |
- |
|
326 |
0139: MOVWF 04 |
- |
|
327 |
013A: BCF 03.7 |
- |
|
328 |
013B: BTFSC 7A.0 |
- |
|
329 |
013C: BSF 03.7 |
- |
|
330 |
013D: CLRF 00 |
- |
|
331 |
013E: DECF 66,F |
- |
|
332 |
013F: GOTO 130 |
- |
|
333 |
.................... |
- |
|
334 |
.................... return(s1); |
- |
|
335 |
0140: MOVF 62,W |
- |
|
336 |
0141: MOVWF 78 |
- |
|
337 |
0142: MOVF 63,W |
- |
|
338 |
0143: MOVWF 79 |
- |
|
339 |
.................... } |
- |
|
340 |
0144: RETURN |
- |
|
341 |
.................... /***********************************************************/ |
- |
|
342 |
.................... |
- |
|
343 |
.................... /*concatenation functions*/ |
- |
|
344 |
.................... /* standard template: char *strcat(char *s1, const char *s2) |
- |
|
345 |
.................... appends s2 to s1*/ |
- |
|
346 |
.................... |
- |
|
347 |
.................... char *strcat(char *s1, char *s2) |
- |
|
348 |
.................... { |
- |
|
349 |
.................... char *s; |
- |
|
350 |
.................... |
- |
|
351 |
.................... for (s = s1; *s != '\0'; ++s); |
- |
|
352 |
.................... while(*s2 != '\0') |
- |
|
353 |
.................... { |
- |
|
354 |
.................... *s = *s2; |
- |
|
355 |
.................... ++s; |
- |
|
356 |
.................... ++s2; |
- |
|
357 |
.................... } |
- |
|
358 |
.................... |
- |
|
359 |
.................... *s = '\0'; |
- |
|
360 |
.................... return(s1); |
- |
|
361 |
.................... } |
- |
|
362 |
.................... /* standard template: char *strncat(char *s1, char *s2,size_t n) |
- |
|
363 |
.................... appends not more than n characters from s2 to s1*/ |
- |
|
364 |
.................... |
- |
|
365 |
.................... char *strncat(char *s1, char *s2, size_t n) |
- |
|
366 |
.................... { |
- |
|
367 |
.................... char *s; |
- |
|
368 |
.................... |
- |
|
369 |
.................... for (s = s1; *s != '\0'; ++s); |
- |
|
370 |
.................... while(*s2 != '\0' && 0<n) |
- |
|
371 |
.................... { |
- |
|
372 |
.................... *s = *s2; |
- |
|
373 |
.................... ++s; |
- |
|
374 |
.................... ++s2; |
- |
|
375 |
.................... --n; |
- |
|
376 |
.................... } |
- |
|
377 |
.................... |
- |
|
378 |
.................... *s = '\0'; |
- |
|
379 |
.................... return(s1); |
- |
|
380 |
.................... } |
- |
|
381 |
.................... |
- |
|
382 |
.................... /***********************************************************/ |
- |
|
383 |
.................... |
- |
|
384 |
.................... |
- |
|
385 |
.................... /*comparison functions*/ |
- |
|
386 |
.................... /* standard template: signed int memcmp(void *s1, void *s2). |
- |
|
387 |
.................... Compares s1 & s2; returns -1 if s1<s2, 0 if s1=s2, 1 if s1>s2 */ |
- |
|
388 |
.................... |
- |
|
389 |
.................... signed int8 memcmp(void * s1,char *s2,size_t n) |
- |
|
390 |
.................... { |
- |
|
391 |
.................... char *su1, *su2; |
- |
|
392 |
.................... for(su1=s1, su2=s2; 0<n; ++su1, ++su2, --n) |
- |
|
393 |
.................... { |
- |
|
394 |
.................... if(*su1!=*su2) |
- |
|
395 |
.................... return ((*su1<*su2)?-1:+1); |
- |
|
396 |
.................... } |
- |
|
397 |
.................... return 0; |
- |
|
398 |
.................... } |
- |
|
399 |
.................... |
- |
|
400 |
.................... /* standard template: int strcmp(const char *s1, const char *s2). |
- |
|
401 |
.................... Compares s1 & s2; returns -1 if s1<s2, 0 if s1=s2, 1 if s1>s2 */ |
- |
|
402 |
.................... |
- |
|
403 |
.................... signed int8 strcmp(char *s1, char *s2) |
- |
|
404 |
.................... { |
- |
|
405 |
.................... for (; *s1 == *s2; s1++, s2++) |
- |
|
406 |
.................... if (*s1 == '\0') |
- |
|
407 |
.................... return(0); |
- |
|
408 |
.................... return((*s1 < *s2) ? -1: 1); |
- |
|
409 |
.................... } |
- |
|
410 |
.................... /* standard template: int strcoll(const char *s1, const char *s2). |
- |
|
411 |
.................... Compares s1 & s2; returns -1 if s1<s2, 0 if s1=s2, 1 if s1>s2 */ |
- |
|
412 |
.................... |
- |
|
413 |
.................... signed int8 strcoll(char *s1, char *s2) |
- |
|
414 |
.................... { |
- |
|
415 |
.................... for (; *s1 == *s2; s1++, s2++) |
- |
|
416 |
.................... if (*s1 == '\0') |
- |
|
417 |
.................... return(0); |
- |
|
418 |
.................... return((*s1 < *s2) ? -1: 1); |
- |
|
419 |
.................... } |
- |
|
420 |
.................... |
- |
|
421 |
.................... /* standard template: |
- |
|
422 |
.................... int strncmp(const char *s1, const char *s2, size_t n). |
- |
|
423 |
.................... Compares max of n characters (not following 0) from s1 to s2; |
- |
|
424 |
.................... returns same as strcmp */ |
- |
|
425 |
.................... |
- |
|
426 |
.................... signed int8 strncmp(char *s1, char *s2, size_t n) |
- |
|
427 |
.................... { |
- |
|
428 |
.................... for (; n > 0; s1++, s2++, n--) |
- |
|
429 |
.................... if (*s1 != *s2) |
- |
|
430 |
.................... return((*s1 <*s2) ? -1: 1); |
- |
|
431 |
.................... else if (*s1 == '\0') |
- |
|
432 |
.................... return(0); |
- |
|
433 |
.................... return(0); |
- |
|
434 |
.................... } |
- |
|
435 |
.................... /* standard template: |
- |
|
436 |
.................... int strxfrm(const char *s1, const char *s2, size_t n). |
- |
|
437 |
.................... transforms maximum of n characters from s2 and places them into s1*/ |
- |
|
438 |
.................... size_t strxfrm(char *s1, char *s2, size_t n) |
- |
|
439 |
.................... { |
- |
|
440 |
.................... char *s; |
- |
|
441 |
.................... unsigned int8 n1; |
- |
|
442 |
.................... n1=n; |
- |
|
443 |
.................... for (s = s1; n > 0 && *s2 != '\0'; n--) |
- |
|
444 |
.................... *s++ = *s2++; |
- |
|
445 |
.................... for (; n > 0; n--) |
- |
|
446 |
.................... *s++ = '\0'; |
- |
|
447 |
.................... |
- |
|
448 |
.................... return(n1); |
- |
|
449 |
.................... } |
- |
|
450 |
.................... |
- |
|
451 |
.................... |
- |
|
452 |
.................... |
- |
|
453 |
.................... |
- |
|
454 |
.................... |
- |
|
455 |
.................... /***********************************************************/ |
- |
|
456 |
.................... /*Search functions*/ |
- |
|
457 |
.................... /* standard template: void *memchr(const char *s, int c). |
- |
|
458 |
.................... Finds first occurrence of c in n characters of s */ |
- |
|
459 |
.................... |
- |
|
460 |
.................... char *memchr(void *s,unsigned int8 c,size_t n) |
- |
|
461 |
.................... { |
- |
|
462 |
.................... char uc; |
- |
|
463 |
.................... char *su; |
- |
|
464 |
.................... uc=c; |
- |
|
465 |
.................... for(su=s;0<n;++su,--n) |
- |
|
466 |
.................... if(*su==uc) |
- |
|
467 |
.................... return su; |
- |
|
468 |
.................... return NULL; |
- |
|
469 |
.................... } |
- |
|
470 |
.................... |
- |
|
471 |
.................... /* standard template: char *strchr(const char *s, int c). |
- |
|
472 |
.................... Finds first occurrence of c in s */ |
- |
|
473 |
.................... |
- |
|
474 |
.................... char *strchr(char *s, unsigned int8 c) |
- |
|
475 |
.................... { |
- |
|
476 |
.................... for (; *s != c; s++) |
- |
|
477 |
.................... if (*s == '\0') |
- |
|
478 |
.................... return(0); |
- |
|
479 |
.................... return(s); |
- |
|
480 |
.................... } |
- |
|
481 |
.................... /* standard template: |
- |
|
482 |
.................... size_t strcspn(const char *s1, const char *s2). |
- |
|
483 |
.................... Computes length of max initial segment of s1 that |
- |
|
484 |
.................... consists entirely of characters NOT from s2*/ |
- |
|
485 |
.................... |
- |
|
486 |
.................... unsigned int8 strcspn(char *s1, char *s2) |
- |
|
487 |
.................... { |
- |
|
488 |
.................... char *sc1, *sc2; |
- |
|
489 |
.................... |
- |
|
490 |
.................... for (sc1 = s1; *sc1 != 0; sc1++) |
- |
|
491 |
.................... for (sc2 = s2; *sc2 != 0; sc2++) |
- |
|
492 |
.................... if (*sc1 == *sc2) |
- |
|
493 |
.................... return(sc1 - s1); |
- |
|
494 |
.................... return(sc1 - s1); |
- |
|
495 |
.................... } |
- |
|
496 |
.................... /* standard template: |
- |
|
497 |
.................... char *strpbrk(const char *s1, const char *s2). |
- |
|
498 |
.................... Locates first occurence of any character from s2 in s1; |
- |
|
499 |
.................... returns s1 if s2 is empty string */ |
- |
|
500 |
.................... |
- |
|
501 |
.................... char *strpbrk(char *s1, char *s2) |
- |
|
502 |
.................... { |
- |
|
503 |
.................... char *sc1, *sc2; |
- |
|
504 |
.................... |
- |
|
505 |
.................... for (sc1 = s1; *sc1 != 0; sc1++) |
- |
|
506 |
.................... for (sc2 = s2; *sc2 != 0; sc2++) |
- |
|
507 |
.................... if (*sc1 == *sc2) |
- |
|
508 |
.................... return(sc1); |
- |
|
509 |
.................... return(0); |
- |
|
510 |
.................... } |
- |
|
511 |
.................... |
- |
|
512 |
.................... |
- |
|
513 |
.................... /* standard template: char *strrchr(const char *s, int c). |
- |
|
514 |
.................... Finds last occurrence of c in s */ |
- |
|
515 |
.................... |
- |
|
516 |
.................... char *strrchr(char *s, unsigned int8 c) |
- |
|
517 |
.................... { |
- |
|
518 |
.................... char *p; |
- |
|
519 |
.................... |
- |
|
520 |
.................... for (p = 0; ; s++) |
- |
|
521 |
.................... { |
- |
|
522 |
.................... if (*s == c) |
- |
|
523 |
.................... p = s; |
- |
|
524 |
.................... if (*s == '\0') |
- |
|
525 |
.................... return(p); |
- |
|
526 |
.................... } |
- |
|
527 |
.................... } |
- |
|
528 |
.................... /* computes length of max initial segment of s1 consisting |
- |
|
529 |
.................... entirely of characters from s2 */ |
- |
|
530 |
.................... |
- |
|
531 |
.................... unsigned int8 strspn(char *s1, char *s2) |
- |
|
532 |
.................... { |
- |
|
533 |
.................... char *sc1, *sc2; |
- |
|
534 |
.................... |
- |
|
535 |
.................... for (sc1 = s1; *sc1 != 0; sc1++) |
- |
|
536 |
.................... for (sc2 = s2; ; sc2++) |
- |
|
537 |
.................... if (*sc2 == '\0') |
- |
|
538 |
.................... return(sc1 - s1); |
- |
|
539 |
.................... else if (*sc1 == *sc2) |
- |
|
540 |
.................... break; |
- |
|
541 |
.................... return(sc1 - s1); |
- |
|
542 |
.................... } |
- |
|
543 |
.................... /* standard template: |
- |
|
544 |
.................... char *strstr(const char *s1, const char *s2); |
- |
|
545 |
.................... Locates first occurence of character sequence s2 in s1; |
- |
|
546 |
.................... returns 0 if s2 is empty string |
- |
|
547 |
.................... |
- |
|
548 |
.................... Uncomment #define FASTER_BUT_MORE_ROM at the top of the |
- |
|
549 |
.................... file to use the faster algorithm */ |
- |
|
550 |
.................... char *strstr(char *s1, char *s2) |
- |
|
551 |
.................... { |
- |
|
552 |
.................... char *s, *t; |
- |
|
553 |
.................... |
- |
|
554 |
.................... #ifdef FASTER_BUT_MORE_ROM |
- |
|
555 |
.................... if (*s2 == '\0') |
- |
|
556 |
.................... return(s1); |
- |
|
557 |
.................... #endif |
- |
|
558 |
.................... |
- |
|
559 |
.................... while (*s1) |
- |
|
560 |
.................... { |
- |
|
561 |
.................... for(s = s1, t = s2; *t && (*s == *t); ++s, ++t); |
- |
|
562 |
.................... |
- |
|
563 |
.................... if (*t == '\0') |
- |
|
564 |
.................... return s1; |
- |
|
565 |
.................... ++s1; |
- |
|
566 |
.................... #ifdef FASTER_BUT_MORE_ROM |
- |
|
567 |
.................... while(*s1 != '\0' && *s1 != *s2) |
- |
|
568 |
.................... ++s1; |
- |
|
569 |
.................... #endif |
- |
|
570 |
.................... } |
- |
|
571 |
.................... return 0; |
- |
|
572 |
.................... } |
- |
|
573 |
.................... |
- |
|
574 |
.................... /* standard template: char *strtok(char *s1, const char *s2). |
- |
|
575 |
.................... |
- |
|
576 |
.................... Finds next token in s1 delimited by a character from separator |
- |
|
577 |
.................... string s2 (which can be different from call to call). First call |
- |
|
578 |
.................... starts at beginning of s1 searching for first character NOT |
- |
|
579 |
.................... contained in s2; returns 0 if none is found. |
- |
|
580 |
.................... If one is found, it is the start of first token (return value). |
- |
|
581 |
.................... Function then searches from there for a character contained in s2. |
- |
|
582 |
.................... If none is found, current token extends to end of s1, and subsequent |
- |
|
583 |
.................... searches for a token will return 0. If one is found, it is |
- |
|
584 |
.................... overwritten by '\0', which terminates current token. Function saves |
- |
|
585 |
.................... pointer to following character from which next search will start. |
- |
|
586 |
.................... Each subsequent call, with 0 as first argument, starts searching |
- |
|
587 |
.................... from saved pointer */ |
- |
|
588 |
.................... |
- |
|
589 |
.................... char *strtok(char *s1, char *s2) |
- |
|
590 |
.................... { |
- |
|
591 |
.................... char *beg, *end; |
- |
|
592 |
.................... static char *save; |
- |
|
593 |
* |
- |
|
594 |
0366: CLRF 29 |
- |
|
595 |
0367: CLRF 2A |
- |
|
596 |
.................... |
- |
|
597 |
.................... beg = (s1)? s1: save; |
- |
|
598 |
.................... beg += strspn(beg, s2); |
- |
|
599 |
.................... if (*beg == '\0') |
- |
|
600 |
.................... { |
- |
|
601 |
.................... *save = ' '; |
- |
|
602 |
.................... return(0); |
- |
|
603 |
.................... } |
- |
|
604 |
.................... end = strpbrk(beg, s2); |
- |
|
605 |
.................... if (*end != '\0') |
- |
|
606 |
.................... { |
- |
|
607 |
.................... *end = '\0'; |
- |
|
608 |
.................... end++; |
- |
|
609 |
.................... } |
- |
|
610 |
.................... save = end; |
- |
|
611 |
.................... return(beg); |
- |
|
612 |
.................... } |
- |
|
613 |
.................... |
- |
|
614 |
.................... /*****************************************************************/ |
- |
|
615 |
.................... /*Miscellaneous functions*/ |
- |
|
616 |
.................... /* standard template |
- |
|
617 |
.................... maps error number in errnum to an error message string |
- |
|
618 |
.................... Returns: Pointer to string |
- |
|
619 |
.................... */ |
- |
|
620 |
.................... #ifdef _ERRNO |
- |
|
621 |
.................... char * strerror(unsigned int8 errnum) |
- |
|
622 |
.................... { |
- |
|
623 |
.................... char s[15]; |
- |
|
624 |
.................... switch( errnum) |
- |
|
625 |
.................... { |
- |
|
626 |
.................... case 0: |
- |
|
627 |
.................... strcpy(s,"no errors"); |
- |
|
628 |
.................... return s; |
- |
|
629 |
.................... case EDOM : |
- |
|
630 |
.................... strcpy(s,"domain error"); |
- |
|
631 |
.................... return s; |
- |
|
632 |
.................... case ERANGE: |
- |
|
633 |
.................... strcpy(s,"range error"); |
- |
|
634 |
.................... return s; |
- |
|
635 |
.................... } |
- |
|
636 |
.................... } |
- |
|
637 |
.................... #ENDIF |
- |
|
638 |
.................... /* standard template: size_t strlen(const char *s). |
- |
|
639 |
.................... Computes length of s1 (preceding terminating 0) */ |
- |
|
640 |
.................... |
- |
|
641 |
.................... unsigned int8 strlen(char *s) |
- |
|
642 |
.................... { |
- |
|
643 |
.................... char *sc; |
150 |
.................... |
644 |
.................... |
- |
|
645 |
.................... for (sc = s; *sc != 0; sc++); |
- |
|
646 |
.................... return(sc - s); |
- |
|
647 |
.................... } |
- |
|
648 |
.................... |
- |
|
649 |
.................... /* standard template: size_t stricmp(const char *s1, const char *s2). |
- |
|
650 |
.................... Compares s1 to s2 ignoring case (upper vs. lower) */ |
- |
|
651 |
.................... |
- |
|
652 |
.................... signed int8 stricmp(char *s1, char *s2) |
- |
|
653 |
.................... { |
- |
|
654 |
.................... for(; *s1==*s2||(isalpha(*s1)&&isalpha(*s2)&&(*s1==*s2+32||*s2==*s1+32)); |
- |
|
655 |
.................... s1++, s2++) |
- |
|
656 |
.................... if (*s1 == '\0') |
- |
|
657 |
.................... return(0); |
- |
|
658 |
.................... return((*s1 < *s2) ? -1: 1); |
- |
|
659 |
.................... } |
- |
|
660 |
.................... |
- |
|
661 |
.................... |
- |
|
662 |
.................... /* standard template: char *strlwr(char *s). |
- |
|
663 |
.................... Replaces uppercase letters by lowercase; |
- |
|
664 |
.................... returns pointer to new string s */ |
- |
|
665 |
.................... |
- |
|
666 |
.................... char *strlwr(char *s) |
- |
|
667 |
.................... { |
- |
|
668 |
.................... char *p; |
- |
|
669 |
.................... |
- |
|
670 |
.................... for (p = s; *p != '\0'; p++) |
- |
|
671 |
.................... if (*p >= 'A' && *p <='Z') |
- |
|
672 |
.................... *p += 'a' - 'A'; |
- |
|
673 |
.................... return(s); |
- |
|
674 |
.................... } |
151 |
.................... |
675 |
.................... |
152 |
.................... |
676 |
.................... |
- |
|
677 |
.................... /************************************************************/ |
- |
|
678 |
.................... |
- |
|
679 |
.................... |
- |
|
680 |
.................... #endif |
- |
|
681 |
.................... |
153 |
.................... |
682 |
.................... |
154 |
.................... #define LED PIN_E1 |
683 |
.................... #define LED PIN_E1 |
155 |
.................... #define CE PIN_E2 |
684 |
.................... #define CE PIN_E2 |
156 |
.................... |
685 |
.................... |
- |
|
686 |
.................... #define SEL0 PIN_E0 // external counter division ratio |
- |
|
687 |
.................... #define SEL1 PIN_E1 // external counter division ratio |
- |
|
688 |
.................... #define MR PIN_E2 // external counter master reset |
- |
|
689 |
.................... #define CLKI PIN_C0 // internal counter input |
- |
|
690 |
.................... #define BEEP PIN_C3 // buzzer |
- |
|
691 |
.................... |
157 |
.................... int16 count; |
692 |
.................... unsigned int32 count; |
158 |
.................... |
693 |
.................... |
159 |
.................... int8 rcv_buf[0x10]; // I2C receive buffer |
- |
|
160 |
.................... int8 snd_buf[0x10]; // I2C send buffer |
- |
|
161 |
.................... |
694 |
.................... |
162 |
.................... int8 buffer[0x10]; // I2C buffer |
695 |
.................... int8 buffer[0x10]; // I2C buffer |
163 |
.................... int8 address; |
696 |
.................... int8 address; |
164 |
.................... |
697 |
.................... |
- |
|
698 |
.................... unsigned int16 of=0; // count of overflow |
- |
|
699 |
.................... |
165 |
.................... const char cmd[40]={0xB5, 0x62, 0x06, 0x31, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x32, 0x00, 0x00, 0x00, 0x80, 0x84, 0x1E, 0x00, 0xE0, 0xC8, 0x10, 0x00, 0x40, 0x42, 0x0F, 0x00, 0xA0, 0x86, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF7, 0x00, 0x00, 0x00, 0x12, 0x03}; |
700 |
.................... const char cmd[40]={0xB5, 0x62, 0x06, 0x31, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x32, 0x00, 0x00, 0x00, 0x80, 0x84, 0x1E, 0x00, 0xE0, 0xC8, 0x10, 0x00, 0x40, 0x42, 0x0F, 0x00, 0xA0, 0x86, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF7, 0x00, 0x00, 0x00, 0x12, 0x03}; |
166 |
.................... |
701 |
.................... |
167 |
.................... #INT_SSP |
702 |
.................... #INT_SSP |
168 |
.................... void ssp_interupt () |
703 |
.................... void ssp_interupt () |
169 |
.................... { |
704 |
.................... { |
170 |
.................... BYTE incoming, state; |
705 |
.................... BYTE incoming, state; |
171 |
.................... |
706 |
.................... |
172 |
.................... state = i2c_isr_state(); |
707 |
.................... state = i2c_isr_state(); |
173 |
* |
708 |
* |
174 |
0066: BSF 03.5 |
709 |
006D: BSF 03.5 |
175 |
0067: BTFSC 14.5 |
710 |
006E: BTFSC 14.5 |
176 |
0068: GOTO 071 |
711 |
006F: GOTO 078 |
177 |
0069: BCF 03.5 |
712 |
0070: BCF 03.5 |
178 |
006A: CLRF 5C |
713 |
0071: CLRF 42 |
179 |
006B: BSF 03.5 |
714 |
0072: BSF 03.5 |
180 |
006C: BTFSS 14.2 |
715 |
0073: BTFSS 14.2 |
181 |
006D: GOTO 071 |
716 |
0074: GOTO 078 |
182 |
006E: BCF 03.5 |
717 |
0075: BCF 03.5 |
183 |
006F: BSF 5C.7 |
718 |
0076: BSF 42.7 |
184 |
0070: BSF 03.5 |
719 |
0077: BSF 03.5 |
185 |
0071: BCF 03.5 |
720 |
0078: BCF 03.5 |
186 |
0072: MOVF 5C,W |
721 |
0079: MOVF 42,W |
187 |
0073: INCF 5C,F |
722 |
007A: INCF 42,F |
188 |
0074: MOVWF 68 |
723 |
007B: MOVWF 4A |
189 |
.................... |
724 |
.................... |
190 |
.................... if(state < 0x80) //Master is sending data |
725 |
.................... if(state < 0x80) //Master is sending data |
191 |
0075: MOVF 68,W |
726 |
007C: MOVF 4A,W |
192 |
0076: SUBLW 7F |
727 |
007D: SUBLW 7F |
193 |
0077: BTFSS 03.0 |
728 |
007E: BTFSS 03.0 |
194 |
0078: GOTO 095 |
729 |
007F: GOTO 0A0 |
195 |
.................... { |
730 |
.................... { |
196 |
.................... incoming = i2c_read(); |
731 |
.................... incoming = i2c_read(); |
197 |
0079: BCF 14.6 |
732 |
0080: BCF 14.6 |
198 |
007A: BTFSS 0C.3 |
733 |
0081: BTFSS 0C.3 |
199 |
007B: GOTO 07A |
734 |
0082: GOTO 081 |
200 |
007C: MOVF 13,W |
735 |
0083: MOVF 13,W |
201 |
007D: BSF 14.4 |
736 |
0084: BSF 14.4 |
202 |
007E: MOVWF 67 |
737 |
0085: MOVWF 49 |
203 |
.................... if(state == 1) //First received byte is address |
738 |
.................... if(state == 1) //First received byte is address |
204 |
007F: DECFSZ 68,W |
739 |
0086: DECFSZ 4A,W |
205 |
0080: GOTO 08B |
740 |
0087: GOTO 096 |
206 |
.................... { |
741 |
.................... { |
207 |
.................... address = incoming; |
742 |
.................... address = incoming; |
208 |
0081: MOVF 67,W |
743 |
0088: MOVF 49,W |
209 |
0082: MOVWF 5B |
744 |
0089: MOVWF 3F |
210 |
.................... if (incoming == 2) |
745 |
.................... if (incoming == 2) |
211 |
0083: MOVF 67,W |
746 |
008A: MOVF 49,W |
212 |
0084: SUBLW 02 |
747 |
008B: SUBLW 02 |
213 |
0085: BTFSS 03.2 |
748 |
008C: BTFSS 03.2 |
214 |
0086: GOTO 08B |
749 |
008D: GOTO 096 |
215 |
.................... { |
750 |
.................... { |
216 |
.................... buffer[0]=make8(count,0); |
751 |
.................... buffer[0]=make8(count,0); |
217 |
0087: MOVF 29,W |
752 |
008E: MOVF 2B,W |
218 |
0088: MOVWF 4B |
753 |
008F: MOVWF 2F |
219 |
.................... buffer[1]=make8(count,1); |
754 |
.................... buffer[1]=make8(count,1); |
220 |
0089: MOVF 2A,W |
755 |
0090: MOVF 2C,W |
- |
|
756 |
0091: MOVWF 30 |
- |
|
757 |
.................... buffer[2]=make8(count,2); |
- |
|
758 |
0092: MOVF 2D,W |
- |
|
759 |
0093: MOVWF 31 |
- |
|
760 |
.................... buffer[3]=make8(count,3); |
- |
|
761 |
0094: MOVF 2E,W |
221 |
008A: MOVWF 4C |
762 |
0095: MOVWF 32 |
222 |
.................... } |
763 |
.................... } |
223 |
.................... } |
764 |
.................... } |
224 |
.................... if(state == 2) //Second received byte is data |
765 |
.................... if(state == 2) //Second received byte is data |
225 |
008B: MOVF 68,W |
766 |
0096: MOVF 4A,W |
226 |
008C: SUBLW 02 |
767 |
0097: SUBLW 02 |
227 |
008D: BTFSS 03.2 |
768 |
0098: BTFSS 03.2 |
228 |
008E: GOTO 095 |
769 |
0099: GOTO 0A0 |
229 |
.................... buffer[address] = incoming; |
770 |
.................... buffer[address] = incoming; |
230 |
008F: MOVLW 4B |
771 |
009A: MOVLW 2F |
231 |
0090: ADDWF 5B,W |
772 |
009B: ADDWF 3F,W |
232 |
0091: MOVWF 04 |
773 |
009C: MOVWF 04 |
233 |
0092: BCF 03.7 |
774 |
009D: BCF 03.7 |
234 |
0093: MOVF 67,W |
775 |
009E: MOVF 49,W |
235 |
0094: MOVWF 00 |
776 |
009F: MOVWF 00 |
236 |
.................... |
777 |
.................... |
237 |
.................... |
778 |
.................... |
238 |
.................... } |
779 |
.................... } |
239 |
.................... if(state == 0x80) //Master is requesting data |
780 |
.................... if(state == 0x80) //Master is requesting data |
240 |
0095: MOVF 68,W |
781 |
00A0: MOVF 4A,W |
241 |
0096: SUBLW 80 |
782 |
00A1: SUBLW 80 |
242 |
0097: BTFSS 03.2 |
783 |
00A2: BTFSS 03.2 |
243 |
0098: GOTO 0AC |
784 |
00A3: GOTO 0B7 |
244 |
.................... { |
785 |
.................... { |
245 |
.................... i2c_write(buffer[address]); |
786 |
.................... i2c_write(buffer[address]); |
246 |
0099: MOVLW 4B |
787 |
00A4: MOVLW 2F |
247 |
009A: ADDWF 5B,W |
788 |
00A5: ADDWF 3F,W |
248 |
009B: MOVWF 04 |
789 |
00A6: MOVWF 04 |
249 |
009C: BCF 03.7 |
790 |
00A7: BCF 03.7 |
250 |
009D: MOVF 00,W |
791 |
00A8: MOVF 00,W |
251 |
009E: MOVWF 69 |
792 |
00A9: MOVWF 4B |
252 |
009F: MOVF 69,W |
793 |
00AA: MOVF 4B,W |
253 |
00A0: MOVWF 6A |
794 |
00AB: MOVWF 4C |
254 |
.................... } |
795 |
.................... } |
255 |
.................... } |
796 |
.................... } |
256 |
.................... |
797 |
.................... |
257 |
.................... |
798 |
.................... |
258 |
* |
799 |
* |
259 |
00AC: BCF 0C.3 |
800 |
00B7: BCF 0C.3 |
260 |
00AD: BCF 0A.3 |
801 |
00B8: BCF 0A.3 |
261 |
00AE: BCF 0A.4 |
802 |
00B9: BCF 0A.4 |
262 |
00AF: GOTO 023 |
803 |
00BA: GOTO 027 |
- |
|
804 |
.................... #int_EXT // Interrupt from 1PPS |
- |
|
805 |
.................... void EXT_isr(void) |
- |
|
806 |
.................... { |
- |
|
807 |
.................... unsigned int16 countH; |
- |
|
808 |
.................... unsigned int8 countL; |
- |
|
809 |
.................... char countS[10], a[4], b[4], c[4]; // strings for printing results |
- |
|
810 |
.................... |
- |
|
811 |
.................... countL=0; |
- |
|
812 |
* |
- |
|
813 |
0145: CLRF 4B |
- |
|
814 |
.................... countH=get_timer1(); // read internal counter |
- |
|
815 |
0146: MOVF 0F,W |
- |
|
816 |
0147: MOVWF 7A |
- |
|
817 |
0148: MOVF 0E,W |
- |
|
818 |
0149: MOVWF 77 |
- |
|
819 |
014A: MOVF 0F,W |
- |
|
820 |
014B: SUBWF 7A,W |
- |
|
821 |
014C: BTFSS 03.2 |
- |
|
822 |
014D: GOTO 146 |
- |
|
823 |
014E: MOVF 77,W |
- |
|
824 |
014F: MOVWF 49 |
- |
|
825 |
0150: MOVF 7A,W |
- |
|
826 |
0151: MOVWF 4A |
- |
|
827 |
.................... output_low(SEL0); |
- |
|
828 |
0152: BSF 03.5 |
- |
|
829 |
0153: BCF 09.0 |
- |
|
830 |
0154: BCF 03.5 |
- |
|
831 |
0155: BCF 09.0 |
- |
|
832 |
.................... output_low(SEL1); |
- |
|
833 |
0156: BSF 03.5 |
- |
|
834 |
0157: BCF 09.1 |
- |
|
835 |
0158: BCF 03.5 |
- |
|
836 |
0159: BCF 09.1 |
- |
|
837 |
.................... countL=input(CLKI); // read bit 0 of external counter |
- |
|
838 |
015A: BSF 28.0 |
- |
|
839 |
015B: MOVF 28,W |
- |
|
840 |
015C: BSF 03.5 |
- |
|
841 |
015D: MOVWF 07 |
- |
|
842 |
015E: BCF 03.5 |
- |
|
843 |
015F: CLRF 4B |
- |
|
844 |
0160: BTFSC 07.0 |
- |
|
845 |
0161: INCF 4B,F |
- |
|
846 |
.................... output_high(SEL0); |
- |
|
847 |
0162: BSF 03.5 |
- |
|
848 |
0163: BCF 09.0 |
- |
|
849 |
0164: BCF 03.5 |
- |
|
850 |
0165: BSF 09.0 |
- |
|
851 |
.................... output_low(SEL1); |
- |
|
852 |
0166: BSF 03.5 |
- |
|
853 |
0167: BCF 09.1 |
- |
|
854 |
0168: BCF 03.5 |
- |
|
855 |
0169: BCF 09.1 |
- |
|
856 |
.................... countL|=input(CLKI)<<1; // read bit 1 of external counter |
- |
|
857 |
016A: BSF 28.0 |
- |
|
858 |
016B: MOVF 28,W |
- |
|
859 |
016C: BSF 03.5 |
- |
|
860 |
016D: MOVWF 07 |
- |
|
861 |
016E: MOVLW 00 |
- |
|
862 |
016F: BCF 03.5 |
- |
|
863 |
0170: BTFSC 07.0 |
- |
|
864 |
0171: MOVLW 01 |
- |
|
865 |
0172: MOVWF 77 |
- |
|
866 |
0173: BCF 03.0 |
- |
|
867 |
0174: RLF 77,F |
- |
|
868 |
0175: MOVF 77,W |
- |
|
869 |
0176: IORWF 4B,F |
- |
|
870 |
.................... output_low(SEL0); |
- |
|
871 |
0177: BSF 03.5 |
- |
|
872 |
0178: BCF 09.0 |
- |
|
873 |
0179: BCF 03.5 |
- |
|
874 |
017A: BCF 09.0 |
- |
|
875 |
.................... output_high(SEL1); |
- |
|
876 |
017B: BSF 03.5 |
- |
|
877 |
017C: BCF 09.1 |
- |
|
878 |
017D: BCF 03.5 |
- |
|
879 |
017E: BSF 09.1 |
- |
|
880 |
.................... countL|=input(CLKI)<<2; // read bit 2 of external counter |
- |
|
881 |
017F: BSF 28.0 |
- |
|
882 |
0180: MOVF 28,W |
- |
|
883 |
0181: BSF 03.5 |
- |
|
884 |
0182: MOVWF 07 |
- |
|
885 |
0183: MOVLW 00 |
- |
|
886 |
0184: BCF 03.5 |
- |
|
887 |
0185: BTFSC 07.0 |
- |
|
888 |
0186: MOVLW 01 |
- |
|
889 |
0187: MOVWF 77 |
- |
|
890 |
0188: RLF 77,F |
- |
|
891 |
0189: RLF 77,F |
- |
|
892 |
018A: MOVLW FC |
- |
|
893 |
018B: ANDWF 77,F |
- |
|
894 |
018C: MOVF 77,W |
- |
|
895 |
018D: IORWF 4B,F |
- |
|
896 |
.................... output_high(SEL0); |
- |
|
897 |
018E: BSF 03.5 |
- |
|
898 |
018F: BCF 09.0 |
- |
|
899 |
0190: BCF 03.5 |
- |
|
900 |
0191: BSF 09.0 |
- |
|
901 |
.................... output_high(SEL1); |
- |
|
902 |
0192: BSF 03.5 |
- |
|
903 |
0193: BCF 09.1 |
- |
|
904 |
0194: BCF 03.5 |
- |
|
905 |
0195: BSF 09.1 |
- |
|
906 |
.................... countL|=input(CLKI)<<3; // read bit 3 of external counter |
- |
|
907 |
0196: BSF 28.0 |
- |
|
908 |
0197: MOVF 28,W |
- |
|
909 |
0198: BSF 03.5 |
- |
|
910 |
0199: MOVWF 07 |
- |
|
911 |
019A: MOVLW 00 |
- |
|
912 |
019B: BCF 03.5 |
- |
|
913 |
019C: BTFSC 07.0 |
- |
|
914 |
019D: MOVLW 01 |
- |
|
915 |
019E: MOVWF 77 |
- |
|
916 |
019F: RLF 77,F |
- |
|
917 |
01A0: RLF 77,F |
- |
|
918 |
01A1: RLF 77,F |
- |
|
919 |
01A2: MOVLW F8 |
- |
|
920 |
01A3: ANDWF 77,F |
- |
|
921 |
01A4: MOVF 77,W |
- |
|
922 |
01A5: IORWF 4B,F |
- |
|
923 |
.................... |
- |
|
924 |
.................... output_low(MR); // External counter Master Reset |
- |
|
925 |
01A6: BSF 03.5 |
- |
|
926 |
01A7: BCF 09.2 |
- |
|
927 |
01A8: BCF 03.5 |
- |
|
928 |
01A9: BCF 09.2 |
- |
|
929 |
.................... output_high(MR); |
- |
|
930 |
01AA: BSF 03.5 |
- |
|
931 |
01AB: BCF 09.2 |
- |
|
932 |
01AC: BCF 03.5 |
- |
|
933 |
01AD: BSF 09.2 |
- |
|
934 |
.................... |
- |
|
935 |
.................... set_timer1(0); // Internal counter reset |
- |
|
936 |
01AE: CLRF 0F |
- |
|
937 |
01AF: CLRF 0E |
- |
|
938 |
.................... |
- |
|
939 |
.................... count=((unsigned int32)of<<20)+((unsigned int32)countH<<4)+(unsigned int32)countL; // concatenate |
- |
|
940 |
01B0: CLRF 65 |
- |
|
941 |
01B1: CLRF 64 |
- |
|
942 |
01B2: MOVF 41,W |
- |
|
943 |
01B3: MOVWF 63 |
- |
|
944 |
01B4: MOVF 40,W |
- |
|
945 |
01B5: MOVWF 62 |
- |
|
946 |
01B6: MOVF 41,W |
- |
|
947 |
01B7: MOVWF 65 |
- |
|
948 |
01B8: MOVF 40,W |
- |
|
949 |
01B9: MOVWF 64 |
- |
|
950 |
01BA: CLRF 62 |
- |
|
951 |
01BB: CLRF 63 |
- |
|
952 |
01BC: RLF 64,F |
- |
|
953 |
01BD: RLF 65,F |
- |
|
954 |
01BE: RLF 64,F |
- |
|
955 |
01BF: RLF 65,F |
- |
|
956 |
01C0: RLF 64,F |
- |
|
957 |
01C1: RLF 65,F |
- |
|
958 |
01C2: RLF 64,F |
- |
|
959 |
01C3: RLF 65,F |
- |
|
960 |
01C4: MOVLW F0 |
- |
|
961 |
01C5: ANDWF 64,F |
- |
|
962 |
01C6: CLRF 6A |
- |
|
963 |
01C7: CLRF 69 |
- |
|
964 |
01C8: RLF 49,W |
- |
|
965 |
01C9: MOVWF 77 |
- |
|
966 |
01CA: RLF 4A,W |
- |
|
967 |
01CB: MOVWF 78 |
- |
|
968 |
01CC: RLF 69,W |
- |
|
969 |
01CD: MOVWF 79 |
- |
|
970 |
01CE: RLF 6A,W |
- |
|
971 |
01CF: MOVWF 7A |
- |
|
972 |
01D0: RLF 77,F |
- |
|
973 |
01D1: RLF 78,F |
- |
|
974 |
01D2: RLF 79,F |
- |
|
975 |
01D3: RLF 7A,F |
- |
|
976 |
01D4: RLF 77,F |
- |
|
977 |
01D5: RLF 78,F |
- |
|
978 |
01D6: RLF 79,F |
- |
|
979 |
01D7: RLF 7A,F |
- |
|
980 |
01D8: RLF 77,F |
- |
|
981 |
01D9: RLF 78,F |
- |
|
982 |
01DA: RLF 79,F |
- |
|
983 |
01DB: RLF 7A,F |
- |
|
984 |
01DC: MOVLW F0 |
- |
|
985 |
01DD: ANDWF 77,F |
- |
|
986 |
01DE: MOVF 77,W |
- |
|
987 |
01DF: ADDWF 62,F |
- |
|
988 |
01E0: MOVF 78,W |
- |
|
989 |
01E1: BTFSC 03.0 |
- |
|
990 |
01E2: INCFSZ 78,W |
- |
|
991 |
01E3: ADDWF 63,F |
- |
|
992 |
01E4: MOVF 79,W |
- |
|
993 |
01E5: BTFSC 03.0 |
- |
|
994 |
01E6: INCFSZ 79,W |
- |
|
995 |
01E7: ADDWF 64,F |
- |
|
996 |
01E8: MOVF 7A,W |
- |
|
997 |
01E9: BTFSC 03.0 |
- |
|
998 |
01EA: INCFSZ 7A,W |
- |
|
999 |
01EB: ADDWF 65,F |
- |
|
1000 |
01EC: CLRF 78 |
- |
|
1001 |
01ED: CLRF 79 |
- |
|
1002 |
01EE: CLRF 7A |
- |
|
1003 |
01EF: MOVF 4B,W |
- |
|
1004 |
01F0: ADDWF 62,W |
- |
|
1005 |
01F1: MOVWF 2B |
- |
|
1006 |
01F2: MOVF 63,W |
- |
|
1007 |
01F3: MOVWF 2C |
- |
|
1008 |
01F4: MOVF 78,W |
- |
|
1009 |
01F5: BTFSC 03.0 |
- |
|
1010 |
01F6: INCFSZ 78,W |
- |
|
1011 |
01F7: ADDWF 2C,F |
- |
|
1012 |
01F8: MOVF 64,W |
- |
|
1013 |
01F9: MOVWF 2D |
- |
|
1014 |
01FA: MOVF 79,W |
- |
|
1015 |
01FB: BTFSC 03.0 |
- |
|
1016 |
01FC: INCFSZ 79,W |
- |
|
1017 |
01FD: ADDWF 2D,F |
- |
|
1018 |
01FE: MOVF 65,W |
- |
|
1019 |
01FF: MOVWF 2E |
- |
|
1020 |
0200: MOVF 7A,W |
- |
|
1021 |
0201: BTFSC 03.0 |
- |
|
1022 |
0202: INCFSZ 7A,W |
- |
|
1023 |
0203: ADDWF 2E,F |
- |
|
1024 |
.................... |
- |
|
1025 |
.................... sprintf(countS,"%09Lu", count); // engeneering values conversion |
- |
|
1026 |
0204: CLRF 44 |
- |
|
1027 |
0205: MOVLW 4C |
- |
|
1028 |
0206: MOVWF 43 |
- |
|
1029 |
0207: MOVLW 49 |
- |
|
1030 |
0208: MOVWF 04 |
- |
|
1031 |
0209: MOVF 2E,W |
- |
|
1032 |
020A: MOVWF 65 |
- |
|
1033 |
020B: MOVF 2D,W |
- |
|
1034 |
020C: MOVWF 64 |
- |
|
1035 |
020D: MOVF 2C,W |
- |
|
1036 |
020E: MOVWF 63 |
- |
|
1037 |
020F: MOVF 2B,W |
- |
|
1038 |
0210: MOVWF 62 |
- |
|
1039 |
.................... strncpy(a, countS, 3); a[3]='\0'; |
- |
|
1040 |
* |
- |
|
1041 |
027A: CLRF 63 |
- |
|
1042 |
027B: MOVLW 56 |
- |
|
1043 |
027C: MOVWF 62 |
- |
|
1044 |
027D: CLRF 65 |
- |
|
1045 |
027E: MOVLW 4C |
- |
|
1046 |
027F: MOVWF 64 |
- |
|
1047 |
0280: MOVLW 03 |
- |
|
1048 |
0281: MOVWF 66 |
- |
|
1049 |
0282: CALL 101 |
- |
|
1050 |
0283: CLRF 59 |
- |
|
1051 |
.................... strncpy(b, &countS[3], 3); b[3]='\0'; |
- |
|
1052 |
0284: CLRF 63 |
- |
|
1053 |
0285: MOVLW 5A |
- |
|
1054 |
0286: MOVWF 62 |
- |
|
1055 |
0287: CLRF 65 |
- |
|
1056 |
0288: MOVLW 4F |
- |
|
1057 |
0289: MOVWF 64 |
- |
|
1058 |
028A: MOVLW 03 |
- |
|
1059 |
028B: MOVWF 66 |
- |
|
1060 |
028C: CALL 101 |
- |
|
1061 |
028D: CLRF 5D |
- |
|
1062 |
.................... strncpy(c, &countS[6], 3); c[3]='\0'; |
- |
|
1063 |
028E: CLRF 63 |
- |
|
1064 |
028F: MOVLW 5E |
- |
|
1065 |
0290: MOVWF 62 |
- |
|
1066 |
0291: CLRF 65 |
- |
|
1067 |
0292: MOVLW 52 |
- |
|
1068 |
0293: MOVWF 64 |
- |
|
1069 |
0294: MOVLW 03 |
- |
|
1070 |
0295: MOVWF 66 |
- |
|
1071 |
0296: CALL 101 |
- |
|
1072 |
0297: CLRF 61 |
- |
|
1073 |
.................... |
- |
|
1074 |
.................... printf("%s\r\n", countS); // output to RS232 |
- |
|
1075 |
0298: MOVLW 4C |
- |
|
1076 |
0299: MOVWF 04 |
- |
|
1077 |
029A: BCF 03.7 |
- |
|
1078 |
* |
- |
|
1079 |
02B1: MOVLW 0D |
- |
|
1080 |
02B2: BTFSS 0C.4 |
- |
|
1081 |
02B3: GOTO 2B2 |
- |
|
1082 |
02B4: MOVWF 19 |
- |
|
1083 |
02B5: MOVLW 0A |
- |
|
1084 |
02B6: BTFSS 0C.4 |
- |
|
1085 |
02B7: GOTO 2B6 |
- |
|
1086 |
02B8: MOVWF 19 |
- |
|
1087 |
.................... |
- |
|
1088 |
.................... output_toggle(BEEP); // cvak... |
- |
|
1089 |
02B9: BCF 28.3 |
- |
|
1090 |
02BA: MOVF 28,W |
- |
|
1091 |
02BB: BSF 03.5 |
- |
|
1092 |
02BC: MOVWF 07 |
- |
|
1093 |
02BD: MOVLW 08 |
- |
|
1094 |
02BE: BCF 03.5 |
- |
|
1095 |
02BF: XORWF 07,F |
- |
|
1096 |
.................... |
- |
|
1097 |
.................... of=0; // reset overflow counter |
- |
|
1098 |
02C0: CLRF 41 |
- |
|
1099 |
02C1: CLRF 40 |
- |
|
1100 |
.................... } |
- |
|
1101 |
.................... |
- |
|
1102 |
02C2: BCF 0B.1 |
- |
|
1103 |
02C3: BCF 0A.3 |
- |
|
1104 |
02C4: BCF 0A.4 |
- |
|
1105 |
02C5: GOTO 027 |
- |
|
1106 |
.................... #int_TIMER1 // Interrupf from overflow |
- |
|
1107 |
.................... void TIMER1_isr(void) |
- |
|
1108 |
.................... { |
- |
|
1109 |
.................... of++; |
- |
|
1110 |
02C6: INCF 40,F |
- |
|
1111 |
02C7: BTFSC 03.2 |
- |
|
1112 |
02C8: INCF 41,F |
- |
|
1113 |
.................... } |
- |
|
1114 |
.................... |
- |
|
1115 |
.................... |
263 |
.................... #int_TIMER2 // every 10 ms |
1116 |
.................... /*#int_TIMER2 // every 10 ms |
264 |
.................... void TIMER2_isr(void) |
1117 |
.................... void TIMER2_isr(void) |
265 |
.................... { |
1118 |
.................... { |
266 |
.................... output_low(CE); |
1119 |
.................... output_low(CE); |
267 |
00B0: BSF 03.5 |
- |
|
268 |
00B1: BCF 09.2 |
- |
|
269 |
00B2: BCF 03.5 |
- |
|
270 |
00B3: BCF 09.2 |
- |
|
271 |
.................... count=get_timer1(); |
1120 |
.................... count=get_timer1(); |
272 |
00B4: MOVF 0F,W |
- |
|
273 |
00B5: MOVWF 7A |
- |
|
274 |
00B6: MOVF 0E,W |
- |
|
275 |
00B7: MOVWF 77 |
- |
|
276 |
00B8: MOVF 0F,W |
- |
|
277 |
00B9: SUBWF 7A,W |
- |
|
278 |
00BA: BTFSS 03.2 |
- |
|
279 |
00BB: GOTO 0B4 |
- |
|
280 |
00BC: MOVF 77,W |
- |
|
281 |
00BD: MOVWF 29 |
- |
|
282 |
00BE: MOVF 7A,W |
- |
|
283 |
00BF: MOVWF 2A |
- |
|
284 |
.................... set_timer1(0); |
1121 |
.................... set_timer1(0); |
285 |
00C0: CLRF 0F |
- |
|
286 |
00C1: CLRF 0E |
- |
|
287 |
.................... output_high(CE); |
1122 |
.................... output_high(CE); |
288 |
00C2: BSF 03.5 |
- |
|
289 |
00C3: BCF 09.2 |
- |
|
290 |
00C4: BCF 03.5 |
- |
|
291 |
00C5: BSF 09.2 |
- |
|
292 |
.................... } |
1123 |
.................... }*/ |
293 |
.................... |
1124 |
.................... |
294 |
.................... |
1125 |
.................... |
295 |
00C6: BCF 0C.1 |
1126 |
02C9: BCF 0C.0 |
296 |
00C7: BCF 0A.3 |
1127 |
02CA: BCF 0A.3 |
297 |
00C8: BCF 0A.4 |
1128 |
02CB: BCF 0A.4 |
298 |
00C9: GOTO 023 |
1129 |
02CC: GOTO 027 |
299 |
.................... void main() |
1130 |
.................... void main() |
300 |
.................... { |
1131 |
.................... { |
301 |
* |
1132 |
* |
302 |
021C: CLRF 04 |
1133 |
0332: CLRF 04 |
303 |
021D: BCF 03.7 |
1134 |
0333: BCF 03.7 |
304 |
021E: MOVLW 1F |
1135 |
0334: MOVLW 1F |
305 |
021F: ANDWF 03,F |
1136 |
0335: ANDWF 03,F |
306 |
0220: BSF 03.5 |
1137 |
0336: BSF 03.5 |
307 |
0221: BSF 03.6 |
1138 |
0337: BSF 03.6 |
308 |
0222: BSF 07.3 |
1139 |
0338: BSF 07.3 |
309 |
0223: MOVLW 08 |
1140 |
0339: MOVLW 08 |
310 |
0224: BCF 03.6 |
1141 |
033A: BCF 03.6 |
311 |
0225: MOVWF 19 |
1142 |
033B: MOVWF 19 |
312 |
0226: MOVLW 02 |
1143 |
033C: MOVLW 02 |
313 |
0227: MOVWF 1A |
1144 |
033D: MOVWF 1A |
314 |
0228: MOVLW A6 |
1145 |
033E: MOVLW A6 |
315 |
0229: MOVWF 18 |
1146 |
033F: MOVWF 18 |
316 |
022A: MOVLW 90 |
1147 |
0340: MOVLW 90 |
317 |
022B: BCF 03.5 |
1148 |
0341: BCF 03.5 |
318 |
022C: MOVWF 18 |
1149 |
0342: MOVWF 18 |
319 |
022D: BSF 28.3 |
1150 |
0343: BSF 28.3 |
320 |
022E: MOVF 28,W |
1151 |
0344: MOVF 28,W |
321 |
022F: BSF 03.5 |
1152 |
0345: BSF 03.5 |
322 |
0230: MOVWF 07 |
1153 |
0346: MOVWF 07 |
323 |
0231: BCF 03.5 |
1154 |
0347: BCF 03.5 |
324 |
0232: BSF 28.4 |
1155 |
0348: BSF 28.4 |
325 |
0233: MOVF 28,W |
1156 |
0349: MOVF 28,W |
326 |
0234: BSF 03.5 |
1157 |
034A: BSF 03.5 |
327 |
0235: MOVWF 07 |
1158 |
034B: MOVWF 07 |
328 |
0236: MOVLW A0 |
1159 |
034C: MOVLW A0 |
329 |
0237: MOVWF 13 |
1160 |
034D: MOVWF 13 |
330 |
0238: MOVLW 36 |
1161 |
034E: MOVLW 36 |
331 |
0239: BCF 03.5 |
1162 |
034F: BCF 03.5 |
332 |
023A: MOVWF 14 |
1163 |
0350: MOVWF 14 |
- |
|
1164 |
0351: CLRF 41 |
- |
|
1165 |
0352: CLRF 40 |
333 |
023B: BSF 03.5 |
1166 |
0353: BSF 03.5 |
334 |
023C: BSF 03.6 |
1167 |
0354: BSF 03.6 |
335 |
023D: MOVF 09,W |
1168 |
0355: MOVF 09,W |
336 |
023E: ANDLW C0 |
1169 |
0356: ANDLW C0 |
337 |
023F: MOVWF 09 |
1170 |
0357: MOVWF 09 |
338 |
0240: BCF 03.6 |
1171 |
0358: BCF 03.6 |
339 |
0241: BCF 1F.4 |
1172 |
0359: BCF 1F.4 |
340 |
0242: BCF 1F.5 |
1173 |
035A: BCF 1F.5 |
341 |
0243: MOVLW 00 |
1174 |
035B: MOVLW 00 |
342 |
0244: BSF 03.6 |
1175 |
035C: BSF 03.6 |
343 |
0245: MOVWF 08 |
1176 |
035D: MOVWF 08 |
344 |
0246: BCF 03.5 |
1177 |
035E: BCF 03.5 |
345 |
0247: CLRF 07 |
1178 |
035F: CLRF 07 |
346 |
0248: CLRF 08 |
1179 |
0360: CLRF 08 |
347 |
0249: CLRF 09 |
1180 |
0361: CLRF 09 |
348 |
.................... setup_adc_ports(NO_ANALOGS|VSS_VDD); |
1181 |
.................... setup_adc_ports(NO_ANALOGS|VSS_VDD); |
349 |
* |
1182 |
* |
350 |
0250: BSF 03.5 |
1183 |
036C: BSF 03.5 |
351 |
0251: BSF 03.6 |
1184 |
036D: BSF 03.6 |
352 |
0252: MOVF 09,W |
1185 |
036E: MOVF 09,W |
353 |
0253: ANDLW C0 |
1186 |
036F: ANDLW C0 |
354 |
0254: MOVWF 09 |
1187 |
0370: MOVWF 09 |
355 |
0255: BCF 03.6 |
1188 |
0371: BCF 03.6 |
356 |
0256: BCF 1F.4 |
1189 |
0372: BCF 1F.4 |
357 |
0257: BCF 1F.5 |
1190 |
0373: BCF 1F.5 |
358 |
0258: MOVLW 00 |
1191 |
0374: MOVLW 00 |
359 |
0259: BSF 03.6 |
1192 |
0375: BSF 03.6 |
360 |
025A: MOVWF 08 |
1193 |
0376: MOVWF 08 |
361 |
.................... setup_adc(ADC_OFF); |
1194 |
.................... setup_adc(ADC_OFF); |
362 |
025B: BCF 03.5 |
1195 |
0377: BCF 03.5 |
363 |
025C: BCF 03.6 |
1196 |
0378: BCF 03.6 |
364 |
025D: BCF 1F.0 |
1197 |
0379: BCF 1F.0 |
365 |
.................... // setup_spi(SPI_SS_DISABLED); |
1198 |
.................... setup_spi(SPI_SS_DISABLED); |
- |
|
1199 |
037A: BCF 14.5 |
- |
|
1200 |
037B: BCF 28.5 |
- |
|
1201 |
037C: MOVF 28,W |
- |
|
1202 |
037D: BSF 03.5 |
- |
|
1203 |
037E: MOVWF 07 |
- |
|
1204 |
037F: BCF 03.5 |
- |
|
1205 |
0380: BSF 28.4 |
- |
|
1206 |
0381: MOVF 28,W |
- |
|
1207 |
0382: BSF 03.5 |
- |
|
1208 |
0383: MOVWF 07 |
- |
|
1209 |
0384: BCF 03.5 |
- |
|
1210 |
0385: BCF 28.3 |
- |
|
1211 |
0386: MOVF 28,W |
- |
|
1212 |
0387: BSF 03.5 |
- |
|
1213 |
0388: MOVWF 07 |
- |
|
1214 |
0389: MOVLW 01 |
- |
|
1215 |
038A: BCF 03.5 |
- |
|
1216 |
038B: MOVWF 14 |
- |
|
1217 |
038C: MOVLW 00 |
- |
|
1218 |
038D: BSF 03.5 |
- |
|
1219 |
038E: MOVWF 14 |
366 |
.................... setup_timer_0(RTCC_INTERNAL|RTCC_DIV_1); |
1220 |
.................... setup_timer_0(RTCC_INTERNAL|RTCC_DIV_1); |
367 |
025E: BSF 03.5 |
- |
|
368 |
025F: MOVF 01,W |
1221 |
038F: MOVF 01,W |
369 |
0260: ANDLW C7 |
1222 |
0390: ANDLW C7 |
370 |
0261: IORLW 08 |
1223 |
0391: IORLW 08 |
371 |
0262: MOVWF 01 |
1224 |
0392: MOVWF 01 |
372 |
.................... // setup_wdt(WDT_144MS); |
1225 |
.................... // setup_wdt(WDT_144MS); |
373 |
.................... setup_timer_1(T1_EXTERNAL|T1_DIV_BY_1); |
1226 |
.................... setup_timer_1(T1_EXTERNAL|T1_DIV_BY_1); |
374 |
0263: MOVLW 07 |
1227 |
0393: MOVLW 07 |
375 |
0264: BCF 03.5 |
1228 |
0394: BCF 03.5 |
376 |
0265: MOVWF 10 |
1229 |
0395: MOVWF 10 |
377 |
.................... setup_timer_2(T2_DIV_BY_16,196,16); |
1230 |
.................... setup_timer_2(T2_DIV_BY_16,196,16); |
378 |
0266: MOVLW 78 |
1231 |
0396: MOVLW 78 |
379 |
0267: MOVWF 78 |
1232 |
0397: MOVWF 78 |
380 |
0268: IORLW 06 |
1233 |
0398: IORLW 06 |
381 |
0269: MOVWF 12 |
1234 |
0399: MOVWF 12 |
382 |
026A: MOVLW C4 |
1235 |
039A: MOVLW C4 |
383 |
026B: BSF 03.5 |
1236 |
039B: BSF 03.5 |
384 |
026C: MOVWF 12 |
1237 |
039C: MOVWF 12 |
385 |
.................... setup_ccp1(CCP_OFF); |
1238 |
.................... setup_ccp1(CCP_OFF); |
386 |
026D: BCF 03.5 |
1239 |
039D: BCF 03.5 |
387 |
026E: BSF 28.2 |
1240 |
039E: BSF 28.2 |
388 |
026F: MOVF 28,W |
1241 |
039F: MOVF 28,W |
389 |
0270: BSF 03.5 |
1242 |
03A0: BSF 03.5 |
390 |
0271: MOVWF 07 |
1243 |
03A1: MOVWF 07 |
391 |
0272: BCF 03.5 |
1244 |
03A2: BCF 03.5 |
392 |
0273: CLRF 17 |
1245 |
03A3: CLRF 17 |
393 |
0274: BSF 03.5 |
1246 |
03A4: BSF 03.5 |
394 |
0275: CLRF 1B |
1247 |
03A5: CLRF 1B |
395 |
0276: CLRF 1C |
1248 |
03A6: CLRF 1C |
396 |
0277: MOVLW 01 |
1249 |
03A7: MOVLW 01 |
397 |
0278: MOVWF 1D |
1250 |
03A8: MOVWF 1D |
398 |
.................... setup_comparator(NC_NC_NC_NC); |
1251 |
.................... setup_comparator(NC_NC_NC_NC); |
399 |
0279: BCF 03.5 |
1252 |
03A9: BCF 03.5 |
400 |
027A: BSF 03.6 |
1253 |
03AA: BSF 03.6 |
401 |
027B: CLRF 07 |
1254 |
03AB: CLRF 07 |
402 |
027C: CLRF 08 |
1255 |
03AC: CLRF 08 |
403 |
027D: CLRF 09 |
1256 |
03AD: CLRF 09 |
404 |
.................... setup_vref(FALSE); |
1257 |
.................... setup_vref(FALSE); |
405 |
027E: BSF 03.5 |
1258 |
03AE: BSF 03.5 |
406 |
027F: BCF 03.6 |
1259 |
03AF: BCF 03.6 |
407 |
0280: CLRF 17 |
1260 |
03B0: CLRF 17 |
408 |
.................... |
1261 |
.................... |
409 |
.................... delay_ms(1000); |
1262 |
.................... delay_ms(1000); |
410 |
0281: MOVLW 04 |
1263 |
03B1: MOVLW 04 |
411 |
0282: BCF 03.5 |
1264 |
03B2: BCF 03.5 |
412 |
0283: MOVWF 5E |
1265 |
03B3: MOVWF 46 |
413 |
0284: MOVLW FA |
1266 |
03B4: MOVLW FA |
414 |
0285: MOVWF 5F |
1267 |
03B5: MOVWF 47 |
415 |
0286: CALL 0DC |
1268 |
03B6: GOTO 2D2 |
416 |
0287: DECFSZ 5E,F |
1269 |
03B7: DECFSZ 46,F |
417 |
0288: GOTO 284 |
1270 |
03B8: GOTO 3B4 |
418 |
.................... int n; |
1271 |
.................... int n; |
419 |
.................... for (n=0;n<40;n++) |
1272 |
.................... for (n=0;n<40;n++) putc(cmd[n]); // setup GPS |
420 |
0289: CLRF 5D |
1273 |
03B9: CLRF 45 |
421 |
028A: MOVF 5D,W |
1274 |
03BA: MOVF 45,W |
422 |
028B: SUBLW 27 |
1275 |
03BB: SUBLW 27 |
423 |
028C: BTFSS 03.0 |
1276 |
03BC: BTFSS 03.0 |
424 |
028D: GOTO 295 |
1277 |
03BD: GOTO 3C5 |
425 |
.................... { |
- |
|
426 |
.................... putc(cmd[n]); |
- |
|
427 |
028E: MOVF 5D,W |
1278 |
03BE: MOVF 45,W |
428 |
028F: CALL 03A |
1279 |
03BF: CALL 041 |
429 |
0290: BTFSS 0C.4 |
1280 |
03C0: BTFSS 0C.4 |
430 |
0291: GOTO 290 |
1281 |
03C1: GOTO 3C0 |
431 |
0292: MOVWF 19 |
1282 |
03C2: MOVWF 19 |
432 |
.................... } |
- |
|
433 |
0293: INCF 5D,F |
1283 |
03C3: INCF 45,F |
434 |
0294: GOTO 28A |
1284 |
03C4: GOTO 3BA |
435 |
.................... |
1285 |
.................... |
436 |
.................... printf("cvak...\r\n"); |
1286 |
.................... printf("cvak...\r\n"); |
437 |
0295: MOVLW CA |
1287 |
03C5: MOVLW CD |
438 |
0296: BSF 03.6 |
1288 |
03C6: BSF 03.6 |
439 |
0297: MOVWF 0D |
1289 |
03C7: MOVWF 0D |
440 |
0298: MOVLW 00 |
1290 |
03C8: MOVLW 02 |
441 |
0299: MOVWF 0F |
1291 |
03C9: MOVWF 0F |
442 |
029A: BCF 03.6 |
1292 |
03CA: BCF 03.6 |
443 |
029B: GOTO 0F0 |
1293 |
03CB: GOTO 2E8 |
444 |
.................... snd_buf[2]=0x55; |
- |
|
445 |
029C: MOVLW 55 |
- |
|
446 |
029D: MOVWF 3D |
- |
|
447 |
.................... snd_buf[3]=0xAA; |
- |
|
448 |
029E: MOVLW AA |
- |
|
449 |
029F: MOVWF 3E |
- |
|
450 |
.................... |
1294 |
.................... |
- |
|
1295 |
.................... ext_int_edge( L_TO_H ); // set 1PPS active edge |
- |
|
1296 |
03CC: BSF 03.5 |
- |
|
1297 |
03CD: BSF 01.6 |
- |
|
1298 |
.................... enable_interrupts(INT_TIMER1); |
- |
|
1299 |
03CE: BSF 0C.0 |
451 |
.................... set_timer1(0); |
1300 |
.................... enable_interrupts(INT_EXT); |
452 |
02A0: CLRF 0F |
1301 |
03CF: BCF 03.5 |
453 |
02A1: CLRF 0E |
1302 |
03D0: BSF 0B.4 |
454 |
.................... enable_interrupts(INT_SSP); |
1303 |
.................... enable_interrupts(INT_SSP); |
455 |
02A2: BSF 03.5 |
1304 |
03D1: BSF 03.5 |
456 |
02A3: BSF 0C.3 |
1305 |
03D2: BSF 0C.3 |
457 |
.................... // enable_interrupts(INT_TIMER2); |
1306 |
.................... // enable_interrupts(INT_TIMER2); |
458 |
.................... enable_interrupts(GLOBAL); |
1307 |
.................... enable_interrupts(GLOBAL); |
459 |
02A4: MOVLW C0 |
1308 |
03D3: MOVLW C0 |
460 |
02A5: BCF 03.5 |
1309 |
03D4: BCF 03.5 |
461 |
02A6: IORWF 0B,F |
1310 |
03D5: IORWF 0B,F |
462 |
.................... |
1311 |
.................... |
463 |
.................... while(true) |
1312 |
.................... while(true) |
464 |
.................... { |
- |
|
465 |
.................... |
1313 |
.................... { |
466 |
.................... output_high(LED); |
1314 |
.................... /* output_high(LED); |
467 |
02A7: BSF 03.5 |
- |
|
468 |
02A8: BCF 09.1 |
- |
|
469 |
02A9: BCF 03.5 |
- |
|
470 |
02AA: BSF 09.1 |
- |
|
471 |
.................... output_low(LED); |
- |
|
472 |
02AB: BSF 03.5 |
- |
|
473 |
02AC: BCF 09.1 |
- |
|
474 |
02AD: BCF 03.5 |
- |
|
475 |
02AE: BCF 09.1 |
- |
|
476 |
.................... set_timer1(0); |
1315 |
.................... delay_ms(999); |
477 |
02AF: CLRF 0F |
- |
|
478 |
02B0: CLRF 0E |
- |
|
479 |
.................... output_high(CE); |
1316 |
.................... output_low(LED); |
480 |
02B1: BSF 03.5 |
- |
|
481 |
02B2: BCF 09.2 |
- |
|
482 |
02B3: BCF 03.5 |
- |
|
483 |
02B4: BSF 09.2 |
- |
|
484 |
.................... delay_ms(999); |
1317 |
.................... delay_ms(999); |
485 |
02B5: MOVLW 09 |
- |
|
486 |
02B6: MOVWF 5E |
- |
|
487 |
02B7: MOVLW 6F |
- |
|
488 |
02B8: MOVWF 5F |
- |
|
489 |
02B9: CALL 0DC |
- |
|
490 |
02BA: DECFSZ 5E,F |
- |
|
491 |
02BB: GOTO 2B7 |
- |
|
492 |
.................... delay_us(966); |
- |
|
493 |
02BC: MOVLW 06 |
- |
|
494 |
02BD: MOVWF 5E |
- |
|
495 |
02BE: MOVLW A0 |
- |
|
496 |
02BF: MOVWF 5F |
- |
|
497 |
02C0: GOTO 13A |
- |
|
498 |
02C1: DECFSZ 5E,F |
- |
|
499 |
02C2: GOTO 2BE |
- |
|
500 |
.................... output_low(CE); |
- |
|
501 |
02C3: BSF 03.5 |
- |
|
502 |
02C4: BCF 09.2 |
- |
|
503 |
02C5: BCF 03.5 |
- |
|
504 |
02C6: BCF 09.2 |
- |
|
505 |
.................... count=get_timer1(); |
1318 |
.................... printf("%X %X %X %X\r\n", buffer[0],buffer[1],buffer[2],buffer[3]); |
506 |
02C7: MOVF 0F,W |
- |
|
507 |
02C8: MOVWF 7A |
- |
|
508 |
02C9: MOVF 0E,W |
- |
|
509 |
02CA: MOVWF 77 |
- |
|
510 |
02CB: MOVF 0F,W |
- |
|
511 |
02CC: SUBWF 7A,W |
- |
|
512 |
02CD: BTFSS 03.2 |
- |
|
513 |
02CE: GOTO 2C7 |
- |
|
514 |
02CF: MOVF 77,W |
- |
|
515 |
02D0: MOVWF 29 |
- |
|
516 |
02D1: MOVF 7A,W |
- |
|
517 |
02D2: MOVWF 2A |
- |
|
518 |
.................... |
1319 |
.................... */ |
519 |
.................... printf("count: %Lu %X %X %X %X\r\n",count, buffer[0],buffer[1],buffer[2],buffer[3]); |
- |
|
520 |
02D3: MOVLW CF |
- |
|
521 |
02D4: BSF 03.6 |
- |
|
522 |
02D5: MOVWF 0D |
- |
|
523 |
02D6: MOVLW 00 |
- |
|
524 |
02D7: MOVWF 0F |
- |
|
525 |
02D8: BCF 03.0 |
- |
|
526 |
02D9: MOVLW 07 |
- |
|
527 |
02DA: BCF 03.6 |
- |
|
528 |
02DB: MOVWF 5E |
- |
|
529 |
02DC: GOTO 14B |
- |
|
530 |
02DD: MOVLW 10 |
- |
|
531 |
02DE: MOVWF 04 |
- |
|
532 |
02DF: MOVF 2A,W |
- |
|
533 |
02E0: MOVWF 5F |
- |
|
534 |
02E1: MOVF 29,W |
- |
|
535 |
02E2: MOVWF 5E |
- |
|
536 |
02E3: GOTO 19E |
- |
|
537 |
02E4: MOVLW 20 |
- |
|
538 |
02E5: BTFSS 0C.4 |
- |
|
539 |
02E6: GOTO 2E5 |
- |
|
540 |
02E7: MOVWF 19 |
- |
|
541 |
02E8: MOVF 4B,W |
- |
|
542 |
02E9: MOVWF 5E |
- |
|
543 |
02EA: MOVLW 37 |
- |
|
544 |
02EB: MOVWF 5F |
- |
|
545 |
02EC: CALL 1F9 |
- |
|
546 |
02ED: MOVLW 20 |
- |
|
547 |
02EE: BTFSS 0C.4 |
- |
|
548 |
02EF: GOTO 2EE |
- |
|
549 |
02F0: MOVWF 19 |
- |
|
550 |
02F1: MOVF 4C,W |
- |
|
551 |
02F2: MOVWF 5E |
- |
|
552 |
02F3: MOVLW 37 |
- |
|
553 |
02F4: MOVWF 5F |
- |
|
554 |
02F5: CALL 1F9 |
- |
|
555 |
02F6: MOVLW 20 |
- |
|
556 |
02F7: BTFSS 0C.4 |
- |
|
557 |
02F8: GOTO 2F7 |
- |
|
558 |
02F9: MOVWF 19 |
- |
|
559 |
02FA: MOVF 4D,W |
- |
|
560 |
02FB: MOVWF 5E |
- |
|
561 |
02FC: MOVLW 37 |
- |
|
562 |
02FD: MOVWF 5F |
- |
|
563 |
02FE: CALL 1F9 |
- |
|
564 |
02FF: MOVLW 20 |
- |
|
565 |
0300: BTFSS 0C.4 |
- |
|
566 |
0301: GOTO 300 |
- |
|
567 |
0302: MOVWF 19 |
- |
|
568 |
0303: MOVF 4E,W |
- |
|
569 |
0304: MOVWF 5E |
- |
|
570 |
0305: MOVLW 37 |
- |
|
571 |
0306: MOVWF 5F |
- |
|
572 |
0307: CALL 1F9 |
- |
|
573 |
0308: MOVLW 0D |
- |
|
574 |
0309: BTFSS 0C.4 |
- |
|
575 |
030A: GOTO 309 |
- |
|
576 |
030B: MOVWF 19 |
- |
|
577 |
030C: MOVLW 0A |
- |
|
578 |
030D: BTFSS 0C.4 |
- |
|
579 |
030E: GOTO 30D |
- |
|
580 |
030F: MOVWF 19 |
- |
|
581 |
.................... } |
1320 |
.................... } |
582 |
0310: GOTO 2A7 |
1321 |
03D6: GOTO 3D6 |
583 |
.................... } |
1322 |
.................... } |
584 |
0311: SLEEP |
1323 |
03D7: SLEEP |
585 |
|
1324 |
|
586 |
Configuration Fuses: |
1325 |
Configuration Fuses: |
587 |
Word 1: 2CF2 HS NOWDT NOPUT MCLR NOPROTECT NOCPD NOBROWNOUT IESO FCMEN NOLVP NODEBUG |
1326 |
Word 1: 2CF2 HS NOWDT NOPUT MCLR NOPROTECT NOCPD NOBROWNOUT IESO FCMEN NOLVP NODEBUG |
588 |
Word 2: 3FFF NOWRT BORV40 |
1327 |
Word 2: 3FFF NOWRT BORV40 |