Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
luozhenger
rt-thread
提交
95540854
R
rt-thread
项目概览
luozhenger
/
rt-thread
与 Fork 源项目一致
Fork自
RT-Thread / rt-thread
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
R
rt-thread
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
未验证
提交
95540854
编写于
3月 02, 2023
作者:
Y
Yaochenger
提交者:
GitHub
3月 02, 2023
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
[libcpu/riscv]迁移libcpu/riscv/ch32中文件至bsp (#7004)
上级
fc2e122e
变更
7
隐藏空白更改
内联
并排
Showing
7 changed file
with
85 addition
and
12 deletion
+85
-12
bsp/wch/risc-v/ch32v103r-evt/board/SConscript
bsp/wch/risc-v/ch32v103r-evt/board/SConscript
+1
-0
bsp/wch/risc-v/ch32v103r-evt/board/software_irq.c
bsp/wch/risc-v/ch32v103r-evt/board/software_irq.c
+0
-0
bsp/wch/risc-v/ch32v208w-r0/board/SConscript
bsp/wch/risc-v/ch32v208w-r0/board/SConscript
+1
-0
bsp/wch/risc-v/ch32v208w-r0/board/software_irq.c
bsp/wch/risc-v/ch32v208w-r0/board/software_irq.c
+41
-0
bsp/wch/risc-v/ch32v307v-r1/board/SConscript
bsp/wch/risc-v/ch32v307v-r1/board/SConscript
+1
-0
bsp/wch/risc-v/ch32v307v-r1/board/software_irq.c
bsp/wch/risc-v/ch32v307v-r1/board/software_irq.c
+41
-0
libcpu/risc-v/ch32/SConscript
libcpu/risc-v/ch32/SConscript
+0
-12
未找到文件。
bsp/wch/risc-v/ch32v103r-evt/board/SConscript
浏览文件 @
95540854
...
...
@@ -11,6 +11,7 @@ src = Split('''
board.c
debug.c
ch32v10x_it.c
software_irq.c
'''
)
path
=
[
cwd
]
...
...
libcpu/risc-v/ch32
/software_irq.c
→
bsp/wch/risc-v/ch32v103r-evt/board
/software_irq.c
浏览文件 @
95540854
文件已移动
bsp/wch/risc-v/ch32v208w-r0/board/SConscript
浏览文件 @
95540854
...
...
@@ -9,6 +9,7 @@ cwd = GetCurrentDir()
# add general drivers
src
=
Split
(
'''
board.c
software_irq.c
'''
)
path
=
[
cwd
]
...
...
bsp/wch/risc-v/ch32v208w-r0/board/software_irq.c
0 → 100644
浏览文件 @
95540854
/*
* Copyright (c) 2006-2018, RT-Thread Development Team
*
* SPDX-License-Identifier: Apache-2.0
*
* Change Logs:
* Date Author Notes
* 2021-09-09 WCH the first version
* 2023-01-04 WangShun Remove redundant files
*/
#include "rtconfig.h"
#if defined (SOC_RISCV_SERIES_CH32V1)
#include "ch32v10x.h"
#elif defined (SOC_RISCV_SERIES_CH32V2)
#include "ch32v20x.h"
#elif defined (SOC_RISCV_SERIES_CH32V3)
#include "ch32v30x.h"
#else
#error "CH32 architecture doesn't support!"
#endif
void
rt_trigger_software_interrupt
(
void
)
{
/*CH32V103 does not support systick software interrupt*/
#if defined(SOC_RISCV_SERIES_CH32V1)
NVIC_SetPendingIRQ
(
Software_IRQn
);
#else
SysTick
->
CTLR
|=
(
1
<<
31
);
#endif
}
void
rt_hw_do_after_save_above
(
void
)
{
__asm
volatile
(
"li t0,0x20"
);
__asm
volatile
(
"csrs 0x804, t0"
);
/*CH32V103 does not support systick software interrupt*/
#if defined(SOC_RISCV_SERIES_CH32V1)
NVIC_ClearPendingIRQ
(
Software_IRQn
);
#else
SysTick
->
CTLR
&=
~
(
1
<<
31
);
#endif
}
\ No newline at end of file
bsp/wch/risc-v/ch32v307v-r1/board/SConscript
浏览文件 @
95540854
...
...
@@ -9,6 +9,7 @@ cwd = GetCurrentDir()
# add general drivers
src
=
Split
(
'''
board.c
software_irq.c
'''
)
path
=
[
cwd
]
...
...
bsp/wch/risc-v/ch32v307v-r1/board/software_irq.c
0 → 100644
浏览文件 @
95540854
/*
* Copyright (c) 2006-2018, RT-Thread Development Team
*
* SPDX-License-Identifier: Apache-2.0
*
* Change Logs:
* Date Author Notes
* 2021-09-09 WCH the first version
* 2023-01-04 WangShun Remove redundant files
*/
#include "rtconfig.h"
#if defined (SOC_RISCV_SERIES_CH32V1)
#include "ch32v10x.h"
#elif defined (SOC_RISCV_SERIES_CH32V2)
#include "ch32v20x.h"
#elif defined (SOC_RISCV_SERIES_CH32V3)
#include "ch32v30x.h"
#else
#error "CH32 architecture doesn't support!"
#endif
void
rt_trigger_software_interrupt
(
void
)
{
/*CH32V103 does not support systick software interrupt*/
#if defined(SOC_RISCV_SERIES_CH32V1)
NVIC_SetPendingIRQ
(
Software_IRQn
);
#else
SysTick
->
CTLR
|=
(
1
<<
31
);
#endif
}
void
rt_hw_do_after_save_above
(
void
)
{
__asm
volatile
(
"li t0,0x20"
);
__asm
volatile
(
"csrs 0x804, t0"
);
/*CH32V103 does not support systick software interrupt*/
#if defined(SOC_RISCV_SERIES_CH32V1)
NVIC_ClearPendingIRQ
(
Software_IRQn
);
#else
SysTick
->
CTLR
&=
~
(
1
<<
31
);
#endif
}
\ No newline at end of file
libcpu/risc-v/ch32/SConscript
已删除
100644 → 0
浏览文件 @
fc2e122e
# RT-Thread building script for component
from
building
import
*
cwd
=
GetCurrentDir
()
src
=
Glob
(
'*.c'
)
+
Glob
(
'*.cpp'
)
+
Glob
(
'*_gcc.S'
)
CPPPATH
=
[
cwd
]
ASFLAGS
=
' -I '
+
cwd
group
=
DefineGroup
(
'CPU'
,
src
,
depend
=
[
''
],
CPPPATH
=
CPPPATH
,
ASFLAGS
=
ASFLAGS
)
Return
(
'group'
)
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录