Skip to content

Commit 295b95c

Browse files
authored
Merge pull request #28 from RT-Thread/master
pr
2 parents c3ffe18 + b12615f commit 295b95c

File tree

744 files changed

+10161
-64368
lines changed

Some content is hidden

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

744 files changed

+10161
-64368
lines changed

bsp/bluetrum/ab32vg1-ab-prougen/README.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,8 @@ ab32vg1-prougen 是 中科蓝讯(Bluetrum) 推出的一款基于 RISC-V 内核
6868

6969
本 BSP 为开发者提供 GCC 开发环境。下面介绍如何将系统运行起来。
7070

71+
教学视频:https://www.bilibili.com/video/BV1RV411v75P/
72+
7173
#### 硬件连接
7274

7375
使用数据线连接开发板到 PC,打开电源开关。
@@ -94,13 +96,12 @@ msh >
9496
此 BSP 默认只开启了 GPIO 和 串口0 的功能,如果需使用 SD 卡、Flash 等更多高级功能,需要利用 ENV 工具对BSP 进行配置,步骤如下:
9597

9698
1. 在 bsp 下打开 env 工具。
97-
9899
2. 输入`menuconfig`命令配置工程,配置好之后保存退出。
99-
100100
3. 输入`pkgs --update`命令更新软件包。
101-
102101
4. 输入`scons` 命令重新编译工程。
103102

103+
更多细节请参见使用指南:https://ab32vg1-example.readthedocs.io/zh/latest/introduction.html
104+
104105
## 注意事项
105106

106107
波特率默认为 1.5M,需要使用 [Downloader](https://github.com/BLUETRUM/Downloader) 下载 `.dcf` 到芯片,需要编译后自动下载,需要在 `Downloader` 中的下载的下拉窗中选择 `自动`;目前暂时屏蔽 uart1 打印

bsp/bluetrum/libraries/hal_drivers/drv_common.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,4 +15,6 @@
1515
#include <rthw.h>
1616
#include <rtdevice.h>
1717

18+
#define GET_PIN(PORTx,PIN) (uint8_t)__AB32_GET_PIN_##PORTx(PIN)
19+
1820
#endif // DRV_COMMON_H__

bsp/bluetrum/libraries/hal_drivers/drv_gpio.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,10 @@
1515
#include "board.h"
1616

1717
#define __AB32_PORT(port) GPIO##port
18+
#define __AB32_GET_PIN_A(PIN) PIN
19+
#define __AB32_GET_PIN_B(PIN) 8 + PIN
20+
#define __AB32_GET_PIN_E(PIN) 13 + PIN
21+
#define __AB32_GET_PIN_F(PIN) 21 + PIN
1822

1923
int rt_hw_pin_init(void);
2024

bsp/nuvoton/README.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
1-
# Nuvoton BSP descriptions
1+
ï»? Nuvoton BSP descriptions
22
Current supported BSP shown in below table:
33

44
| **BSP folder** | **Board name** |
55
|:------------------------- |:-------------------------- |
66
| [numaker-iot-m487](numaker-iot-m487) | Nuvoton NuMaker-IoT-M487 |
77
| [numaker-pfm-m487](numaker-pfm-m487) | Nuvoton NuMaker-PFM-M487 |
88
| [nk-980iot](nk-980iot) | Nuvoton NK-980IOT |
9-
| [numaker-m2354](numaker-m2354) | Nuvoton NuMaker-M2354 |
9+
| [numaker-m2354](numaker-m2354) | Nuvoton NuMaker-M2354 |
10+
| [nk-rtu980](nk-rtu980) | Nuvoton NK-RTU980 |

bsp/nuvoton/libraries/m2354/Device/Nuvoton/M2354/Include/NuMicro.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
#ifndef __NUMICRO_H__
1010
#define __NUMICRO_H__
1111

12+
#include "nutool_clkcfg.h"
1213
#include "M2354.h"
1314

1415
#endif /* __NUMICRO_H__ */

bsp/nuvoton/libraries/m2354/Device/Nuvoton/M2354/Include/system_M2354.h

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,11 +49,21 @@ extern "C" {
4949
/*----------------------------------------------------------------------------
5050
Define SYSCLK
5151
*----------------------------------------------------------------------------*/
52+
#ifndef __HXT
5253
#define __HXT (12000000UL) /*!< External Crystal Clock Frequency */
54+
#endif
55+
5356
#define __LIRC (32000UL) /*!< Internal 32K RC Oscillator Frequency */
5457
#define __HIRC (12000000UL) /*!< Internal 12M RC Oscillator Frequency */
58+
59+
#ifndef __LXT
5560
#define __LXT (32768UL) /*!< External Crystal Clock Frequency 32.768KHz */
61+
#endif
62+
63+
#ifndef __HSI
5664
#define __HSI (48000000UL) /*!< PLL Output Clock Frequency */
65+
#endif
66+
5767
#define __HIRC48 (48000000UL) /*!< Internal 48M RC Oscillator Frequency */
5868
#define __LIRC32 (32000UL) /*!< Internal 32K RC Oscillator Frequency */
5969
#define __MIRC (4000000UL) /*!< Internal 4M RC Oscillator Frequency */
@@ -93,7 +103,7 @@ extern uint32_t __PC(void); /*!< Return the current program counter valu
93103
*/
94104
#define ASSERT_PARAM(expr) { if (!(expr)) { AssertError((uint8_t*)__FILE__, __LINE__); } }
95105

96-
void AssertError(uint8_t* file, uint32_t line);
106+
void AssertError(uint8_t *file, uint32_t line);
97107
#else
98108
#define ASSERT_PARAM(expr)
99109
#endif

bsp/nuvoton/libraries/m2354/StdDriver/lib/libStdDriver.ewp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -348,6 +348,7 @@
348348
<state>$PROJ_DIR$\..\..\Device\Nuvoton\M2354\Include</state>
349349
<state>$PROJ_DIR$\..\..\CMSIS\Include</state>
350350
<state>$PROJ_DIR$\..\inc</state>
351+
<state>$PROJ_DIR$</state>
351352
</option>
352353
<option>
353354
<name>CCStdIncCheck</name>
@@ -1385,6 +1386,7 @@
13851386
<state>$PROJ_DIR$\..\..\Device\Nuvoton\M2354\Include</state>
13861387
<state>$PROJ_DIR$\..\..\CMSIS\Include</state>
13871388
<state>$PROJ_DIR$\..\inc</state>
1389+
<state>$PROJ_DIR$</state>
13881390
</option>
13891391
<option>
13901392
<name>CCStdIncCheck</name>

bsp/nuvoton/libraries/m2354/StdDriver/lib/libStdDriver.uvprojx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -338,7 +338,7 @@
338338
<MiscControls></MiscControls>
339339
<Define></Define>
340340
<Undefine></Undefine>
341-
<IncludePath>..\inc;..\..\CMSIS\Include;..\..\Device\Nuvoton\M2354\Include</IncludePath>
341+
<IncludePath>..\inc;..\..\CMSIS\Include;..\..\Device\Nuvoton\M2354\Include;.</IncludePath>
342342
</VariousControls>
343343
</Cads>
344344
<Aads>

bsp/nuvoton/libraries/m2354/rtt_port/drv_bpwm_capture.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
#if defined(BSP_USING_BPWM_CAPTURE)
1515
#if ((BSP_USING_BPWM0_CAPTURE_CHMSK+BSP_USING_BPWM1_CAPTURE_CHMSK)!=0)
1616
#include <rtdevice.h>
17-
#include <NuMicro.h>
17+
#include "NuMicro.h"
1818

1919
/* Private typedef --------------------------------------------------------------*/
2020
typedef struct _bpwm_dev

bsp/nuvoton/libraries/m2354/rtt_port/drv_can.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
#include <rtdevice.h>
1818
#include <rthw.h>
19-
#include <NuMicro.h>
19+
#include "NuMicro.h"
2020

2121
/* Private Define ---------------------------------------------------------------*/
2222
#define RX_MSG_ID_INDEX 16

0 commit comments

Comments
 (0)