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

📄 waveplayer.txt

📁 STM32F103ZET6+UCOSII+UCGUI源码
💻 TXT
📖 第 1 页 / 共 4 页
字号:
;;;231        if(MyKey == SEL)
00010e  2c01              CMP      r4,#1
000110  d11e              BNE      |L4.336|
;;;232        {
;;;233          /* Mask All Interrupts */
;;;234          NVIC_SETPRIMASK();
000112  f7fffffe          BL       NVIC_SETPRIMASK
;;;235    
;;;236          /* Update the display information */
;;;237          LCD_Update(STOP);
000116  0720              LSLS     r0,r4,#28
000118  f7fffffe          BL       LCD_Update
;;;238    
;;;239          /* Command the Stop of the current audio stream */
;;;240          SetVar_AudioPlayStatus(AudioPlayStatus_STOPPED);
00011c  2000              MOVS     r0,#0
00011e  f7fffffe          BL       SetVar_AudioPlayStatus
;;;241    
;;;242          /* Disable mask of all interrupts */
;;;243          NVIC_RESETPRIMASK();
000122  f7fffffe          BL       NVIC_RESETPRIMASK
;;;244    
;;;245          I2S_CODEC_Stop();
000126  f7fffffe          BL       I2S_CODEC_Stop
;;;246          SPI_I2S_ITConfig(SPI2, SPI_I2S_IT_TXE, DISABLE);
00012a  2200              MOVS     r2,#0
00012c  2171              MOVS     r1,#0x71
00012e  4821              LDR      r0,|L4.436|
000130  f7fffffe          BL       SPI_I2S_ITConfig
;;;247    
;;;248          /* Enable the FSMC that share a pin w/ I2C1 (LBAR) */
;;;249          RCC_AHBPeriphClockCmd(RCC_AHBPeriph_FSMC, ENABLE);
000134  2101              MOVS     r1,#1
000136  4640              MOV      r0,r8
000138  f7fffffe          BL       RCC_AHBPeriphClockCmd
;;;250    
;;;251          /* Clear the LCD */
;;;252          LCD_Clear(White);
00013c  4650              MOV      r0,r10
00013e  f7fffffe          BL       LCD_Clear
;;;253    
;;;254          /* Display the previous menu */
;;;255          DisplayMenu();
000142  f7fffffe          BL       DisplayMenu
                  |L4.326|
;;;256          /* Enable the JoyStick interrupts */
;;;257          IntExtOnOffConfig(ENABLE); 
;;;258          return;     
;;;259        }
;;;260        /* If "KEY" pushbutton is pressed */
;;;261        if(MyKey == KEY)
;;;262        {
;;;263          /* Mask All Interrupts */
;;;264          NVIC_SETPRIMASK();
;;;265    
;;;266          /* If the Codec is Playing => PAUSE */
;;;267          if (GetVar_AudioPlayStatus() == AudioPlayStatus_PLAYING)
;;;268          {
;;;269            /* Update the display information */
;;;270            LCD_Update(PAUSE);
;;;271    
;;;272            /* Command the Pause of the current stream */
;;;273            SetVar_AudioPlayStatus(AudioPlayStatus_PAUSED);
;;;274          }
;;;275    
;;;276          /* If the Codec is PAUSED => Resume PLAYING */
;;;277          else if (GetVar_AudioPlayStatus() == AudioPlayStatus_PAUSED)
;;;278          {
;;;279            /* Update the LCD display */ 
;;;280            LCD_Update(PLAY); 
;;;281    
;;;282            /* Start playing from the last saved position */
;;;283            I2S_CODEC_Play(GetVar_AudioDataIndex());
;;;284          }
;;;285          /* If the Codec is STOPPED => PLAY from the file start address */
;;;286          else if (GetVar_AudioPlayStatus() == AudioPlayStatus_STOPPED)
;;;287          {
;;;288            /* Update the display information */
;;;289            LCD_Update(PLAY);
;;;290    
;;;291            /* Initialize all devices w/choosen parameters */
;;;292            err = I2S_CODEC_Init(GetVar_CurrentOutputDevice(), AUDIO_FILE_ADDRESS);
;;;293      
;;;294            /* Error message display if failure */
;;;295            if (err != 0)
;;;296            {
;;;297              LCD_DisplayError(err);
;;;298    
;;;299              /* Enable the FSMC that share a pin w/ I2C1 (LBAR) */
;;;300              RCC_AHBPeriphClockCmd(RCC_AHBPeriph_FSMC, ENABLE);
;;;301    
;;;302              /* Clear the LCD */
;;;303              LCD_Clear(White);
;;;304    
;;;305              /* Display the previous menu */
;;;306              DisplayMenu();
;;;307    
;;;308              /* Disable mask of all interrupts */
;;;309              NVIC_RESETPRIMASK();
;;;310    
;;;311              /* Enable the JoyStick interrupts */
;;;312              IntExtOnOffConfig(ENABLE); 
000146  e8bd47f0          POP      {r4-r10,lr}
00014a  2001              MOVS     r0,#1
00014c  f7ffbffe          B.W      IntExtOnOffConfig
                  |L4.336|
000150  2c06              CMP      r4,#6                 ;261
000152  d1db              BNE      |L4.268|
000154  f7fffffe          BL       NVIC_SETPRIMASK
000158  f7fffffe          BL       GetVar_AudioPlayStatus
00015c  2801              CMP      r0,#1                 ;267
00015e  d106              BNE      |L4.366|
000160  0500              LSLS     r0,r0,#20             ;270
000162  f7fffffe          BL       LCD_Update
000166  2002              MOVS     r0,#2                 ;273
000168  f7fffffe          BL       SetVar_AudioPlayStatus
00016c  e7cc              B        |L4.264|
                  |L4.366|
00016e  f7fffffe          BL       GetVar_AudioPlayStatus
000172  2802              CMP      r0,#2                 ;277
000174  d105              BNE      |L4.386|
000176  4648              MOV      r0,r9                 ;280
000178  f7fffffe          BL       LCD_Update
00017c  f7fffffe          BL       GetVar_AudioDataIndex
000180  e00f              B        |L4.418|
                  |L4.386|
000182  f7fffffe          BL       GetVar_AudioPlayStatus
000186  2800              CMP      r0,#0                 ;286
000188  d1be              BNE      |L4.264|
00018a  4648              MOV      r0,r9                 ;289
00018c  f7fffffe          BL       LCD_Update
000190  f7fffffe          BL       GetVar_CurrentOutputDevice
000194  4631              MOV      r1,r6                 ;292
000196  f7fffffe          BL       I2S_CODEC_Init
00019a  2800              CMP      r0,#0                 ;295
00019c  d196              BNE      |L4.204|
;;;313              return; 
;;;314            }  
;;;315              
;;;316            /* Enable Playing the audio file */
;;;317            I2S_CODEC_Play(GetVar_DataStartAddr());
00019e  f7fffffe          BL       GetVar_DataStartAddr
                  |L4.418|
0001a2  f7fffffe          BL       I2S_CODEC_Play
0001a6  e7af              B        |L4.264|
;;;318          }
;;;319          /* Disable mask of all interrupts */
;;;320          NVIC_RESETPRIMASK();
;;;321        }
;;;322      }
;;;323    }
;;;324    
                          ENDP

                  |L4.424|
                          DCD      0x11110100
                  |L4.428|
                          DCD      0x64060000
                  |L4.432|
                          DCD      0x0005ffff
                  |L4.436|
                          DCD      0x40003800

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

                  previoustmp
000000  32                DCB      0x32
                  DemoTitle
000001  53544d            DCB      0x53,0x54,0x4d
000004  33322049          DCB      0x33,0x32,0x20,0x49
000008  32532043          DCB      0x32,0x53,0x20,0x43
00000c  6f646563          DCB      0x6f,0x64,0x65,0x63
000010  2044656d          DCB      0x20,0x44,0x65,0x6d
000014  6f                DCB      0x6f
                  CmdTitle0
000015  202043            DCB      0x20,0x20,0x43
000018  6f6e7472          DCB      0x6f,0x6e,0x74,0x72
00001c  6f6c2042          DCB      0x6f,0x6c,0x20,0x42
000020  7574746f          DCB      0x75,0x74,0x74,0x6f
000024  6e733a20          DCB      0x6e,0x73,0x3a,0x20
000028  20                DCB      0x20
                  CmdTitle1Playing
000029  4b4559            DCB      0x4b,0x45,0x59
00002c  3e506175          DCB      0x3e,0x50,0x61,0x75
000030  73652020          DCB      0x73,0x65,0x20,0x20
000034  55502020          DCB      0x55,0x50,0x20,0x20
000038  3e566f6c          DCB      0x3e,0x56,0x6f,0x6c
00003c  2b                DCB      0x2b
                  CmdTitle2Playing
00003d  53454c            DCB      0x53,0x45,0x4c
000040  3e53746f          DCB      0x3e,0x53,0x74,0x6f
000044  70202020          DCB      0x70,0x20,0x20,0x20
000048  444f574e          DCB      0x44,0x4f,0x57,0x4e
00004c  3e566f6c          DCB      0x3e,0x56,0x6f,0x6c
000050  2d                DCB      0x2d
                  CmdTitle1Paused
000051  4b4559            DCB      0x4b,0x45,0x59
000054  3e506c61          DCB      0x3e,0x50,0x6c,0x61
000058  79202020          DCB      0x79,0x20,0x20,0x20
00005c  55502020          DCB      0x55,0x50,0x20,0x20
000060  3e53706b          DCB      0x3e,0x53,0x70,0x6b
000064  72                DCB      0x72
                  CmdTitle2Paused
000065  53454c            DCB      0x53,0x45,0x4c
000068  3e53746f          DCB      0x3e,0x53,0x74,0x6f
00006c  70202020          DCB      0x70,0x20,0x20,0x20
000070  444f574e          DCB      0x44,0x4f,0x57,0x4e
000074  3e486561          DCB      0x3e,0x48,0x65,0x61
000078  64                DCB      0x64
                  CmdTitle1Stopped
000079  202020            DCB      0x20,0x20,0x20
00007c  20555020          DCB      0x20,0x55,0x50,0x20
000080  3e205370          DCB      0x3e,0x20,0x53,0x70
000084  65616b65          DCB      0x65,0x61,0x6b,0x65
000088  72202020          DCB      0x72,0x20,0x20,0x20
00008c  20                DCB      0x20
                  CmdTitle2Stopped
00008d  202044            DCB      0x20,0x20,0x44
000090  4f574e20          DCB      0x4f,0x57,0x4e,0x20
000094  3e204865          DCB      0x3e,0x20,0x48,0x65
000098  61647068          DCB      0x61,0x64,0x70,0x68
00009c  6f6e6520          DCB      0x6f,0x6e,0x65,0x20
0000a0  20                DCB      0x20
                  StatusTitleStopped
0000a1  202020            DCB      0x20,0x20,0x20
0000a4  20202053          DCB      0x20,0x20,0x20,0x53
0000a8  746f7070          DCB      0x74,0x6f,0x70,0x70
0000ac  65642020          DCB      0x65,0x64,0x20,0x20
0000b0  20202020          DCB      0x20,0x20,0x20,0x20
0000b4  20                DCB      0x20
                  StatusTitlePlaying
0000b5  202020            DCB      0x20,0x20,0x20
0000b8  20202050          DCB      0x20,0x20,0x20,0x50
0000bc  6c617969          DCB      0x6c,0x61,0x79,0x69
0000c0  6e672020          DCB      0x6e,0x67,0x20,0x20
0000c4  20202020          DCB      0x20,0x20,0x20,0x20
0000c8  20                DCB      0x20
                  StatusTitlePaused
0000c9  202020            DCB      0x20,0x20,0x20
0000cc  20202020          DCB      0x20,0x20,0x20,0x20
0000d0  50617573          DCB      0x50,0x61,0x75,0x73
0000d4  65642020          DCB      0x65,0x64,0x20,0x20
0000d8  20202020          DCB      0x20,0x20,0x20,0x20
0000dc  20                DCB      0x20
                  i2cerr
0000dd  455252            DCB      0x45,0x52,0x52
0000e0  4f523a49          DCB      0x4f,0x52,0x3a,0x49
0000e4  32432063          DCB      0x32,0x43,0x20,0x63
0000e8  6f6d2e20          DCB      0x6f,0x6d,0x2e,0x20
0000ec  2d3e5253          DCB      0x2d,0x3e,0x52,0x53
0000f0  54                DCB      0x54
                  memerr
0000f1  455252            DCB      0x45,0x52,0x52
0000f4  4f523a20          DCB      0x4f,0x52,0x3a,0x20
0000f8  4d656d6f          DCB      0x4d,0x65,0x6d,0x6f
0000fc  72792020          DCB      0x72,0x79,0x20,0x20
000100  2d3e5253          DCB      0x2d,0x3e,0x52,0x53
000104  54                DCB      0x54
                  fileerr
000105  455252            DCB      0x45,0x52,0x52
000108  4f523a20          DCB      0x4f,0x52,0x3a,0x20
00010c  4e6f2057          DCB      0x4e,0x6f,0x20,0x57
000110  61766520          DCB      0x61,0x76,0x65,0x20
000114  46696c65          DCB      0x46,0x69,0x6c,0x65
000118  20                DCB      0x20

⌨️ 快捷键说明

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