Repository navigation
Merge the XRobot 1.0 migration into dev - #3
Merged
Merged
Conversation
User/xrobot_main.hpp is generated from User/xrobot.yaml and xrobot.lock and now committed; LibXR refuses to build it once either input changes. CI regenerates app_main.cpp, libxr_config.yaml, the entry and Modules/CMakeLists.txt from the committed inputs with the locked module commits (--frozen) and fails when they differ from the commit. Registrations follow the generated object order; the unused device_aliases table is gone. LibXR pinned to the stamp check.
The call moves from User Code 3 to right after it, where the generator now writes it (and refuses to regenerate while a user region still contains it). Each FDCAN object is also registered as LibXR::CAN through canN references.
Install the XRobot and CodeGenerator versions pinned in modules.yaml and libxr_config.yaml; check the CodeGenerator outputs and the config layout; resolve the lock frozen with the release-line gate of the target branch. The generated entry, module list and lock are no longer diffed.
modules.yaml pins xrobot 1.0.0 and libxr_config.yaml pins the generator 6.0.0; CI installs exactly these. User/xrobot_main.hpp and Modules/CMakeLists.txt are produced by xrobot setup and are no longer committed. Remove the STATIC_CANDIDATE.md task notes.
…ecks LibXR now requires the generated module list, checks the entry header against the files it lists, prints the selected product, rejects RawData callback payloads and keeps init-time topic type checks in Release.
The Modules drop their empty OnMonitor hooks and gain licenses, CI and README updates; no interface this BSP uses changes.
Describe setup, build, BSP object regeneration and CI. Add the Apache-2.0 LICENSE and a NOTICE listing the vendored third-party code that keeps its own license.
app_main.cpp, app_main.h and flash_map.hpp from CodeGenerator 459f125 and xrobot.lock from XRobot bfe20af1; only the notice lines change.
XRobot reads a double-quoted value as a C++ string and any other value as C++ code; xrobot format writes code without quotes where YAML allows it. The generated headers are unchanged.
libxr 6.0.0 gathers its commands under `libxr`; CI, the README and the generated file notices use the new names. Regenerated output is otherwise unchanged.
STM32Cube FW_H7 V1.13.0 no longer ships the CMSIS-RTOS V1 wrapper, so CubeMX 6.18.1 drops FreeRTOS from a project that uses it. The FreeRTOS interface moves to CMSIS_V2 (in STM32CubeMX), then the project moves from 6.15.0 / FW_H7 V1.12.1 to 6.18.1 / FW_H7 V1.13.0; HAL, CMSIS and FreeRTOS (10.6.2) follow the package. - CMSIS-RTOS V2 makes CubeMX enable FreeRTOS software timers. The USER CODE Defines section of FreeRTOSConfig.h turns them off again, with the osTimer API and event flags from interrupts that depend on them (as freertos_os2.h describes). The old define of INCLUDE_xTimerPendFunctionCall in the Includes section is gone. - The USB HS handle is placed in RAM_D1 (its Setup buffer is written by the USB DMA, which cannot reach DTCM) and cleared before init, now from USER CODE sections of usb_otg.c, so regeneration keeps them; the attribute was on the generated declaration and the memset in a section CubeMX 6.18 renamed. - The stack overflow hook in USER CODE 4 takes char *, as FreeRTOS 10.6 declares it. - CubeMX 6.18 names the linker script STM32H723xG_flash.ld; the file (with its .ram_d1 section) and its references follow. libxr parse/gen reproduce the committed User files. The CI image build (ST Arm Clang 21.1.1) links; text/data/bss go from 135444/84/116196 to 136976/84/117172. system_stm32h7xx.h of the new package adds an optimize attribute that Clang ignores with a warning in each unit. Not tested on hardware.
The stack overflow hook in USER CODE 4 of freertos.c is now a strong definition that disables interrupts and calls libxr_fatal_error, as bsp-dev-c does. It replaces the empty weak hook of the CubeMX template; a strong definition is needed because the first weak definition the linker sees wins, so LibXR's own weak hook never took effect. CubeMX keeps the section when it regenerates the file. In this CMSIS-RTOS V2 project the weak hook of cmsis_os2.c (configASSERT) was the one linked.
Regenerated with libxr gen, which keys CAN and FDCAN instances in libxr_config.yaml by their lower-case name like every other peripheral; the settings are unchanged and the generated sources are identical.
app_main.cpp names LibXR priority levels in PlatformInit() and for the terminal thread. With configMAX_PRIORITIES 56 both threads move from FreeRTOS priority 2, below every module thread, to MEDIUM (22). cmake/LibXR.CMake globs User/*.cpp with CONFIGURE_DEPENDS and cmake/starm-clang.cmake selects the runtime profile per build directory, as the current setup writes them.
PE10 (ACC_INT) and PE12 (GYRO_INT) are external interrupt pins, but EXTI15_10 was not enabled in NVIC, so CubeMX generated no EXTI15_10_IRQHandler and the BMI088 interrupt would go to Default_Handler once enabled. Regenerated with STM32CubeMX 6.18.1, line endings kept as before; libxr gen output is unchanged.
libxr gen 6.0.0 no longer copies the flash sector table into libxr_config.yaml; the layout stays in User/flash_map.hpp.
LibXR now checks User/xrobot_main.hpp against the content digest that xrobot writes into it, instead of comparing file times.
libxr 6c51bf4 describes the sector table as runs of equal sectors (FlashRegion). flash_map.hpp is regenerated and the flash is built from FLASH_REGIONS; its storage area stays the last two sectors.
Every Module now has its dev branch at the commit this lock already pins; xrobot setup --update --context-ref refs/heads/dev records dev as the resolved branch.
With the CubeMX default STARM_PICOLIBC, starm-clang reads errno through a GOT entry. The CubeMX linker script names no .got, so the linker places the orphan section by its own rules; in some builds it lands in RAM without a load address, which gives a bin of about 400 MB and a wrong errno address. The GOT holds only link-time constants and now has its own FLASH section, as in the other STM32 BSPs.
# Conflicts: # .github/workflows/xrobot_stm32.yml # .mxproject # Core/Inc/FreeRTOSConfig.h # Core/Inc/main.h # Core/Inc/stm32h7xx_it.h # Core/Src/adc.c # Core/Src/dac.c # Core/Src/fdcan.c # Core/Src/freertos.c # Core/Src/gpio.c # Core/Src/main.c # Core/Src/spi.c # Core/Src/stm32h7xx_hal_msp.c # Core/Src/stm32h7xx_hal_timebase_tim.c # Core/Src/stm32h7xx_it.c # Core/Src/tim.c # Core/Src/usart.c # Core/Src/usb_otg.c # STM32H723xG_flash.ld
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
把 feat/static-assembly-20260915 合入 dev。BSP 迁移到 XRobot 1.0(静态装配、
xrobot命令、libxr命令、提交的xrobot.lock),具体改动见下方提交列表。Merges feat/static-assembly-20260915 into dev. Migrates the BSP to XRobot 1.0 (static assembly, the
xrobotandlibxrcommands, a committedxrobot.lock); the commits below list the changes.合并顺序:工具先合并并发布(xrobot 1.0.0、libxr 6.0.0、扩展 2.0.0,XRobot 打
v1),BSP 的 CI 安装已发布的 xrobot 1.0.0 和 libxr 6.0.0,因此本 PR 在发布之后合入 dev,再由 dev 合入默认分支。Merge order: the tools are merged and released first (xrobot 1.0.0, libxr 6.0.0, extension 2.0.0, XRobot tag
v1). The BSP CI installs the released xrobot 1.0.0 and libxr 6.0.0, so this PR is merged into dev after the release, and dev then into the default branch.验证 / Verification
ci: validate dev branch已合入本分支,工作流内容以本分支为准(已包含 dev 触发)。提交 / Commits