Skip to content

Commit

Permalink
Merge branch 'master' of github.com:Synwit-Co-Ltd/rt-thread
Browse files Browse the repository at this point in the history
  • Loading branch information
XIVN1987 committed Dec 26, 2023
2 parents 580cd0a + 97f74b0 commit 71cefbe
Show file tree
Hide file tree
Showing 478 changed files with 142,071 additions and 2,176 deletions.
1 change: 1 addition & 0 deletions .github/actions/spelling/allow.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
github
19 changes: 3 additions & 16 deletions .github/workflows/bsp_buildings.yml
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,7 @@ jobs:
- "stm32/stm32g491-st-nucleo"
- "stm32/stm32g474-st-nucleo"
- "stm32/stm32h563-st-nucleo"
- "stm32/stm32h503-st-nucleo"
- "stm32/stm32h743-armfly-v7"
- "stm32/stm32h743-atk-apollo"
- "stm32/stm32h743-openmv-h7plus"
Expand Down Expand Up @@ -202,6 +203,7 @@ jobs:
- "renesas/ra4m2-eco"
- "renesas/ra2l1-cpk"
- "renesas/ra8m1-ek"
- "renesas/ra8d1-ek"
- RTT_BSP: "gd32_n32_apm32"
RTT_TOOL_CHAIN: "sourcery-arm"
SUB_RTT_BSP:
Expand Down Expand Up @@ -419,19 +421,4 @@ jobs:
SRTT_BSP: ${{ join(matrix.legs.SUB_RTT_BSP, ',') }}
run: |
source ~/.env/env.sh
failed=0
count=0
for bsp in $(echo $SRTT_BSP | tr ',' '\n'); do
count=$((count+1))
echo "::group::Compiling BSP: ==$count=== $bsp ===="
echo bsp/$bsp
ls bsp/$bsp/Kconfig && scons -C bsp/$bsp --pyconfig-silent
pushd bsp/$bsp && pkgs --update && popd
scons -C bsp/$bsp -j$(nproc) --debug=time | tee output.log || \
{ total_time=$(grep "Total command execution time" output.log | awk '{print $5}'); \
failed=$((failed+1)) ; echo "::endgroup::" ; echo "::error::build $bsp failed" ; \
echo "- ❌ build $bsp failed in $total_time seconds " >> $GITHUB_STEP_SUMMARY ; } && \
{ total_time=$(grep "Total command execution time" output.log | awk '{print $5}'); \
echo "- ✅ build $bsp success in $total_time seconds " >> $GITHUB_STEP_SUMMARY ; echo "::endgroup::" ; }
done
exit $failed
python tools/ci/bsp_buildings.py
42 changes: 42 additions & 0 deletions .github/workflows/spell_check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: Check Spelling

on:
push:
branches:
- master
pull_request:
branches:
- master

jobs:
spelling:
name: Check Spelling
runs-on: ubuntu-latest
if: github.repository_owner == 'RT-Thread'
permissions:
contents: read
pull-requests: read
actions: read
steps:
- name: output ignore words info
run: |
echo "> If any words shown as incorrect are spelled correctly, please add them to .github/actions/spelling/allow.txt." >> $GITHUB_STEP_SUMMARY
- name: check spelling
id: spelling
uses: check-spelling/[email protected]
with:
checkout: true
check_file_names: 0
only_check_changed_files: 1
post_comment: 0
extra_dictionaries:
cspell:en_US/src/en_US.txt
cspell:software-terms/softwareTerms.txt
cspell:python/python.txt
cspell:cpp/cpp.txt

check_extra_dictionaries: ''

- name: output Success info
run: |
echo "✅ Check spelling success." >> $GITHUB_STEP_SUMMARY
24 changes: 9 additions & 15 deletions bsp/avr32/at32uc3a0256/.config
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
#
CONFIG_RT_NAME_MAX=8
# CONFIG_RT_USING_ARCH_DATA_TYPE is not set
# CONFIG_RT_USING_NANO is not set
# CONFIG_RT_USING_AMP is not set
# CONFIG_RT_USING_SMP is not set
CONFIG_RT_CPUS_NR=1
Expand All @@ -34,10 +35,7 @@ CONFIG_RT_TIMER_THREAD_STACK_SIZE=512
# CONFIG_RT_KSERVICE_USING_TINY_SIZE is not set
# CONFIG_RT_USING_TINY_FFS is not set
# CONFIG_RT_KPRINTF_USING_LONGLONG is not set
CONFIG_RT_USING_DEBUG=y
CONFIG_RT_DEBUGING_COLOR=y
# CONFIG_RT_DEBUGING_CONTEXT is not set
# CONFIG_RT_DEBUGING_INIT is not set
# CONFIG_RT_USING_DEBUG is not set

#
# Inter-Thread communication
Expand Down Expand Up @@ -206,6 +204,12 @@ CONFIG_RT_LIBC_TZ_DEFAULT_SEC=0
# CONFIG_RT_USING_LWIP is not set
# CONFIG_RT_USING_AT is not set

#
# Memory protection
#
# CONFIG_RT_USING_MEM_PROTECTION is not set
# CONFIG_RT_USING_HW_STACK_GUARD is not set

#
# Utilities
#
Expand All @@ -218,17 +222,6 @@ CONFIG_RT_LIBC_TZ_DEFAULT_SEC=0
# CONFIG_RT_USING_RT_LINK is not set
# CONFIG_RT_USING_VBUS is not set

#
# Memory management
#
# CONFIG_RT_USING_MEMBLOCK is not set

#
# Memory protection
#
# CONFIG_RT_USING_MEM_PROTECTION is not set
# CONFIG_RT_USING_HW_STACK_GUARD is not set

#
# RT-Thread Utestcases
#
Expand Down Expand Up @@ -1014,3 +1007,4 @@ CONFIG_BSP_UART1_RX_PIN_5=y
# CONFIG_BSP_UART1_RX_PIN_96 is not set
CONFIG_BSP_UART1_RX_PIN=5
CONFIG_BSP_UART1_RX_PIN_FUNCTION=0
# CONFIG_BSP_USING_SOFT_I2C is not set
20 changes: 20 additions & 0 deletions bsp/avr32/at32uc3a0256/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -132,5 +132,25 @@ menu "On-chip Peripheral Drivers"
default 1 if BSP_UART1_RX_PIN_96
endif
endif

menuconfig BSP_USING_SOFT_I2C
bool "Enable I2C BUS (software simulation)"
default n
select RT_USING_I2C
select RT_USING_I2C_BITOPS
select RT_USING_PIN
if BSP_USING_SOFT_I2C
config BSP_USING_SOFT_I2C1
bool "Enable I2C1 Bus (software simulation)"
default n
if BSP_USING_SOFT_I2C1
config BSP_SOFT_I2C1_SCL_PIN
int "I2C1 SCL pin number (GP)"
default 30
config BSP_SOFT_I2C1_SDA_PIN
int "I2C1 SDA pin number (GP)"
default 29
endif
endif
endmenu
endmenu
6 changes: 6 additions & 0 deletions bsp/avr32/at32uc3a0256/board.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
* 2010-03-30 Kyle First version
* 2023-10-13 Raman Gopalan Move UART specific code sections into the drv_uart files
* 2023-10-20 Raman Gopalan Initialize GPIO sub-system
* 2023-12-01 Raman Gopalan Initialize software I2C sub-system
*/

#include <rtthread.h>
Expand All @@ -18,6 +19,7 @@
#include "intc.h"
#include "drv_uart.h"
#include "drv_gpio.h"
#include "drv_soft_i2c.h"

/**
* System tick interrupt handler.
Expand Down Expand Up @@ -78,6 +80,10 @@ void rt_hw_board_init(void)
rt_hw_gpio_init();
#endif

#ifdef BSP_USING_SOFT_I2C
rt_sw_i2c_init();
#endif

#ifdef RT_USING_CONSOLE
rt_console_set_device(RT_CONSOLE_DEVICE_NAME);
#endif
Expand Down
9 changes: 2 additions & 7 deletions bsp/avr32/at32uc3a0256/rtconfig.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,6 @@

/* kservice optimization */

#define RT_USING_DEBUG
#define RT_DEBUGING_COLOR

/* Inter-Thread communication */

Expand Down Expand Up @@ -103,13 +101,10 @@
/* Network */


/* Utilities */


/* Memory management */
/* Memory protection */


/* Memory protection */
/* Utilities */


/* RT-Thread Utestcases */
Expand Down
14 changes: 7 additions & 7 deletions bsp/avr32/drivers/SConscript
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,16 @@ cwd = GetCurrentDir()
# add the general drivers.
src = []

if GetDepend(['RT_USING_PIN']):
if GetDepend(['BSP_USING_PIN']):
src += ['drv_gpio.c']

if GetDepend(['RT_USING_SERIAL']):
if GetDepend(['RT_USING_SERIAL_V2']):
src += ['drv_uart_v2.c']
else:
src += ['drv_uart.c']
if GetDepend(['BSP_USING_UART']):
src += ['drv_uart.c']

path = [cwd]
if GetDepend(['BSP_USING_SOFT_I2C']):
src += ['drv_soft_i2c.c']

path = [cwd]

group = DefineGroup('Drivers', src, depend = [''], CPPPATH = path)

Expand Down
Loading

0 comments on commit 71cefbe

Please sign in to comment.