Skip to content

Commit 74faed0

Browse files
authored
SDK v1.1.0,add 07_module_xxx (#12)
* add 07_module_key_matrix * add 07_module_spi_eth_enc28j60 * add 07_module_ultrasonic_sr04 * add 07_module_ws2812_led * update pdf
1 parent 9438058 commit 74faed0

File tree

198 files changed

+35470
-15077
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

198 files changed

+35470
-15077
lines changed

README.md

+41-37
Original file line numberDiff line numberDiff line change
@@ -33,42 +33,46 @@
3333
示例项目文件夹和相应学习阶段如下所示:
3434

3535

36-
| 阶段 | 序号 | 项目实现功能 | 项目文件夹名称 |
37-
| ------------------------ | ---- | :-------------------------------- | ------------------------ |
38-
| 01,入门 RT-Thread 内核 | 01 | RT-Thread 内核学习 | 01_kernel |
39-
| 02,简单外设的使用 | 02 | LED 闪烁例程 | 02_basic_led_blink |
40-
| | 03 | RGB LED 例程 | 02_basic_rgb_led |
41-
| | 04 | 按键输入例程 | 02_basic_key |
42-
| | 05 | 蜂鸣器和 LED 控制例程 | 02_basic_irq_beep |
43-
| | 06 | 红外遥控例程 | 02_basic_ir |
44-
| | 07 | RTC 和 RTC 闹钟的使用例程 | 02_basic_rtc |
45-
| 03,板载外设模块的使用 | 08 | LCD 显示例程 | 03_driver_lcd |
46-
| | 09 | AHT10 温湿度传感器例程 | 03_driver_temp_humi |
47-
| | 10 | AP3216C 接近与光强传感器例程 | 03_driver_als_ps |
48-
| | 11 | ICM20608 六轴传感器例程 | 03_driver_axis |
49-
| | 12 | CAN 通信例程 | 03_driver_can |
50-
| | 13 | LED MATRIX 闪烁例程 | 03_driver_led_matrix |
51-
| 04,RT-Thread 组件的使用 | 14 | USB 鼠标例程 | 04_component_usb_mouse |
52-
| | 15 | TF 卡文件系统例程 | 04_component_fs_tf_card |
53-
| | 16 | 低功耗例程 | 04_component_pm |
54-
| | 17 | Flash 分区管理例程 | 04_component_fal |
55-
| | 18 | KV 参数存储例程 | 04_component_kv |
56-
| | 19 | SPI Flash 文件系统例程 | 04_component_fs_flash |
57-
| 05,IoT 相关组件的使用 | 20 | WiFi 管理例程 | 05_iot_wifi_manager |
58-
| | 21 | MQTT 协议通信例程 | 05_iot_mqtt |
59-
| | 22 | HTTP Client 功能实现例程 | 05_iot_http_client |
60-
| | 23 | MEMBEDTLS 例程 | 05_iot_mbedtls |
61-
| | 24 | Ymodem 协议固件升级例程 | 05_iot_ota_ymodem |
62-
| | 25 | HTTP 协议固件升级例程 | 05_iot_ota_http |
63-
| | 26 | 网络小工具集使用例程 | 05_iot_netutils |
64-
| | 27 | 中国移动 OneNET 云平台接入例程 | 05_iot_cloud_onenet |
65-
| | 28 | 阿里云物联网平台接入例程 | 05_iot_cloud_ali_iotkit |
66-
| | 29 | 使用 Web 服务器组件:WebNet | 05_iot_web_server |
67-
| 06,综合 Demo 学习 | 30 | LVGL 例程 | 06_demo_lvgl |
68-
| | 31 | MicroPython 例程 | 06_demo_micropython |
69-
| | 32 | 板载 LED matrix 和 RS485 驱动例程 | 06_demo_rs485_led_matrix |
70-
| | 33 | nes 模拟器实验 | 06_demo_nes_simulator |
71-
| | 34 | 开发板综合 Demo(出厂 Demo) | 06_demo_factory |
36+
| 阶段 | 序号 | 项目实现功能 | 项目文件夹名称 |
37+
| ------------------------ | ---- | :-------------------------------- | -------------------------- |
38+
| 01,入门 RT-Thread 内核 | 01 | RT-Thread 内核学习 | 01_kernel |
39+
| 02,简单外设的使用 | 02 | LED 闪烁例程 | 02_basic_led_blink |
40+
| | 03 | RGB LED 例程 | 02_basic_rgb_led |
41+
| | 04 | 按键输入例程 | 02_basic_key |
42+
| | 05 | 蜂鸣器和 LED 控制例程 | 02_basic_irq_beep |
43+
| | 06 | 红外遥控例程 | 02_basic_ir |
44+
| | 07 | RTC 和 RTC 闹钟的使用例程 | 02_basic_rtc |
45+
| 03,板载外设模块的使用 | 08 | LCD 显示例程 | 03_driver_lcd |
46+
| | 09 | AHT10 温湿度传感器例程 | 03_driver_temp_humi |
47+
| | 10 | AP3216C 接近与光强传感器例程 | 03_driver_als_ps |
48+
| | 11 | ICM20608 六轴传感器例程 | 03_driver_axis |
49+
| | 12 | CAN 通信例程 | 03_driver_can |
50+
| | 13 | LED MATRIX 闪烁例程 | 03_driver_led_matrix |
51+
| 04,RT-Thread 组件的使用 | 14 | USB 鼠标例程 | 04_component_usb_mouse |
52+
| | 15 | TF 卡文件系统例程 | 04_component_fs_tf_card |
53+
| | 16 | 低功耗例程 | 04_component_pm |
54+
| | 17 | Flash 分区管理例程 | 04_component_fal |
55+
| | 18 | KV 参数存储例程 | 04_component_kv |
56+
| | 19 | SPI Flash 文件系统例程 | 04_component_fs_flash |
57+
| 05,IoT 相关组件的使用 | 20 | WiFi 管理例程 | 05_iot_wifi_manager |
58+
| | 21 | MQTT 协议通信例程 | 05_iot_mqtt |
59+
| | 22 | HTTP Client 功能实现例程 | 05_iot_http_client |
60+
| | 23 | MEMBEDTLS 例程 | 05_iot_mbedtls |
61+
| | 24 | Ymodem 协议固件升级例程 | 05_iot_ota_ymodem |
62+
| | 25 | HTTP 协议固件升级例程 | 05_iot_ota_http |
63+
| | 26 | 网络小工具集使用例程 | 05_iot_netutils |
64+
| | 27 | 中国移动 OneNET 云平台接入例程 | 05_iot_cloud_onenet |
65+
| | 28 | 阿里云物联网平台接入例程 | 05_iot_cloud_ali_iotkit |
66+
| | 29 | 使用 Web 服务器组件:WebNet | 05_iot_web_server |
67+
| 06,综合 Demo 学习 | 30 | LVGL 例程 | 06_demo_lvgl |
68+
| | 31 | MicroPython 例程 | 06_demo_micropython |
69+
| | 32 | 板载 LED matrix 和 RS485 驱动例程 | 06_demo_rs485_led_matrix |
70+
| | 33 | nes 模拟器实验 | 06_demo_nes_simulator |
71+
| | 34 | 开发板综合 Demo(出厂 Demo) | 06_demo_factory |
72+
| 07,教育套件对应模块例程 | 35 | 矩阵键盘模块例程 | 07_module_key_matrix |
73+
| | 36 | ENC28J60 网络模块例程 | 07_module_spi_eth_enc28j60 |
74+
| | 37 | 超声波测距模块例程 | 07_module_ultrasonic_sr04 |
75+
| | 38 | ws2812 led 灯带例程 | 07_module_ws2812_led |
7276

7377
## 使用
7478

@@ -83,7 +87,7 @@ sdk-bsp-stm32f407-spark 支持 RT-Thread Studio 和 MDK 开发。
8387

8488
为了避免 SDK 在持续更新中,每一个 `projects` 都创建一份 `rt-thread` 文件夹 和 `libraries` 文件夹导致的 SDK 越来越臃肿,所以这些通用文件夹被单独提取了出来。这样就会导致直接打开 `MDK` 的工程编译会提示缺少上述两个文件夹的文件,我们使用如下步骤解决这个问题:
8589

86-
1. 双击某个 `project` 目录下的 `mklinks.bat` 文件,或者使用 [Env](https://club.rt-thread.org/ask/question/5699.html) 工具执行 mklink 命令,分别为 `rt-thread``libraries` 文件创建符号链接。
90+
1. 双击某个 `project` 目录下的 `mklinks.bat` 文件,或者使用 [Env](https://club.rt-thread.org/ask/question/5699.html) 工具执行 mklinks.bat 命令,分别为 `rt-thread``libraries` 文件创建符号链接。
8791
2. 查看目录下是否有 `rt-thread``libraries` 的文件夹图标。
8892
3. 使用 [Env](https://club.rt-thread.org/ask/question/5699.html) 工具执行 scons --target=mdk5 更新 MDK5 工程文件。
8993

Binary file not shown.
Binary file not shown.

libraries/Board_Drivers/SConscript

+3
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,9 @@ if GetDepend(['BSP_USING_ONBOARD_LED_MATRIX']):
4040
src += Glob('led_matrix/drv_matrix_led.c')
4141
path += [cwd + '/led_matrix']
4242

43+
if GetDepend(['BSP_USING_NEOPIXEL']):
44+
src += Glob('led_matrix/drv_neo_pixel.c')
45+
4346
if GetDepend(['BSP_USING_EASYFLASH']):
4447
src += Glob('ef_fal_port.c')
4548

libraries/Board_Drivers/drv_enc28j60.c

+2-3
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,13 @@
88
* 2018-08-27 ZYLX the first version
99
*/
1010

11-
#include <drivers/pin.h>
11+
#include <rtdevice.h>
1212
#include <enc28j60.h>
1313
#include "drv_spi.h"
1414
#include "board.h"
1515

1616
#define PIN_NRF_IRQ GET_PIN(E,2)
1717

18-
1918
int enc28j60_init(void)
2019
{
2120
__HAL_RCC_GPIOD_CLK_ENABLE();
@@ -26,7 +25,7 @@ int enc28j60_init(void)
2625

2726
/* init interrupt pin */
2827
rt_pin_mode(PIN_NRF_IRQ, PIN_MODE_INPUT_PULLUP);
29-
rt_pin_attach_irq(PIN_NRF_IRQ, PIN_IRQ_MODE_FALLING, (void(*)(void*))enc28j60_isr, RT_NULL);
28+
rt_pin_attach_irq(PIN_NRF_IRQ, PIN_IRQ_MODE_FALLING, (void(*)(void *))enc28j60_isr, RT_NULL);
3029
rt_pin_irq_enable(PIN_NRF_IRQ, PIN_IRQ_ENABLE);
3130

3231
return 0;

0 commit comments

Comments
 (0)