Skip to content

Commit 1c3e45b

Browse files
committed
add ci build.
1 parent e0bc4d3 commit 1c3e45b

File tree

131 files changed

+1196
-1680
lines changed

Some content is hidden

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

131 files changed

+1196
-1680
lines changed

.github/workflows/action.yml

Lines changed: 116 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,116 @@
1+
name: PSOC-Edge-Edgi-Talk
2+
3+
# Controls when the action will run. Triggers the workflow on push or pull request
4+
# events but only for the master branch
5+
on:
6+
# Runs at 16:00 UTC (BeiJing 00:00) on the 1st of every month
7+
schedule:
8+
- cron: '0 16 1 * *'
9+
push:
10+
branches:
11+
- main
12+
paths-ignore:
13+
- docs/**
14+
- '**/README.md'
15+
# - '**/README_ZH.md'
16+
pull_request:
17+
branches:
18+
- main
19+
paths-ignore:
20+
- docs/**
21+
- '**/README.md'
22+
# - '**/README_ZH.md'
23+
24+
env:
25+
RTT_TOOL_CHAIN: "sourcery-arm"
26+
27+
jobs:
28+
check:
29+
runs-on: ubuntu-latest
30+
name: check-yaml-format
31+
if: github.repository_owner == 'RT-Thread-Studio'
32+
steps:
33+
- uses: actions/checkout@v2
34+
- name: Set up Python
35+
uses: actions/setup-python@master
36+
with:
37+
python-version: 3.8
38+
39+
- name: Check yaml
40+
if: ${{ success() }}
41+
shell: bash
42+
run: |
43+
pip install rt-thread-studio
44+
python -c "from rt_thread_studio import bsp_checker;bsp_path = '.';checker = bsp_checker.BspChecker(bsp_path);checker.check();"
45+
46+
compile:
47+
needs: [check]
48+
runs-on: ubuntu-latest
49+
name: ${{ matrix.legs.RTT_BSP }}
50+
strategy:
51+
fail-fast: false
52+
matrix:
53+
legs:
54+
- {RTT_BSP: "Edgi-Talk_ADC/Edgi_Talk_M33_ADC"}
55+
- {RTT_BSP: "Edgi-Talk_AHT20/Edgi_Talk_M33_AHT20"}
56+
- {RTT_BSP: "Edgi-Talk_Audio/Edgi_Talk_M33_Audio"}
57+
- {RTT_BSP: "Edgi-Talk_Blink_Led/Edgi_Talk_M33_Blink_LED"}
58+
- {RTT_BSP: "Edgi-Talk_Blink_Led/Edgi_Talk_M55_Blink_LED"}
59+
- {RTT_BSP: "Edgi-Talk_CoreMark/Edgi_Talk_M55_CoreMark"}
60+
- {RTT_BSP: "Edgi-Talk_emUSB-device_CDC_Echo/Edgi_Talk_M33_emUSB-device_CDC_Echo"}
61+
- {RTT_BSP: "Edgi-Talk_HyperRam/Edgi_Talk_M33_HyperRam"}
62+
- {RTT_BSP: "Edgi-Talk_Key_Irq/Edgi_Talk_M33_Key_Irq"}
63+
- {RTT_BSP: "Edgi-Talk_LSM6DS3/Edgi_Talk_M33_LSM6DS3"}
64+
- {RTT_BSP: "Edgi-Talk_LVGL/Edgi_Talk_M55_LVGL"}
65+
- {RTT_BSP: "Edgi-Talk_M33_Template/Edgi_Talk_M33_Template"}
66+
- {RTT_BSP: "Edgi-Talk_MIPI_LCD/Edgi_Talk_M55_MIPI_LCD"}
67+
- {RTT_BSP: "Edgi-Talk_RTC/Edgi_Talk_M33_RTC"}
68+
- {RTT_BSP: "Edgi-Talk_SDCARD/Edgi_Talk_M33_SDCARD"}
69+
- {RTT_BSP: "Edgi-Talk_WavPlayer/Edgi_Talk_M33_WavPlayer"}
70+
- {RTT_BSP: "Edgi-Talk_WIFI/Edgi_Talk_M55_WIFI"}
71+
- {RTT_BSP: "Edgi-Talk_XiaoZhi/Edgi_Talk_M55_XiaoZhi"}
72+
steps:
73+
- uses: actions/checkout@v2
74+
- name: Set up Python
75+
uses: actions/setup-python@master
76+
with:
77+
python-version: 3.8
78+
79+
- name: Install Arm ToolChains
80+
if: ${{ success() }}
81+
shell: bash
82+
run: |
83+
wget -c https://github.com/RT-Thread/toolchains-ci/releases/download/v1.10/arm-gnu-toolchain-13.3.rel1-x86_64-arm-none-eabi.tar.xz
84+
sudo tar -xf arm-gnu-toolchain-13.3.rel1-x86_64-arm-none-eabi.tar.xz -C /opt
85+
/opt/arm-gnu-toolchain-13.3.rel1-x86_64-arm-none-eabi/bin/arm-none-eabi-gcc --version
86+
echo "RTT_EXEC_PATH=/opt/arm-gnu-toolchain-13.3.rel1-x86_64-arm-none-eabi/bin" >> $GITHUB_ENV
87+
88+
- name: Install Tools
89+
if: ${{ success() }}
90+
shell: bash
91+
run: |
92+
sudo apt-get update
93+
sudo apt-get -qq install gcc-multilib libsdl2-dev scons
94+
echo "RTT_ROOT=${{ github.workspace }}" >> $GITHUB_ENV
95+
echo "RTT_CC=gcc" >> $GITHUB_ENV
96+
97+
- name: Check and Run mklinks.sh
98+
if: ${{ success() }}
99+
shell: bash
100+
env:
101+
RTT_BSP: ${{ matrix.legs.RTT_BSP }}
102+
run: |
103+
cd projects/$RTT_BSP
104+
if [ -f mklinks.sh ]; then
105+
chmod +x mklinks.sh
106+
./mklinks.sh
107+
fi
108+
109+
- name: Compile ${{ matrix.legs.RTT_BSP }}
110+
if: ${{ success() }}
111+
shell: bash
112+
env:
113+
RTT_BSP: ${{ matrix.legs.RTT_BSP }}
114+
run: |
115+
cd projects
116+
scons -C $RTT_BSP

libraries/HAL_Drivers/SConscript

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,7 @@ if GetDepend(['BSP_USING_TIM']):
6969
path = [cwd]
7070
path += [cwd + '/config']
7171

72-
group = DefineGroup('Drivers', src, depend = [''], CPPPATH = path)
72+
group = DefineGroup('Drivers', src, depend = [''], CPPPATH = path, LOCAL_CPPPATH = path)
7373

7474
Return('group')
75+

libraries/components/async-transfer/SConscript

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ Import('RTT_ROOT')
55
# get current directory
66
cwd = GetCurrentDir()
77
path = [cwd + '/include']
8-
src = [cwd + '/source/mtb_async_transfer.c']
8+
src = ['source/mtb_async_transfer.c']
99

1010
group = DefineGroup('Libraries', src, depend=[''], CPPPATH=path)
1111
Return('group')

libraries/components/emusb-device/SConscript

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,11 @@ LIBPATH = []
1212
if GetDepend(['BSP_USING_USB']):
1313
LIBS+= ['usbd']
1414
LIBPATH += [cwd + '/USBD/COMPONENT_USBD_BASE/COMPONENT_CAT1D/CONFIG_Release/COMPONENT_CM33/COMPONENT_SOFTFP/TOOLCHAIN_GCC_ARM']
15-
src += [cwd + '/export/Config/usbd_config_io.c']
16-
src += [cwd + '/export/Config/COMPONENT_CAT1D/usbd_config.c']
17-
src += [cwd + '/OS/usbd_os_abs_rtos.c']
15+
src += ['export/Config/usbd_config_io.c']
16+
src += ['export/Config/COMPONENT_CAT1D/usbd_config.c']
17+
src += ['OS/usbd_os_abs_rtos.c']
1818
path += [cwd + '/USBD']
1919
path += [cwd + '/USBD/COMPONENT_CAT1D']
2020
path += [cwd + '/USBD/COMPONENT_USBD_BASE/COMPONENT_CAT1D/CONFIG_Release']
21-
group = DefineGroup('Libraries', src, depend=[''],LIBS = LIBS, LIBPATH=LIBPATH, CPPPATH=path)
21+
group = DefineGroup('Libraries', src, depend=[''], LIBS = LIBS, LIBPATH=LIBPATH, CPPPATH=path)
2222
Return('group')

libraries/components/mtb-device-support-pse8xxgp/pdl/SConscript

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,13 @@ src = Split('''
2121
drivers/source/cy_scb_common.c
2222
''')
2323

24-
path = [cwd + '/drivers/include',
25-
cwd + '/drivers/third_party/ethernet/include']
24+
# Add toolchain-specific assembly files
25+
if rtconfig.PLATFORM in ['gcc']:
26+
src += ['drivers/source/TOOLCHAIN_GCC_ARM/cy_syslib_ext.S']
27+
elif rtconfig.PLATFORM in ['armclang']:
28+
src += ['drivers/source/TOOLCHAIN_ARM/cy_syslib_ext.S']
29+
30+
path = [cwd + '/drivers/include', cwd + 'drivers/third_party/ethernet/include']
2631

2732
if GetDepend(['SOC_SERIES_IFX_PSOCE84']):
2833
src += ['drivers/source/cy_syspm_ppu.c']
@@ -138,3 +143,4 @@ if GetDepend(['SOC_SERIES_IFX_PSOCE84']):
138143

139144
group = DefineGroup('Libraries', src, depend=[''], CPPPATH=path, CPPDEFINES = CPPDEFINES)
140145
Return('group')
146+

projects/.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
*.pyc
2+
*.dbsqlite
3+
*pkgs_error.json
4+
*rtconfig_preinc.h

0 commit comments

Comments
 (0)