Files
STM32F4-Base/Drivers/BSP/dbg_cfg.h
2026-07-19 15:27:49 +08:00

41 lines
1.0 KiB
C
Raw 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.
/*
* 模块名称Debug Output Configuration
* 模块功能:全局调试输出配置,定义各调试级别的编译开关
* 参考 FlashDB fdb_cfg.h 设计模式
* 使用方法:
* - DBG_ENABLE 总开关,定义后启用 DBG_ERROR / DBG_INFO
* - DBG_DEBUG_ENABLE 子开关,同时定义 DBG_ENABLE 后启用 DBG_DEBUG含 __func__:__LINE__
* - 两者都不定义:所有 DBG_* 宏为空操作release 版本)
*
* 用户可在本文件中直接控制,也可在编译器预定义中覆盖
* 适用平台:所有 BSP 驱动
* 作者:王建锋
* 创建日期2026-07-18
* 修改记录:
* 2026-07-18 王建锋 创建初始版本
*/
#ifndef __DBG_CFG_H
#define __DBG_CFG_H
#ifdef __cplusplus
extern "C" {
#endif
/*
* 总开关:取消注释启用所有调试输出
*/
#define DBG_ENABLE
/*
* 调试级别开关:取消注释额外输出 DBG_DEBUG 级别
* 仅在 DBG_ENABLE 定义时生效
*/
/* #define DBG_DEBUG_ENABLE */
#ifdef __cplusplus
}
#endif
#endif /* __DBG_CFG_H */