Blame | Last modification | View Log | RSS feed
1 .file "twimaster.c"
2 .arch atmega1284p
3 __SREG__ = 0x3f
4 __SP_H__ = 0x3e
5 __SP_L__ = 0x3d
6 __tmp_reg__ = 0
7 __zero_reg__ = 1
8 .global __do_copy_data
9 .global __do_clear_bss
10 .global BLConfig_ReadMask
11 .global BLConfig_ReadMask
12 .section .bss
15 BLConfig_ReadMask:
16 0000 0000 .skip 2,0
17 .global BLConfig_WriteMask
18 .global BLConfig_WriteMask
21 BLConfig_WriteMask:
22 0002 0000 .skip 2,0
23 .global BLFlags
24 .global BLFlags
27 BLFlags:
28 0004 00 .skip 1,0
29 .global MissingMotor
30 .global MissingMotor
33 MissingMotor:
34 0005 00 .skip 1,0
35 .global I2CTimeout
36 .data
39 I2CTimeout:
40 0000 6400 .word 100
41 .global I2C_TransferActive
42 .global I2C_TransferActive
43 .section .bss
46 I2C_TransferActive:
47 0006 00 .skip 1,0
48 .global motor_read
49 .global motor_read
52 motor_read:
53 0007 00 .skip 1,0
54 .global motor_write
55 .global motor_write
58 motor_write:
59 0008 00 .skip 1,0
60 .global dac_channel
61 .global dac_channel
64 dac_channel:
65 0009 00 .skip 1,0
66 .global twi_state
67 .global twi_state
70 twi_state:
71 000a 00 .skip 1,0
72 .text
73 .global I2C_Init
75 I2C_Init:
76 /* prologue: frame size=0 */
77 /* prologue end (size=0) */
78 0000 982F mov r25,r24
79 0002 2FB7 in r18,95-0x20
80 /* #APP */
81 0004 F894 cli
82 /* #NOAPP */
83 0006 3998 cbi 39-0x20,1
84 0008 389A sbi 39-0x20,0
85 000a 88B1 in r24,40-0x20
86 000c 8360 ori r24,lo8(3)
87 000e 88B9 out 40-0x20,r24
88 0010 8091 B900 lds r24,185
89 0014 8C7F andi r24,lo8(-4)
90 0016 8093 B900 sts 185,r24
91 001a 8AE2 ldi r24,lo8(42)
92 001c 8093 B800 sts 184,r24
93 0020 1092 0000 sts twi_state,__zero_reg__
94 0024 1092 0000 sts motor_write,__zero_reg__
95 0028 1092 0000 sts motor_read,__zero_reg__
96 002c 9923 tst r25
97 002e 01F0 breq .L2
98 0030 E0E0 ldi r30,lo8(Motor)
99 0032 F0E0 ldi r31,hi8(Motor)
100 0034 8BE0 ldi r24,lo8(11)
101 .L6:
102 0036 1082 st Z,__zero_reg__
103 0038 1182 std Z+1,__zero_reg__
104 003a 1282 std Z+2,__zero_reg__
105 003c 1382 std Z+3,__zero_reg__
106 003e 1482 std Z+4,__zero_reg__
107 0040 1582 std Z+5,__zero_reg__
108 0042 1682 std Z+6,__zero_reg__
109 0044 1782 std Z+7,__zero_reg__
110 0046 8150 subi r24,lo8(-(-1))
111 0048 3896 adiw r30,8
112 004a 87FF sbrs r24,7
113 004c 00C0 rjmp .L6
114 .L2:
115 /* #APP */
116 004e 7894 sei
117 /* #NOAPP */
118 0050 2FBF out 95-0x20,r18
119 /* epilogue: frame size=0 */
120 0052 0895 ret
121 /* epilogue end (size=1) */
122 /* function I2C_Init size 44 (43) */
124 .global I2C_Reset
126 I2C_Reset:
127 /* prologue: frame size=0 */
128 /* prologue end (size=0) */
129 0054 1092 0000 sts twi_state,__zero_reg__
130 0058 84E9 ldi r24,lo8(-108)
131 005a 8093 BC00 sts 188,r24
132 005e 80E8 ldi r24,lo8(-128)
133 0060 8093 BC00 sts 188,r24
134 0064 1092 BD00 sts 189,__zero_reg__
135 0068 1092 BA00 sts 186,__zero_reg__
136 006c 1092 BB00 sts 187,__zero_reg__
137 0070 1092 B900 sts 185,__zero_reg__
138 0074 1092 B800 sts 184,__zero_reg__
139 0078 1092 0000 sts I2C_TransferActive,__zero_reg__
140 007c 80E0 ldi r24,lo8(0)
141 007e 0E94 0000 call I2C_Init
142 0082 1092 BB00 sts 187,__zero_reg__
143 0086 85E8 ldi r24,lo8(-123)
144 0088 8093 BC00 sts 188,r24
145 008c 8091 0000 lds r24,BLFlags
146 0090 8260 ori r24,lo8(2)
147 0092 8093 0000 sts BLFlags,r24
148 /* epilogue: frame size=0 */
149 0096 0895 ret
150 /* epilogue end (size=1) */
151 /* function I2C_Reset size 34 (33) */
153 .lcomm missing_motor.0,1
154 .lcomm motor_read_temperature.1,1
155 .lcomm pBuff.2,2
156 .lcomm BuffLen.3,1
157 .global __vector_26
159 __vector_26:
160 /* prologue: frame size=0 */
161 0098 1F92 push __zero_reg__
162 009a 0F92 push __tmp_reg__
163 009c 0FB6 in __tmp_reg__,__SREG__
164 009e 0F92 push __tmp_reg__
165 00a0 1124 clr __zero_reg__
166 00a2 2F93 push r18
167 00a4 3F93 push r19
168 00a6 4F93 push r20
169 00a8 5F93 push r21
170 00aa 8F93 push r24
171 00ac 9F93 push r25
172 00ae EF93 push r30
173 00b0 FF93 push r31
174 /* prologue end (size=13) */
175 00b2 8091 0000 lds r24,twi_state
176 00b6 282F mov r18,r24
177 00b8 3327 clr r19
178 00ba 4427 clr r20
179 00bc 5527 clr r21
180 00be 8F5F subi r24,lo8(-(1))
181 00c0 8093 0000 sts twi_state,r24
182 00c4 F901 movw r30,r18
183 00c6 2731 cpi r18,23
184 00c8 3105 cpc r19,__zero_reg__
185 00ca 00F0 brlo .+2
186 00cc 00C0 rjmp .L72
187 00ce E050 subi r30,lo8(-(pm(.L73)))
188 00d0 F040 sbci r31,hi8(-(pm(.L73)))
189 00d2 0C94 0000 jmp __tablejump2__
190 .data
191 .section .progmem.gcc_sw_table, "a", @progbits
192 .p2align 1
193 .L73:
194 0000 0000 .word pm(.L11)
195 0002 0000 .word pm(.L17)
196 0004 0000 .word pm(.L22)
197 0006 0000 .word pm(.L27)
198 0008 0000 .word pm(.L29)
199 000a 0000 .word pm(.L33)
200 000c 0000 .word pm(.L50)
201 000e 0000 .word pm(.L72)
202 0010 0000 .word pm(.L72)
203 0012 0000 .word pm(.L72)
204 0014 0000 .word pm(.L72)
205 0016 0000 .word pm(.L72)
206 0018 0000 .word pm(.L72)
207 001a 0000 .word pm(.L72)
208 001c 0000 .word pm(.L72)
209 001e 0000 .word pm(.L72)
210 0020 0000 .word pm(.L72)
211 0022 0000 .word pm(.L72)
212 0024 0000 .word pm(.L60)
213 0026 0000 .word pm(.L61)
214 0028 0000 .word pm(.L62)
215 002a 0000 .word pm(.L68)
216 002c 0000 .word pm(.L69)
217 .text
218 .L11:
219 00d6 81E0 ldi r24,lo8(1)
220 00d8 8093 0000 sts I2C_TransferActive,r24
221 00dc 00C0 rjmp .L76
222 .L75:
223 00de 8091 0000 lds r24,motor_write
224 00e2 8C30 cpi r24,lo8(12)
225 00e4 00F4 brsh .L13
226 00e6 8091 0000 lds r24,motor_write
227 00ea 8F5F subi r24,lo8(-(1))
228 00ec 8093 0000 sts motor_write,r24
229 .L76:
230 00f0 8091 0000 lds r24,motor_write
231 00f4 E82F mov r30,r24
232 00f6 FF27 clr r31
233 00f8 EE0F lsl r30
234 00fa FF1F rol r31
235 00fc EE0F lsl r30
236 00fe FF1F rol r31
237 0100 E050 subi r30,lo8(-(Mixer))
238 0102 F040 sbci r31,hi8(-(Mixer))
239 0104 8585 ldd r24,Z+13
240 0106 1816 cp __zero_reg__,r24
241 0108 04F4 brge .L75
242 .L13:
243 010a 8091 0000 lds r24,motor_write
244 010e 8C30 cpi r24,lo8(12)
245 0110 00F0 brlo .L15
246 0112 1092 0000 sts (BLConfig_WriteMask)+1,__zero_reg__
247 0116 1092 0000 sts BLConfig_WriteMask,__zero_reg__
248 011a 1092 0000 sts motor_write,__zero_reg__
249 011e 85E0 ldi r24,lo8(5)
250 0120 8093 0000 sts twi_state,r24
251 0124 8091 0000 lds r24,motor_read
252 0128 880F lsl r24
253 012a 8D5A subi r24,lo8(-(83))
254 012c 00C0 rjmp .L84
255 .L15:
256 012e 8091 0000 lds r24,motor_write
257 0132 880F lsl r24
258 0134 8E5A subi r24,lo8(-(82))
259 .L84:
260 0136 8093 BB00 sts 187,r24
261 013a 85E8 ldi r24,lo8(-123)
262 013c 00C0 rjmp .L80
263 .L17:
264 013e 8091 0000 lds r24,motor_write
265 0142 E82F mov r30,r24
266 0144 FF27 clr r31
267 0146 83E0 ldi r24,3
268 0148 EE0F 1: lsl r30
269 014a FF1F rol r31
270 014c 8A95 dec r24
271 014e 01F4 brne 1b
272 0150 E050 subi r30,lo8(-(Motor))
273 0152 F040 sbci r31,hi8(-(Motor))
274 0154 8181 ldd r24,Z+1
275 0156 8093 BB00 sts 187,r24
276 015a 85E8 ldi r24,lo8(-123)
277 015c 8093 BC00 sts 188,r24
278 0160 8091 0000 lds r24,motor_write
279 0164 E82F mov r30,r24
280 0166 FF27 clr r31
281 0168 EE0F lsl r30
282 016a FF1F rol r31
283 016c EE0F lsl r30
284 016e FF1F rol r31
285 0170 EE0F lsl r30
286 0172 FF1F rol r31
287 0174 E050 subi r30,lo8(-(Motor))
288 0176 F040 sbci r31,hi8(-(Motor))
289 0178 8081 ld r24,Z
290 017a 80FF sbrs r24,0
291 017c 00C0 rjmp .L25
292 017e 8091 0000 lds r24,motor_write
293 0182 E82F mov r30,r24
294 0184 FF27 clr r31
295 0186 EE0F lsl r30
296 0188 FF1F rol r31
297 018a EE0F lsl r30
298 018c FF1F rol r31
299 018e EE0F lsl r30
300 0190 FF1F rol r31
301 0192 E050 subi r30,lo8(-(Motor))
302 0194 F040 sbci r31,hi8(-(Motor))
303 0196 8281 ldd r24,Z+2
304 0198 8823 tst r24
305 019a 01F0 breq .L21
306 019c 8091 0000 lds r24,RequiredMotors
307 01a0 8730 cpi r24,lo8(7)
308 01a2 00F4 brsh .+2
309 01a4 00C0 rjmp .L9
310 .L21:
311 01a6 8091 0000 lds r24,BLConfig_WriteMask
312 01aa 9091 0000 lds r25,(BLConfig_WriteMask)+1
313 01ae 892B or r24,r25
314 01b0 01F0 breq .+2
315 01b2 00C0 rjmp .L9
316 01b4 8091 0000 lds r24,BLConfig_ReadMask
317 01b8 9091 0000 lds r25,(BLConfig_ReadMask)+1
318 01bc 892B or r24,r25
319 01be 01F0 breq .+2
320 01c0 00C0 rjmp .L9
321 01c2 00C0 rjmp .L25
322 .L22:
323 01c4 8091 0000 lds r24,motor_write
324 01c8 21E0 ldi r18,lo8(1)
325 01ca 30E0 ldi r19,hi8(1)
326 01cc 00C0 rjmp 2f
327 01ce 220F 1: lsl r18
328 01d0 331F rol r19
329 01d2 8A95 2: dec r24
330 01d4 02F4 brpl 1b
331 01d6 8091 0000 lds r24,BLConfig_ReadMask
332 01da 9091 0000 lds r25,(BLConfig_ReadMask)+1
333 01de 2823 and r18,r24
334 01e0 3923 and r19,r25
335 01e2 232B or r18,r19
336 01e4 01F0 breq .L23
337 01e6 8091 0000 lds r24,motor_write
338 01ea E82F mov r30,r24
339 01ec FF27 clr r31
340 01ee EE0F lsl r30
341 01f0 FF1F rol r31
342 01f2 EE0F lsl r30
343 01f4 FF1F rol r31
344 01f6 EE0F lsl r30
345 01f8 FF1F rol r31
346 01fa E050 subi r30,lo8(-(Motor))
347 01fc F040 sbci r31,hi8(-(Motor))
348 01fe 80E1 ldi r24,lo8(16)
349 0200 8483 std Z+4,r24
350 0202 00C0 rjmp .L24
351 .L23:
352 0204 8091 0000 lds r24,motor_write
353 0208 E82F mov r30,r24
354 020a FF27 clr r31
355 020c EE0F lsl r30
356 020e FF1F rol r31
357 0210 EE0F lsl r30
358 0212 FF1F rol r31
359 0214 EE0F lsl r30
360 0216 FF1F rol r31
361 0218 E050 subi r30,lo8(-(Motor))
362 021a F040 sbci r31,hi8(-(Motor))
363 021c 1482 std Z+4,__zero_reg__
364 .L24:
365 021e 8091 0000 lds r24,motor_write
366 0222 E82F mov r30,r24
367 0224 FF27 clr r31
368 0226 53E0 ldi r21,3
369 0228 EE0F 1: lsl r30
370 022a FF1F rol r31
371 022c 5A95 dec r21
372 022e 01F4 brne 1b
373 0230 E050 subi r30,lo8(-(Motor))
374 0232 F040 sbci r31,hi8(-(Motor))
375 0234 8481 ldd r24,Z+4
376 0236 282F mov r18,r24
377 0238 3327 clr r19
378 023a 43E0 ldi r20,3
379 023c 220F 1: lsl r18
380 023e 331F rol r19
381 0240 4A95 dec r20
382 0242 01F4 brne 1b
383 0244 8091 0000 lds r24,motor_write
384 0248 E82F mov r30,r24
385 024a FF27 clr r31
386 024c 93E0 ldi r25,3
387 024e EE0F 1: lsl r30
388 0250 FF1F rol r31
389 0252 9A95 dec r25
390 0254 01F4 brne 1b
391 0256 E050 subi r30,lo8(-(Motor))
392 0258 F040 sbci r31,hi8(-(Motor))
393 025a 8281 ldd r24,Z+2
394 025c 8770 andi r24,lo8(7)
395 025e 822B or r24,r18
396 0260 8093 BB00 sts 187,r24
397 0264 85E8 ldi r24,lo8(-123)
398 0266 8093 BC00 sts 188,r24
399 026a 2091 0000 lds r18,motor_write
400 026e 81E0 ldi r24,lo8(1)
401 0270 90E0 ldi r25,hi8(1)
402 0272 00C0 rjmp 2f
403 0274 880F 1: lsl r24
404 0276 991F rol r25
405 0278 2A95 2: dec r18
406 027a 02F4 brpl 1b
407 027c 2091 0000 lds r18,BLConfig_WriteMask
408 0280 3091 0000 lds r19,(BLConfig_WriteMask)+1
409 0284 8223 and r24,r18
410 0286 9323 and r25,r19
411 0288 892B or r24,r25
412 028a 01F0 breq .L25
413 028c 80E0 ldi r24,lo8(BLConfig)
414 028e 90E0 ldi r25,hi8(BLConfig)
415 0290 9093 0000 sts (pBuff.2)+1,r25
416 0294 8093 0000 sts pBuff.2,r24
417 0298 88E0 ldi r24,lo8(8)
418 029a 8093 0000 sts BuffLen.3,r24
419 029e 00C0 rjmp .L9
420 .L25:
421 02a0 84E0 ldi r24,lo8(4)
422 02a2 00C0 rjmp .L82
423 .L27:
424 02a4 E091 0000 lds r30,pBuff.2
425 02a8 F091 0000 lds r31,(pBuff.2)+1
426 02ac 8191 ld r24,Z+
427 02ae 8093 BB00 sts 187,r24
428 02b2 85E8 ldi r24,lo8(-123)
429 02b4 8093 BC00 sts 188,r24
430 02b8 F093 0000 sts (pBuff.2)+1,r31
431 02bc E093 0000 sts pBuff.2,r30
432 02c0 8091 0000 lds r24,BuffLen.3
433 02c4 8150 subi r24,lo8(-(-1))
434 02c6 8093 0000 sts BuffLen.3,r24
435 02ca 8823 tst r24
436 02cc 01F4 brne .+2
437 02ce 00C0 rjmp .L9
438 02d0 83E0 ldi r24,lo8(3)
439 02d2 00C0 rjmp .L82
440 .L29:
441 02d4 8091 B900 lds r24,185
442 02d8 8033 cpi r24,lo8(48)
443 02da 01F4 brne .L30
444 02dc 8091 0000 lds r24,missing_motor.0
445 02e0 8823 tst r24
446 02e2 01F4 brne .L31
447 02e4 8091 0000 lds r24,motor_write
448 02e8 8F5F subi r24,lo8(-(1))
449 02ea 8093 0000 sts missing_motor.0,r24
450 .L31:
451 02ee 8091 0000 lds r24,motor_write
452 02f2 E82F mov r30,r24
453 02f4 FF27 clr r31
454 02f6 83E0 ldi r24,3
455 02f8 EE0F 1: lsl r30
456 02fa FF1F rol r31
457 02fc 8A95 dec r24
458 02fe 01F4 brne 1b
459 0300 E050 subi r30,lo8(-(Motor))
460 0302 F040 sbci r31,hi8(-(Motor))
461 0304 8381 ldd r24,Z+3
462 0306 9927 clr r25
463 0308 8F77 andi r24,lo8(127)
464 030a 9070 andi r25,hi8(127)
465 030c 8F37 cpi r24,127
466 030e 9105 cpc r25,__zero_reg__
467 0310 04F4 brge .L30
468 0312 8091 0000 lds r24,motor_write
469 0316 E82F mov r30,r24
470 0318 FF27 clr r31
471 031a EE0F lsl r30
472 031c FF1F rol r31
473 031e EE0F lsl r30
474 0320 FF1F rol r31
475 0322 EE0F lsl r30
476 0324 FF1F rol r31
477 0326 E050 subi r30,lo8(-(Motor))
478 0328 F040 sbci r31,hi8(-(Motor))
479 032a 8381 ldd r24,Z+3
480 032c 8F5F subi r24,lo8(-(1))
481 032e 8383 std Z+3,r24
482 .L30:
483 0330 1092 0000 sts twi_state,__zero_reg__
484 0334 84E9 ldi r24,lo8(-108)
485 0336 8093 BC00 sts 188,r24
486 033a 8AE0 ldi r24,lo8(10)
487 033c 90E0 ldi r25,hi8(10)
488 033e 9093 0000 sts (I2CTimeout)+1,r25
489 0342 8093 0000 sts I2CTimeout,r24
490 0346 8091 0000 lds r24,motor_write
491 034a 8F5F subi r24,lo8(-(1))
492 034c 8093 0000 sts motor_write,r24
493 0350 1092 0000 sts twi_state,__zero_reg__
494 0354 00C0 rjmp .L85
495 .L33:
496 0356 8091 B900 lds r24,185
497 035a 8034 cpi r24,lo8(64)
498 035c 01F0 breq .L34
499 035e 8091 0000 lds r24,motor_read
500 0362 E82F mov r30,r24
501 0364 FF27 clr r31
502 0366 EE0F lsl r30
503 0368 FF1F rol r31
504 036a EE0F lsl r30
505 036c FF1F rol r31
506 036e EE0F lsl r30
507 0370 FF1F rol r31
508 0372 E050 subi r30,lo8(-(Motor))
509 0374 F040 sbci r31,hi8(-(Motor))
510 0376 8381 ldd r24,Z+3
511 0378 8F77 andi r24,lo8(127)
512 037a 8383 std Z+3,r24
513 037c 8091 0000 lds r24,motor_read
514 0380 8F5F subi r24,lo8(-(1))
515 0382 8093 0000 sts motor_read,r24
516 0386 8091 0000 lds r24,motor_read
517 038a 8C30 cpi r24,lo8(12)
518 038c 00F0 brlo .L35
519 038e 1092 0000 sts motor_read,__zero_reg__
520 0392 1092 0000 sts (BLConfig_ReadMask)+1,__zero_reg__
521 0396 1092 0000 sts BLConfig_ReadMask,__zero_reg__
522 039a 8091 0000 lds r24,motor_read_temperature.1
523 039e 8F5F subi r24,lo8(-(1))
524 03a0 8093 0000 sts motor_read_temperature.1,r24
525 03a4 8C30 cpi r24,lo8(12)
526 03a6 00F0 brlo .L35
527 03a8 1092 0000 sts motor_read_temperature.1,__zero_reg__
528 03ac 8091 0000 lds r24,BLFlags
529 03b0 8D7F andi r24,lo8(-3)
530 03b2 8093 0000 sts BLFlags,r24
531 .L35:
532 03b6 8091 0000 lds r24,BLFlags
533 03ba 8160 ori r24,lo8(1)
534 03bc 8093 0000 sts BLFlags,r24
535 03c0 1092 0000 sts twi_state,__zero_reg__
536 03c4 84E9 ldi r24,lo8(-108)
537 03c6 8093 BC00 sts 188,r24
538 03ca 1092 0000 sts I2C_TransferActive,__zero_reg__
539 03ce 00C0 rjmp .L37
540 .L34:
541 03d0 8091 0000 lds r24,motor_read
542 03d4 E82F mov r30,r24
543 03d6 FF27 clr r31
544 03d8 EE0F lsl r30
545 03da FF1F rol r31
546 03dc EE0F lsl r30
547 03de FF1F rol r31
548 03e0 EE0F lsl r30
549 03e2 FF1F rol r31
550 03e4 E050 subi r30,lo8(-(Motor))
551 03e6 F040 sbci r31,hi8(-(Motor))
552 03e8 8381 ldd r24,Z+3
553 03ea 8068 ori r24,lo8(-128)
554 03ec 8383 std Z+3,r24
555 03ee 8091 0000 lds r24,motor_read
556 03f2 E82F mov r30,r24
557 03f4 FF27 clr r31
558 03f6 EE0F lsl r30
559 03f8 FF1F rol r31
560 03fa EE0F lsl r30
561 03fc FF1F rol r31
562 03fe EE0F lsl r30
563 0400 FF1F rol r31
564 0402 E050 subi r30,lo8(-(Motor))
565 0404 F040 sbci r31,hi8(-(Motor))
566 0406 8081 ld r24,Z
567 0408 80FF sbrs r24,0
568 040a 00C0 rjmp .L38
569 040c 8091 0000 lds r24,motor_read
570 0410 E82F mov r30,r24
571 0412 FF27 clr r31
572 0414 53E0 ldi r21,3
573 0416 EE0F 1: lsl r30
574 0418 FF1F rol r31
575 041a 5A95 dec r21
576 041c 01F4 brne 1b
577 041e E050 subi r30,lo8(-(Motor))
578 0420 F040 sbci r31,hi8(-(Motor))
579 0422 8481 ldd r24,Z+4
580 0424 9927 clr r25
581 0426 0097 sbiw r24,0
582 0428 01F0 breq .L41
583 042a 4097 sbiw r24,16
584 042c 01F4 brne .L44
585 042e 80E0 ldi r24,lo8(BLConfig)
586 0430 90E0 ldi r25,hi8(BLConfig)
587 0432 9093 0000 sts (pBuff.2)+1,r25
588 0436 8093 0000 sts pBuff.2,r24
589 043a 88E0 ldi r24,lo8(8)
590 043c 00C0 rjmp .L77
591 .L41:
592 043e 8091 0000 lds r24,motor_read
593 0442 9927 clr r25
594 0444 43E0 ldi r20,3
595 0446 880F 1: lsl r24
596 0448 991F rol r25
597 044a 4A95 dec r20
598 044c 01F4 brne 1b
599 044e 8050 subi r24,lo8(-(Motor+5))
600 0450 9040 sbci r25,hi8(-(Motor+5))
601 0452 9093 0000 sts (pBuff.2)+1,r25
602 0456 8093 0000 sts pBuff.2,r24
603 045a 9091 0000 lds r25,motor_read
604 045e 8091 0000 lds r24,motor_read_temperature.1
605 0462 9817 cp r25,r24
606 0464 01F4 brne .L45
607 0466 83E0 ldi r24,lo8(3)
608 0468 00C0 rjmp .L77
609 .L38:
610 046a 8091 0000 lds r24,motor_read
611 046e 9927 clr r25
612 0470 33E0 ldi r19,3
613 0472 880F 1: lsl r24
614 0474 991F rol r25
615 0476 3A95 dec r19
616 0478 01F4 brne 1b
617 047a 8050 subi r24,lo8(-(Motor+5))
618 047c 9040 sbci r25,hi8(-(Motor+5))
619 047e 9093 0000 sts (pBuff.2)+1,r25
620 0482 8093 0000 sts pBuff.2,r24
621 0486 8091 0000 lds r24,BLFlags
622 048a 81FD sbrc r24,1
623 048c 00C0 rjmp .L46
624 048e 9091 0000 lds r25,motor_read
625 0492 8091 0000 lds r24,motor_read_temperature.1
626 0496 9817 cp r25,r24
627 0498 01F4 brne .L45
628 .L46:
629 049a 82E0 ldi r24,lo8(2)
630 049c 00C0 rjmp .L77
631 .L45:
632 049e 81E0 ldi r24,lo8(1)
633 .L77:
634 04a0 8093 0000 sts BuffLen.3,r24
635 .L44:
636 04a4 8091 0000 lds r24,BuffLen.3
637 04a8 8130 cpi r24,lo8(1)
638 04aa 01F4 brne .L48
639 04ac 85E8 ldi r24,lo8(-123)
640 04ae 00C0 rjmp .L78
641 .L48:
642 04b0 85EC ldi r24,lo8(-59)
643 .L78:
644 04b2 8093 BC00 sts 188,r24
645 .L37:
646 04b6 8091 0000 lds r24,missing_motor.0
647 04ba 8093 0000 sts MissingMotor,r24
648 04be 1092 0000 sts missing_motor.0,__zero_reg__
649 04c2 00C0 rjmp .L9
650 .L50:
651 04c4 E091 0000 lds r30,pBuff.2
652 04c8 F091 0000 lds r31,(pBuff.2)+1
653 04cc 8091 BB00 lds r24,187
654 04d0 8083 st Z,r24
655 04d2 8091 0000 lds r24,pBuff.2
656 04d6 9091 0000 lds r25,(pBuff.2)+1
657 04da 0196 adiw r24,1
658 04dc 9093 0000 sts (pBuff.2)+1,r25
659 04e0 8093 0000 sts pBuff.2,r24
660 04e4 8091 0000 lds r24,BuffLen.3
661 04e8 8150 subi r24,lo8(-(-1))
662 04ea 8093 0000 sts BuffLen.3,r24
663 04ee 8230 cpi r24,lo8(2)
664 04f0 00F0 brlo .L51
665 04f2 85EC ldi r24,lo8(-59)
666 04f4 00C0 rjmp .L79
667 .L51:
668 04f6 8130 cpi r24,lo8(1)
669 04f8 01F4 brne .L53
670 04fa 85E8 ldi r24,lo8(-123)
671 04fc 00C0 rjmp .L79
672 .L53:
673 04fe 8091 0000 lds r24,BLFlags
674 0502 81FF sbrs r24,1
675 0504 00C0 rjmp .L55
676 0506 8091 0000 lds r24,FC_StatusFlags
677 050a 80FD sbrc r24,0
678 050c 00C0 rjmp .L56
679 050e 8091 0000 lds r24,motor_read
680 0512 E82F mov r30,r24
681 0514 FF27 clr r31
682 0516 23E0 ldi r18,3
683 0518 EE0F 1: lsl r30
684 051a FF1F rol r31
685 051c 2A95 dec r18
686 051e 01F4 brne 1b
687 0520 E050 subi r30,lo8(-(Motor))
688 0522 F040 sbci r31,hi8(-(Motor))
689 0524 8681 ldd r24,Z+6
690 0526 8A3F cpi r24,lo8(-6)
691 0528 01F4 brne .L56
692 052a 8091 0000 lds r24,motor_read
693 052e E82F mov r30,r24
694 0530 FF27 clr r31
695 0532 93E0 ldi r25,3
696 0534 EE0F 1: lsl r30
697 0536 FF1F rol r31
698 0538 9A95 dec r25
699 053a 01F4 brne 1b
700 053c E050 subi r30,lo8(-(Motor))
701 053e F040 sbci r31,hi8(-(Motor))
702 0540 8081 ld r24,Z
703 0542 8160 ori r24,lo8(1)
704 0544 8083 st Z,r24
705 0546 00C0 rjmp .L55
706 .L56:
707 0548 8091 0000 lds r24,motor_read
708 054c E82F mov r30,r24
709 054e FF27 clr r31
710 0550 83E0 ldi r24,3
711 0552 EE0F 1: lsl r30
712 0554 FF1F rol r31
713 0556 8A95 dec r24
714 0558 01F4 brne 1b
715 055a E050 subi r30,lo8(-(Motor))
716 055c F040 sbci r31,hi8(-(Motor))
717 055e 1082 st Z,__zero_reg__
718 .L55:
719 0560 8091 0000 lds r24,motor_read
720 0564 8F5F subi r24,lo8(-(1))
721 0566 8093 0000 sts motor_read,r24
722 056a 8091 0000 lds r24,motor_read
723 056e 8C30 cpi r24,lo8(12)
724 0570 00F0 brlo .L58
725 0572 1092 0000 sts motor_read,__zero_reg__
726 0576 1092 0000 sts (BLConfig_ReadMask)+1,__zero_reg__
727 057a 1092 0000 sts BLConfig_ReadMask,__zero_reg__
728 057e 8091 0000 lds r24,motor_read_temperature.1
729 0582 8F5F subi r24,lo8(-(1))
730 0584 8093 0000 sts motor_read_temperature.1,r24
731 0588 8C30 cpi r24,lo8(12)
732 058a 00F0 brlo .L58
733 058c 1092 0000 sts motor_read_temperature.1,__zero_reg__
734 0590 8091 0000 lds r24,BLFlags
735 0594 8D7F andi r24,lo8(-3)
736 0596 8093 0000 sts BLFlags,r24
737 .L58:
738 059a 1092 0000 sts twi_state,__zero_reg__
739 059e 84E9 ldi r24,lo8(-108)
740 05a0 8093 BC00 sts 188,r24
741 05a4 8091 0000 lds r24,BLFlags
742 05a8 8160 ori r24,lo8(1)
743 05aa 8093 0000 sts BLFlags,r24
744 05ae 00C0 rjmp .L81
745 .L79:
746 05b0 8093 BC00 sts 188,r24
747 05b4 86E0 ldi r24,lo8(6)
748 .L82:
749 05b6 8093 0000 sts twi_state,r24
750 05ba 00C0 rjmp .L9
751 .L60:
752 05bc 88E9 ldi r24,lo8(-104)
753 05be 00C0 rjmp .L84
754 .L61:
755 05c0 8091 0000 lds r24,dac_channel
756 05c4 880F lsl r24
757 05c6 805F subi r24,lo8(-(16))
758 05c8 00C0 rjmp .L84
759 .L62:
760 05ca 8091 0000 lds r24,dac_channel
761 05ce 9927 clr r25
762 05d0 8130 cpi r24,1
763 05d2 9105 cpc r25,__zero_reg__
764 05d4 01F0 breq .L65
765 05d6 8230 cpi r24,2
766 05d8 9105 cpc r25,__zero_reg__
767 05da 04F4 brge .L67
768 05dc 892B or r24,r25
769 05de 01F0 breq .L64
770 05e0 00C0 rjmp .L9
771 .L67:
772 05e2 0297 sbiw r24,2
773 05e4 01F0 breq .L66
774 05e6 00C0 rjmp .L9
775 .L64:
776 05e8 8091 0000 lds r24,AnalogOffsetNick
777 05ec 00C0 rjmp .L84
778 .L65:
779 05ee 8091 0000 lds r24,AnalogOffsetRoll
780 05f2 00C0 rjmp .L84
781 .L66:
782 05f4 8091 0000 lds r24,AnalogOffsetGier
783 05f8 00C0 rjmp .L84
784 .L68:
785 05fa 80E8 ldi r24,lo8(-128)
786 05fc 00C0 rjmp .L84
787 .L69:
788 05fe 1092 0000 sts twi_state,__zero_reg__
789 0602 84E9 ldi r24,lo8(-108)
790 0604 8093 BC00 sts 188,r24
791 0608 1092 0000 sts I2C_TransferActive,__zero_reg__
792 060c 8AE0 ldi r24,lo8(10)
793 060e 90E0 ldi r25,hi8(10)
794 0610 9093 0000 sts (I2CTimeout)+1,r25
795 0614 8093 0000 sts I2CTimeout,r24
796 0618 8091 0000 lds r24,dac_channel
797 061c 8230 cpi r24,lo8(2)
798 061e 00F4 brsh .L70
799 0620 8091 0000 lds r24,dac_channel
800 0624 8F5F subi r24,lo8(-(1))
801 0626 8093 0000 sts dac_channel,r24
802 062a 82E1 ldi r24,lo8(18)
803 062c 8093 0000 sts twi_state,r24
804 .L85:
805 0630 8091 0000 lds r24,BLFlags
806 0634 8E7F andi r24,lo8(-2)
807 0636 8093 0000 sts BLFlags,r24
808 063a 85EA ldi r24,lo8(-91)
809 .L80:
810 063c 8093 BC00 sts 188,r24
811 0640 00C0 rjmp .L9
812 .L70:
813 0642 1092 0000 sts dac_channel,__zero_reg__
814 0646 8091 0000 lds r24,BLFlags
815 064a 8160 ori r24,lo8(1)
816 064c 8093 0000 sts BLFlags,r24
817 0650 00C0 rjmp .L9
818 .L72:
819 0652 1092 0000 sts twi_state,__zero_reg__
820 0656 84E9 ldi r24,lo8(-108)
821 0658 8093 BC00 sts 188,r24
822 065c 8091 0000 lds r24,BLFlags
823 0660 8160 ori r24,lo8(1)
824 0662 8093 0000 sts BLFlags,r24
825 0666 8AE0 ldi r24,lo8(10)
826 0668 90E0 ldi r25,hi8(10)
827 066a 9093 0000 sts (I2CTimeout)+1,r25
828 066e 8093 0000 sts I2CTimeout,r24
829 0672 1092 0000 sts motor_write,__zero_reg__
830 0676 1092 0000 sts motor_read,__zero_reg__
831 .L81:
832 067a 1092 0000 sts I2C_TransferActive,__zero_reg__
833 .L9:
834 /* epilogue: frame size=0 */
835 067e FF91 pop r31
836 0680 EF91 pop r30
837 0682 9F91 pop r25
838 0684 8F91 pop r24
839 0686 5F91 pop r21
840 0688 4F91 pop r20
841 068a 3F91 pop r19
842 068c 2F91 pop r18
843 068e 0F90 pop __tmp_reg__
844 0690 0FBE out __SREG__,__tmp_reg__
845 0692 0F90 pop __tmp_reg__
846 0694 1F90 pop __zero_reg__
847 0696 1895 reti
848 /* epilogue end (size=13) */
849 /* function __vector_26 size 796 (770) */
851 .global I2C_WriteBLConfig
853 I2C_WriteBLConfig:
854 /* prologue: frame size=0 */
855 0698 1F93 push r17
856 069a CF93 push r28
857 069c DF93 push r29
858 /* prologue end (size=3) */
859 069e 182F mov r17,r24
860 06a0 8091 0000 lds r24,MotorenEin
861 06a4 8823 tst r24
862 06a6 01F4 brne .L88
863 06a8 8091 0000 lds r24,PC_MotortestActive
864 06ac 8823 tst r24
865 06ae 01F0 breq .L87
866 .L88:
867 06b0 81E0 ldi r24,lo8(1)
868 06b2 90E0 ldi r25,hi8(1)
869 06b4 00C0 rjmp .L86
870 .L87:
871 06b6 1D30 cpi r17,lo8(13)
872 06b8 00F0 brlo .+2
873 06ba 00C0 rjmp .L115
874 06bc 1123 tst r17
875 06be 01F0 breq .L90
876 06c0 E12F mov r30,r17
877 06c2 FF27 clr r31
878 06c4 23E0 ldi r18,3
879 06c6 EE0F 1: lsl r30
880 06c8 FF1F rol r31
881 06ca 2A95 dec r18
882 06cc 01F4 brne 1b
883 06ce E050 subi r30,lo8(-(Motor))
884 06d0 F040 sbci r31,hi8(-(Motor))
885 06d2 3597 sbiw r30,5
886 06d4 8081 ld r24,Z
887 06d6 3596 adiw r30,5
888 06d8 8823 tst r24
889 06da 04F0 brlt .+2
890 06dc 00C0 rjmp .L115
891 06de 3897 sbiw r30,8
892 06e0 8081 ld r24,Z
893 06e2 80FD sbrc r24,0
894 06e4 00C0 rjmp .L90
895 06e6 83E0 ldi r24,lo8(3)
896 06e8 90E0 ldi r25,hi8(3)
897 06ea 00C0 rjmp .L86
898 .L90:
899 06ec 8091 0000 lds r24,BLConfig
900 06f0 8230 cpi r24,lo8(2)
901 06f2 01F0 breq .L93
902 06f4 84E0 ldi r24,lo8(4)
903 06f6 90E0 ldi r25,hi8(4)
904 06f8 00C0 rjmp .L86
905 .L93:
906 06fa 67E0 ldi r22,lo8(7)
907 06fc 70E0 ldi r23,hi8(7)
908 06fe 80E0 ldi r24,lo8(BLConfig)
909 0700 90E0 ldi r25,hi8(BLConfig)
910 0702 0E94 0000 call RAM_Checksum
911 0706 9091 0000 lds r25,BLConfig+7
912 070a 8917 cp r24,r25
913 070c 01F0 breq .L94
914 070e 85E0 ldi r24,lo8(5)
915 0710 90E0 ldi r25,hi8(5)
916 0712 00C0 rjmp .L86
917 .L94:
918 0714 80ED ldi r24,lo8(2000)
919 0716 97E0 ldi r25,hi8(2000)
920 0718 0E94 0000 call SetDelay
921 071c EC01 movw r28,r24
922 .L95:
923 071e 8091 0000 lds r24,BLFlags
924 0722 80FD sbrc r24,0
925 0724 00C0 rjmp .L96
926 0726 CE01 movw r24,r28
927 0728 0E94 0000 call CheckDelay
928 072c 8823 tst r24
929 072e 01F0 breq .L95
930 .L96:
931 0730 1123 tst r17
932 0732 01F4 brne .L98
933 0734 8FEF ldi r24,lo8(255)
934 0736 90E0 ldi r25,hi8(255)
935 0738 00C0 rjmp .L114
936 .L98:
937 073a 212F mov r18,r17
938 073c 3327 clr r19
939 073e 2150 subi r18,lo8(-(-1))
940 0740 3040 sbci r19,hi8(-(-1))
941 0742 81E0 ldi r24,lo8(1)
942 0744 90E0 ldi r25,hi8(1)
943 0746 00C0 rjmp 2f
944 0748 880F 1: lsl r24
945 074a 991F rol r25
946 074c 2A95 2: dec r18
947 074e 02F4 brpl 1b
948 .L114:
949 0750 9093 0000 sts (BLConfig_WriteMask)+1,r25
950 0754 8093 0000 sts BLConfig_WriteMask,r24
951 0758 A1E0 ldi r26,lo8(1)
952 075a B0E0 ldi r27,hi8(1)
953 075c E0E0 ldi r30,lo8(Motor)
954 075e F0E0 ldi r31,hi8(Motor)
955 0760 40E0 ldi r20,lo8(0)
956 0762 50E0 ldi r21,hi8(0)
957 0764 6BE0 ldi r22,lo8(11)
958 .L104:
959 0766 CD01 movw r24,r26
960 0768 042E mov r0,r20
961 076a 00C0 rjmp 2f
962 076c 880F 1: lsl r24
963 076e 991F rol r25
964 0770 0A94 2: dec r0
965 0772 02F4 brpl 1b
966 0774 2091 0000 lds r18,BLConfig_WriteMask
967 0778 3091 0000 lds r19,(BLConfig_WriteMask)+1
968 077c 8223 and r24,r18
969 077e 9323 and r25,r19
970 0780 892B or r24,r25
971 0782 01F0 breq .L102
972 0784 1182 std Z+1,__zero_reg__
973 0786 1282 std Z+2,__zero_reg__
974 .L102:
975 0788 6150 subi r22,lo8(-(-1))
976 078a 4F5F subi r20,lo8(-(1))
977 078c 5F4F sbci r21,hi8(-(1))
978 078e 3896 adiw r30,8
979 0790 67FF sbrs r22,7
980 0792 00C0 rjmp .L104
981 0794 1092 0000 sts motor_write,__zero_reg__
982 .L105:
983 0798 1092 0000 sts twi_state,__zero_reg__
984 079c 8091 0000 lds r24,BLFlags
985 07a0 8E7F andi r24,lo8(-2)
986 07a2 8093 0000 sts BLFlags,r24
987 07a6 85EA ldi r24,lo8(-91)
988 07a8 8093 BC00 sts 188,r24
989 .L108:
990 07ac 8091 0000 lds r24,BLFlags
991 07b0 80FD sbrc r24,0
992 07b2 00C0 rjmp .L109
993 07b4 CE01 movw r24,r28
994 07b6 0E94 0000 call CheckDelay
995 07ba 8823 tst r24
996 07bc 01F0 breq .L108
997 .L109:
998 07be 8091 0000 lds r24,BLConfig_WriteMask
999 07c2 9091 0000 lds r25,(BLConfig_WriteMask)+1
1000 07c6 892B or r24,r25
1001 07c8 01F0 breq .L106
1002 07ca CE01 movw r24,r28
1003 07cc 0E94 0000 call CheckDelay
1004 07d0 8823 tst r24
1005 07d2 01F0 breq .L105
1006 .L106:
1007 07d4 8091 0000 lds r24,BLConfig_WriteMask
1008 07d8 9091 0000 lds r25,(BLConfig_WriteMask)+1
1009 07dc 0097 sbiw r24,0
1010 07de 01F0 breq .L86
1011 .L115:
1012 07e0 82E0 ldi r24,lo8(2)
1013 07e2 90E0 ldi r25,hi8(2)
1014 .L86:
1015 /* epilogue: frame size=0 */
1016 07e4 DF91 pop r29
1017 07e6 CF91 pop r28
1018 07e8 1F91 pop r17
1019 07ea 0895 ret
1020 /* epilogue end (size=4) */
1021 /* function I2C_WriteBLConfig size 172 (165) */
1023 .global I2C_ReadBLConfig
1025 I2C_ReadBLConfig:
1026 /* prologue: frame size=0 */
1027 07ec 0F93 push r16
1028 07ee 1F93 push r17
1029 07f0 CF93 push r28
1030 07f2 DF93 push r29
1031 /* prologue end (size=4) */
1032 07f4 982F mov r25,r24
1033 07f6 8091 0000 lds r24,MotorenEin
1034 07fa 8823 tst r24
1035 07fc 01F4 brne .L118
1036 07fe 8091 0000 lds r24,PC_MotortestActive
1037 0802 8823 tst r24
1038 0804 01F0 breq .L117
1039 .L118:
1040 0806 81E0 ldi r24,lo8(1)
1041 0808 90E0 ldi r25,hi8(1)
1042 080a 00C0 rjmp .L116
1043 .L117:
1044 080c 9D30 cpi r25,lo8(13)
1045 080e 00F4 brsh .L141
1046 0810 9923 tst r25
1047 0812 01F4 brne .L120
1048 0814 86E0 ldi r24,lo8(6)
1049 0816 90E0 ldi r25,hi8(6)
1050 0818 00C0 rjmp .L116
1051 .L120:
1052 081a C92F mov r28,r25
1053 081c DD27 clr r29
1054 081e FE01 movw r30,r28
1055 0820 33E0 ldi r19,3
1056 0822 EE0F 1: lsl r30
1057 0824 FF1F rol r31
1058 0826 3A95 dec r19
1059 0828 01F4 brne 1b
1060 082a E050 subi r30,lo8(-(Motor))
1061 082c F040 sbci r31,hi8(-(Motor))
1062 082e 3597 sbiw r30,5
1063 0830 8081 ld r24,Z
1064 0832 3596 adiw r30,5
1065 0834 87FD sbrc r24,7
1066 0836 00C0 rjmp .L121
1067 .L141:
1068 0838 82E0 ldi r24,lo8(2)
1069 083a 90E0 ldi r25,hi8(2)
1070 083c 00C0 rjmp .L116
1071 .L121:
1072 083e 3897 sbiw r30,8
1073 0840 8081 ld r24,Z
1074 0842 80FD sbrc r24,0
1075 0844 00C0 rjmp .L122
1076 0846 83E0 ldi r24,lo8(3)
1077 0848 90E0 ldi r25,hi8(3)
1078 084a 00C0 rjmp .L116
1079 .L122:
1080 084c 80ED ldi r24,lo8(2000)
1081 084e 97E0 ldi r25,hi8(2000)
1082 0850 0E94 0000 call SetDelay
1083 0854 8C01 movw r16,r24
1084 .L123:
1085 0856 8091 0000 lds r24,BLFlags
1086 085a 80FD sbrc r24,0
1087 085c 00C0 rjmp .L124
1088 085e C801 movw r24,r16
1089 0860 0E94 0000 call CheckDelay
1090 0864 8823 tst r24
1091 0866 01F0 breq .L123
1092 .L124:
1093 0868 2197 sbiw r28,1
1094 086a 21E0 ldi r18,lo8(1)
1095 086c 30E0 ldi r19,hi8(1)
1096 086e C901 movw r24,r18
1097 0870 00C0 rjmp 2f
1098 0872 880F 1: lsl r24
1099 0874 991F rol r25
1100 0876 CA95 2: dec r28
1101 0878 02F4 brpl 1b
1102 087a 9093 0000 sts (BLConfig_ReadMask)+1,r25
1103 087e 8093 0000 sts BLConfig_ReadMask,r24
1104 0882 D901 movw r26,r18
1105 0884 E0E0 ldi r30,lo8(Motor)
1106 0886 F0E0 ldi r31,hi8(Motor)
1107 0888 40E0 ldi r20,lo8(0)
1108 088a 50E0 ldi r21,hi8(0)
1109 088c 6BE0 ldi r22,lo8(11)
1110 .L130:
1111 088e CD01 movw r24,r26
1112 0890 042E mov r0,r20
1113 0892 00C0 rjmp 2f
1114 0894 880F 1: lsl r24
1115 0896 991F rol r25
1116 0898 0A94 2: dec r0
1117 089a 02F4 brpl 1b
1118 089c 2091 0000 lds r18,BLConfig_ReadMask
1119 08a0 3091 0000 lds r19,(BLConfig_ReadMask)+1
1120 08a4 8223 and r24,r18
1121 08a6 9323 and r25,r19
1122 08a8 892B or r24,r25
1123 08aa 01F0 breq .L128
1124 08ac 1182 std Z+1,__zero_reg__
1125 08ae 1282 std Z+2,__zero_reg__
1126 .L128:
1127 08b0 6150 subi r22,lo8(-(-1))
1128 08b2 4F5F subi r20,lo8(-(1))
1129 08b4 5F4F sbci r21,hi8(-(1))
1130 08b6 3896 adiw r30,8
1131 08b8 67FF sbrs r22,7
1132 08ba 00C0 rjmp .L130
1133 08bc 1092 0000 sts motor_read,__zero_reg__
1134 08c0 1092 0000 sts BLConfig,__zero_reg__
1135 08c4 1092 0000 sts BLConfig+7,__zero_reg__
1136 .L131:
1137 08c8 1092 0000 sts twi_state,__zero_reg__
1138 08cc 8091 0000 lds r24,BLFlags
1139 08d0 8E7F andi r24,lo8(-2)
1140 08d2 8093 0000 sts BLFlags,r24
1141 08d6 85EA ldi r24,lo8(-91)
1142 08d8 8093 BC00 sts 188,r24
1143 .L134:
1144 08dc 8091 0000 lds r24,BLFlags
1145 08e0 80FD sbrc r24,0
1146 08e2 00C0 rjmp .L135
1147 08e4 C801 movw r24,r16
1148 08e6 0E94 0000 call CheckDelay
1149 08ea 8823 tst r24
1150 08ec 01F0 breq .L134
1151 .L135:
1152 08ee 8091 0000 lds r24,BLConfig_ReadMask
1153 08f2 9091 0000 lds r25,(BLConfig_ReadMask)+1
1154 08f6 892B or r24,r25
1155 08f8 01F0 breq .L132
1156 08fa C801 movw r24,r16
1157 08fc 0E94 0000 call CheckDelay
1158 0900 8823 tst r24
1159 0902 01F0 breq .L131
1160 .L132:
1161 0904 8091 0000 lds r24,BLConfig
1162 0908 8230 cpi r24,lo8(2)
1163 090a 01F0 breq .L137
1164 090c 84E0 ldi r24,lo8(4)
1165 090e 90E0 ldi r25,hi8(4)
1166 0910 00C0 rjmp .L116
1167 .L137:
1168 0912 67E0 ldi r22,lo8(7)
1169 0914 70E0 ldi r23,hi8(7)
1170 0916 80E0 ldi r24,lo8(BLConfig)
1171 0918 90E0 ldi r25,hi8(BLConfig)
1172 091a 0E94 0000 call RAM_Checksum
1173 091e 9091 0000 lds r25,BLConfig+7
1174 0922 8917 cp r24,r25
1175 0924 01F0 breq .L138
1176 0926 85E0 ldi r24,lo8(5)
1177 0928 90E0 ldi r25,hi8(5)
1178 092a 00C0 rjmp .L116
1179 .L138:
1180 092c 80E0 ldi r24,lo8(0)
1181 092e 90E0 ldi r25,hi8(0)
1182 .L116:
1183 /* epilogue: frame size=0 */
1184 0930 DF91 pop r29
1185 0932 CF91 pop r28
1186 0934 1F91 pop r17
1187 0936 0F91 pop r16
1188 0938 0895 ret
1189 /* epilogue end (size=5) */
1190 /* function I2C_ReadBLConfig size 168 (159) */
1192 .comm Motor,96,1
1193 .comm BLConfig,8,1
1194 /* File "twimaster.c": code 1214 = 0x04be (1170), prologues 20, epilogues 24 */
DEFINED SYMBOLS
*ABS*:00000000 twimaster.c
C:\Temp/ccpDF3o1.s:3 *ABS*:0000003f __SREG__
C:\Temp/ccpDF3o1.s:4 *ABS*:0000003e __SP_H__
C:\Temp/ccpDF3o1.s:5 *ABS*:0000003d __SP_L__
C:\Temp/ccpDF3o1.s:6 *ABS*:00000000 __tmp_reg__
C:\Temp/ccpDF3o1.s:7 *ABS*:00000001 __zero_reg__
C:\Temp/ccpDF3o1.s:15 .bss:00000000 BLConfig_ReadMask
C:\Temp/ccpDF3o1.s:21 .bss:00000002 BLConfig_WriteMask
C:\Temp/ccpDF3o1.s:27 .bss:00000004 BLFlags
C:\Temp/ccpDF3o1.s:33 .bss:00000005 MissingMotor
C:\Temp/ccpDF3o1.s:39 .data:00000000 I2CTimeout
C:\Temp/ccpDF3o1.s:46 .bss:00000006 I2C_TransferActive
C:\Temp/ccpDF3o1.s:52 .bss:00000007 motor_read
C:\Temp/ccpDF3o1.s:58 .bss:00000008 motor_write
C:\Temp/ccpDF3o1.s:64 .bss:00000009 dac_channel
C:\Temp/ccpDF3o1.s:70 .bss:0000000a twi_state
C:\Temp/ccpDF3o1.s:75 .text:00000000 I2C_Init
*COM*:00000060 Motor
C:\Temp/ccpDF3o1.s:126 .text:00000054 I2C_Reset
.bss:0000000b missing_motor.0
C:\Temp/ccpDF3o1.s:153 .bss:0000000c motor_read_temperature.1
C:\Temp/ccpDF3o1.s:154 .bss:0000000d pBuff.2
C:\Temp/ccpDF3o1.s:155 .bss:0000000f BuffLen.3
C:\Temp/ccpDF3o1.s:159 .text:00000098 __vector_26
*COM*:00000008 BLConfig
C:\Temp/ccpDF3o1.s:853 .text:00000698 I2C_WriteBLConfig
C:\Temp/ccpDF3o1.s:1025 .text:000007ec I2C_ReadBLConfig
UNDEFINED SYMBOLS
__do_copy_data
__do_clear_bss
__tablejump2__
Mixer
RequiredMotors
FC_StatusFlags
AnalogOffsetNick
AnalogOffsetRoll
AnalogOffsetGier
MotorenEin
PC_MotortestActive
RAM_Checksum
SetDelay
CheckDelay