44 lines
758 B
C
44 lines
758 B
C
|
#include "main.h"
|
||
|
#include "uart.h"
|
||
|
#include "lin.h"
|
||
|
#include "user_init.h"
|
||
|
#include "sleep.h"
|
||
|
|
||
|
int main(void)
|
||
|
{
|
||
|
/* Reset of all peripherals, Initializes the Flash interface and the Systick. */
|
||
|
/* SHOULD BE KEPT!!! */
|
||
|
MF_Clock_Init();
|
||
|
|
||
|
/* Configure the system clock */
|
||
|
/* SHOULD BE KEPT!!! */
|
||
|
MF_SystemClock_Config();
|
||
|
|
||
|
/* Initialize FL Driver Library */
|
||
|
/* SHOULD BE KEPT!!! */
|
||
|
FL_Init();
|
||
|
|
||
|
/* Initialize all configured peripherals */
|
||
|
/* SHOULD BE KEPT!!! */
|
||
|
MF_Config_Init();
|
||
|
|
||
|
/* 用户参数配置 */
|
||
|
UserInit();
|
||
|
|
||
|
/* LIN初始化 */
|
||
|
lin_init();
|
||
|
|
||
|
while(1)
|
||
|
{
|
||
|
#if (0)
|
||
|
if (lin_is_sleep())
|
||
|
{
|
||
|
sleep();
|
||
|
}
|
||
|
#endif
|
||
|
;
|
||
|
}
|
||
|
}
|
||
|
|
||
|
|