⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 app.lst

📁 adhoc信息节点程序源代码(点对多点)——for atmega128
💻 LST
📖 第 1 页 / 共 2 页
字号:
 131:app.c         **** 		pack = (SensorMsg *)LLCmsg[LLCcurrentMsg].data;
 278               	.LM37:
 279 0086 9091 0000 		lds r25,LLCcurrentMsg
 280 008a 14E6      		ldi r17,lo8(100)
 281 008c 919F      		mul r25,r17
 282 008e F001      		movw r30,r0
 283 0090 1124      		clr r1
 284 0092 E050      		subi r30,lo8(-(LLCmsg+5))
 285 0094 F040      		sbci r31,hi8(-(LLCmsg+5))
 132:app.c         **** 		LLCpacketReadingNumber = 0;
 287               	.LM38:
 288 0096 1092 0000 		sts LLCpacketReadingNumber,__zero_reg__
 133:app.c         **** 		pack->seqNo = LLCPacketNumber;
 290               	.LM39:
 291 009a 9091 0000 		lds r25,LLCPacketNumber
 292 009e 9083      		st Z,r25
 134:app.c         ****     }
 135:app.c         ****     AtomicEnd(atomicState); }
 294               	.LM40:
 295 00a0 0E94 0000 		call AtomicEnd
 296               	.LBE3:
 136:app.c         **** 	
 137:app.c         **** 	if (LLCDataMsgSend(OS_BCAST_ADDR, 
 298               	.LM41:
 299 00a4 8091 0000 		lds r24,LLCcurrentMsg
 300 00a8 819F      		mul r24,r17
 301 00aa C001      		movw r24,r0
 302 00ac 1124      		clr r1
 303 00ae 8050      		subi r24,lo8(-(LLCmsg))
 304 00b0 9040      		sbci r25,hi8(-(LLCmsg))
 305 00b2 AC01      		movw r20,r24
 306 00b4 65E1      		ldi r22,lo8(21)
 307 00b6 8091 0000 		lds r24,OS_BCAST_ADDR
 308 00ba 0E94 0000 		call LLCDataMsgSend
 309 00be 8823      		tst r24
 310 00c0 51F0      		breq .L10
 311               	.LBB4:
 138:app.c         **** 		sizeof(SensorMsg), &LLCmsg[LLCcurrentMsg])) 
 139:app.c         ****     {
 140:app.c         **** 		
 141:app.c         **** 		{ uint8_t atomicState = AtomicStart();
 313               	.LM42:
 314 00c2 0E94 0000 		call AtomicStart
 142:app.c         ****         {
 143:app.c         **** 			LLCcurrentMsg ^= 0x1;
 316               	.LM43:
 317 00c6 9091 0000 		lds r25,LLCcurrentMsg
 318 00ca 21E0      		ldi r18,lo8(1)
 319 00cc 9227      		eor r25,r18
 320 00ce 9093 0000 		sts LLCcurrentMsg,r25
 144:app.c         ****         }
 145:app.c         ****         AtomicEnd(atomicState); }
 322               	.LM44:
 323 00d2 0E94 0000 		call AtomicEnd
 324               	.L10:
 325               	.LBE4:
 326               	/* epilogue: frame size=0 */
 327 00d6 1F91      		pop r17
 328 00d8 0895      		ret
 329               	/* epilogue end (size=2) */
 330               	/* function LLCdataTask size 45 (42) */
 334               	.global	LLCADCDataReady
 336               	LLCADCDataReady:
 146:app.c         ****     }
 147:app.c         **** }
 148:app.c         **** 
 149:app.c         **** /*************************************************************************
 150:app.c         **** *功能描述:从ADC获得数据,并进行缓存,调用发送处理函数
 151:app.c         **** *参数说明:传感采集到的数据
 152:app.c         **** *返回值:  
 153:app.c         **** **************************************************************************/
 154:app.c         **** result_t LLCADCDataReady(uint16_t data)
 155:app.c         **** {
 338               	.LM45:
 339               	/* prologue: frame size=0 */
 340 00da 1F93      		push r17
 341 00dc CF93      		push r28
 342 00de DF93      		push r29
 343               	/* prologue end (size=3) */
 344 00e0 EC01      		movw r28,r24
 345               	.LBB5:
 156:app.c         **** 	SensorMsg *pack;
 157:app.c         **** 	{ uint8_t atomicState = AtomicStart();
 347               	.LM46:
 348 00e2 0E94 0000 		call AtomicStart
 349 00e6 182F      		mov r17,r24
 158:app.c         ****     {
 159:app.c         **** 		pack = (SensorMsg *)LLCmsg[LLCcurrentMsg].data;
 351               	.LM47:
 352 00e8 9091 0000 		lds r25,LLCcurrentMsg
 353 00ec 84E6      		ldi r24,lo8(100)
 354 00ee 989F      		mul r25,r24
 355 00f0 C001      		movw r24,r0
 356 00f2 1124      		clr r1
 357 00f4 8050      		subi r24,lo8(-(LLCmsg+5))
 358 00f6 9040      		sbci r25,hi8(-(LLCmsg+5))
 160:app.c         **** 		pack->data[LLCpacketReadingNumber++] = data;
 360               	.LM48:
 361 00f8 2091 0000 		lds r18,LLCpacketReadingNumber
 362 00fc E22F      		mov r30,r18
 363 00fe FF27      		clr r31
 364 0100 EE0F      		add r30,r30
 365 0102 FF1F      		adc r31,r31
 366 0104 E80F      		add r30,r24
 367 0106 F91F      		adc r31,r25
 368 0108 C183      		std Z+1,r28
 369 010a D283      		std Z+2,r29
 370 010c 2F5F      		subi r18,lo8(-(1))
 371 010e 2093 0000 		sts LLCpacketReadingNumber,r18
 161:app.c         **** 		
 162:app.c         **** 		if (LLCpacketReadingNumber == BUFFER_LEN) {
 373               	.LM49:
 374 0112 2A30      		cpi r18,lo8(10)
 375 0114 49F4      		brne .L13
 163:app.c         **** 			OSPostTask(LLCdataTask);							// 如果缓存区已满,则发送
 377               	.LM50:
 378 0116 80E0      		ldi r24,lo8(pm(LLCdataTask))
 379 0118 90E0      		ldi r25,hi8(pm(LLCdataTask))
 380 011a 0E94 0000 		call OSPostTask
 164:app.c         **** 			LLCPacketNumber++;
 382               	.LM51:
 383 011e 8091 0000 		lds r24,LLCPacketNumber
 384 0122 8F5F      		subi r24,lo8(-(1))
 385 0124 8093 0000 		sts LLCPacketNumber,r24
 386               	.L13:
 165:app.c         **** 		}
 166:app.c         ****     }
 167:app.c         ****     AtomicEnd(atomicState); }
 388               	.LM52:
 389 0128 812F      		mov r24,r17
 390 012a 0E94 0000 		call AtomicEnd
 391               	.LBE5:
 168:app.c         **** 	
 169:app.c         **** 	if (data > 0x0270) {
 393               	.LM53:
 394 012e 82E0      		ldi r24,hi8(625)
 395 0130 C137      		cpi r28,lo8(625)
 396 0132 D807      		cpc r29,r24
 397 0134 18F0      		brlo .L14
 170:app.c         **** 		LedRedOn();
 399               	.LM54:
 400 0136 0E94 0000 		call LedRedOn
 401 013a 02C0      		rjmp .L15
 402               	.L14:
 171:app.c         ****     }
 172:app.c         **** 	else {
 173:app.c         **** 		LedRedOff();
 404               	.LM55:
 405 013c 0E94 0000 		call LedRedOff
 406               	.L15:
 174:app.c         ****     }
 175:app.c         **** 	if (data < 0x0230) {
 408               	.LM56:
 409 0140 C053      		subi r28,lo8(560)
 410 0142 D240      		sbci r29,hi8(560)
 411 0144 18F4      		brsh .L16
 176:app.c         **** 		LedGreenOn();
 413               	.LM57:
 414 0146 0E94 0000 		call LedGreenOn
 415 014a 02C0      		rjmp .L17
 416               	.L16:
 177:app.c         ****     }
 178:app.c         **** 	else {
 179:app.c         **** 		LedGreenOff();
 418               	.LM58:
 419 014c 0E94 0000 		call LedGreenOff
 420               	.L17:
 180:app.c         ****     }
 181:app.c         **** 	return SUCCESS;
 182:app.c         **** }
 422               	.LM59:
 423 0150 81E0      		ldi r24,lo8(1)
 424 0152 90E0      		ldi r25,hi8(1)
 425               	/* epilogue: frame size=0 */
 426 0154 DF91      		pop r29
 427 0156 CF91      		pop r28
 428 0158 1F91      		pop r17
 429 015a 0895      		ret
 430               	/* epilogue end (size=4) */
 431               	/* function LLCADCDataReady size 66 (59) */
 439               	.global	LLCDataMsgSendDone
 441               	LLCDataMsgSendDone:
 183:app.c         **** 
 184:app.c         **** result_t LLCDataMsgSendDone(OSMACMsgPtr sent, result_t success)
 185:app.c         **** {
 443               	.LM60:
 444               	/* prologue: frame size=0 */
 445               	/* prologue end (size=0) */
 186:app.c         **** 	return SUCCESS;
 187:app.c         **** }
 447               	.LM61:
 448 015c 81E0      		ldi r24,lo8(1)
 449 015e 90E0      		ldi r25,hi8(1)
 450               	/* epilogue: frame size=0 */
 451 0160 0895      		ret
 452               	/* epilogue end (size=1) */
 453               	/* function LLCDataMsgSendDone size 3 (2) */
 457               	.global	LLCResetCounterMsgReceive
 459               	LLCResetCounterMsgReceive:
 188:app.c         **** 
 189:app.c         **** OSMACMsgPtr LLCResetCounterMsgReceive(OSMACMsgPtr m)
 190:app.c         **** {
 461               	.LM62:
 462               	/* prologue: frame size=0 */
 463 0162 0F93      		push r16
 464 0164 1F93      		push r17
 465               	/* prologue end (size=2) */
 466 0166 8C01      		movw r16,r24
 467               	.LBB6:
 191:app.c         **** 	{ uint8_t atomicState = AtomicStart();
 469               	.LM63:
 470 0168 0E94 0000 		call AtomicStart
 192:app.c         ****     {
 193:app.c         **** 		LLCPacketNumber = 0;
 472               	.LM64:
 473 016c 1092 0000 		sts LLCPacketNumber,__zero_reg__
 194:app.c         ****     }
 195:app.c         ****     AtomicEnd(atomicState); }
 475               	.LM65:
 476 0170 0E94 0000 		call AtomicEnd
 477               	.LBE6:
 196:app.c         **** 	return m;
 197:app.c         **** }...
 479               	.LM66:
 480 0174 C801      		movw r24,r16
 481               	/* epilogue: frame size=0 */
 482 0176 1F91      		pop r17
 483 0178 0F91      		pop r16
 484 017a 0895      		ret
 485               	/* epilogue end (size=3) */
 486               	/* function LLCResetCounterMsgReceive size 13 (8) */
 488               		.comm LLCpacketReadingNumber,1,1
 489               		.comm LLCPacketNumber,1,1
 490               		.comm LLCmsg,200,1
 491               		.comm LLCcurrentMsg,1,1
 497               		.text
 499               	Letext:
 500               	/* File "app.c": code  191 = 0x00bf ( 169), prologues   6, epilogues  16 */
DEFINED SYMBOLS
                            *ABS*:00000000 app.c
                            *ABS*:0000003f __SREG__
                            *ABS*:0000003e __SP_H__
                            *ABS*:0000003d __SP_L__
                            *ABS*:00000000 __tmp_reg__
                            *ABS*:00000001 __zero_reg__
C:\DOCUME~1\xiapeng\LOCALS~1\Temp/ccSAbaaa.s:77     .data:00000000 OS_GROUP
C:\DOCUME~1\xiapeng\LOCALS~1\Temp/ccSAbaaa.s:83     .text:00000000 LLCStdControlInit
                            *COM*:00000001 LLCcurrentMsg
                            *COM*:00000001 LLCpacketReadingNumber
                            *COM*:00000001 LLCPacketNumber
C:\DOCUME~1\xiapeng\LOCALS~1\Temp/ccSAbaaa.s:136    .text:00000032 LLCTimerStart
C:\DOCUME~1\xiapeng\LOCALS~1\Temp/ccSAbaaa.s:156    .text:0000003c LLCStdControlStart
C:\DOCUME~1\xiapeng\LOCALS~1\Temp/ccSAbaaa.s:180    .text:0000004c LLCADCGetData
C:\DOCUME~1\xiapeng\LOCALS~1\Temp/ccSAbaaa.s:199    .text:00000054 LLCTimerFired
C:\DOCUME~1\xiapeng\LOCALS~1\Temp/ccSAbaaa.s:221    .text:0000005c LLCDataMsgSend
C:\DOCUME~1\xiapeng\LOCALS~1\Temp/ccSAbaaa.s:267    .text:00000080 LLCdataTask
                            *COM*:000000c8 LLCmsg
C:\DOCUME~1\xiapeng\LOCALS~1\Temp/ccSAbaaa.s:336    .text:000000da LLCADCDataReady
C:\DOCUME~1\xiapeng\LOCALS~1\Temp/ccSAbaaa.s:441    .text:0000015c LLCDataMsgSendDone
C:\DOCUME~1\xiapeng\LOCALS~1\Temp/ccSAbaaa.s:459    .text:00000162 LLCResetCounterMsgReceive
C:\DOCUME~1\xiapeng\LOCALS~1\Temp/ccSAbaaa.s:499    .text:0000017c Letext

UNDEFINED SYMBOLS
__do_copy_data
__do_clear_bss
LedInit
LedRedOff
LedGreenOff
LedYellowOff
SensorPhoOStdControlInit
MACInit
AtomicStart
AtomicEnd
ClockSet
SensorPhoOStdControlStart
SensorExternalPhotoADCGetData
OS_BCAST_ADDR
MACBroadcastMsg
OSPostTask
LedRedOn
LedGreenOn

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -