⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 debug.h

📁 Philips LPC2138 Demo Application with Keil C
💻 H
字号:
/*****************************************************************************\*              efs - General purpose Embedded Filesystem library              **          ---------------------------------------------------------          **                                                                             ** Filename : debug.h                                                          ** Description : Headerfile for debug.c                                        **                                                                             ** This library is free software; you can redistribute it and/or               ** modify it under the terms of the GNU Lesser General Public                  ** License as published by the Free Software Foundation; either                ** version 2.1 of the License, or (at your option) any later version.          **                                                                             ** This library is distributed in the hope that it will be useful,             ** but WITHOUT ANY WARRANTY; without even the implied warranty of              ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU           ** Lesser General Public License for more details.                             **                                                                             **                                                    (c)2005 Lennart Yseboody **                                                    (c)2005 Michael De Nil   **                             LPC2000 ARM7 Interface (c)2005 Martin Thomas    *\*****************************************************************************/#ifndef __DEBUG_H__#define __DEBUG_H__/*****************************************************************************/#include "types.h"#include "config.h"/*****************************************************************************/#ifndef DEBUG	#define TXT(x) ;	#define DBG(x) ;	#define FUNC_IN(x) ;	#define FUNC_OUT(x) ;#endif#ifdef DEBUG	#if defined(HW_ENDPOINT_LINUX) || defined(HW_ENDPOINT_LINUX64)	    #define HW_ENDPOINT_LINUX_ALL		#endif	#ifdef HW_ENDPOINT_ATMEGA128_SD		#include <avr/io.h>		#include <compat/ina90.h>		#include <avr/pgmspace.h>		#include <stdio.h>		#define TXT(x) PSTR(x)		#define DBG(x) debug x		#define FUNC_IN(x) ;		#define FUNC_OUT(x) ;	#endif	#ifdef HW_ENDPOINT_LINUX_ALL		#include <stdio.h>		#include <stdarg.h>			#define TXT(x) x		#define DBG(x) debug x		#define FUNC_IN(x) debug_funcin(x)		#define FUNC_OUT(x) debug_funcout(x)	#endif	#ifdef HW_ENDPOINT_DSP_TI6713_SD		#include <stdio.h>		#include <stdarg.h>		#define TXT(x) x		#define DBG(x) printf x		#define FUNC_IN(x) ;		#define FUNC_OUT(x) ;	#endif	#ifdef HW_ENDPOINT_NIOS_2_SD		#include <stdio.h>		#include <stdarg.h>		#define TXT(x) x		#define DBG(x) printf x		#define FUNC_IN(x) ;		#define FUNC_OUT(x) ;	#endif	#ifdef HW_ENDPOINT_LPC2000_SD		#include "lpc2000_dbg_printf.h"				#define TXT(x) x		#define DBG(x) debug x		#define FUNC_IN(x) ;		#define FUNC_OUT(x) ;		#define debug lpc2000_debug_printf	#else	void debug(const eint8 *format, ...); /* This is messy FIXME */	#endif	void debug_init();	void debug_end();	#ifdef HW_ENDPOINT_LINUX_ALL	FILE* debugfile;	volatile euint8 tw;	void debug_funcin(const eint8 *format, ...);	void debug_funcout(const eint8 *format, ...);	euint8 debug_getByte();	euint8 debug_getString(euint8 *data,euint16 length);	#endif	#ifdef HW_ENDPOINT_ATMEGA128_SD	void debug_initUART(euint16 baudrate );	void debug_sendByte(euint8 data );	#endif#endif#endif

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -