Subversion Repositories FlightCtrl

Rev

Go to most recent revision | Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
2285 - 1
   1               		.file	"led.c"
2
   2               		.arch atmega1284p
3
   3               	__SREG__ = 0x3f
4
   4               	__SP_H__ = 0x3e
5
   5               	__SP_L__ = 0x3d
6
   6               	__tmp_reg__ = 0
7
   7               	__zero_reg__ = 1
8
   8               		.global __do_copy_data
9
   9               		.global __do_clear_bss
10
  10               	.global	J17Mask
11
  11               		.data
12
  14               	J17Mask:
13
  15 0000 01        		.byte	1
14
  16               	.global	J17Blinkcount
15
  17               	.global	J17Blinkcount
16
  18               		.section .bss
17
  21               	J17Blinkcount:
18
  22 0000 00        		.skip 1,0
19
  23               	.global	J16Mask
20
  24               		.data
21
  27               	J16Mask:
22
  28 0001 01        		.byte	1
23
  29               	.global	J16Blinkcount
24
  30               	.global	J16Blinkcount
25
  31               		.section .bss
26
  34               	J16Blinkcount:
27
  35 0001 00        		.skip 1,0
28
  36               	.global	LED2_Timing
29
  37               	.global	LED2_Timing
30
  40               	LED2_Timing:
31
  41 0002 0000      		.skip 2,0
32
  42               	.global	LED1_Timing
33
  43               	.global	LED1_Timing
34
  46               	LED1_Timing:
35
  47 0004 0000      		.skip 2,0
36
  48               		.text
37
  49               	.global	LED_Init
38
  51               	LED_Init:
39
  52               	/* prologue: frame size=0 */
40
  53               	/* prologue end (size=0) */
41
  54 0000 87B1      		in r24,39-0x20
42
  55 0002 8C60      		ori r24,lo8(12)
43
  56 0004 87B9      		out 39-0x20,r24
44
  57 0006 4298      		cbi 40-0x20,2
45
  58 0008 4398      		cbi 40-0x20,3
46
  59 000a 1092 0000 		sts J16Blinkcount,__zero_reg__
47
  60 000e 80E8      		ldi r24,lo8(-128)
48
  61 0010 8093 0000 		sts J16Mask,r24
49
  62 0014 1092 0000 		sts J17Blinkcount,__zero_reg__
50
  63 0018 8093 0000 		sts J17Mask,r24
51
  64               	/* epilogue: frame size=0 */
52
  65 001c 0895      		ret
53
  66               	/* epilogue end (size=1) */
54
  67               	/* function LED_Init size 15 (14) */
55
  69               		.lcomm delay.0,1
56
  70               		.lcomm J16Bitmask.1,1
57
  71               		.lcomm J17Bitmask.2,1
58
  72               		.lcomm J16Warn.3,1
59
  73               		.lcomm J17Warn.4,1
60
  74               		.lcomm from_nc.5,1
61
  75               	.global	LED_Update
62
  77               	LED_Update:
63
  78               	/* prologue: frame size=0 */
64
  79               	/* prologue end (size=0) */
65
  80 001e 8091 0000 		lds r24,delay.0
66
  81 0022 8150      		subi r24,lo8(-(-1))
67
  82 0024 8093 0000 		sts delay.0,r24
68
  83 0028 8F3F      		cpi r24,lo8(-1)
69
  84 002a 01F0      		breq .+2
70
  85 002c 00C0      		rjmp .L2
71
  86 002e 89E0      		ldi r24,lo8(9)
72
  87 0030 8093 0000 		sts delay.0,r24
73
  88 0034 8091 0000 		lds r24,PPM_in+50
74
  89 0038 9091 0000 		lds r25,(PPM_in+50)+1
75
  90 003c 8158      		subi r24,lo8(-127)
76
  91 003e 9F4F      		sbci r25,hi8(-127)
77
  92 0040 01F0      		breq .L4
78
  93 0042 8091 0000 		lds r24,PPM_in+50
79
  94 0046 9091 0000 		lds r25,(PPM_in+50)+1
80
  95 004a 8158      		subi r24,lo8(-(127))
81
  96 004c 8093 0000 		sts from_nc.5,r24
82
  97               	.L4:
83
  98 0050 8091 0000 		lds r24,FC_StatusFlags
84
  99 0054 9927      		clr r25
85
 100 0056 8073      		andi r24,lo8(48)
86
 101 0058 9070      		andi r25,hi8(48)
87
 102 005a 892B      		or r24,r25
88
 103 005c 01F4      		brne .L6
89
 104 005e 8091 0000 		lds r24,VersionInfo+6
90
 105 0062 80FF      		sbrs r24,0
91
 106 0064 00C0      		rjmp .L5
92
 107               	.L6:
93
 108 0066 8091 0000 		lds r24,EE_Parameter+78
94
 109 006a 8823      		tst r24
95
 110 006c 01F0      		breq .L7
96
 111 006e 8091 0000 		lds r24,J16Warn.3
97
 112 0072 8823      		tst r24
98
 113 0074 01F4      		brne .L8
99
 114 0076 84E0      		ldi r24,lo8(4)
100
 115 0078 8093 0000 		sts J16Blinkcount,r24
101
 116               	.L8:
102
 117 007c 81E0      		ldi r24,lo8(1)
103
 118 007e 8093 0000 		sts J16Warn.3,r24
104
 119               	.L7:
105
 120 0082 8091 0000 		lds r24,EE_Parameter+79
106
 121 0086 8823      		tst r24
107
 122 0088 01F0      		breq .L11
108
 123 008a 8091 0000 		lds r24,J17Warn.4
109
 124 008e 8823      		tst r24
110
 125 0090 01F4      		brne .L10
111
 126 0092 84E0      		ldi r24,lo8(4)
112
 127 0094 8093 0000 		sts J17Blinkcount,r24
113
 128               	.L10:
114
 129 0098 81E0      		ldi r24,lo8(1)
115
 130 009a 8093 0000 		sts J17Warn.4,r24
116
 131 009e 00C0      		rjmp .L11
117
 132               	.L5:
118
 133 00a0 1092 0000 		sts J16Warn.3,__zero_reg__
119
 134 00a4 1092 0000 		sts J17Warn.4,__zero_reg__
120
 135 00a8 8091 0000 		lds r24,EE_Parameter+74
121
 136 00ac 8093 0000 		sts J16Bitmask.1,r24
122
 137 00b0 8091 0000 		lds r24,EE_Parameter+76
123
 138 00b4 8093 0000 		sts J17Bitmask.2,r24
124
 139               	.L11:
125
 140 00b8 8091 0000 		lds r24,J16Warn.3
126
 141 00bc 8823      		tst r24
127
 142 00be 01F0      		breq .+2
128
 143 00c0 00C0      		rjmp .L12
129
 144 00c2 8091 0000 		lds r24,EE_Parameter+108
130
 145 00c6 282F      		mov r18,r24
131
 146 00c8 3327      		clr r19
132
 147 00ca 24FF      		sbrs r18,4
133
 148 00cc 00C0      		rjmp .L13
134
 149 00ce 8091 0000 		lds r24,MotorenEin
135
 150 00d2 8823      		tst r24
136
 151 00d4 01F4      		brne .L13
137
 152 00d6 25FD      		sbrc r18,5
138
 153 00d8 00C0      		rjmp .L78
139
 154 00da 00C0      		rjmp .L46
140
 155               	.L13:
141
 156 00dc 9091 0000 		lds r25,EE_Parameter+75
142
 157 00e0 983F      		cpi r25,lo8(-8)
143
 158 00e2 00F0      		brlo .L17
144
 159 00e4 8091 0000 		lds r24,Parameter_J16Timing
145
 160 00e8 8D3D      		cpi r24,lo8(-35)
146
 161 00ea 00F0      		brlo .L17
147
 162 00ec 8091 0000 		lds r24,J16Bitmask.1
148
 163 00f0 8823      		tst r24
149
 164 00f2 04F0      		brlt .L22
150
 165 00f4 00C0      		rjmp .L87
151
 166               	.L17:
152
 167 00f6 983F      		cpi r25,lo8(-8)
153
 168 00f8 00F0      		brlo .L21
154
 169 00fa 8091 0000 		lds r24,Parameter_J16Timing
155
 170 00fe 8530      		cpi r24,lo8(5)
156
 171 0100 01F4      		brne .L21
157
 172 0102 8091 0000 		lds r24,J16Bitmask.1
158
 173 0106 87FF      		sbrs r24,7
159
 174 0108 00C0      		rjmp .L22
160
 175               	.L87:
161
 176 010a 4298      		cbi 40-0x20,2
162
 177 010c 00C0      		rjmp .L23
163
 178               	.L22:
164
 179 010e 429A      		sbi 40-0x20,2
165
 180               	.L23:
166
 181 0110 81E0      		ldi r24,lo8(1)
167
 182 0112 00C0      		rjmp .L79
168
 183               	.L21:
169
 184 0114 8091 0000 		lds r24,J16Blinkcount
170
 185 0118 8150      		subi r24,lo8(-(-1))
171
 186 011a 8093 0000 		sts J16Blinkcount,r24
172
 187 011e 8F3F      		cpi r24,lo8(-1)
173
 188 0120 01F0      		breq .+2
174
 189 0122 00C0      		rjmp .L42
175
 190 0124 8091 0000 		lds r24,EE_Parameter+111
176
 191 0128 85FF      		sbrs r24,5
177
 192 012a 00C0      		rjmp .L26
178
 193 012c 9091 0000 		lds r25,from_nc.5
179
 194 0130 892F      		mov r24,r25
180
 195 0132 8695      		lsr r24
181
 196 0134 8093 0000 		sts J16Blinkcount,r24
182
 197 0138 9923      		tst r25
183
 198 013a 01F4      		brne .L27
184
 199 013c 8091 0000 		lds r24,J16Bitmask.1
185
 200 0140 87FF      		sbrs r24,7
186
 201 0142 00C0      		rjmp .L28
187
 202 0144 4298      		cbi 40-0x20,2
188
 203 0146 00C0      		rjmp .L29
189
 204               	.L28:
190
 205 0148 429A      		sbi 40-0x20,2
191
 206               	.L29:
192
 207 014a 1092 0000 		sts J16Mask,__zero_reg__
193
 208 014e 00C0      		rjmp .L42
194
 209               	.L27:
195
 210 0150 8091 0000 		lds r24,J16Mask
196
 211 0154 9091 0000 		lds r25,J16Bitmask.1
197
 212 0158 8823      		tst r24
198
 213 015a 01F4      		brne .L31
199
 214 015c 8093 0000 		sts from_nc.5,r24
200
 215 0160 80E8      		ldi r24,lo8(-128)
201
 216 0162 8093 0000 		sts J16Mask,r24
202
 217 0166 9923      		tst r25
203
 218 0168 04F0      		brlt .L46
204
 219 016a 00C0      		rjmp .L78
205
 220               	.L31:
206
 221 016c 9823      		and r25,r24
207
 222 016e 01F0      		breq .L35
208
 223 0170 429A      		sbi 40-0x20,2
209
 224 0172 00C0      		rjmp .L36
210
 225               	.L35:
211
 226 0174 4298      		cbi 40-0x20,2
212
 227               	.L36:
213
 228 0176 8695      		lsr r24
214
 229               	.L79:
215
 230 0178 8093 0000 		sts J16Mask,r24
216
 231 017c 00C0      		rjmp .L42
217
 232               	.L26:
218
 233 017e 8091 0000 		lds r24,Parameter_J16Timing
219
 234 0182 8695      		lsr r24
220
 235 0184 8093 0000 		sts J16Blinkcount,r24
221
 236 0188 8091 0000 		lds r24,J16Mask
222
 237 018c 8130      		cpi r24,lo8(1)
223
 238 018e 01F4      		brne .L38
224
 239 0190 1092 0000 		sts from_nc.5,__zero_reg__
225
 240 0194 80E8      		ldi r24,lo8(-128)
226
 241 0196 00C0      		rjmp .L76
227
 242               	.L38:
228
 243 0198 8695      		lsr r24
229
 244               	.L76:
230
 245 019a 8093 0000 		sts J16Mask,r24
231
 246 019e 8091 0000 		lds r24,J16Mask
232
 247 01a2 9091 0000 		lds r25,J16Bitmask.1
233
 248 01a6 00C0      		rjmp .L84
234
 249               	.L12:
235
 250 01a8 8091 0000 		lds r24,J16Blinkcount
236
 251 01ac 8150      		subi r24,lo8(-(-1))
237
 252 01ae 8093 0000 		sts J16Blinkcount,r24
238
 253 01b2 8F3F      		cpi r24,lo8(-1)
239
 254 01b4 01F4      		brne .L42
240
 255 01b6 89E0      		ldi r24,lo8(9)
241
 256 01b8 8093 0000 		sts J16Blinkcount,r24
242
 257 01bc 8091 0000 		lds r24,J16Mask
243
 258 01c0 8130      		cpi r24,lo8(1)
244
 259 01c2 01F4      		brne .L44
245
 260 01c4 80E8      		ldi r24,lo8(-128)
246
 261 01c6 00C0      		rjmp .L77
247
 262               	.L44:
248
 263 01c8 8695      		lsr r24
249
 264               	.L77:
250
 265 01ca 8093 0000 		sts J16Mask,r24
251
 266 01ce 8091 0000 		lds r24,J16Mask
252
 267 01d2 9091 0000 		lds r25,EE_Parameter+78
253
 268               	.L84:
254
 269 01d6 8923      		and r24,r25
255
 270 01d8 01F0      		breq .L46
256
 271               	.L78:
257
 272 01da 429A      		sbi 40-0x20,2
258
 273 01dc 00C0      		rjmp .L42
259
 274               	.L46:
260
 275 01de 4298      		cbi 40-0x20,2
261
 276               	.L42:
262
 277 01e0 8091 0000 		lds r24,J17Warn.4
263
 278 01e4 8823      		tst r24
264
 279 01e6 01F0      		breq .+2
265
 280 01e8 00C0      		rjmp .L48
266
 281 01ea 9091 0000 		lds r25,EE_Parameter+108
267
 282 01ee 97FF      		sbrs r25,7
268
 283 01f0 00C0      		rjmp .L49
269
 284 01f2 8091 0000 		lds r24,MotorenEin
270
 285 01f6 8823      		tst r24
271
 286 01f8 01F4      		brne .L49
272
 287 01fa 96FD      		sbrc r25,6
273
 288 01fc 00C0      		rjmp .L82
274
 289 01fe 00C0      		rjmp .L70
275
 290               	.L49:
276
 291 0200 9091 0000 		lds r25,EE_Parameter+77
277
 292 0204 983F      		cpi r25,lo8(-8)
278
 293 0206 00F0      		brlo .L53
279
 294 0208 8091 0000 		lds r24,Parameter_J17Timing
280
 295 020c 8D3D      		cpi r24,lo8(-35)
281
 296 020e 00F0      		brlo .L53
282
 297 0210 8091 0000 		lds r24,J17Bitmask.2
283
 298 0214 8823      		tst r24
284
 299 0216 04F0      		brlt .L58
285
 300 0218 00C0      		rjmp .L85
286
 301               	.L53:
287
 302 021a 983F      		cpi r25,lo8(-8)
288
 303 021c 00F0      		brlo .L57
289
 304 021e 8091 0000 		lds r24,Parameter_J17Timing
290
 305 0222 8530      		cpi r24,lo8(5)
291
 306 0224 01F4      		brne .L57
292
 307 0226 8091 0000 		lds r24,J17Bitmask.2
293
 308 022a 87FF      		sbrs r24,7
294
 309 022c 00C0      		rjmp .L58
295
 310               	.L85:
296
 311 022e 4398      		cbi 40-0x20,3
297
 312 0230 00C0      		rjmp .L59
298
 313               	.L58:
299
 314 0232 439A      		sbi 40-0x20,3
300
 315               	.L59:
301
 316 0234 81E0      		ldi r24,lo8(1)
302
 317 0236 8093 0000 		sts J17Mask,r24
303
 318 023a 00C0      		rjmp .L66
304
 319               	.L57:
305
 320 023c 8091 0000 		lds r24,J17Blinkcount
306
 321 0240 8150      		subi r24,lo8(-(-1))
307
 322 0242 8093 0000 		sts J17Blinkcount,r24
308
 323 0246 8F3F      		cpi r24,lo8(-1)
309
 324 0248 01F4      		brne .L66
310
 325 024a 8091 0000 		lds r24,Parameter_J17Timing
311
 326 024e 8695      		lsr r24
312
 327 0250 8093 0000 		sts J17Blinkcount,r24
313
 328 0254 8091 0000 		lds r24,J17Mask
314
 329 0258 8130      		cpi r24,lo8(1)
315
 330 025a 01F4      		brne .L62
316
 331 025c 80E8      		ldi r24,lo8(-128)
317
 332 025e 00C0      		rjmp .L80
318
 333               	.L62:
319
 334 0260 8695      		lsr r24
320
 335               	.L80:
321
 336 0262 8093 0000 		sts J17Mask,r24
322
 337 0266 8091 0000 		lds r24,J17Mask
323
 338 026a 9091 0000 		lds r25,J17Bitmask.2
324
 339 026e 00C0      		rjmp .L86
325
 340               	.L48:
326
 341 0270 8091 0000 		lds r24,J17Blinkcount
327
 342 0274 8150      		subi r24,lo8(-(-1))
328
 343 0276 8093 0000 		sts J17Blinkcount,r24
329
 344 027a 8F3F      		cpi r24,lo8(-1)
330
 345 027c 01F4      		brne .L66
331
 346 027e 89E0      		ldi r24,lo8(9)
332
 347 0280 8093 0000 		sts J17Blinkcount,r24
333
 348 0284 8091 0000 		lds r24,J17Mask
334
 349 0288 8130      		cpi r24,lo8(1)
335
 350 028a 01F4      		brne .L68
336
 351 028c 80E8      		ldi r24,lo8(-128)
337
 352 028e 00C0      		rjmp .L81
338
 353               	.L68:
339
 354 0290 8695      		lsr r24
340
 355               	.L81:
341
 356 0292 8093 0000 		sts J17Mask,r24
342
 357 0296 8091 0000 		lds r24,J17Mask
343
 358 029a 9091 0000 		lds r25,EE_Parameter+79
344
 359               	.L86:
345
 360 029e 8923      		and r24,r25
346
 361 02a0 01F0      		breq .L70
347
 362               	.L82:
348
 363 02a2 439A      		sbi 40-0x20,3
349
 364 02a4 00C0      		rjmp .L66
350
 365               	.L70:
351
 366 02a6 4398      		cbi 40-0x20,3
352
 367               	.L66:
353
 368 02a8 429B      		sbis 40-0x20,2
354
 369 02aa 00C0      		rjmp .L72
355
 370 02ac 8091 0000 		lds r24,FC_StatusFlags2
356
 371 02b0 8860      		ori r24,lo8(8)
357
 372 02b2 00C0      		rjmp .L83
358
 373               	.L72:
359
 374 02b4 8091 0000 		lds r24,FC_StatusFlags2
360
 375 02b8 877F      		andi r24,lo8(-9)
361
 376               	.L83:
362
 377 02ba 8093 0000 		sts FC_StatusFlags2,r24
363
 378 02be 439B      		sbis 40-0x20,3
364
 379 02c0 00C0      		rjmp .L74
365
 380 02c2 8091 0000 		lds r24,FC_StatusFlags2
366
 381 02c6 8061      		ori r24,lo8(16)
367
 382 02c8 8093 0000 		sts FC_StatusFlags2,r24
368
 383 02cc 0895      		ret
369
 384               	.L74:
370
 385 02ce 8091 0000 		lds r24,FC_StatusFlags2
371
 386 02d2 8F7E      		andi r24,lo8(-17)
372
 387 02d4 8093 0000 		sts FC_StatusFlags2,r24
373
 388               	.L2:
374
 389 02d8 0895      		ret
375
 390               	/* epilogue: frame size=0 */
376
 391               	/* epilogue: noreturn */
377
 392               	/* epilogue end (size=0) */
378
 393               	/* function LED_Update size 357 (357) */
379
 395               	/* File "led.c": code  372 = 0x0174 ( 371), prologues   0, epilogues   1 */
380
DEFINED SYMBOLS
381
                            *ABS*:00000000 led.c
382
  C:\Temp/ccffEeZr.s:3      *ABS*:0000003f __SREG__
383
  C:\Temp/ccffEeZr.s:4      *ABS*:0000003e __SP_H__
384
  C:\Temp/ccffEeZr.s:5      *ABS*:0000003d __SP_L__
385
  C:\Temp/ccffEeZr.s:6      *ABS*:00000000 __tmp_reg__
386
  C:\Temp/ccffEeZr.s:7      *ABS*:00000001 __zero_reg__
387
  C:\Temp/ccffEeZr.s:14     .data:00000000 J17Mask
388
  C:\Temp/ccffEeZr.s:21     .bss:00000000 J17Blinkcount
389
  C:\Temp/ccffEeZr.s:27     .data:00000001 J16Mask
390
  C:\Temp/ccffEeZr.s:34     .bss:00000001 J16Blinkcount
391
  C:\Temp/ccffEeZr.s:40     .bss:00000002 LED2_Timing
392
  C:\Temp/ccffEeZr.s:46     .bss:00000004 LED1_Timing
393
  C:\Temp/ccffEeZr.s:51     .text:00000000 LED_Init
394
                             .bss:00000006 delay.0
395
  C:\Temp/ccffEeZr.s:69     .bss:00000007 J16Bitmask.1
396
  C:\Temp/ccffEeZr.s:70     .bss:00000008 J17Bitmask.2
397
  C:\Temp/ccffEeZr.s:71     .bss:00000009 J16Warn.3
398
  C:\Temp/ccffEeZr.s:72     .bss:0000000a J17Warn.4
399
  C:\Temp/ccffEeZr.s:73     .bss:0000000b from_nc.5
400
  C:\Temp/ccffEeZr.s:77     .text:0000001e LED_Update
401
 
402
UNDEFINED SYMBOLS
403
__do_copy_data
404
__do_clear_bss
405
PPM_in
406
FC_StatusFlags
407
VersionInfo
408
EE_Parameter
409
MotorenEin
410
Parameter_J16Timing
411
Parameter_J17Timing
412
FC_StatusFlags2