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

📄 pjhost.lst

📁 AVR megal128下的ucos_ii
💻 LST
📖 第 1 页 / 共 5 页
字号:
    04B1 9503      INC	R16
(0354)                 STS     _OSIntNesting,R16           ;
    04B2 93000917  STS	OSIntNesting,R16
(0355) 
(0356)                 CPI     R16,1                       ; if (OSIntNesting == 1) {
    04B4 3001      CPI	R16,1
(0357)                 BRNE    OSTickISR_1
    04B5 F431      BNE	0x04BC
(0358) 
(0359)                 LDS     R30,_OSTCBCur               ;     OSTCBCur->OSTCBStkPtr = Y
    04B6 91E00807  LDS	R30,OSTCBCur
(0360)                 LDS     R31,_OSTCBCur+1
    04B8 91F00808  LDS	R31,OSTCBCur+1
(0361)                 ST      Z+,R28
    04BA 93C1      ST	R28,Z+
(0362)                 ST      Z+,R29                      ; }
    04BB 93D1      ST	R29,Z+
(0363) 
(0364) OSTickISR_1:
(0365)                 CALL    _OSTickISR_Handler          ; Handle the tick ISR
    04BC 940E02A4  CALL	_OSTickISR_Handler
(0366) 
(0367)                 CALL    _OSIntExit                  ; Notify uC/OS-II about end of ISR
    04BE 940E072E  CALL	_OSIntExit
    04C0 9109      LD	R16,Y+
    04C1 BF0D      OUT	0x3D,R16
    04C2 9109      LD	R16,Y+
(0368) 
(0369)                 POP_SP                              ; Restore the hardware stack pointer from task's stack
    04C3 BF0E      OUT	0x3E,R16
    04C4 9109      LD	R16,Y+
(0370)                 POP_SREG                            ; Restore the SREG register
    04C5 BF0F      OUT	0x3F,R16
    04C6 9109      LD	R16,Y+
    04C7 BF0B      OUT	0x3B,R16
    04C8 91F9      LD	R31,Y+
    04C9 91E9      LD	R30,Y+
    04CA 91B9      LD	R27,Y+
    04CB 91A9      LD	R26,Y+
    04CC 9199      LD	R25,Y+
    04CD 9189      LD	R24,Y+
    04CE 9179      LD	R23,Y+
    04CF 9169      LD	R22,Y+
    04D0 9159      LD	R21,Y+
    04D1 9149      LD	R20,Y+
    04D2 9139      LD	R19,Y+
    04D3 9129      LD	R18,Y+
    04D4 9119      LD	R17,Y+
    04D5 9109      LD	R16,Y+
    04D6 90F9      LD	R15,Y+
    04D7 90E9      LD	R14,Y+
    04D8 90D9      LD	R13,Y+
    04D9 90C9      LD	R12,Y+
    04DA 90B9      LD	R11,Y+
    04DB 90A9      LD	R10,Y+
    04DC 9099      LD	R9,Y+
    04DD 9089      LD	R8,Y+
    04DE 9079      LD	R7,Y+
    04DF 9069      LD	R6,Y+
    04E0 9059      LD	R5,Y+
    04E1 9049      LD	R4,Y+
    04E2 9039      LD	R3,Y+
    04E3 9029      LD	R2,Y+
    04E4 9019      LD	R1,Y+
(0371)                 POP_ALL                             ; Restore all registers
    04E5 9009      LD	R0,Y+
(0372) 
(0373)                 RET                                 ; Note: RET instead of RETI
    04E6 9508      RET
_uart0_rx_isr:
    04E7 920A      ST	R0,-Y
    04E8 921A      ST	R1,-Y
    04E9 922A      ST	R2,-Y
    04EA 923A      ST	R3,-Y
    04EB 924A      ST	R4,-Y
    04EC 925A      ST	R5,-Y
    04ED 926A      ST	R6,-Y
    04EE 927A      ST	R7,-Y
    04EF 928A      ST	R8,-Y
    04F0 929A      ST	R9,-Y
    04F1 92AA      ST	R10,-Y
    04F2 92BA      ST	R11,-Y
    04F3 92CA      ST	R12,-Y
    04F4 92DA      ST	R13,-Y
    04F5 92EA      ST	R14,-Y
    04F6 92FA      ST	R15,-Y
    04F7 930A      ST	R16,-Y
    04F8 931A      ST	R17,-Y
    04F9 932A      ST	R18,-Y
    04FA 933A      ST	R19,-Y
    04FB 934A      ST	R20,-Y
    04FC 935A      ST	R21,-Y
    04FD 936A      ST	R22,-Y
    04FE 937A      ST	R23,-Y
    04FF 938A      ST	R24,-Y
    0500 939A      ST	R25,-Y
    0501 93AA      ST	R26,-Y
    0502 93BA      ST	R27,-Y
    0503 93EA      ST	R30,-Y
    0504 93FA      ST	R31,-Y
    0505 B70B      IN	R16,0x3B
(0374) ;/*$PAGE*/.
(0375) ;********************************************************************************************************
(0376) ;                                              Uart0  rx ISR
(0377) ;
(0378) ; Description : This function is the ISR used to notify uC/OS-II that a system tick has occurred.
(0379) ;
(0380) ;               The following C-like pseudo-code describe the operation being performed in the code below.
(0381) ;
(0382) ;               Save all registers on the current task's stack:
(0383) ;                      Use the PUSH_ALL macro
(0384) ;                      Get the SREG, set Bit #7 and save onto the task's stack using -Y addressing
(0385) ;                      Use the PUSH_SP macro to save the task's hardware stack pointer onto the current task's stack
(0386) ;               OSIntNesting++;
(0387) ;               if (OSIntNesting == 1) {
(0388) ;                  OSTCBCur->OSTCBStkPtr = SP
(0389) ;               }
(0390) ;               Clear the interrupt;                  Not needed for the timer we used.
(0391) ;                                          Notify uC/OS-II that a tick has occured
(0392) ;                                          Notify uC/OS-II about end of ISR
(0393) ;               Restore all registers that were save on the current task's stack:
(0394) ;                      Use the POP_SP macro to restore the task's hardware stack pointer
(0395) ;                      Use the POP_SREG macro to restore the SREG register
(0396) ;                      Use the POP_ALL macro to restore the remaining registers
(0397) ;               Return (DO NOT use a RETI instruction);
(0398) ;********************************************************************************************************
(0399) 
(0400) _uart0_rx_isr::
(0401)                 PUSH_ALL                            ; Save all registers and status register
    0506 930A      ST	R16,-Y
(0402)                 IN      R16,SREG                    ; Save the SREG but with interrupts enabled
    0507 B70F      IN	R16,0x3F
(0403)                 SBR     R16,BIT07                    
    0508 6800      ORI	R16,0x80
(0404)                 ST      -Y,R16
    0509 930A      ST	R16,-Y
    050A B70E      IN	R16,0x3E
    050B 930A      ST	R16,-Y
    050C B70D      IN	R16,0x3D
(0405)                 PUSH_SP                             ; Save the task's hardware stack pointer onto task's stack
    050D 930A      ST	R16,-Y
(0406) 
(0407)                 LDS     R16,_OSIntNesting           ; Notify uC/OS-II of ISR
    050E 91000917  LDS	R16,OSIntNesting
(0408)                 INC     R16                         ;
    0510 9503      INC	R16
(0409)                 STS     _OSIntNesting,R16           ;
    0511 93000917  STS	OSIntNesting,R16
(0410) 
(0411)                 CPI     R16,1                       ; if (OSIntNesting == 1) {
    0513 3001      CPI	R16,1
(0412)                 BRNE    uart0_rx_isr_1
    0514 F431      BNE	0x051B
(0413) 
(0414)                 LDS     R30,_OSTCBCur               ;     OSTCBCur->OSTCBStkPtr = Y
    0515 91E00807  LDS	R30,OSTCBCur
(0415)                 LDS     R31,_OSTCBCur+1
    0517 91F00808  LDS	R31,OSTCBCur+1
(0416)                 ST      Z+,R28
    0519 93C1      ST	R28,Z+
(0417)                 ST      Z+,R29                      ; }
    051A 93D1      ST	R29,Z+
(0418) 
(0419) uart0_rx_isr_1:
(0420)                 //CALL    _Uart0Rx_Handler          ; Handle the tick ISR
(0421) 
(0422)                 CALL    _OSIntExit                  ; Notify uC/OS-II about end of ISR
    051B 940E072E  CALL	_OSIntExit
    051D 9109      LD	R16,Y+
    051E BF0D      OUT	0x3D,R16
    051F 9109      LD	R16,Y+
(0423) 
(0424)                 POP_SP                              ; Restore the hardware stack pointer from task's stack
    0520 BF0E      OUT	0x3E,R16
    0521 9109      LD	R16,Y+
(0425)                 POP_SREG                            ; Restore the SREG register
    0522 BF0F      OUT	0x3F,R16
    0523 9109      LD	R16,Y+
    0524 BF0B      OUT	0x3B,R16
    0525 91F9      LD	R31,Y+
    0526 91E9      LD	R30,Y+
    0527 91B9      LD	R27,Y+
    0528 91A9      LD	R26,Y+
    0529 9199      LD	R25,Y+
    052A 9189      LD	R24,Y+
    052B 9179      LD	R23,Y+
    052C 9169      LD	R22,Y+
    052D 9159      LD	R21,Y+
    052E 9149      LD	R20,Y+
    052F 9139      LD	R19,Y+
    0530 9129      LD	R18,Y+
    0531 9119      LD	R17,Y+
    0532 9109      LD	R16,Y+
    0533 90F9      LD	R15,Y+
    0534 90E9      LD	R14,Y+
    0535 90D9      LD	R13,Y+
    0536 90C9      LD	R12,Y+
    0537 90B9      LD	R11,Y+
    0538 90A9      LD	R10,Y+
    0539 9099      LD	R9,Y+
    053A 9089      LD	R8,Y+
    053B 9079      LD	R7,Y+
    053C 9069      LD	R6,Y+
    053D 9059      LD	R5,Y+
    053E 9049      LD	R4,Y+
    053F 9039      LD	R3,Y+
    0540 9029      LD	R2,Y+
    0541 9019      LD	R1,Y+
(0426)                 POP_ALL                             ; Restore all registers
    0542 9009      LD	R0,Y+
(0427) 
(0428)                 RET                                 ; Note: RET instead of RETI
    0543 9508      RET
_uart0_udre_isr:
    0544 920A      ST	R0,-Y
    0545 921A      ST	R1,-Y
    0546 922A      ST	R2,-Y
    0547 923A      ST	R3,-Y
    0548 924A      ST	R4,-Y
    0549 925A      ST	R5,-Y
    054A 926A      ST	R6,-Y
    054B 927A      ST	R7,-Y
    054C 928A      ST	R8,-Y
    054D 929A      ST	R9,-Y
    054E 92AA      ST	R10,-Y
    054F 92BA      ST	R11,-Y
    0550 92CA      ST	R12,-Y
    0551 92DA      ST	R13,-Y
    0552 92EA      ST	R14,-Y
    0553 92FA      ST	R15,-Y
    0554 930A      ST	R16,-Y
    0555 931A      ST	R17,-Y
    0556 932A      ST	R18,-Y
    0557 933A      ST	R19,-Y
    0558 934A      ST	R20,-Y
    0559 935A      ST	R21,-Y
    055A 936A      ST	R22,-Y
    055B 937A      ST	R23,-Y
    055C 938A      ST	R24,-Y
    055D 939A      ST	R25,-Y
    055E 93AA      ST	R26,-Y
    055F 93BA      ST	R27,-Y
    0560 93EA      ST	R30,-Y
    0561 93FA      ST	R31,-Y
    0562 B70B      IN	R16,0x3B
(0429)                 
(0430)               
(0431) ;/*$PAGE*/.
(0432) ;********************************************************************************************************
(0433) ;                                              Uart0  udre  ISR
(0434) ;
(0435) ; Description : This function is the ISR used to notify uC/OS-II that a system tick has occurred.
(0436) ;
(0437) ;               The following C-like pseudo-code describe the operation being performed in the code below.
(0438) ;
(0439) ;               Save all registers on the current task's stack:
(0440) ;                      Use the PUSH_ALL macro
(0441) ;                      Get the SREG, set Bit #7 and save onto the task's stack using -Y addressing
(0442) ;                      Use the PUSH_SP macro to save the task's hardware stack pointer onto the current task's stack
(0443) ;               OSIntNesting++;
(0444) ;               if (OSIntNesting == 1) {
(0445) ;                  OSTCBCur->OSTCBStkPtr = SP
(0446) ;               }
(0447) ;               Clear the interrupt;                  Not needed for the timer we used.
(0448) ;                                          Notify uC/OS-II that a tick has occured
(0449) ;                                          Notify uC/OS-II about end of ISR
(0450) ;               Restore all registers that were save on the current task's stack:
(0451) ;                      Use the POP_SP macro to restore the task's hardware stack pointer
(0452) ;                      Use the POP_SREG macro to restore the SREG register
(0453) ;                      Use the POP_ALL macro to restore the remaining registers
(0454) ;               Return (DO NOT use a RETI instruction);
(0455) ;********************************************************************************************************
(0456) /*
(0457) _uart0_udre_isr::
(0458)                 PUSH_ALL                            ; Save all registers and status register
    0563 930A      ST	R16,-Y
(0459)                 IN      R16,SREG                    ; Save the SREG but with interrupts enabled
    0564 B70F      IN	R16,0x3F
(0460)                 SBR     R16,BIT07                    
    0565 6800      ORI	R16,0x80
(0461)                 ST      -Y,R16
    0566 930A      ST	R16,-Y
    0567 B70E      IN	R16,0x3E
    0568 930A      ST	R16,-Y
    0569 B70D      IN	R16,0x3D
(0462)                 PUSH_SP                             ; Save the task's hardware stack pointer onto task's stack
    056A 930A      ST	R16,-Y
(0463) 
(0464)                 LDS     R16,_OSIntNesting           ; Notify uC/OS-II of ISR
    056B 91000917  LDS	R16,OSIntNesting
(0465)                 INC     R16                         ;
    056D 9503      INC	R16
(0466)                 STS     _OSIntNesting,R16           ;
    056E 93000917  STS	OSIntNesting,R16
(0467) 
(0468)                 CPI     R16,1                       ; if (OSIntNesting == 1) {
    0570 3001      CPI	R16,1
(0469)                 BRNE    uart0_udre_isr_1
    0571 F431      BNE	0x0578
(0470) 
(0471)                 LDS     R30,_OSTCBCur               ;     OSTCBCur->OSTCBStkPtr = Y
    0572 91E00807  LDS	R30,OSTCBCur
(0472)                 LDS     R31,_OSTCBCur+1
    0574 91F00808  LDS	R31,OSTCBCur+1
(0473)                 ST      Z+,R28
    0576 93C1      ST	R28,Z+
(0474)                 ST      Z+,R29                      ; }
    0577 93D1      ST	R29,Z+
(0475) 
(0476) uart0_udre_isr_1:
(0477)                // CALL    _Uart0Ud_Handler     ; Handle the tick ISR
(0478) 
(0479)                 CALL    _OSIntExit                  ; Notify uC/OS-II about end of ISR
    0578 940E072E  CALL	_OSIntExit
    057A 9109      LD	R16,Y+
    057B BF0D      OUT	0x3D,R16
    057C 9109      LD	R16,Y+
(0480) 
(0481)                 POP_SP                              ; Restore the hardware stack pointer from task's stack
    057D BF0E      OUT	0x3E,R16
    057E 9109      LD	R16,Y+
(0482)                 POP_SREG                            ; Restore the SREG register
    057F BF0F      OUT	0x3F,R16
    0580 9109      LD	R16,Y+
    0581 BF0B      OUT	0x3B,R16
    0582 91F9      LD	R

⌨️ 快捷键说明

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