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

📄 main.txt

📁 STM32 demo板的例程
💻 TXT
📖 第 1 页 / 共 2 页
字号:
;;;61       NVIC_SetVectorTable(NVIC_VectTab_RAM, 0x0); 
0000f4  2100              MOVS     r1,#0
0000f6  f04ff04f          MOV      r0,#0x20000000
0000fa  f7fff7ff          BL       NVIC_SetVectorTable
;;;62     #else  /* VECT_TAB_FLASH  */
;;;63       /* Set the Vector Table base location at 0x08000000 */ 
;;;64       NVIC_SetVectorTable(NVIC_VectTab_FLASH, 0x0);   
;;;65     #endif
;;;66     
;;;67       /* Configure one bit for preemption priority */
;;;68       NVIC_PriorityGroupConfig(NVIC_PriorityGroup_1);
0000fe  f44ff44f          MOV      r0,#0x600
000102  f7fff7ff          BL       NVIC_PriorityGroupConfig
;;;69       
;;;70       /* Enable the EXTI0 Interrupt */
;;;71       NVIC_InitStructure.NVIC_IRQChannel = EXTI0_IRQChannel;
000106  2006              MOVS     r0,#6
000108  4958              LDR      r1,|L1.620|
00010a  7008              STRB     r0,[r1,#0]  ; NVIC_InitStructure
;;;72       NVIC_InitStructure.NVIC_IRQChannelPreemptionPriority = PreemptionPriorityValue;
00010c  4858              LDR      r0,|L1.624|
00010e  7800              LDRB     r0,[r0,#0]  ; PreemptionPriorityValue
000110  7048              STRB     r0,[r1,#1]  ; NVIC_InitStructure
;;;73       NVIC_InitStructure.NVIC_IRQChannelSubPriority = 0;
000112  2000              MOVS     r0,#0
000114  7088              STRB     r0,[r1,#2]  ; NVIC_InitStructure
;;;74       NVIC_InitStructure.NVIC_IRQChannelCmd = ENABLE;
000116  2001              MOVS     r0,#1
000118  70c8              STRB     r0,[r1,#3]  ; NVIC_InitStructure
;;;75       NVIC_Init(&NVIC_InitStructure);
00011a  4608              MOV      r0,r1
00011c  f7fff7ff          BL       NVIC_Init
;;;76       
;;;77       /* Enable the EXTI9_5 Interrupt */
;;;78       NVIC_InitStructure.NVIC_IRQChannel = EXTI9_5_IRQChannel;
000120  2017              MOVS     r0,#0x17
000122  4952              LDR      r1,|L1.620|
000124  7008              STRB     r0,[r1,#0]  ; NVIC_InitStructure
;;;79       NVIC_InitStructure.NVIC_IRQChannelPreemptionPriority = 0;
000126  2000              MOVS     r0,#0
000128  7048              STRB     r0,[r1,#1]  ; NVIC_InitStructure
;;;80       NVIC_InitStructure.NVIC_IRQChannelSubPriority = 1;
00012a  2001              MOVS     r0,#1
00012c  7088              STRB     r0,[r1,#2]  ; NVIC_InitStructure
;;;81       NVIC_InitStructure.NVIC_IRQChannelCmd = ENABLE;
00012e  70c8              STRB     r0,[r1,#3]  ; NVIC_InitStructure
;;;82       NVIC_Init(&NVIC_InitStructure);
000130  4608              MOV      r0,r1
000132  f7fff7ff          BL       NVIC_Init
;;;83       
;;;84       /* Configure the SysTick Handler Priority: Preemption priority and subpriority */
;;;85       NVIC_SystemHandlerPriorityConfig(SystemHandler_SysTick, !PreemptionPriorityValue, 0);
000136  484e              LDR      r0,|L1.624|
000138  7800              LDRB     r0,[r0,#0]  ; PreemptionPriorityValue
00013a  b908              CBNZ     r0,|L1.320|
00013c  2001              MOVS     r0,#1
00013e  e000              B        |L1.322|
                  |L1.320|
000140  2000              MOVS     r0,#0
                  |L1.322|
000142  b2c1              UXTB     r1,r0
000144  2200              MOVS     r2,#0
000146  484b              LDR      r0,|L1.628|
000148  f7fff7ff          BL       NVIC_SystemHandlerPriorityConfig
;;;86       
;;;87       while (1)
00014c  e087              B        |L1.606|
                  |L1.334|
;;;88       {
;;;89       //  if(PreemptionOccured != FALSE)
;;;90       //  {
;;;91           GPIO_WriteBit(GPIOB, GPIO_Pin_8, (BitAction)(1 - GPIO_ReadOutputDataBit(GPIOB, GPIO_Pin_8)));
00014e  f44ff44f          MOV      r1,#0x100
000152  4843              LDR      r0,|L1.608|
000154  f7fff7ff          BL       GPIO_ReadOutputDataBit
000158  f1c0f1c0          RSB      r0,r0,#1
00015c  b2c4              UXTB     r4,r0
00015e  4622              MOV      r2,r4
000160  f44ff44f          MOV      r1,#0x100
000164  483e              LDR      r0,|L1.608|
000166  f7fff7ff          BL       GPIO_WriteBit
;;;92           Delay(0x2FFFF);
00016a  4843              LDR      r0,|L1.632|
00016c  f7fff7ff          BL       Delay
;;;93           GPIO_WriteBit(GPIOB, GPIO_Pin_9, (BitAction)(1 - GPIO_ReadOutputDataBit(GPIOB, GPIO_Pin_9)));
000170  f44ff44f          MOV      r1,#0x200
000174  483a              LDR      r0,|L1.608|
000176  f7fff7ff          BL       GPIO_ReadOutputDataBit
00017a  f1c0f1c0          RSB      r0,r0,#1
00017e  b2c4              UXTB     r4,r0
000180  4622              MOV      r2,r4
000182  f44ff44f          MOV      r1,#0x200
000186  4836              LDR      r0,|L1.608|
000188  f7fff7ff          BL       GPIO_WriteBit
;;;94           Delay(0x2FFFF);
00018c  483a              LDR      r0,|L1.632|
00018e  f7fff7ff          BL       Delay
;;;95           GPIO_WriteBit(GPIOB, GPIO_Pin_10, (BitAction)(1 - GPIO_ReadOutputDataBit(GPIOB, GPIO_Pin_10)));
000192  f44ff44f          MOV      r1,#0x400
000196  4832              LDR      r0,|L1.608|
000198  f7fff7ff          BL       GPIO_ReadOutputDataBit
00019c  f1c0f1c0          RSB      r0,r0,#1
0001a0  b2c4              UXTB     r4,r0
0001a2  4622              MOV      r2,r4
0001a4  f44ff44f          MOV      r1,#0x400
0001a8  482d              LDR      r0,|L1.608|
0001aa  f7fff7ff          BL       GPIO_WriteBit
;;;96           Delay(0x2FFFF);
0001ae  4832              LDR      r0,|L1.632|
0001b0  f7fff7ff          BL       Delay
;;;97           GPIO_WriteBit(GPIOB, GPIO_Pin_11, (BitAction)(1 - GPIO_ReadOutputDataBit(GPIOB, GPIO_Pin_11)));
0001b4  f44ff44f          MOV      r1,#0x800
0001b8  4829              LDR      r0,|L1.608|
0001ba  f7fff7ff          BL       GPIO_ReadOutputDataBit
0001be  f1c0f1c0          RSB      r0,r0,#1
0001c2  b2c4              UXTB     r4,r0
0001c4  4622              MOV      r2,r4
0001c6  f44ff44f          MOV      r1,#0x800
0001ca  4825              LDR      r0,|L1.608|
0001cc  f7fff7ff          BL       GPIO_WriteBit
;;;98           Delay(0x2FFFF); 
0001d0  4829              LDR      r0,|L1.632|
0001d2  f7fff7ff          BL       Delay
;;;99     	  GPIO_WriteBit(GPIOB, GPIO_Pin_12, (BitAction)(1 - GPIO_ReadOutputDataBit(GPIOB, GPIO_Pin_12)));
0001d6  f44ff44f          MOV      r1,#0x1000
0001da  4821              LDR      r0,|L1.608|
0001dc  f7fff7ff          BL       GPIO_ReadOutputDataBit
0001e0  f1c0f1c0          RSB      r0,r0,#1
0001e4  b2c4              UXTB     r4,r0
0001e6  4622              MOV      r2,r4
0001e8  f44ff44f          MOV      r1,#0x1000
0001ec  481c              LDR      r0,|L1.608|
0001ee  f7fff7ff          BL       GPIO_WriteBit
;;;100          Delay(0x2FFFF); 
0001f2  4821              LDR      r0,|L1.632|
0001f4  f7fff7ff          BL       Delay
;;;101    	  GPIO_WriteBit(GPIOB, GPIO_Pin_13, (BitAction)(1 - GPIO_ReadOutputDataBit(GPIOB, GPIO_Pin_13)));
0001f8  f44ff44f          MOV      r1,#0x2000
0001fc  4818              LDR      r0,|L1.608|
0001fe  f7fff7ff          BL       GPIO_ReadOutputDataBit
000202  f1c0f1c0          RSB      r0,r0,#1
000206  b2c4              UXTB     r4,r0
000208  4622              MOV      r2,r4
00020a  f44ff44f          MOV      r1,#0x2000
00020e  4814              LDR      r0,|L1.608|
000210  f7fff7ff          BL       GPIO_WriteBit
;;;102          Delay(0x2FFFF); 
000214  4818              LDR      r0,|L1.632|
000216  f7fff7ff          BL       Delay
;;;103    	  GPIO_WriteBit(GPIOB, GPIO_Pin_14, (BitAction)(1 - GPIO_ReadOutputDataBit(GPIOB, GPIO_Pin_14)));
00021a  f44ff44f          MOV      r1,#0x4000
00021e  4810              LDR      r0,|L1.608|
000220  f7fff7ff          BL       GPIO_ReadOutputDataBit
000224  f1c0f1c0          RSB      r0,r0,#1
000228  b2c4              UXTB     r4,r0
00022a  4622              MOV      r2,r4
00022c  f44ff44f          MOV      r1,#0x4000
000230  480b              LDR      r0,|L1.608|
000232  f7fff7ff          BL       GPIO_WriteBit
;;;104          Delay(0x2FFFF); 
000236  4810              LDR      r0,|L1.632|
000238  f7fff7ff          BL       Delay
;;;105    	  GPIO_WriteBit(GPIOB, GPIO_Pin_15, (BitAction)(1 - GPIO_ReadOutputDataBit(GPIOB, GPIO_Pin_15)));
00023c  f44ff44f          MOV      r1,#0x8000
000240  4807              LDR      r0,|L1.608|
000242  f7fff7ff          BL       GPIO_ReadOutputDataBit
000246  f1c0f1c0          RSB      r0,r0,#1
00024a  b2c4              UXTB     r4,r0
00024c  4622              MOV      r2,r4
00024e  f44ff44f          MOV      r1,#0x8000
000252  4803              LDR      r0,|L1.608|
000254  f7fff7ff          BL       GPIO_WriteBit
;;;106          Delay(0x2FFFF); 
000258  4807              LDR      r0,|L1.632|
00025a  f7fff7ff          BL       Delay
                  |L1.606|
00025e  e776              B        |L1.334|
;;;107      //  }
;;;108      }
;;;109    }
;;;110    
                          ENDP

                  |L1.608|
000260  40010c00          DCD      0x40010c00
                  |L1.612|
000264  40010800          DCD      0x40010800
                  |L1.616|
000268  40011000          DCD      0x40011000
                  |L1.620|
00026c  00000000          DCD      NVIC_InitStructure
                  |L1.624|
000270  00000000          DCD      PreemptionPriorityValue
                  |L1.628|
000274  0002c39a          DCD      0x0002c39a
                  |L1.632|
000278  0002ffff          DCD      0x0002ffff

                          AREA ||.data||, DATA, ALIGN=0

                  PreemptionOccured
000000  00                DCB      0x00
                  PreemptionPriorityValue
000001  00                DCB      0x00
                  NVIC_InitStructure
000002  00000000          DCDU     0x00000000

                  __ARM_use_no_argv EQU 0

⌨️ 快捷键说明

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