📄 main.lst
字号:
417
418 P3SEL_bit.P3SEL_0 = 0; // 0 is digital I/O
419 P3SEL_bit.P3SEL_1 = 0; // 0 is digital I/O
420 P3SEL_bit.P3SEL_2 = 0; // 0 is digital I/O
421 P3SEL_bit.P3SEL_3 = 0; // 0 is digital I/O
422
423 P3DIR_bit.P3DIR_0 = 1; // 1 is output
424 P3DIR_bit.P3DIR_1 = 1; // 1 is output
425 P3DIR_bit.P3DIR_2 = 1; // 1 is output
426 P3DIR_bit.P3DIR_3 = 1; // 1 is output
427
428 // P4:
429
430 P4SEL_bit.P4SEL_7 = 0; // 0 is digital I/O
431 P4DIR_bit.P4DIR_7 = 1; // 1 is output
432
433 // P5:
434
435 P5SEL_bit.P5SEL_7 = 0; // 0 is digital I/O
436 P5DIR_bit.P5DIR_7 = 1; // 1 is output
437
438 // P6:
439
440 P6SEL_bit.P6SEL_0 = 0; // 0 is digital I/O
441 P6SEL_bit.P6SEL_1 = 0; // 0 is digital I/O
442 P6SEL_bit.P6SEL_2 = 0; // 0 is digital I/O
443 P6SEL_bit.P6SEL_3 = 0; // 0 is digital I/O
444
445 P6SEL_bit.P6SEL_5 = 0; // 0 is digital I/O
446 P6SEL_bit.P6SEL_6 = 0; // 0 is digital I/O
447 P6SEL_bit.P6SEL_7 = 0; // 0 is digital I/O
448
449 P6DIR_bit.P6DIR_0 = 1; // 1 is output
450 P6DIR_bit.P6DIR_1 = 1; // 1 is output
451 P6DIR_bit.P6DIR_2 = 1; // 1 is output
452 P6DIR_bit.P6DIR_3 = 1; // 1 is output
453
454 P6DIR_bit.P6DIR_5 = 1; // 1 is output
455 P6DIR_bit.P6DIR_6 = 1; // 1 is output
456 P6DIR_bit.P6DIR_7 = 1; // 1 is output
457 */
458
459 /* Setup DCO+ for ( xtal * D * (N + 1) ) operation. */
460 // FLL_CTL0 |= DCOPLUS + XCAP18PF;
461
462 /* X2 DCO frequency, 8MHz nominal DCO */
463 // XXX - OK - this looks like our master clock...
464 // SCFI0 |= FN_4;
465
466 /* (121+1) x 32768 x 2 = 7.99 Mhz */
467 // SCFQCTL = mainMAX_FREQUENCY;
468
469 /* Setup the IO. This is just copied from the demo supplied by SoftBaugh
470 for the ES449 demo board. */
471
472 // P1SEL = 0x32;
473 // P2SEL = 0x00;
474 // P3SEL = 0x00;
475 // P4SEL = 0xFC;
476 // P5SEL = 0xFF;
477
478
479 // (re)enable the watchdog if you wish
480
481
482 }
\ 0001D6 3041 RET
483 /*-----------------------------------------------------------*/
484
485 /* The idle hook is just a copy of the standard integer maths tasks. See
486 Demo/Common/integer.c for rationale. */
487
488 // void vApplicationIdleHook( void ) __toplevel
\ In segment CODE, align 2
489 void vApplicationIdleHook( void )
\ vApplicationIdleHook:
490 {
\ 000000 31800600 SUB.W #0x6, SP
491 /* These variables are all effectively set to constants so they are volatile to
492 ensure the compiler does not just get rid of them. */
493 volatile portLONG lValue;
494 volatile signed portBASE_TYPE *pxTaskHasExecuted;
^
Warning[Pe177]: variable "pxTaskHasExecuted" was declared but never referenced
495
496 /* Keep performing a calculation and checking the result against a constant. */
497 for( ;; )
498 {
499 /* Perform the calculation. This will store partial value in
500 registers, resulting in a good test of the context switch mechanism. */
501 lValue = intgCONST1;
\ ??vApplicationIdleHook_0:
\ 000004 B1407B000000 MOV.W #0x7b, 0x0(SP)
\ 00000A 81430200 MOV.W #0x0, 0x2(SP)
502 lValue += intgCONST2;
\ 00000E B15047940000 ADD.W #0x9447, 0x0(SP)
\ 000014 B16003000200 ADDC.W #0x3, 0x2(SP)
503
504 /* Yield in case cooperative scheduling is being used. */
505 #if configUSE_PREEMPTION == 0
506 {
507 taskYIELD();
508 }
509 #endif
510
511 /* Finish off the calculation. */
512 lValue *= intgCONST3;
\ 00001A 2C41 MOV.W 0x0(SP), R12
\ 00001C 1D410200 MOV.W 0x2(SP), R13
\ 000020 3E40FDFF MOV.W #0xfffd, R14
\ 000024 3F43 MOV.W #0xffff, R15
\ 000026 B012.... CALL #?Mul32
\ 00002A 814C0000 MOV.W R12, 0x0(SP)
\ 00002E 814D0200 MOV.W R13, 0x2(SP)
513 lValue /= intgCONST4;
\ 000032 2C41 MOV.W 0x0(SP), R12
\ 000034 1D410200 MOV.W 0x2(SP), R13
\ 000038 3E400700 MOV.W #0x7, R14
\ 00003C 0F43 MOV.W #0x0, R15
\ 00003E B012.... CALL #?DivMod32s
\ 000042 814C0000 MOV.W R12, 0x0(SP)
\ 000046 814D0200 MOV.W R13, 0x2(SP)
514
515 /* If the calculation is found to be incorrect we stop setting the
516 TaskHasExecuted variable so the check task can see an error has
517 occurred. */
518 if( lValue != intgEXPECTED_ANSWER ) /*lint !e774 volatile used to prevent this being optimised out. */
\ 00004A B1901B770000 CMP.W #0x771b, 0x0(SP)
\ 000050 0420 JNE ??vApplicationIdleHook_1
\ 000052 B190FEFF0200 CMP.W #0xfffe, 0x2(SP)
\ 000058 D527 JEQ ??vApplicationIdleHook_0
519 {
520 /* Don't bother with mutual exclusion - it is only read from the
521 check task and never written. */
522 xLocalError = pdTRUE;
\ ??vApplicationIdleHook_1:
\ 00005A 9243.... MOV.W #0x1, &xLocalError
\ 00005E D23F JMP ??vApplicationIdleHook_0
523 }
524 /* Yield in case cooperative scheduling is being used. */
525 #if configUSE_PREEMPTION == 0
526 {
527 taskYIELD();
528 }
529 #endif
530 }
531 }
\ In segment DATA16_ID, align 2, align-sorted
\ `?<Initializer for sNoErrorFound>`:
\ 000000 0100 DC16 1
\ In segment DATA16_C, align 1, align-sorted
\ `?<Constant "Check">`:
\ 000000 436865636B00 DC8 "Check"
532
533
534
535
536
Maximum stack usage in bytes:
Function CSTACK
-------- ------
main 12
-> prvSetupHardware 2
-> vParTestInitialise 2
-> vStartLEDFlashTasks 2
-> vStartMathTasks 2
-> vStartIntegerMathTasks 2
-> vAltStartComTestTasks 4
-> vStartPolledQueueTasks 4
-> vStartBlockingQueueTasks 4
-> vStartDynamicPriorityTasks
4
-> xTaskCreate 12
-> vTaskStartScheduler 12
prvCheckOtherTasksAreStillRunning
2
-> xAreIntegerMathsTaskStillRunning
2
-> xAreComTestTasksStillRunning
2
-> xArePollingQueuesStillRunning
2
prvSetupHardware 2
vApplicationIdleHook 8
vErrorChecks 6
-> vTaskDelay 6
-> prvCheckOtherTasksAreStillRunning
6
Segment part sizes:
Function/Label Bytes
-------------- -----
_A_IFG1 1
_A_WDTCTL 2
_A_P1DIR 1
_A_P1SEL 1
_A_P2DIR 1
_A_P2SEL 1
_A_P3DIR 1
_A_P3SEL 1
_A_P4DIR 1
_A_P4SEL 1
_A_P5DIR 1
_A_P5SEL 1
_A_P6DIR 1
_A_P6SEL 1
_A_BCSCTL1 1
_A_BCSCTL2 1
xLocalError 2
main 94
vErrorChecks 30
prvCheckOtherTasksAreStillRunning
52
sNoErrorFound 2
prvSetupHardware 472
vApplicationIdleHook 96
?<Initializer for sNoErrorFound>
2
?<Constant "Check"> 6
744 bytes in segment CODE
17 bytes in segment DATA16_AN
6 bytes in segment DATA16_C
2 bytes in segment DATA16_I
2 bytes in segment DATA16_ID
2 bytes in segment DATA16_Z
744 bytes of CODE memory
8 bytes of CONST memory
4 bytes of DATA memory (+ 17 bytes shared)
Errors: none
Warnings: 4
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -