# stm32f103vet6-esp8266 **Repository Path**: shchlu/stm32f103vet6-esp8266 ## Basic Information - **Project Name**: stm32f103vet6-esp8266 - **Description**: stm32f103vet6和esp8266的工程项目 - **Primary Language**: Unknown - **License**: MIT - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 1 - **Created**: 2023-06-08 - **Last Updated**: 2024-04-07 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # 程序目录结构划分定义 -stm32f103vet6-esp8266 --Core (HAL库生成的,包含启动汇编文件、主入口函数、中断相关、HAL库配置相关) --Driver (HAL库、CMSIS相关) --System (系统系别的目录文件、通用工具和MCU外设封装都在此目录定义) --User (作为业务逻辑开发相关都在此处定义) # 程序命名约定 ## 文件名命名约定 1. 在System/Core目录下:加上前缀sys_core_xxx,例如sys_core_log 2. 在System/Drivers目录下: 加上前缀 bsp_xxx,例如bsp_serial 3. 在User/Config目录下: 加上前缀 app_cnf_xxx,例如app_cnf_log 4. 在User/Drivers目录下: 加上前缀 app_dr_xxx或module_xxx, 例如 app_dr_esp8266,module_esp8266 # 注意事项 ## CMakeLists文件的修改 > 在CMakeLists_template模板文件中添加 1. 重新用stm32cubemx生成的时候,CMakeLists模板文件会覆盖使用的文件,所以在模板文件添加即可 ```cmake file(GLOB_RECURSE SOURCES ${sources}) #[[-----------------------开始添加的位置--------------------------]] # 添加系统层面的文件 include_directories(System/Core/Include System/Drivers/Include) file(GLOB_RECURSE SYS_SOURCES "System/*.c") set(SOURCES ${SOURCES} ${SYS_SOURCES}) # 添加用户层面的文件 include_directories(User/Config/Include User/Drivers/Include) file(GLOB_RECURSE USER_SOURCES "User/*.c") set(SOURCES ${SOURCES} ${USER_SOURCES}) #[[-----------------------结束添加的位置--------------------------]] set(LINKER_SCRIPT $${CMAKE_SOURCE_DIR}/${linkerScript}) ```