Browse Source

更改默认不启动qspi驱动 N25@128

jinsheng 6 years ago
parent
commit
57036d8d4a

+ 3 - 14
bsp/stm32/stm32f746-st-disco/.config

@@ -125,18 +125,7 @@ CONFIG_RT_USING_PIN=y
 # CONFIG_RT_USING_PM is not set
 # CONFIG_RT_USING_PM is not set
 # CONFIG_RT_USING_RTC is not set
 # CONFIG_RT_USING_RTC is not set
 # CONFIG_RT_USING_SDIO is not set
 # CONFIG_RT_USING_SDIO is not set
-CONFIG_RT_USING_SPI=y
-CONFIG_RT_USING_QSPI=y
-# CONFIG_RT_USING_SPI_MSD is not set
-CONFIG_RT_USING_SFUD=y
-CONFIG_RT_SFUD_USING_SFDP=y
-CONFIG_RT_SFUD_USING_FLASH_INFO_TABLE=y
-CONFIG_RT_SFUD_USING_QSPI=y
-# CONFIG_RT_DEBUG_SFUD is not set
-# CONFIG_RT_USING_W25QXX is not set
-# CONFIG_RT_USING_GD is not set
-# CONFIG_RT_USING_ENC28J60 is not set
-# CONFIG_RT_USING_SPI_WIFI is not set
+# CONFIG_RT_USING_SPI is not set
 # CONFIG_RT_USING_WDT is not set
 # CONFIG_RT_USING_WDT is not set
 # CONFIG_RT_USING_AUDIO is not set
 # CONFIG_RT_USING_AUDIO is not set
 
 
@@ -317,7 +306,7 @@ CONFIG_SOC_STM32F746NG=y
 # Onboard Peripheral Drivers
 # Onboard Peripheral Drivers
 #
 #
 CONFIG_BSP_USING_USB_TO_USART=y
 CONFIG_BSP_USING_USB_TO_USART=y
-CONFIG_BSP_USING_QSPI_FLASH=y
+# CONFIG_BSP_USING_QSPI_FLASH is not set
 
 
 #
 #
 # On-chip Peripheral Drivers
 # On-chip Peripheral Drivers
@@ -326,7 +315,7 @@ CONFIG_BSP_USING_GPIO=y
 CONFIG_BSP_USING_UART=y
 CONFIG_BSP_USING_UART=y
 CONFIG_BSP_USING_UART1=y
 CONFIG_BSP_USING_UART1=y
 # CONFIG_BSP_UART1_RX_USING_DMA is not set
 # CONFIG_BSP_UART1_RX_USING_DMA is not set
-CONFIG_BSP_USING_QSPI=y
+# CONFIG_BSP_USING_QSPI is not set
 
 
 #
 #
 # Board extended module Drivers
 # Board extended module Drivers

+ 4 - 7
bsp/stm32/stm32f746-st-disco/README.md

@@ -96,17 +96,14 @@ STM32F746-disco 是 ST 推出的一款基于 ARM Cortex-M7 内核的开发板,
 ```bash
 ```bash
  \ | /
  \ | /
 - RT -     Thread Operating System
 - RT -     Thread Operating System
- / | \     4.0.0 build Jan 26 2019
+ / | \     4.0.0 build Jan 30 2019
  2006 - 2018 Copyright by rt-thread team
  2006 - 2018 Copyright by rt-thread team
-[D/drv.qspi] qspi init succsee!
-[SFUD] Find a Micron flash chip. Size is 16777216 bytes.
-[SFUD] n25q128 flash device is initialize success.
-[D/drv.qspi] qspi init succsee!
-flash already enter qspi mode
+msh >
 ```
 ```
+
 ### 进阶使用
 ### 进阶使用
 
 
-此 BSP 默认开启了 GPIO, 串口1, QSPI和SFUD的功能,更多高级功能,需要利用 ENV 工具对 BSP 进行配置,步骤如下:
+此 BSP 默认只开启了 GPIO 和 串口1 的功能,更多高级功能,需要利用 ENV 工具对 BSP 进行配置,步骤如下:
 
 
 1. 在 bsp 下打开 env 工具。
 1. 在 bsp 下打开 env 工具。
 
 

+ 1 - 1
bsp/stm32/stm32f746-st-disco/board/Kconfig

@@ -12,7 +12,7 @@ menu "Onboard Peripheral Drivers"
         select BSP_USING_UART1
         select BSP_USING_UART1
         default y
         default y
     config BSP_USING_QSPI_FLASH
     config BSP_USING_QSPI_FLASH
-        bool "Enable QSPI FLASH (N25Q256 qspi)"
+        bool "Enable QSPI FLASH (N25Q256 qspi1)"
         select BSP_USING_QSPI
         select BSP_USING_QSPI
         select RT_USING_SFUD
         select RT_USING_SFUD
         select RT_SFUD_USING_QSPI
         select RT_SFUD_USING_QSPI

+ 8 - 6
bsp/stm32/stm32f746-st-disco/project.ewp

@@ -346,6 +346,7 @@
           <state>$PROJ_DIR$\..\..\..\components\finsh</state>
           <state>$PROJ_DIR$\..\..\..\components\finsh</state>
           <state>$PROJ_DIR$\..\..\..\libcpu\arm\common</state>
           <state>$PROJ_DIR$\..\..\..\libcpu\arm\common</state>
           <state>$PROJ_DIR$\..\..\..\libcpu\arm\cortex-m7</state>
           <state>$PROJ_DIR$\..\..\..\libcpu\arm\cortex-m7</state>
+          <state>$PROJ_DIR$\board\ports</state>
           <state>$PROJ_DIR$\..\..\..\components\drivers\include</state>
           <state>$PROJ_DIR$\..\..\..\components\drivers\include</state>
           <state>$PROJ_DIR$\.</state>
           <state>$PROJ_DIR$\.</state>
           <state>$PROJ_DIR$\applications</state>
           <state>$PROJ_DIR$\applications</state>
@@ -1375,6 +1376,7 @@
           <state>$PROJ_DIR$\..\..\..\components\finsh</state>
           <state>$PROJ_DIR$\..\..\..\components\finsh</state>
           <state>$PROJ_DIR$\..\..\..\libcpu\arm\common</state>
           <state>$PROJ_DIR$\..\..\..\libcpu\arm\common</state>
           <state>$PROJ_DIR$\..\..\..\libcpu\arm\cortex-m7</state>
           <state>$PROJ_DIR$\..\..\..\libcpu\arm\cortex-m7</state>
+          <state>$PROJ_DIR$\board\ports</state>
           <state>$PROJ_DIR$\..\..\..\components\drivers\include</state>
           <state>$PROJ_DIR$\..\..\..\components\drivers\include</state>
           <state>$PROJ_DIR$\.</state>
           <state>$PROJ_DIR$\.</state>
           <state>$PROJ_DIR$\applications</state>
           <state>$PROJ_DIR$\applications</state>
@@ -2135,21 +2137,21 @@
     </file>
     </file>
   </group>
   </group>
   <group>
   <group>
-    <name>CORTEX-M7</name>
+    <name>cpu</name>
     <file>
     <file>
-      <name>$PROJ_DIR$\..\..\..\libcpu\arm\cortex-m7\cpuport.c</name>
+      <name>$PROJ_DIR$\..\..\..\libcpu\arm\common\backtrace.c</name>
     </file>
     </file>
     <file>
     <file>
-      <name>$PROJ_DIR$\..\..\..\libcpu\arm\cortex-m7\context_iar.S</name>
+      <name>$PROJ_DIR$\..\..\..\libcpu\arm\common\div0.c</name>
     </file>
     </file>
     <file>
     <file>
-      <name>$PROJ_DIR$\..\..\..\libcpu\arm\common\backtrace.c</name>
+      <name>$PROJ_DIR$\..\..\..\libcpu\arm\common\showmem.c</name>
     </file>
     </file>
     <file>
     <file>
-      <name>$PROJ_DIR$\..\..\..\libcpu\arm\common\div0.c</name>
+      <name>$PROJ_DIR$\..\..\..\libcpu\arm\cortex-m7\cpuport.c</name>
     </file>
     </file>
     <file>
     <file>
-      <name>$PROJ_DIR$\..\..\..\libcpu\arm\common\showmem.c</name>
+      <name>$PROJ_DIR$\..\..\..\libcpu\arm\cortex-m7\context_iar.S</name>
     </file>
     </file>
   </group>
   </group>
   <group>
   <group>

+ 1 - 90
bsp/stm32/stm32f746-st-disco/project.uvprojx

@@ -332,7 +332,7 @@
               <MiscControls />
               <MiscControls />
               <Define>USE_HAL_DRIVER, STM32F746xx</Define>
               <Define>USE_HAL_DRIVER, STM32F746xx</Define>
               <Undefine />
               <Undefine />
-              <IncludePath>.;..\..\..\include;applications;.;board;board\CubeMX_Config\Inc;board\ports;..\libraries\HAL_Drivers;..\libraries\HAL_Drivers\config;..\..\..\libcpu\arm\common;..\..\..\libcpu\arm\cortex-m7;..\..\..\components\drivers\include;..\..\..\components\drivers\include;..\..\..\components\drivers\spi;..\..\..\components\drivers\include;..\..\..\components\drivers\spi\sfud\inc;..\..\..\components\drivers\include;..\..\..\components\finsh;..\libraries\STM32F7xx_HAL\STM32F7xx_HAL_Driver\Inc;..\libraries\STM32F7xx_HAL\CMSIS\Device\ST\STM32F7xx\Include;..\libraries\STM32F7xx_HAL\CMSIS\Include</IncludePath>
+              <IncludePath>.;..\..\..\include;applications;.;board;board\CubeMX_Config\Inc;board\ports;..\libraries\HAL_Drivers;..\libraries\HAL_Drivers\config;..\..\..\libcpu\arm\common;..\..\..\libcpu\arm\cortex-m7;..\..\..\components\drivers\include;..\..\..\components\drivers\include;..\..\..\components\drivers\include;..\..\..\components\finsh;..\libraries\STM32F7xx_HAL\STM32F7xx_HAL_Driver\Inc;..\libraries\STM32F7xx_HAL\CMSIS\Device\ST\STM32F7xx\Include;..\libraries\STM32F7xx_HAL\CMSIS\Include</IncludePath>
             </VariousControls>
             </VariousControls>
           </Cads>
           </Cads>
           <Aads>
           <Aads>
@@ -507,13 +507,6 @@
               <FilePath>board\CubeMX_Config\Src\stm32f7xx_hal_msp.c</FilePath>
               <FilePath>board\CubeMX_Config\Src\stm32f7xx_hal_msp.c</FilePath>
             </File>
             </File>
           </Files>
           </Files>
-          <Files>
-            <File>
-              <FileName>drv_qspi_flash.c</FileName>
-              <FileType>1</FileType>
-              <FilePath>board\ports\drv_qspi_flash.c</FilePath>
-            </File>
-          </Files>
           <Files>
           <Files>
             <File>
             <File>
               <FileName>startup_stm32f746xx.s</FileName>
               <FileName>startup_stm32f746xx.s</FileName>
@@ -535,20 +528,6 @@
               <FilePath>..\libraries\HAL_Drivers\drv_usart.c</FilePath>
               <FilePath>..\libraries\HAL_Drivers\drv_usart.c</FilePath>
             </File>
             </File>
           </Files>
           </Files>
-          <Files>
-            <File>
-              <FileName>drv_spi.c</FileName>
-              <FileType>1</FileType>
-              <FilePath>..\libraries\HAL_Drivers\drv_spi.c</FilePath>
-            </File>
-          </Files>
-          <Files>
-            <File>
-              <FileName>drv_qspi.c</FileName>
-              <FileType>1</FileType>
-              <FilePath>..\libraries\HAL_Drivers\drv_qspi.c</FilePath>
-            </File>
-          </Files>
           <Files>
           <Files>
             <File>
             <File>
               <FileName>drv_common.c</FileName>
               <FileName>drv_common.c</FileName>
@@ -611,48 +590,6 @@
               <FilePath>..\..\..\components\drivers\serial\serial.c</FilePath>
               <FilePath>..\..\..\components\drivers\serial\serial.c</FilePath>
             </File>
             </File>
           </Files>
           </Files>
-          <Files>
-            <File>
-              <FileName>spi_core.c</FileName>
-              <FileType>1</FileType>
-              <FilePath>..\..\..\components\drivers\spi\spi_core.c</FilePath>
-            </File>
-          </Files>
-          <Files>
-            <File>
-              <FileName>spi_dev.c</FileName>
-              <FileType>1</FileType>
-              <FilePath>..\..\..\components\drivers\spi\spi_dev.c</FilePath>
-            </File>
-          </Files>
-          <Files>
-            <File>
-              <FileName>qspi_core.c</FileName>
-              <FileType>1</FileType>
-              <FilePath>..\..\..\components\drivers\spi\qspi_core.c</FilePath>
-            </File>
-          </Files>
-          <Files>
-            <File>
-              <FileName>spi_flash_sfud.c</FileName>
-              <FileType>1</FileType>
-              <FilePath>..\..\..\components\drivers\spi\spi_flash_sfud.c</FilePath>
-            </File>
-          </Files>
-          <Files>
-            <File>
-              <FileName>sfud.c</FileName>
-              <FileType>1</FileType>
-              <FilePath>..\..\..\components\drivers\spi\sfud\src\sfud.c</FilePath>
-            </File>
-          </Files>
-          <Files>
-            <File>
-              <FileName>sfud_sfdp.c</FileName>
-              <FileType>1</FileType>
-              <FilePath>..\..\..\components\drivers\spi\sfud\src\sfud_sfdp.c</FilePath>
-            </File>
-          </Files>
           <Files>
           <Files>
             <File>
             <File>
               <FileName>completion.c</FileName>
               <FileName>completion.c</FileName>
@@ -702,18 +639,6 @@
               <FilePath>..\..\..\components\drivers\src\workqueue.c</FilePath>
               <FilePath>..\..\..\components\drivers\src\workqueue.c</FilePath>
             </File>
             </File>
           </Files>
           </Files>
-          <GroupOption>
-            <GroupArmAds>
-              <Cads>
-                <VariousControls>
-                  <MiscControls> --c99</MiscControls>
-                  <Define> </Define>
-                  <Undefine> </Undefine>
-                  <IncludePath> </IncludePath>
-                </VariousControls>
-              </Cads>
-            </GroupArmAds>
-          </GroupOption>
         </Group>
         </Group>
         <Group>
         <Group>
           <GroupName>finsh</GroupName>
           <GroupName>finsh</GroupName>
@@ -888,20 +813,6 @@
               <FilePath>..\libraries\STM32F7xx_HAL\STM32F7xx_HAL_Driver\Src\stm32f7xx_hal_usart.c</FilePath>
               <FilePath>..\libraries\STM32F7xx_HAL\STM32F7xx_HAL_Driver\Src\stm32f7xx_hal_usart.c</FilePath>
             </File>
             </File>
           </Files>
           </Files>
-          <Files>
-            <File>
-              <FileName>stm32f7xx_hal_spi.c</FileName>
-              <FileType>1</FileType>
-              <FilePath>..\libraries\STM32F7xx_HAL\STM32F7xx_HAL_Driver\Src\stm32f7xx_hal_spi.c</FilePath>
-            </File>
-          </Files>
-          <Files>
-            <File>
-              <FileName>stm32f7xx_hal_qspi.c</FileName>
-              <FileType>1</FileType>
-              <FilePath>..\libraries\STM32F7xx_HAL\STM32F7xx_HAL_Driver\Src\stm32f7xx_hal_qspi.c</FilePath>
-            </File>
-          </Files>
         </Group>
         </Group>
       </Groups>
       </Groups>
     </Target>
     </Target>

+ 0 - 8
bsp/stm32/stm32f746-st-disco/rtconfig.h

@@ -79,12 +79,6 @@
 #define RT_USING_SERIAL
 #define RT_USING_SERIAL
 #define RT_SERIAL_USING_DMA
 #define RT_SERIAL_USING_DMA
 #define RT_USING_PIN
 #define RT_USING_PIN
-#define RT_USING_SPI
-#define RT_USING_QSPI
-#define RT_USING_SFUD
-#define RT_SFUD_USING_SFDP
-#define RT_SFUD_USING_FLASH_INFO_TABLE
-#define RT_SFUD_USING_QSPI
 
 
 /* Using WiFi */
 /* Using WiFi */
 
 
@@ -167,14 +161,12 @@
 /* Onboard Peripheral Drivers */
 /* Onboard Peripheral Drivers */
 
 
 #define BSP_USING_USB_TO_USART
 #define BSP_USING_USB_TO_USART
-#define BSP_USING_QSPI_FLASH
 
 
 /* On-chip Peripheral Drivers */
 /* On-chip Peripheral Drivers */
 
 
 #define BSP_USING_GPIO
 #define BSP_USING_GPIO
 #define BSP_USING_UART
 #define BSP_USING_UART
 #define BSP_USING_UART1
 #define BSP_USING_UART1
-#define BSP_USING_QSPI
 
 
 /* Board extended module Drivers */
 /* Board extended module Drivers */