Subversion Repositories FlightCtrl

Rev

Rev 1755 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
1755 - 1
   1               		.file	"spi.c"
1789 - 2
   2               	__SREG__ = 0x3f
3
   3               	__SP_H__ = 0x3e
4
   4               	__SP_L__ = 0x3d
5
   5               	__CCP__  = 0x34
1755 - 6
   6               	__tmp_reg__ = 0
7
   7               	__zero_reg__ = 1
1789 - 8
   8               		.text
9
   9               	.global	SPI_MasterInit
10
  11               	SPI_MasterInit:
11
  12               	/* prologue: function */
12
  13               	/* frame size = 0 */
13
  14 0000 84B1      		in r24,36-32
14
  15 0002 806A      		ori r24,lo8(-96)
15
  16 0004 84B9      		out 36-32,r24
16
  17 0006 3D9A      		sbi 39-32,5
17
  18 0008 82E5      		ldi r24,lo8(82)
18
  19 000a 8CBD      		out 76-32,r24
19
  20 000c 1DBC      		out 77-32,__zero_reg__
20
  21 000e 459A      		sbi 40-32,5
21
  22 0010 81E0      		ldi r24,lo8(1)
22
  23 0012 8093 0000 		sts SPITransferCompleted,r24
23
  24 0016 8AEA      		ldi r24,lo8(-86)
24
  25 0018 8093 0000 		sts ToNaviCtrl,r24
25
  26 001c 83E8      		ldi r24,lo8(-125)
26
  27 001e 8093 0000 		sts ToNaviCtrl+1,r24
27
  28 0022 8AE0      		ldi r24,lo8(10)
28
  29 0024 8093 0000 		sts ToNaviCtrl+2,r24
29
  30 0028 1092 0000 		sts (ToNaviCtrl+3)+1,__zero_reg__
30
  31 002c 1092 0000 		sts ToNaviCtrl+3,__zero_reg__
31
  32 0030 1092 0000 		sts (ToNaviCtrl+5)+1,__zero_reg__
32
  33 0034 1092 0000 		sts ToNaviCtrl+5,__zero_reg__
33
  34 0038 1092 0000 		sts FromNaviCtrl_Value+3,__zero_reg__
34
  35 003c 1092 0000 		sts SPI_RxDataValid,__zero_reg__
35
  36               	/* epilogue start */
36
  37 0040 0895      		ret
37
  39               	.global	UpdateSPI_Buffer
38
  41               	UpdateSPI_Buffer:
39
  42 0042 EF92      		push r14
40
  43 0044 FF92      		push r15
41
  44 0046 0F93      		push r16
42
  45 0048 1F93      		push r17
43
  46               	/* prologue: function */
44
  47               	/* frame size = 0 */
45
  48 004a E090 0000 		lds r14,EE_Parameter+28
46
  49 004e FF24      		clr r15
47
  50 0050 EE0C      		lsl r14
48
  51 0052 FF1C      		rol r15
49
  52 0054 EE0C      		lsl r14
50
  53 0056 FF1C      		rol r15
51
  54 0058 0027      		clr r16
52
  55 005a F7FC      		sbrc r15,7
53
  56 005c 0095      		com r16
54
  57 005e 102F      		mov r17,r16
55
  58 0060 6091 0000 		lds r22,IntegralNick
56
  59 0064 7091 0000 		lds r23,(IntegralNick)+1
57
  60 0068 8091 0000 		lds r24,(IntegralNick)+2
58
  61 006c 9091 0000 		lds r25,(IntegralNick)+3
59
  62 0070 A801      		movw r20,r16
60
  63 0072 9701      		movw r18,r14
61
  64 0074 0E94 0000 		call __divmodsi4
62
  65 0078 3093 0000 		sts (ToNaviCtrl+3)+1,r19
63
  66 007c 2093 0000 		sts ToNaviCtrl+3,r18
64
  67 0080 6091 0000 		lds r22,IntegralRoll
65
  68 0084 7091 0000 		lds r23,(IntegralRoll)+1
66
  69 0088 8091 0000 		lds r24,(IntegralRoll)+2
67
  70 008c 9091 0000 		lds r25,(IntegralRoll)+3
68
  71 0090 A801      		movw r20,r16
69
  72 0092 9701      		movw r18,r14
70
  73 0094 0E94 0000 		call __divmodsi4
71
  74 0098 3093 0000 		sts (ToNaviCtrl+5)+1,r19
72
  75 009c 2093 0000 		sts ToNaviCtrl+5,r18
73
  76 00a0 6091 0000 		lds r22,ErsatzKompass
74
  77 00a4 7091 0000 		lds r23,(ErsatzKompass)+1
75
  78 00a8 8091 0000 		lds r24,(ErsatzKompass)+2
76
  79 00ac 9091 0000 		lds r25,(ErsatzKompass)+3
77
  80 00b0 2AE0      		ldi r18,lo8(10)
78
  81 00b2 30E0      		ldi r19,hi8(10)
79
  82 00b4 40E0      		ldi r20,hlo8(10)
80
  83 00b6 50E0      		ldi r21,hhi8(10)
81
  84 00b8 0E94 0000 		call __mulsi3
82
  85 00bc 2091 0000 		lds r18,GIER_GRAD_FAKTOR
83
  86 00c0 3091 0000 		lds r19,(GIER_GRAD_FAKTOR)+1
84
  87 00c4 4091 0000 		lds r20,(GIER_GRAD_FAKTOR)+2
85
  88 00c8 5091 0000 		lds r21,(GIER_GRAD_FAKTOR)+3
86
  89 00cc 0E94 0000 		call __divmodsi4
87
  90 00d0 3093 0000 		sts (ToNaviCtrl+11)+1,r19
88
  91 00d4 2093 0000 		sts ToNaviCtrl+11,r18
89
  92 00d8 2091 0000 		lds r18,AdWertGier
90
  93 00dc 3091 0000 		lds r19,(AdWertGier)+1
91
  94 00e0 8091 0000 		lds r24,AdNeutralGier
92
  95 00e4 9091 0000 		lds r25,(AdNeutralGier)+1
93
  96 00e8 821B      		sub r24,r18
94
  97 00ea 930B      		sbc r25,r19
95
  98 00ec 9093 0000 		sts (ToNaviCtrl+17)+1,r25
96
  99 00f0 8093 0000 		sts ToNaviCtrl+17,r24
97
 100 00f4 2091 0000 		lds r18,NaviCntAcc
98
 101 00f8 3091 0000 		lds r19,(NaviCntAcc)+1
99
 102 00fc 8091 0000 		lds r24,NaviAccNick
100
 103 0100 9091 0000 		lds r25,(NaviAccNick)+1
101
 104 0104 B901      		movw r22,r18
102
 105 0106 0E94 0000 		call __divmodhi4
103
 106 010a CB01      		movw r24,r22
104
 107 010c 880F      		lsl r24
105
 108 010e 991F      		rol r25
106
 109 0110 860F      		add r24,r22
107
 110 0112 971F      		adc r25,r23
108
 111 0114 880F      		lsl r24
109
 112 0116 991F      		rol r25
110
 113 0118 64E0      		ldi r22,lo8(4)
111
 114 011a 70E0      		ldi r23,hi8(4)
112
 115 011c 0E94 0000 		call __divmodhi4
113
 116 0120 7093 0000 		sts (ToNaviCtrl+7)+1,r23
114
 117 0124 6093 0000 		sts ToNaviCtrl+7,r22
115
 118 0128 8091 0000 		lds r24,NaviAccRoll
116
 119 012c 9091 0000 		lds r25,(NaviAccRoll)+1
117
 120 0130 B901      		movw r22,r18
118
 121 0132 0E94 0000 		call __divmodhi4
119
 122 0136 CB01      		movw r24,r22
120
 123 0138 880F      		lsl r24
121
 124 013a 991F      		rol r25
122
 125 013c 860F      		add r24,r22
123
 126 013e 971F      		adc r25,r23
124
 127 0140 880F      		lsl r24
125
 128 0142 991F      		rol r25
126
 129 0144 64E0      		ldi r22,lo8(4)
127
 130 0146 70E0      		ldi r23,hi8(4)
128
 131 0148 0E94 0000 		call __divmodhi4
129
 132 014c 7093 0000 		sts (ToNaviCtrl+9)+1,r23
130
 133 0150 6093 0000 		sts ToNaviCtrl+9,r22
131
 134 0154 1092 0000 		sts (NaviCntAcc)+1,__zero_reg__
132
 135 0158 1092 0000 		sts NaviCntAcc,__zero_reg__
133
 136 015c 1092 0000 		sts (NaviAccNick)+1,__zero_reg__
134
 137 0160 1092 0000 		sts NaviAccNick,__zero_reg__
135
 138 0164 1092 0000 		sts (NaviAccRoll)+1,__zero_reg__
136
 139 0168 1092 0000 		sts NaviAccRoll,__zero_reg__
137
 140 016c 8091 0000 		lds r24,ToNaviCtrl+2
138
 141 0170 8D30      		cpi r24,lo8(13)
139
 142 0172 01F4      		brne .+2
140
 143 0174 00C0      		rjmp .L8
141
 144 0176 8E30      		cpi r24,lo8(14)
142
 145 0178 00F4      		brsh .L12
143
 146 017a 8B30      		cpi r24,lo8(11)
144
 147 017c 01F4      		brne .+2
145
 148 017e 00C0      		rjmp .L6
146
 149 0180 8C30      		cpi r24,lo8(12)
147
 150 0182 00F0      		brlo .+2
148
 151 0184 00C0      		rjmp .L7
149
 152 0186 8A30      		cpi r24,lo8(10)
150
 153 0188 01F0      		breq .+2
151
 154 018a 00C0      		rjmp .L4
152
 155 018c 00C0      		rjmp .L33
153
 156               	.L12:
154
 157 018e 8F30      		cpi r24,lo8(15)
155
 158 0190 01F4      		brne .+2
156
 159 0192 00C0      		rjmp .L10
157
 160 0194 8F30      		cpi r24,lo8(15)
158
 161 0196 00F4      		brsh .+2
159
 162 0198 00C0      		rjmp .L9
160
 163 019a 8031      		cpi r24,lo8(16)
161
 164 019c 01F0      		breq .+2
162
 165 019e 00C0      		rjmp .L4
163
 166 01a0 00C0      		rjmp .L34
164
 167               	.L33:
165
 168 01a2 8091 0000 		lds r24,Parameter_UserParam1
166
 169 01a6 8093 0000 		sts ToNaviCtrl+19,r24
167
 170 01aa 8091 0000 		lds r24,Parameter_UserParam2
168
 171 01ae 8093 0000 		sts ToNaviCtrl+20,r24
169
 172 01b2 8091 0000 		lds r24,Parameter_UserParam3
170
 173 01b6 8093 0000 		sts ToNaviCtrl+21,r24
171
 174 01ba 8091 0000 		lds r24,Parameter_UserParam4
172
 175 01be 8093 0000 		sts ToNaviCtrl+22,r24
173
 176 01c2 8091 0000 		lds r24,Parameter_UserParam5
174
 177 01c6 8093 0000 		sts ToNaviCtrl+23,r24
175
 178 01ca 8091 0000 		lds r24,Parameter_UserParam6
176
 179 01ce 8093 0000 		sts ToNaviCtrl+24,r24
177
 180 01d2 8091 0000 		lds r24,Parameter_UserParam7
178
 181 01d6 8093 0000 		sts ToNaviCtrl+25,r24
179
 182 01da 8091 0000 		lds r24,Parameter_UserParam8
180
 183 01de 8093 0000 		sts ToNaviCtrl+26,r24
181
 184 01e2 8091 0000 		lds r24,FCFlags
182
 185 01e6 8093 0000 		sts ToNaviCtrl+27,r24
183
 186 01ea 8091 0000 		lds r24,FCFlags
184
 187 01ee 837F      		andi r24,lo8(-13)
185
 188 01f0 8093 0000 		sts FCFlags,r24
186
 189 01f4 0E94 0000 		call GetActiveParamSet
187
 190 01f8 8093 0000 		sts ToNaviCtrl+28,r24
188
 191 01fc 8091 0000 		lds r24,ControlHeading
189
 192 0200 8093 0000 		sts ToNaviCtrl+29,r24
190
 193 0204 00C0      		rjmp .L4
191
 194               	.L34:
192
 195 0206 8091 0000 		lds r24,Capacity
193
 196 020a 9091 0000 		lds r25,(Capacity)+1
194
 197 020e 9093 0000 		sts (ToNaviCtrl+19)+1,r25
195
 198 0212 8093 0000 		sts ToNaviCtrl+19,r24
196
 199 0216 8091 0000 		lds r24,Capacity+4
197
 200 021a 9091 0000 		lds r25,(Capacity+4)+1
198
 201 021e 9093 0000 		sts (ToNaviCtrl+21)+1,r25
199
 202 0222 8093 0000 		sts ToNaviCtrl+21,r24
200
 203 0226 8091 0000 		lds r24,UBat
201
 204 022a 9091 0000 		lds r25,(UBat)+1
202
 205 022e 8093 0000 		sts ToNaviCtrl+23,r24
203
 206 0232 8091 0000 		lds r24,BattLowVoltageWarning
204
 207 0236 8093 0000 		sts ToNaviCtrl+24,r24
205
 208 023a 00C0      		rjmp .L4
206
 209               	.L8:
207
 210 023c 8091 0000 		lds r24,EE_Parameter+78
208
 211 0240 8093 0000 		sts ToNaviCtrl+19,r24
209
 212 0244 8091 0000 		lds r24,EE_Parameter+79
210
 213 0248 8093 0000 		sts ToNaviCtrl+20,r24
211
 214 024c 8091 0000 		lds r24,EE_Parameter+80
212
 215 0250 8093 0000 		sts ToNaviCtrl+21,r24
213
 216 0254 8091 0000 		lds r24,EE_Parameter+81
214
 217 0258 8093 0000 		sts ToNaviCtrl+22,r24
215
 218 025c 8091 0000 		lds r24,EE_Parameter+82
216
 219 0260 8093 0000 		sts ToNaviCtrl+23,r24
217
 220 0264 8091 0000 		lds r24,EE_Parameter+86
218
 221 0268 8093 0000 		sts ToNaviCtrl+24,r24
219
 222 026c 8091 0000 		lds r24,EE_Parameter+87
220
 223 0270 8093 0000 		sts ToNaviCtrl+25,r24
221
 224 0274 8091 0000 		lds r24,EE_Parameter+88
222
 225 0278 8093 0000 		sts ToNaviCtrl+26,r24
223
 226 027c 8091 0000 		lds r24,EE_Parameter+91
224
 227 0280 8093 0000 		sts ToNaviCtrl+27,r24
225
 228 0284 8091 0000 		lds r24,EE_Parameter+89
226
 229 0288 8093 0000 		sts ToNaviCtrl+28,r24
227
 230 028c 8091 0000 		lds r24,EE_Parameter+90
228
 231 0290 8093 0000 		sts ToNaviCtrl+29,r24
229
 232 0294 8091 0000 		lds r24,EE_Parameter+92
230
 233 0298 00C0      		rjmp .L32
231
 234               	.L6:
232
 235               	/* #APP */
233
 236               	 ;  209 "spi.c" 1
234
 237 029a F894      		cli
235
 238               	 ;  0 "" 2
236
 239               	/* #NOAPP */
237
 240 029c E091 0000 		lds r30,EE_Parameter+3
238
 241 02a0 F0E0      		ldi r31,lo8(0)
239
 242 02a2 EE0F      		lsl r30
240
 243 02a4 FF1F      		rol r31
241
 244 02a6 E050      		subi r30,lo8(-(PPM_in))
242
 245 02a8 F040      		sbci r31,hi8(-(PPM_in))
243
 246 02aa 0190      		ld __tmp_reg__,Z+
244
 247 02ac F081      		ld r31,Z
245
 248 02ae E02D      		mov r30,__tmp_reg__
246
 249 02b0 2FEF      		ldi r18,hi8(-127)
247
 250 02b2 E138      		cpi r30,lo8(-127)
248
 251 02b4 F207      		cpc r31,r18
249
 252 02b6 04F4      		brge .L13
250
 253 02b8 E1E8      		ldi r30,lo8(-127)
251
 254 02ba FFEF      		ldi r31,hi8(-127)
252
 255               	.L13:
253
 256 02bc E038      		cpi r30,128
254
 257 02be F105      		cpc r31,__zero_reg__
255
 258 02c0 04F0      		brlt .L14
256
 259 02c2 EFE7      		ldi r30,lo8(127)
257
 260 02c4 F0E0      		ldi r31,hi8(127)
258
 261               	.L14:
259
 262 02c6 E093 0000 		sts ToNaviCtrl+19,r30
260
 263 02ca E091 0000 		lds r30,EE_Parameter+4
261
 264 02ce F0E0      		ldi r31,lo8(0)
262
 265 02d0 EE0F      		lsl r30
263
 266 02d2 FF1F      		rol r31
264
 267 02d4 E050      		subi r30,lo8(-(PPM_in))
265
 268 02d6 F040      		sbci r31,hi8(-(PPM_in))
266
 269 02d8 0190      		ld __tmp_reg__,Z+
267
 270 02da F081      		ld r31,Z
268
 271 02dc E02D      		mov r30,__tmp_reg__
269
 272 02de 6FEF      		ldi r22,hi8(-127)
270
 273 02e0 E138      		cpi r30,lo8(-127)
271
 274 02e2 F607      		cpc r31,r22
272
 275 02e4 04F4      		brge .L15
273
 276 02e6 E1E8      		ldi r30,lo8(-127)
274
 277 02e8 FFEF      		ldi r31,hi8(-127)
275
 278               	.L15:
276
 279 02ea E038      		cpi r30,128
277
 280 02ec F105      		cpc r31,__zero_reg__
278
 281 02ee 04F0      		brlt .L16
279
 282 02f0 EFE7      		ldi r30,lo8(127)
280
 283 02f2 F0E0      		ldi r31,hi8(127)
281
 284               	.L16:
282
 285 02f4 E093 0000 		sts ToNaviCtrl+20,r30
283
 286 02f8 E091 0000 		lds r30,EE_Parameter+2
284
 287 02fc F0E0      		ldi r31,lo8(0)
285
 288 02fe EE0F      		lsl r30
286
 289 0300 FF1F      		rol r31
287
 290 0302 E050      		subi r30,lo8(-(PPM_in))
288
 291 0304 F040      		sbci r31,hi8(-(PPM_in))
289
 292 0306 0190      		ld __tmp_reg__,Z+
290
 293 0308 F081      		ld r31,Z
291
 294 030a E02D      		mov r30,__tmp_reg__
292
 295 030c 8FEF      		ldi r24,hi8(-127)
293
 296 030e E138      		cpi r30,lo8(-127)
294
 297 0310 F807      		cpc r31,r24
295
 298 0312 04F4      		brge .L17
296
 299 0314 E1E8      		ldi r30,lo8(-127)
297
 300 0316 FFEF      		ldi r31,hi8(-127)
298
 301               	.L17:
299
 302 0318 E038      		cpi r30,128
300
 303 031a F105      		cpc r31,__zero_reg__
301
 304 031c 04F0      		brlt .L18
302
 305 031e EFE7      		ldi r30,lo8(127)
303
 306 0320 F0E0      		ldi r31,hi8(127)
304
 307               	.L18:
305
 308 0322 E093 0000 		sts ToNaviCtrl+21,r30
306
 309 0326 E091 0000 		lds r30,EE_Parameter+1
307
 310 032a F0E0      		ldi r31,lo8(0)
308
 311 032c EE0F      		lsl r30
309
 312 032e FF1F      		rol r31
310
 313 0330 E050      		subi r30,lo8(-(PPM_in))
311
 314 0332 F040      		sbci r31,hi8(-(PPM_in))
312
 315 0334 0190      		ld __tmp_reg__,Z+
313
 316 0336 F081      		ld r31,Z
314
 317 0338 E02D      		mov r30,__tmp_reg__
315
 318 033a 2FEF      		ldi r18,hi8(-127)
316
 319 033c E138      		cpi r30,lo8(-127)
317
 320 033e F207      		cpc r31,r18
318
 321 0340 04F4      		brge .L19
319
 322 0342 E1E8      		ldi r30,lo8(-127)
320
 323 0344 FFEF      		ldi r31,hi8(-127)
321
 324               	.L19:
322
 325               	/* #APP */
323
 326               	 ;  217 "spi.c" 1
324
 327 0346 7894      		sei
325
 328               	 ;  0 "" 2
326
 329               	/* #NOAPP */
327
 330 0348 E038      		cpi r30,128
328
 331 034a F105      		cpc r31,__zero_reg__
329
 332 034c 04F0      		brlt .L20
330
 333 034e EFE7      		ldi r30,lo8(127)
331
 334 0350 F0E0      		ldi r31,hi8(127)
332
 335               	.L20:
333
 336 0352 E093 0000 		sts ToNaviCtrl+22,r30
334
 337 0356 8091 0000 		lds r24,Poti
335
 338 035a 8093 0000 		sts ToNaviCtrl+23,r24
336
 339 035e 8091 0000 		lds r24,Poti+1
337
 340 0362 8093 0000 		sts ToNaviCtrl+24,r24
338
 341 0366 8091 0000 		lds r24,Poti+2
339
 342 036a 8093 0000 		sts ToNaviCtrl+25,r24
340
 343 036e 8091 0000 		lds r24,Poti+3
341
 344 0372 8093 0000 		sts ToNaviCtrl+26,r24
342
 345 0376 8091 0000 		lds r24,Poti+4
343
 346 037a 8093 0000 		sts ToNaviCtrl+27,r24
344
 347 037e 8091 0000 		lds r24,Poti+5
345
 348 0382 8093 0000 		sts ToNaviCtrl+28,r24
346
 349 0386 8091 0000 		lds r24,Poti+6
347
 350 038a 8093 0000 		sts ToNaviCtrl+29,r24
348
 351 038e 8091 0000 		lds r24,Poti+7
349
 352               	.L32:
350
 353 0392 8093 0000 		sts ToNaviCtrl+30,r24
351
 354 0396 00C0      		rjmp .L4
352
 355               	.L7:
353
 356 0398 8091 0000 		lds r24,WinkelOut+6
354
 357 039c 8630      		cpi r24,lo8(6)
355
 358 039e 00F0      		brlo .L21
356
 359 03a0 1092 0000 		sts WinkelOut+6,__zero_reg__
357
 360 03a4 85E0      		ldi r24,lo8(5)
358
 361               	.L21:
359
 362 03a6 8093 0000 		sts ToNaviCtrl+19,r24
360
 363 03aa 8091 0000 		lds r24,EE_Parameter+93
361
 364 03ae 8093 0000 		sts ToNaviCtrl+20,r24
362
 365 03b2 6091 0000 		lds r22,HoehenWert
363
 366 03b6 7091 0000 		lds r23,(HoehenWert)+1
364
 367 03ba 8091 0000 		lds r24,(HoehenWert)+2
365
 368 03be 9091 0000 		lds r25,(HoehenWert)+3
366
 369 03c2 25E0      		ldi r18,lo8(5)
367
 370 03c4 30E0      		ldi r19,hi8(5)
368
 371 03c6 40E0      		ldi r20,hlo8(5)
369
 372 03c8 50E0      		ldi r21,hhi8(5)
370
 373 03ca 0E94 0000 		call __divmodsi4
371
 374 03ce 3093 0000 		sts (ToNaviCtrl+21)+1,r19
372
 375 03d2 2093 0000 		sts ToNaviCtrl+21,r18
373
 376 03d6 6091 0000 		lds r22,SollHoehe
374
 377 03da 7091 0000 		lds r23,(SollHoehe)+1
375
 378 03de 8091 0000 		lds r24,(SollHoehe)+2
376
 379 03e2 9091 0000 		lds r25,(SollHoehe)+3
377
 380 03e6 25E0      		ldi r18,lo8(5)
378
 381 03e8 30E0      		ldi r19,hi8(5)
379
 382 03ea 40E0      		ldi r20,hlo8(5)
380
 383 03ec 50E0      		ldi r21,hhi8(5)
381
 384 03ee 0E94 0000 		call __divmodsi4
382
 385 03f2 3093 0000 		sts (ToNaviCtrl+23)+1,r19
383
 386 03f6 2093 0000 		sts ToNaviCtrl+23,r18
384
 387 03fa 8091 0000 		lds r24,EE_Parameter+83
385
 388 03fe 8093 0000 		sts ToNaviCtrl+25,r24
386
 389 0402 8091 0000 		lds r24,EE_Parameter+84
387
 390 0406 8093 0000 		sts ToNaviCtrl+26,r24
388
 391 040a 8091 0000 		lds r24,EE_Parameter+85
389
 392 040e 8093 0000 		sts ToNaviCtrl+27,r24
390
 393 0412 8091 0000 		lds r24,SenderOkay
391
 394 0416 8093 0000 		sts ToNaviCtrl+28,r24
392
 395 041a 8091 0000 		lds r24,PPM_in
393
 396 041e 9091 0000 		lds r25,(PPM_in)+1
394
 397 0422 8093 0000 		sts ToNaviCtrl+29,r24
395
 398 0426 8091 0000 		lds r24,DebugOut+16
396
 399 042a 9091 0000 		lds r25,(DebugOut+16)+1
397
 400 042e 64E0      		ldi r22,lo8(4)
398
 401 0430 70E0      		ldi r23,hi8(4)
399
 402 0432 0E94 0000 		call __divmodhi4
400
 403 0436 6093 0000 		sts ToNaviCtrl+30,r22
401
 404 043a 00C0      		rjmp .L4
402
 405               	.L9:
403
 406 043c 1092 0000 		sts ToNaviCtrl+19,__zero_reg__
404
 407 0440 80E5      		ldi r24,lo8(80)
405
 408 0442 8093 0000 		sts ToNaviCtrl+20,r24
406
 409 0446 86E0      		ldi r24,lo8(6)
407
 410 0448 8093 0000 		sts ToNaviCtrl+21,r24
408
 411 044c 8EE0      		ldi r24,lo8(14)
409
 412 044e 8093 0000 		sts ToNaviCtrl+22,r24
410
 413 0452 8091 0000 		lds r24,PlatinenVersion
411
 414 0456 8093 0000 		sts ToNaviCtrl+23,r24
412
 415 045a 8091 0000 		lds r24,VersionInfo+5
413
 416 045e 8093 0000 		sts ToNaviCtrl+24,r24
414
 417 0462 8091 0000 		lds r24,VersionInfo+6
415
 418 0466 8093 0000 		sts ToNaviCtrl+25,r24
416
 419 046a 8091 0000 		lds r24,VersionInfo+7
417
 420 046e 8093 0000 		sts ToNaviCtrl+26,r24
418
 421 0472 00C0      		rjmp .L4
419
 422               	.L10:
420
 423 0474 8091 0000 		lds r24,EE_Parameter+53
421
 424 0478 8093 0000 		sts ToNaviCtrl+19,r24
422
 425 047c 8091 0000 		lds r24,EE_Parameter+98
423
 426 0480 8093 0000 		sts ToNaviCtrl+20,r24
424
 427 0484 8091 0000 		lds r24,Parameter_ServoNickControl
425
 428 0488 8093 0000 		sts ToNaviCtrl+21,r24
426
 429 048c 8091 0000 		lds r24,EE_Parameter+46
427
 430 0490 8093 0000 		sts ToNaviCtrl+22,r24
428
 431 0494 8091 0000 		lds r24,EE_Parameter+47
429
 432 0498 8093 0000 		sts ToNaviCtrl+23,r24
430
 433 049c 8091 0000 		lds r24,EE_Parameter+48
431
 434 04a0 8093 0000 		sts ToNaviCtrl+24,r24
432
 435 04a4 8091 0000 		lds r24,Parameter_ServoRollControl
433
 436 04a8 8093 0000 		sts ToNaviCtrl+25,r24
434
 437 04ac 8091 0000 		lds r24,EE_Parameter+50
435
 438 04b0 8093 0000 		sts ToNaviCtrl+26,r24
436
 439 04b4 8091 0000 		lds r24,EE_Parameter+51
437
 440 04b8 8093 0000 		sts ToNaviCtrl+27,r24
438
 441 04bc 8091 0000 		lds r24,EE_Parameter+52
439
 442 04c0 8093 0000 		sts ToNaviCtrl+28,r24
440
 443               	.L4:
441
 444 04c4 8091 0000 		lds r24,SPI_RxDataValid
442
 445 04c8 8823      		tst r24
443
 446 04ca 01F4      		brne .+2
444
 447 04cc 00C0      		rjmp .L23
445
 448 04ce 8AEF      		ldi r24,lo8(-6)
446
 449 04d0 8093 0000 		sts NaviDataOkay,r24
447
 450 04d4 4091 0000 		lds r20,FromNaviCtrl+1
448
 451 04d8 5091 0000 		lds r21,(FromNaviCtrl+1)+1
449
 452 04dc CA01      		movw r24,r20
450
 453 04de 8150      		subi r24,lo8(-(511))
451
 454 04e0 9E4F      		sbci r25,hi8(-(511))
452
 455 04e2 8F5F      		subi r24,lo8(1023)
453
 456 04e4 9340      		sbci r25,hi8(1023)
454
 457 04e6 00F4      		brsh .L24
455
 458 04e8 2091 0000 		lds r18,FromNaviCtrl+3
456
 459 04ec 3091 0000 		lds r19,(FromNaviCtrl+3)+1
457
 460 04f0 C901      		movw r24,r18
458
 461 04f2 8150      		subi r24,lo8(-(511))
459
 462 04f4 9E4F      		sbci r25,hi8(-(511))
460
 463 04f6 8F5F      		subi r24,lo8(1023)
461
 464 04f8 9340      		sbci r25,hi8(1023)
462
 465 04fa 00F4      		brsh .L24
463
 466 04fc 8091 0000 		lds r24,EE_Parameter+13
464
 467 0500 85FF      		sbrs r24,5
465
 468 0502 00C0      		rjmp .L24
466
 469 0504 5093 0000 		sts (GPS_Nick)+1,r21
467
 470 0508 4093 0000 		sts GPS_Nick,r20
468
 471 050c 3093 0000 		sts (GPS_Roll)+1,r19
469
 472 0510 2093 0000 		sts GPS_Roll,r18
470
 473               	.L24:
471
 474 0514 8091 0000 		lds r24,FromNaviCtrl+7
472
 475 0518 9091 0000 		lds r25,(FromNaviCtrl+7)+1
473
 476 051c 21E0      		ldi r18,hi8(361)
474
 477 051e 8936      		cpi r24,lo8(361)
475
 478 0520 9207      		cpc r25,r18
476
 479 0522 04F4      		brge .L25
477
 480 0524 9093 0000 		sts (KompassValue)+1,r25
478
 481 0528 8093 0000 		sts KompassValue,r24
479
 482               	.L25:
480
 483 052c 8091 0000 		lds r24,KompassValue
481
 484 0530 9091 0000 		lds r25,(KompassValue)+1
482
 485 0534 845E      		subi r24,lo8(-(540))
483
 486 0536 9D4F      		sbci r25,hi8(-(540))
484
 487 0538 2091 0000 		lds r18,KompassStartwert
485
 488 053c 3091 0000 		lds r19,(KompassStartwert)+1
486
 489 0540 821B      		sub r24,r18
487
 490 0542 930B      		sbc r25,r19
488
 491 0544 68E6      		ldi r22,lo8(360)
489
 492 0546 71E0      		ldi r23,hi8(360)
490
 493 0548 0E94 0000 		call __divmodhi4
491
 494 054c 845B      		subi r24,lo8(-(-180))
492
 495 054e 9040      		sbci r25,hi8(-(-180))
493
 496 0550 9093 0000 		sts (KompassRichtung)+1,r25
494
 497 0554 8093 0000 		sts KompassRichtung,r24
495
 498 0558 2091 0000 		lds r18,FromNaviCtrl+11
496
 499 055c 3091 0000 		lds r19,(FromNaviCtrl+11)+1
497
 500 0560 8091 0000 		lds r24,beeptime
498
 501 0564 9091 0000 		lds r25,(beeptime)+1
499
 502 0568 8217      		cp r24,r18
500
 503 056a 9307      		cpc r25,r19
501
 504 056c 00F4      		brsh .L26
502
 505 056e 8091 0000 		lds r24,WinkelOut+6
503
 506 0572 8823      		tst r24
504
 507 0574 01F4      		brne .L26
505
 508 0576 3093 0000 		sts (beeptime)+1,r19
506
 509 057a 2093 0000 		sts beeptime,r18
507
 510               	.L26:
508
 511 057e 8091 0000 		lds r24,FromNaviCtrl
509
 512 0582 8836      		cpi r24,lo8(104)
510
 513 0584 01F0      		breq .L29
511
 514 0586 8936      		cpi r24,lo8(105)
512
 515 0588 01F4      		brne .+2
513
 516 058a 00C0      		rjmp .L30
514
 517 058c 8736      		cpi r24,lo8(103)
515
 518 058e 01F0      		breq .+2
516
 519 0590 00C0      		rjmp .L31
517
 520 0592 8091 0000 		lds r24,FromNaviCtrl+13
518
 521 0596 8093 0000 		sts FromNaviCtrl_Value,r24
519
 522 059a 8091 0000 		lds r24,FromNaviCtrl+14
520
 523 059e 8093 0000 		sts FromNaviCtrl_Value+2,r24
521
 524 05a2 8091 0000 		lds r24,FromNaviCtrl+15
522
 525 05a6 8093 0000 		sts FromNaviCtrl_Value+1,r24
523
 526 05aa 8091 0000 		lds r24,FromNaviCtrl+16
524
 527 05ae 8093 0000 		sts FromNaviCtrl_Value+3,r24
525
 528 05b2 8091 0000 		lds r24,FromNaviCtrl+17
526
 529 05b6 8093 0000 		sts FromNaviCtrl_Value+4,r24
527
 530 05ba 8091 0000 		lds r24,FromNaviCtrl+18
528
 531 05be 8093 0000 		sts FromNC_Rotate_C,r24
529
 532 05c2 8091 0000 		lds r24,FromNaviCtrl+19
530
 533 05c6 8093 0000 		sts FromNC_Rotate_S,r24
531
 534 05ca 00C0      		rjmp .L31
532
 535               	.L29:
533
 536 05cc 8091 0000 		lds r24,FromNaviCtrl+13
534
 537 05d0 8093 0000 		sts NC_Version,r24
535
 538 05d4 8091 0000 		lds r24,FromNaviCtrl+14
536
 539 05d8 8093 0000 		sts NC_Version+1,r24
537
 540 05dc 8091 0000 		lds r24,FromNaviCtrl+15
538
 541 05e0 8093 0000 		sts NC_Version+2,r24
539
 542 05e4 8091 0000 		lds r24,FromNaviCtrl+16
540
 543 05e8 8093 0000 		sts NC_Version+3,r24
541
 544 05ec 8091 0000 		lds r24,FromNaviCtrl+17
542
 545 05f0 8093 0000 		sts NC_Version+4,r24
543
 546 05f4 8091 0000 		lds r24,FromNaviCtrl+18
544
 547 05f8 9091 0000 		lds r25,DebugOut
545
 548 05fc 892B      		or r24,r25
546
 549 05fe 8093 0000 		sts DebugOut,r24
547
 550 0602 9091 0000 		lds r25,FromNaviCtrl+19
548
 551 0606 9093 0000 		sts NC_ErrorCode,r25
549
 552 060a 9C70      		andi r25,lo8(12)
550
 553 060c 8091 0000 		lds r24,DebugOut+1
551
 554 0610 8370      		andi r24,lo8(3)
552
 555 0612 982B      		or r25,r24
553
 556 0614 9093 0000 		sts DebugOut+1,r25
554
 557 0618 00C0      		rjmp .L31
555
 558               	.L30:
556
 559 061a 8091 0000 		lds r24,FromNaviCtrl+13
557
 560 061e 8093 0000 		sts GPSInfo,r24
558
 561 0622 8091 0000 		lds r24,FromNaviCtrl+14
559
 562 0626 8093 0000 		sts GPSInfo+1,r24
560
 563 062a 8091 0000 		lds r24,FromNaviCtrl+15
561
 564 062e 8093 0000 		sts GPSInfo+2,r24
562
 565 0632 8091 0000 		lds r24,FromNaviCtrl+16
563
 566 0636 8093 0000 		sts GPSInfo+3,r24
564
 567 063a 8091 0000 		lds r24,FromNaviCtrl+17
565
 568 063e 9091 0000 		lds r25,(FromNaviCtrl+17)+1
566
 569 0642 9093 0000 		sts (GPSInfo+4)+1,r25
567
 570 0646 8093 0000 		sts GPSInfo+4,r24
568
 571 064a 8091 0000 		lds r24,FromNaviCtrl+19
569
 572 064e 9091 0000 		lds r25,(FromNaviCtrl+19)+1
570
 573 0652 9093 0000 		sts (GPSInfo+6)+1,r25
571
 574 0656 8093 0000 		sts GPSInfo+6,r24
572
 575 065a 00C0      		rjmp .L31
573
 576               	.L23:
574
 577 065c 1092 0000 		sts (GPS_Nick)+1,__zero_reg__
575
 578 0660 1092 0000 		sts GPS_Nick,__zero_reg__
576
 579 0664 1092 0000 		sts (GPS_Roll)+1,__zero_reg__
577
 580 0668 1092 0000 		sts GPS_Roll,__zero_reg__
578
 581               	.L31:
579
 582               	/* epilogue start */
580
 583 066c 1F91      		pop r17
581
 584 066e 0F91      		pop r16
582
 585 0670 FF90      		pop r15
583
 586 0672 EF90      		pop r14
584
 587 0674 0895      		ret
585
 589               	.global	SPI_StartTransmitPacket
586
 591               	SPI_StartTransmitPacket:
587
 592               	/* prologue: function */
588
 593               	/* frame size = 0 */
589
 594 0676 8091 0000 		lds r24,SPITransferCompleted
590
 595 067a 8823      		tst r24
591
 596 067c 01F4      		brne .+2
592
 597 067e 00C0      		rjmp .L38
593
 598 0680 4598      		cbi 40-32,5
594
 599 0682 80E0      		ldi r24,lo8(ToNaviCtrl)
595
 600 0684 90E0      		ldi r25,hi8(ToNaviCtrl)
596
 601 0686 9093 0000 		sts (SPI_TX_Buffer)+1,r25
597
 602 068a 8093 0000 		sts SPI_TX_Buffer,r24
598
 603 068e 9091 0000 		lds r25,SPI_CommandCounter
599
 604 0692 E92F      		mov r30,r25
600
 605 0694 F0E0      		ldi r31,lo8(0)
601
 606 0696 E050      		subi r30,lo8(-(SPI_CommandSequence))
602
 607 0698 F040      		sbci r31,hi8(-(SPI_CommandSequence))
603
 608 069a 8081      		ld r24,Z
604
 609 069c 8093 0000 		sts ToNaviCtrl+2,r24
605
 610 06a0 9F5F      		subi r25,lo8(-(1))
606
 611 06a2 9093 0000 		sts SPI_CommandCounter,r25
607
 612 06a6 9930      		cpi r25,lo8(9)
608
 613 06a8 00F0      		brlo .L37
609
 614 06aa 1092 0000 		sts SPI_CommandCounter,__zero_reg__
610
 615               	.L37:
611
 616 06ae 1092 0000 		sts SPITransferCompleted,__zero_reg__
612
 617 06b2 0E94 0000 		call UpdateSPI_Buffer
613
 618 06b6 81E0      		ldi r24,lo8(1)
614
 619 06b8 8093 0000 		sts SPI_BufferIndex,r24
615
 620               	/* #APP */
616
 621               	 ;  75 "spi.c" 1
617
 622 06bc 0000      		nop
618
 623               	 ;  0 "" 2
619
 624               	 ;  75 "spi.c" 1
620
 625 06be 0000      		nop
621
 626               	 ;  0 "" 2
622
 627               	 ;  75 "spi.c" 1
623
 628 06c0 0000      		nop
624
 629               	 ;  0 "" 2
625
 630               	 ;  75 "spi.c" 1
626
 631 06c2 0000      		nop
627
 632               	 ;  0 "" 2
628
 633               	 ;  75 "spi.c" 1
629
 634 06c4 0000      		nop
630
 635               	 ;  0 "" 2
631
 636               	 ;  75 "spi.c" 1
632
 637 06c6 0000      		nop
633
 638               	 ;  0 "" 2
634
 639               	 ;  75 "spi.c" 1
635
 640 06c8 0000      		nop
636
 641               	 ;  0 "" 2
637
 642               	 ;  75 "spi.c" 1
638
 643 06ca 0000      		nop
639
 644               	 ;  0 "" 2
640
 645               	 ;  76 "spi.c" 1
641
 646 06cc 0000      		nop
642
 647               	 ;  0 "" 2
643
 648               	 ;  76 "spi.c" 1
644
 649 06ce 0000      		nop
645
 650               	 ;  0 "" 2
646
 651               	 ;  76 "spi.c" 1
647
 652 06d0 0000      		nop
648
 653               	 ;  0 "" 2
649
 654               	 ;  76 "spi.c" 1
650
 655 06d2 0000      		nop
651
 656               	 ;  0 "" 2
652
 657               	 ;  76 "spi.c" 1
653
 658 06d4 0000      		nop
654
 659               	 ;  0 "" 2
655
 660               	 ;  76 "spi.c" 1
656
 661 06d6 0000      		nop
657
 662               	 ;  0 "" 2
658
 663               	 ;  76 "spi.c" 1
659
 664 06d8 0000      		nop
660
 665               	 ;  0 "" 2
661
 666               	 ;  76 "spi.c" 1
662
 667 06da 0000      		nop
663
 668               	 ;  0 "" 2
664
 669               	 ;  77 "spi.c" 1
665
 670 06dc 0000      		nop
666
 671               	 ;  0 "" 2
667
 672               	 ;  77 "spi.c" 1
668
 673 06de 0000      		nop
669
 674               	 ;  0 "" 2
670
 675               	 ;  77 "spi.c" 1
671
 676 06e0 0000      		nop
672
 677               	 ;  0 "" 2
673
 678               	 ;  77 "spi.c" 1
674
 679 06e2 0000      		nop
675
 680               	 ;  0 "" 2
676
 681               	 ;  77 "spi.c" 1
677
 682 06e4 0000      		nop
678
 683               	 ;  0 "" 2
679
 684               	 ;  77 "spi.c" 1
680
 685 06e6 0000      		nop
681
 686               	 ;  0 "" 2
682
 687               	 ;  77 "spi.c" 1
683
 688 06e8 0000      		nop
684
 689               	 ;  0 "" 2
685
 690               	 ;  77 "spi.c" 1
686
 691 06ea 0000      		nop
687
 692               	 ;  0 "" 2
688
 693               	/* #NOAPP */
689
 694 06ec 8091 0000 		lds r24,ToNaviCtrl
690
 695 06f0 8093 0000 		sts ToNaviCtrl+31,r24
691
 696 06f4 8EBD      		out 78-32,r24
692
 697               	.L38:
693
 698 06f6 0895      		ret
694
 700               	.global	SPI_TransmitByte
695
 702               	SPI_TransmitByte:
696
 703               	/* prologue: function */
697
 704               	/* frame size = 0 */
698
 705 06f8 8091 0000 		lds r24,SPITransferCompleted
699
 706 06fc 8823      		tst r24
700
 707 06fe 01F0      		breq .+2
701
 708 0700 00C0      		rjmp .L52
702
 709 0702 0DB4      		in __tmp_reg__,77-32
703
 710 0704 07FE      		sbrs __tmp_reg__,7
704
 711 0706 00C0      		rjmp .L52
705
 712 0708 84E0      		ldi r24,lo8(4)
706
 713 070a 8093 0000 		sts SendSPI,r24
707
 714 070e 459A      		sbi 40-32,5
708
 715 0710 2EB5      		in r18,78-32
709
 716 0712 8091 0000 		lds r24,SPI_RXState.2259
710
 717 0716 8130      		cpi r24,lo8(1)
711
 718 0718 01F0      		breq .L43
712
 719 071a 8130      		cpi r24,lo8(1)
713
 720 071c 00F0      		brlo .L42
714
 721 071e 8230      		cpi r24,lo8(2)
715
 722 0720 01F4      		brne .L41
716
 723 0722 00C0      		rjmp .L55
717
 724               	.L42:
718
 725 0724 1092 0000 		sts SPI_RxBufferIndex,__zero_reg__
719
 726 0728 2093 0000 		sts rxchksum.2261,r18
720
 727 072c 2138      		cpi r18,lo8(-127)
721
 728 072e 01F4      		brne .L41
722
 729 0730 81E0      		ldi r24,lo8(1)
723
 730 0732 00C0      		rjmp .L54
724
 731               	.L43:
725
 732 0734 2535      		cpi r18,lo8(85)
726
 733 0736 01F4      		brne .L49
727
 734 0738 8091 0000 		lds r24,rxchksum.2261
728
 735 073c 8B5A      		subi r24,lo8(-(85))
729
 736 073e 8093 0000 		sts rxchksum.2261,r24
730
 737 0742 82E0      		ldi r24,lo8(2)
731
 738               	.L54:
732
 739 0744 8093 0000 		sts SPI_RXState.2259,r24
733
 740 0748 00C0      		rjmp .L41
734
 741               	.L55:
735
 742 074a 8091 0000 		lds r24,SPI_RxBufferIndex
736
 743 074e E82F      		mov r30,r24
737
 744 0750 F0E0      		ldi r31,lo8(0)
738
 745 0752 E050      		subi r30,lo8(-(SPI_Buffer))
739
 746 0754 F040      		sbci r31,hi8(-(SPI_Buffer))
740
 747 0756 2083      		st Z,r18
741
 748 0758 8F5F      		subi r24,lo8(-(1))
742
 749 075a 8093 0000 		sts SPI_RxBufferIndex,r24
743
 750 075e 9091 0000 		lds r25,rxchksum.2261
744
 751 0762 8A31      		cpi r24,lo8(26)
745
 752 0764 00F0      		brlo .L46
746
 753 0766 2917      		cp r18,r25
747
 754 0768 01F4      		brne .L47
748
 755 076a A0E0      		ldi r26,lo8(FromNaviCtrl)
749
 756 076c B0E0      		ldi r27,hi8(FromNaviCtrl)
750
 757 076e E0E0      		ldi r30,lo8(SPI_Buffer)
751
 758 0770 F0E0      		ldi r31,hi8(SPI_Buffer)
752
 759 0772 8AE1      		ldi r24,lo8(26)
753
 760               	.L48:
754
 761 0774 0190      		ld r0,Z+
755
 762 0776 0D92      		st X+,r0
756
 763 0778 8150      		subi r24,lo8(-(-1))
757
 764 077a 01F4      		brne .L48
758
 765 077c 81E0      		ldi r24,lo8(1)
759
 766 077e 8093 0000 		sts SPI_RxDataValid,r24
760
 767 0782 00C0      		rjmp .L49
761
 768               	.L47:
762
 769 0784 1092 0000 		sts SPI_RxDataValid,__zero_reg__
763
 770               	.L49:
764
 771 0788 1092 0000 		sts SPI_RXState.2259,__zero_reg__
765
 772 078c 00C0      		rjmp .L41
766
 773               	.L46:
767
 774 078e 920F      		add r25,r18
768
 775 0790 9093 0000 		sts rxchksum.2261,r25
769
 776               	.L41:
770
 777 0794 2091 0000 		lds r18,SPI_BufferIndex
771
 778 0798 2032      		cpi r18,lo8(32)
772
 779 079a 00F0      		brlo .+2
773
 780 079c 00C0      		rjmp .L50
774
 781 079e 4598      		cbi 40-32,5
775
 782               	/* #APP */
776
 783               	 ;  141 "spi.c" 1
777
 784 07a0 0000      		nop
778
 785               	 ;  0 "" 2
779
 786               	 ;  141 "spi.c" 1
780
 787 07a2 0000      		nop
781
 788               	 ;  0 "" 2
782
 789               	 ;  141 "spi.c" 1
783
 790 07a4 0000      		nop
784
 791               	 ;  0 "" 2
785
 792               	 ;  141 "spi.c" 1
786
 793 07a6 0000      		nop
787
 794               	 ;  0 "" 2
788
 795               	 ;  141 "spi.c" 1
789
 796 07a8 0000      		nop
790
 797               	 ;  0 "" 2
791
 798               	 ;  141 "spi.c" 1
792
 799 07aa 0000      		nop
793
 800               	 ;  0 "" 2
794
 801               	 ;  141 "spi.c" 1
795
 802 07ac 0000      		nop
796
 803               	 ;  0 "" 2
797
 804               	 ;  141 "spi.c" 1
798
 805 07ae 0000      		nop
799
 806               	 ;  0 "" 2
800
 807               	 ;  142 "spi.c" 1
801
 808 07b0 0000      		nop
802
 809               	 ;  0 "" 2
803
 810               	 ;  142 "spi.c" 1
804
 811 07b2 0000      		nop
805
 812               	 ;  0 "" 2
806
 813               	 ;  142 "spi.c" 1
807
 814 07b4 0000      		nop
808
 815               	 ;  0 "" 2
809
 816               	 ;  142 "spi.c" 1
810
 817 07b6 0000      		nop
811
 818               	 ;  0 "" 2
812
 819               	 ;  142 "spi.c" 1
813
 820 07b8 0000      		nop
814
 821               	 ;  0 "" 2
815
 822               	 ;  142 "spi.c" 1
816
 823 07ba 0000      		nop
817
 824               	 ;  0 "" 2
818
 825               	 ;  142 "spi.c" 1
819
 826 07bc 0000      		nop
820
 827               	 ;  0 "" 2
821
 828               	 ;  142 "spi.c" 1
822
 829 07be 0000      		nop
823
 830               	 ;  0 "" 2
824
 831               	 ;  143 "spi.c" 1
825
 832 07c0 0000      		nop
826
 833               	 ;  0 "" 2
827
 834               	 ;  143 "spi.c" 1
828
 835 07c2 0000      		nop
829
 836               	 ;  0 "" 2
830
 837               	 ;  143 "spi.c" 1
831
 838 07c4 0000      		nop
832
 839               	 ;  0 "" 2
833
 840               	 ;  143 "spi.c" 1
834
 841 07c6 0000      		nop
835
 842               	 ;  0 "" 2
836
 843               	 ;  143 "spi.c" 1
837
 844 07c8 0000      		nop
838
 845               	 ;  0 "" 2
839
 846               	 ;  143 "spi.c" 1
840
 847 07ca 0000      		nop
841
 848               	 ;  0 "" 2
842
 849               	 ;  143 "spi.c" 1
843
 850 07cc 0000      		nop
844
 851               	 ;  0 "" 2
845
 852               	 ;  143 "spi.c" 1
846
 853 07ce 0000      		nop
847
 854               	 ;  0 "" 2
848
 855               	/* #NOAPP */
849
 856 07d0 E091 0000 		lds r30,SPI_TX_Buffer
850
 857 07d4 F091 0000 		lds r31,(SPI_TX_Buffer)+1
851
 858 07d8 E20F      		add r30,r18
852
 859 07da F11D      		adc r31,__zero_reg__
853
 860 07dc 8081      		ld r24,Z
854
 861 07de 8EBD      		out 78-32,r24
855
 862 07e0 9091 0000 		lds r25,ToNaviCtrl+31
856
 863 07e4 890F      		add r24,r25
857
 864 07e6 8093 0000 		sts ToNaviCtrl+31,r24
858
 865 07ea 00C0      		rjmp .L51
859
 866               	.L50:
860
 867 07ec 81E0      		ldi r24,lo8(1)
861
 868 07ee 8093 0000 		sts SPITransferCompleted,r24
862
 869               	.L51:
863
 870 07f2 2F5F      		subi r18,lo8(-(1))
864
 871 07f4 2093 0000 		sts SPI_BufferIndex,r18
865
 872               	.L52:
866
 873 07f8 0895      		ret
867
 875               	.global	FromNC_Rotate_C
868
 876               		.data
869
 879               	FromNC_Rotate_C:
870
 880 0000 20        		.byte	32
871
 881               	.global	FromNC_Rotate_S
872
 882               	.global	FromNC_Rotate_S
873
 883               		.section .bss
874
 886               	FromNC_Rotate_S:
875
 887 0000 00        		.skip 1,0
876
 888               	.global	NaviDataOkay
877
 889               		.data
878
 892               	NaviDataOkay:
879
 893 0001 FA        		.byte	-6
880
 894               	.global	SPI_CommandSequence
881
 897               	SPI_CommandSequence:
882
 898 0002 0B        		.byte	11
883
 899 0003 0A        		.byte	10
884
 900 0004 0D        		.byte	13
885
 901 0005 0B        		.byte	11
886
 902 0006 0C        		.byte	12
887
 903 0007 0E        		.byte	14
888
 904 0008 0B        		.byte	11
889
 905 0009 0F        		.byte	15
890
 906 000a 10        		.byte	16
891
 907               	.global	SPI_CommandCounter
892
 908               	.global	SPI_CommandCounter
893
 909               		.section .bss
894
 912               	SPI_CommandCounter:
895
 913 0001 00        		.skip 1,0
896
 914               	.global	NC_ErrorCode
897
 915               	.global	NC_ErrorCode
898
 918               	NC_ErrorCode:
899
 919 0002 00        		.skip 1,0
900
 920               		.lcomm rxchksum.2261,1
901
 921               		.lcomm SPI_RXState.2259,1
902
 922               		.comm GPSInfo,8,1
903
 923               		.comm NC_Version,5,1
904
 924               		.comm FromNaviCtrl_Value,5,1
905
 925               		.comm ToNaviCtrl,32,1
906
 926               		.comm FromNaviCtrl,26,1
907
 927               		.comm SPI_BufferIndex,1,1
908
 928               		.comm SPI_RxBufferIndex,1,1
909
 929               		.comm SPI_Buffer,26,1
910
 930               		.comm SPI_TX_Buffer,2,1
911
 931               		.comm SPITransferCompleted,1,1
912
 932               		.comm SPI_ChkSum,1,1
913
 933               		.comm SPI_RxDataValid,1,1
914
 934               	.global __do_copy_data
915
 935               	.global __do_clear_bss
1755 - 916
DEFINED SYMBOLS
917
                            *ABS*:00000000 spi.c
1789 - 918
C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp/ccV068Pj.s:2      *ABS*:0000003f __SREG__
919
C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp/ccV068Pj.s:3      *ABS*:0000003e __SP_H__
920
C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp/ccV068Pj.s:4      *ABS*:0000003d __SP_L__
921
C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp/ccV068Pj.s:5      *ABS*:00000034 __CCP__
922
C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp/ccV068Pj.s:6      *ABS*:00000000 __tmp_reg__
923
C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp/ccV068Pj.s:7      *ABS*:00000001 __zero_reg__
924
C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp/ccV068Pj.s:11     .text:00000000 SPI_MasterInit
1755 - 925
                            *COM*:00000001 SPITransferCompleted
926
                            *COM*:00000020 ToNaviCtrl
927
                            *COM*:00000005 FromNaviCtrl_Value
928
                            *COM*:00000001 SPI_RxDataValid
1789 - 929
C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp/ccV068Pj.s:41     .text:00000042 UpdateSPI_Buffer
930
C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp/ccV068Pj.s:892    .data:00000001 NaviDataOkay
1755 - 931
                            *COM*:0000001a FromNaviCtrl
1789 - 932
C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp/ccV068Pj.s:879    .data:00000000 FromNC_Rotate_C
933
C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp/ccV068Pj.s:886    .bss:00000000 FromNC_Rotate_S
1755 - 934
                            *COM*:00000005 NC_Version
1789 - 935
C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp/ccV068Pj.s:918    .bss:00000002 NC_ErrorCode
1755 - 936
                            *COM*:00000008 GPSInfo
1789 - 937
C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp/ccV068Pj.s:591    .text:00000676 SPI_StartTransmitPacket
938
                            *COM*:00000002 SPI_TX_Buffer
939
C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp/ccV068Pj.s:912    .bss:00000001 SPI_CommandCounter
940
C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp/ccV068Pj.s:897    .data:00000002 SPI_CommandSequence
941
                            *COM*:00000001 SPI_BufferIndex
942
C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp/ccV068Pj.s:702    .text:000006f8 SPI_TransmitByte
943
C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp/ccV068Pj.s:920    .bss:00000004 SPI_RXState.2259
944
                            *COM*:00000001 SPI_RxBufferIndex
945
                             .bss:00000003 rxchksum.2261
946
                            *COM*:0000001a SPI_Buffer
1755 - 947
                            *COM*:00000001 SPI_ChkSum
948
 
949
UNDEFINED SYMBOLS
950
EE_Parameter
951
IntegralNick
952
__divmodsi4
953
IntegralRoll
954
ErsatzKompass
1789 - 955
__mulsi3
1755 - 956
GIER_GRAD_FAKTOR
1789 - 957
AdWertGier
1755 - 958
AdNeutralGier
959
NaviCntAcc
960
NaviAccNick
961
__divmodhi4
962
NaviAccRoll
963
Parameter_UserParam1
964
Parameter_UserParam2
965
Parameter_UserParam3
966
Parameter_UserParam4
967
Parameter_UserParam5
968
Parameter_UserParam6
969
Parameter_UserParam7
970
Parameter_UserParam8
971
FCFlags
972
GetActiveParamSet
973
ControlHeading
974
Capacity
975
UBat
976
BattLowVoltageWarning
977
PPM_in
978
Poti
979
WinkelOut
980
HoehenWert
981
SollHoehe
982
SenderOkay
983
DebugOut
984
PlatinenVersion
985
VersionInfo
986
Parameter_ServoNickControl
987
Parameter_ServoRollControl
988
GPS_Nick
989
GPS_Roll
990
KompassValue
991
KompassStartwert
992
KompassRichtung
993
beeptime
1789 - 994
SendSPI
995
__do_copy_data
996
__do_clear_bss