TRY 文件系统,关闭WIFI
This commit is contained in:
parent
c070045513
commit
71a393d937
@ -240,8 +240,37 @@ W25Q64→注册为spi20设备,挂载到spi2总线上(**SPI设备**)→*通
|
|||||||
|
|
||||||
### DFS结合FAL配置W25Q64
|
### DFS结合FAL配置W25Q64
|
||||||

|

|
||||||
|
1. 开启板上外设
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
|
2. 配置自动挂载
|
||||||
|
|
||||||
|
yw
|
||||||
|
|
||||||
|
3. 配置Component组件
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
|
4. 配置DFS
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
|
5. 配置elmFat
|
||||||
|
|
||||||
|

|
||||||
|
因为WiFi和flash挂在同一个spi下
|
||||||
|
所以需要先关闭WiFi,在main函数加以下代码
|
||||||
|
计算引脚 CS:90 (F-A)*16 + 10 = 90
|
||||||
|
``` c
|
||||||
|
#define WIFI_CS GET_PIN(F, 10)
|
||||||
|
void WIFI_CS_PULL_DOWM(void)
|
||||||
|
{
|
||||||
|
rt_pin_mode(WIFI_CS, PIN_MODE_OUTPUT);
|
||||||
|
rt_pin_write(WIFI_CS, PIN_LOW);
|
||||||
|
}
|
||||||
|
INIT_BOARD_EXPORT(WIFI_CS GET_PIN);
|
||||||
|
```
|
||||||
## 我的实践
|
## 我的实践
|
||||||
### 读取传感器数据,上传到阿里云
|
### 读取传感器数据,上传到阿里云
|
||||||
(合并头两个代码),拼接字符串时我用了`sprintf`,其实应该也可以样例原有的`HAL_Snprintf`的
|
(合并头两个代码),拼接字符串时我用了`sprintf`,其实应该也可以样例原有的`HAL_Snprintf`的
|
||||||
|
BIN
Day5/文件系统开关1.png
Normal file
BIN
Day5/文件系统开关1.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 60 KiB |
BIN
Day5/文件系统开关2.png
Normal file
BIN
Day5/文件系统开关2.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 28 KiB |
BIN
Day5/文件系统开关3.png
Normal file
BIN
Day5/文件系统开关3.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 46 KiB |
BIN
Day5/文件系统开关4.png
Normal file
BIN
Day5/文件系统开关4.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 52 KiB |
BIN
Day5/文件系统开关5.png
Normal file
BIN
Day5/文件系统开关5.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 53 KiB |
@ -77,3 +77,11 @@ static int onboard_sdcard_mount(void)
|
|||||||
|
|
||||||
return RT_EOK;
|
return RT_EOK;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#define WIFI_CS GET_PIN(F, 10)
|
||||||
|
void WIFI_CS_PULL_DOWM(void)
|
||||||
|
{
|
||||||
|
rt_pin_mode(WIFI_CS, PIN_MODE_OUTPUT);
|
||||||
|
rt_pin_write(WIFI_CS, PIN_LOW);
|
||||||
|
}
|
||||||
|
INIT_BOARD_EXPORT(WIFI_CS_PULL_DOWM);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user