mirror of
https://github.com/Fishwaldo/bl_mcu_sdk.git
synced 2025-07-07 05:18:34 +00:00
[chore] update tools
This commit is contained in:
parent
aa11059205
commit
79ff39938b
8 changed files with 49 additions and 11 deletions
|
@ -169,7 +169,7 @@
|
||||||
</target>
|
</target>
|
||||||
<target name="download" path="" targetID="org.eclipse.cdt.build.MakeTargetBuilder">
|
<target name="download" path="" targetID="org.eclipse.cdt.build.MakeTargetBuilder">
|
||||||
<buildCommand>make</buildCommand>
|
<buildCommand>make</buildCommand>
|
||||||
<buildArguments>INTERFACE=jlink</buildArguments>
|
<buildArguments>INTERFACE=uart</buildArguments>
|
||||||
<buildTarget>download</buildTarget>
|
<buildTarget>download</buildTarget>
|
||||||
<stopOnError>true</stopOnError>
|
<stopOnError>true</stopOnError>
|
||||||
<useDefaultCommand>false</useDefaultCommand>
|
<useDefaultCommand>false</useDefaultCommand>
|
||||||
|
|
|
@ -6,6 +6,7 @@ include(${CMAKE_SOURCE_DIR}/tools/cmake/tools.cmake)
|
||||||
PROJECT(${BOARD} C CXX ASM)
|
PROJECT(${BOARD} C CXX ASM)
|
||||||
|
|
||||||
# set(CMAKE_VERBOSE_MAKEFILE ON)
|
# set(CMAKE_VERBOSE_MAKEFILE ON)
|
||||||
|
ENABLE_LANGUAGE(ASM)
|
||||||
|
|
||||||
include_directories(${CMAKE_SOURCE_DIR}/common/misc)
|
include_directories(${CMAKE_SOURCE_DIR}/common/misc)
|
||||||
include_directories(${CMAKE_SOURCE_DIR}/bsp/bsp_common/platform)
|
include_directories(${CMAKE_SOURCE_DIR}/bsp/bsp_common/platform)
|
||||||
|
|
18
Makefile
18
Makefile
|
@ -6,13 +6,18 @@ CPU_ID?=m0
|
||||||
|
|
||||||
SUPPORT_SHELL?=n
|
SUPPORT_SHELL?=n
|
||||||
SUPPORT_FREERTOS?=n
|
SUPPORT_FREERTOS?=n
|
||||||
|
SUPPORT_CRYPTO?=n
|
||||||
SUPPORT_LVGL?=n
|
SUPPORT_LVGL?=n
|
||||||
SUPPORT_FLOAT?=n
|
SUPPORT_FLOAT?=n
|
||||||
SUPPORT_BLE?=n
|
SUPPORT_BLE?=n
|
||||||
SUPPORT_XZ?=n
|
SUPPORT_XZ?=n
|
||||||
|
SUPPORT_LWIP?=n
|
||||||
|
SUPPORT_TFLITE?=n
|
||||||
|
|
||||||
INTERFACE?=jlink
|
INTERFACE?=uart
|
||||||
BAUDRATE ?=12000
|
BAUDRATE ?=2000000
|
||||||
|
|
||||||
|
FORMAT_DIR?=.
|
||||||
|
|
||||||
export BOARD
|
export BOARD
|
||||||
export CHIP
|
export CHIP
|
||||||
|
@ -21,10 +26,13 @@ export APP
|
||||||
export CPU_ID
|
export CPU_ID
|
||||||
export SUPPORT_SHELL
|
export SUPPORT_SHELL
|
||||||
export SUPPORT_FREERTOS
|
export SUPPORT_FREERTOS
|
||||||
|
export SUPPORT_CRYPTO
|
||||||
export SUPPORT_LVGL
|
export SUPPORT_LVGL
|
||||||
export SUPPORT_FLOAT
|
export SUPPORT_FLOAT
|
||||||
export SUPPORT_BLE
|
export SUPPORT_BLE
|
||||||
export SUPPORT_XZ
|
export SUPPORT_XZ
|
||||||
|
export SUPPORT_LWIP
|
||||||
|
export SUPPORT_TFLITE
|
||||||
|
|
||||||
# The command to remove a file.
|
# The command to remove a file.
|
||||||
RM = cmake -E rm -rf
|
RM = cmake -E rm -rf
|
||||||
|
@ -37,8 +45,12 @@ build:
|
||||||
download:
|
download:
|
||||||
./tools/bflb_flash_tool/bflb_mcu_tool --chipname=$(CHIP) --interface=$(INTERFACE) --baudrate=$(BAUDRATE)
|
./tools/bflb_flash_tool/bflb_mcu_tool --chipname=$(CHIP) --interface=$(INTERFACE) --baudrate=$(BAUDRATE)
|
||||||
|
|
||||||
|
format:
|
||||||
|
find $(FORMAT_DIR)/ -name "*.c" -o -name "*.h" | xargs clang-format -style=file -i
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
$(RM) out
|
$(RM) out
|
||||||
$(RM) build
|
$(RM) build
|
||||||
.PHONY:build clean download
|
|
||||||
|
.PHONY:build clean download format
|
||||||
|
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
<stringAttribute key="ilg.gnumcueclipse.debug.gdbjtag.openocd.gdbServerExecutable" value="${openocd_path}/${openocd_executable}"/>
|
<stringAttribute key="ilg.gnumcueclipse.debug.gdbjtag.openocd.gdbServerExecutable" value="${openocd_path}/${openocd_executable}"/>
|
||||||
<intAttribute key="ilg.gnumcueclipse.debug.gdbjtag.openocd.gdbServerGdbPortNumber" value="3333"/>
|
<intAttribute key="ilg.gnumcueclipse.debug.gdbjtag.openocd.gdbServerGdbPortNumber" value="3333"/>
|
||||||
<stringAttribute key="ilg.gnumcueclipse.debug.gdbjtag.openocd.gdbServerLog" value=""/>
|
<stringAttribute key="ilg.gnumcueclipse.debug.gdbjtag.openocd.gdbServerLog" value=""/>
|
||||||
<stringAttribute key="ilg.gnumcueclipse.debug.gdbjtag.openocd.gdbServerOther" value="-f tools\openocd\if_702_hack.cfg -f tools\openocd\tgt_702.cfg"/>
|
<stringAttribute key="ilg.gnumcueclipse.debug.gdbjtag.openocd.gdbServerOther" value="-f tools\openocd\if_rv_dbg_plus.cfg -f tools\openocd\tgt_702.cfg"/>
|
||||||
<stringAttribute key="ilg.gnumcueclipse.debug.gdbjtag.openocd.gdbServerTclPortNumber" value="6666"/>
|
<stringAttribute key="ilg.gnumcueclipse.debug.gdbjtag.openocd.gdbServerTclPortNumber" value="6666"/>
|
||||||
<intAttribute key="ilg.gnumcueclipse.debug.gdbjtag.openocd.gdbServerTelnetPortNumber" value="4444"/>
|
<intAttribute key="ilg.gnumcueclipse.debug.gdbjtag.openocd.gdbServerTelnetPortNumber" value="4444"/>
|
||||||
<stringAttribute key="ilg.gnumcueclipse.debug.gdbjtag.openocd.otherInitCommands" value=""/>
|
<stringAttribute key="ilg.gnumcueclipse.debug.gdbjtag.openocd.otherInitCommands" value=""/>
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
<stringAttribute key="ilg.gnumcueclipse.debug.gdbjtag.openocd.gdbServerExecutable" value="${openocd_path}/${openocd_executable}"/>
|
<stringAttribute key="ilg.gnumcueclipse.debug.gdbjtag.openocd.gdbServerExecutable" value="${openocd_path}/${openocd_executable}"/>
|
||||||
<intAttribute key="ilg.gnumcueclipse.debug.gdbjtag.openocd.gdbServerGdbPortNumber" value="3333"/>
|
<intAttribute key="ilg.gnumcueclipse.debug.gdbjtag.openocd.gdbServerGdbPortNumber" value="3333"/>
|
||||||
<stringAttribute key="ilg.gnumcueclipse.debug.gdbjtag.openocd.gdbServerLog" value=""/>
|
<stringAttribute key="ilg.gnumcueclipse.debug.gdbjtag.openocd.gdbServerLog" value=""/>
|
||||||
<stringAttribute key="ilg.gnumcueclipse.debug.gdbjtag.openocd.gdbServerOther" value="-f tools\openocd\if_702_hack.cfg -f tools\openocd\tgt_702.cfg"/>
|
<stringAttribute key="ilg.gnumcueclipse.debug.gdbjtag.openocd.gdbServerOther" value="-f tools\openocd\if_rv_dbg_plus.cfg -f tools\openocd\tgt_702.cfg"/>
|
||||||
<stringAttribute key="ilg.gnumcueclipse.debug.gdbjtag.openocd.gdbServerTclPortNumber" value="6666"/>
|
<stringAttribute key="ilg.gnumcueclipse.debug.gdbjtag.openocd.gdbServerTclPortNumber" value="6666"/>
|
||||||
<intAttribute key="ilg.gnumcueclipse.debug.gdbjtag.openocd.gdbServerTelnetPortNumber" value="4444"/>
|
<intAttribute key="ilg.gnumcueclipse.debug.gdbjtag.openocd.gdbServerTelnetPortNumber" value="4444"/>
|
||||||
<stringAttribute key="ilg.gnumcueclipse.debug.gdbjtag.openocd.otherInitCommands" value=""/>
|
<stringAttribute key="ilg.gnumcueclipse.debug.gdbjtag.openocd.otherInitCommands" value=""/>
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
set(TARGET_REQUIRED_LIBS shell)
|
||||||
set(mains main.c)
|
set(mains main.c)
|
||||||
generate_bin()
|
generate_bin()
|
||||||
|
|
||||||
|
|
|
@ -4,9 +4,12 @@ cmake_definition+= -DBOARD=$(BOARD)
|
||||||
cmake_definition+= -DSUPPORT_FLOAT=$(SUPPORT_FLOAT)
|
cmake_definition+= -DSUPPORT_FLOAT=$(SUPPORT_FLOAT)
|
||||||
cmake_definition+= -DSUPPORT_SHELL=$(SUPPORT_SHELL)
|
cmake_definition+= -DSUPPORT_SHELL=$(SUPPORT_SHELL)
|
||||||
cmake_definition+= -DSUPPORT_FREERTOS=$(SUPPORT_FREERTOS)
|
cmake_definition+= -DSUPPORT_FREERTOS=$(SUPPORT_FREERTOS)
|
||||||
|
cmake_definition+= -DSUPPORT_CRYPTO=$(SUPPORT_CRYPTO)
|
||||||
cmake_definition+= -DSUPPORT_LVGL=$(SUPPORT_LVGL)
|
cmake_definition+= -DSUPPORT_LVGL=$(SUPPORT_LVGL)
|
||||||
cmake_definition+= -DSUPPORT_BLE=$(SUPPORT_BLE)
|
cmake_definition+= -DSUPPORT_BLE=$(SUPPORT_BLE)
|
||||||
cmake_definition+= -DSUPPORT_XZ=$(SUPPORT_XZ)
|
cmake_definition+= -DSUPPORT_XZ=$(SUPPORT_XZ)
|
||||||
|
cmake_definition+= -DSUPPORT_LWIP=$(SUPPORT_LWIP)
|
||||||
|
cmake_definition+= -DSUPPORT_TFLITE=$(SUPPORT_TFLITE)
|
||||||
cmake_definition+= -DAPP_DIR=$(APP_DIR)
|
cmake_definition+= -DAPP_DIR=$(APP_DIR)
|
||||||
cmake_definition+= -DAPP=$(APP)
|
cmake_definition+= -DAPP=$(APP)
|
||||||
|
|
||||||
|
|
21
tools/openocd/if_rv_dbg_plus.cfg
Normal file
21
tools/openocd/if_rv_dbg_plus.cfg
Normal file
|
@ -0,0 +1,21 @@
|
||||||
|
# BouffaloLab USB-JTAG/TTL adapter
|
||||||
|
interface ftdi
|
||||||
|
#adapter driver ftdi
|
||||||
|
ftdi_vid_pid 0x0403 0x6010
|
||||||
|
|
||||||
|
ftdi_channel 0
|
||||||
|
#ftdi_tdo_sample_edge falling
|
||||||
|
transport select jtag
|
||||||
|
adapter_khz 5000
|
||||||
|
#adapter speed 1000
|
||||||
|
|
||||||
|
ftdi_layout_init 0x00f8 0x00fb
|
||||||
|
#ftdi_layout_signal nTRST -data 0x0400
|
||||||
|
#ftdi_layout_signal nSRST -ndata 0x0020
|
||||||
|
|
||||||
|
#reset_config srst_only srst_push_pull
|
||||||
|
#adapter_nsrst_delay 100
|
||||||
|
#adapter_nsrst_assert_width 100
|
||||||
|
|
||||||
|
#bindto 0.0.0.0
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue