main.c
/** @copyright Copyright(c)2014-2011 XXXX Co.,Ltd. All rights reserved.
******************************************************************************
* @mainpage 无人机固件程序
* <table>
* <tr><th>Project <td>A600
* <tr><th>Author <td>匠在江湖(ID:1234)
* <tr><th>Source <td>F:\BaiduNetdiskWorkspace\Work\Item\DDItem\A600\Software
* </table>
* @section 项目描述
* 该无人机是主要应用于......
*
* @section 功能描述
* -# 定高悬停
* -# 路径规划飞行
*
* @section 用法描述
* -# 用遥控器
*
* @section 固件更新记录
* <table>
* <tr><th>Date <th>H_Version <th>S_Version <th>Author(ID:xxxxxx) <th>Description </tr>
* <tr><td>2018/08/17 <td>1.0 <td>S02010041808171 <td>匠在江湖(ID:1234) <td>创建初始版本 </tr>
* <tr><td>2019/06/24 <td>1.1 <td>S02010041906241 <td>匠在江湖(ID:1234) <td>
* -# 无
* </tr>
* </table>
******************************************************************************
*/
/** @defgroup Main Main
* @brief Main module driver
* @{
*/
/* Includes *******************************************************************/
#include <stdio.h> //库头文件
#include "tst.h" //其他文件头文件
#include "main.h" //自己头文件
/* Private typedef ************************************************************/
/* Private constants **********************************************************/
/* Private macro **************************************************************/
/* Private variables **********************************************************/
/* Private function prototypes ************************************************/
/**
******************************************************************************
* @brief main 函数
* @param None
* @retval None
******************************************************************************
*/
void main(void)
{
u16 x = tst(3, 2);
printf("结果 = %d\r\n", x);
while(1);
}
/** @} end of Main */
/********************************* END OF FILE ********************************/
main.h
/** @copyright Copyright(c)2014-2011 XXXX Co.,Ltd. All rights reserved.
******************************************************************************
* @file main.h
* @brief
* @details
* @author 匠在江湖(ID:1234)
* @version V1.0
* @date 2014/05/08
******************************************************************************
* @attention
*
* @par 修改日志:
* <table>
* <tr><th>Date <th>Version <th>Author(ID:xxxxxx) <th>Description</tr>
* <tr><td>2014/05/08 <td>V1.0 <td>匠在江湖(ID:1234) <td>创建初始版本</tr>
* </table>
******************************************************************************
*/
#ifndef MAIN_H_
#define MAIN_H_
/* Includes *******************************************************************/
#ifdef __cplusplus
extern "C"{
#endif
/* Exported types *************************************************************/
/* Exported constants *********************************************************/
/* Exported macro *************************************************************/
/* Exported functions *********************************************************/
#ifdef __cplusplus
}
#endif
#endif /* MAIN_H_ */
/********************************* END OF FILE ********************************/
其他函数 tst.c
/** @copyright Copyright(c)2014-2011 XXXX Co.,Ltd. All rights reserved.
******************************************************************************
* @file tst.c
* @brief
* @details
* @author 匠在江湖(ID:1234)
* @version V1.0
* @date 2014/05/08
******************************************************************************
* @attention
* - 类别1
* -# 情况1......
* -# 情况2......
* - 类别2
* -# 情况1......
* -# 情况2......
* @par 修改日志:
* <table>
* <tr><th>Date <th>Version <th>Author(ID:xxxxxx) <th>Description</tr>
* <tr><td>2014/05/08 <td>V1.0 <td>匠在江湖(ID:1234) <td>创建初始版本</tr>
* </table>
******************************************************************************
*/
/** @defgroup Tst Tst
* @brief 测试功能代码
*/
/* Includes *******************************************************************/
#include "tst.h"
/* Private typedef ************************************************************/
/* Private constants **********************************************************/
/* Private macro **************************************************************/
/* Private variables **********************************************************/
/* Private function prototypes ************************************************/
/**
******************************************************************************
* @brief tst 函数
* @param - a 输入值1
* - b 输入值2
* @retval 计算的和
******************************************************************************
*/
u16 tst(u8 a, u8 b)
{
u16 sum = a + b;
return sum;
}
/********************************* END OF FILE ********************************/
其他函数 tst.h
/** @copyright Copyright(c)2014-2011 XXXX Co.,Ltd. All rights reserved.
******************************************************************************
* @file tst.h
* @brief
* @details
* @author 匠在江湖(ID:1234)
* @version V1.0
* @date 2014/05/08
******************************************************************************
* @attention
*
* @par 修改日志:
* <table>
* <tr><th>Date <th>Version <th>Author(ID:xxxxxx) <th>Description</tr>
* <tr><td>2014/05/08 <td>V1.0 <td>匠在江湖(ID:1234) <td>创建初始版本</tr>
* </table>
******************************************************************************
*/
#ifndef TST_H_
#define TST_H_
/* Includes *******************************************************************/
#ifdef __cplusplus
extern "C"{
#endif
/* Exported types *************************************************************/
/* Exported constants *********************************************************/
/* Exported macro *************************************************************/
/* Exported functions *********************************************************/
/** @defgroup Tst_exported_functions Tst exported functions
* @ingroup Tst
* @{
*/
extern u16 tst(u8 a, u8 b);
/** @} end of Tst_exported_functions */
#ifdef __cplusplus
}
#endif
#endif /* TST_H_ */
/********************************* END OF FILE ********************************/