mwerks.h

来自「Coldfire MCF5282 DBug bootloader」· C头文件 代码 · 共 30 行

H
30
字号
/*
 * File:	mwerks.h
 * Purpose:	Define constants used by CodeWarrior Preprocessor
 *
 * Notes:	Use this as a prefix file for the assembler and compiler
 *
 */

/* MetroWerks looks for an underscore prepended to C function names */
#define _UNDERSCORE_

/* Define a constant to inform files we are using CodeWarrior */
#ifndef __MWERKS__
#define __MWERKS__
#endif

/* Modify the interrupt type to work with CodeWarrior */
#define __interrupt__	__declspec(interrupt)

/* Force functions to return values in D0 */
#pragma pointers_in_D0

/* Define custom sections for relocating code, data, and constants */
#pragma define_section relocate_code ".relocate_code" far_absolute RX
#pragma define_section relocate_data ".relocate_data" far_absolute RW
#pragma define_section relocate_const ".relocate_const" far_absolute R
#define __relocate_code__	__declspec(relocate_code)
#define __relocate_data__	__declspec(relocate_data)
#define __relocate_const__	__declspec(relocate_const)

⌨️ 快捷键说明

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