nongye/STM32F103_App1/Src/main.c

24 lines
591 B
C
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

#include "main.h"
#include "app_common.h"
#include "app_loop.h"
/**
* @brief APP 主函数FreeRTOS 版)
*
* 分层结构:
* Board_Init() - 基础硬件HAL/时钟/GPIO/DMA/UART/看门狗system.c
* app_init() - 业务模块:横幅/EEPROM/W25Q64/继电器/秤/LED/ADC/网络app_loop.c
* app_rtos_start() - 创建 net/app/sys 三个任务并启动调度器app_loop.c
* IWDG 由 idle 钩子喂养app_loop.c vApplicationIdleHook
*/
int main(void)
{
SCB->VTOR = FLASH_BASE | Application_1_Addr;
Board_Init();
app_init();
app_rtos_start(); /* 不再返回 */
while (1) { }
}