嗯,如果有人有興趣,這裏是一個implemntation.oil文件的樣子:
IMPLEMENTATION trampoline {
OS {
ENUM [STANDARD, EXTENDED] STATUS;
BOOLEAN STARTUPHOOK = FALSE;
BOOLEAN ERRORHOOK = FALSE;
BOOLEAN SHUTDOWNHOOK = FALSE;
BOOLEAN PRETASKHOOK = FALSE;
BOOLEAN POSTTASKHOOK = FALSE;
BOOLEAN USEGETSERVICEID = FALSE;
BOOLEAN USEPARAMETERACCESS = FALSE;
BOOLEAN USERESSCHEDULER = TRUE;
BOOLEAN SYSTEM_CALL = FALSE;
BOOLEAN DEBUG = FALSE;
BOOLEAN INTERRUPTTABLE = FALSE;
BOOLEAN PACKED_DATA = FALSE;
IDENTIFIER SCHEDULER = osek;
BOOLEAN [
TRUE {
ENUM [
elxr { STRING SCRIPT = "script.ld"; },
gnu_ld { STRING SCRIPT = "script.ld"; },
mwld { STRING SCRIPT = "script.mcf"; }
] LINKER;
ENUM [gcc, ghs, mwc] COMPILER;
ENUM [gnu_as] ASSEMBLER;
BOOLEAN MEMORY_PROTECTION = FALSE;
},
FALSE
] MEMMAP = FALSE;
BOOLEAN [
TRUE {
STRING APP_SRC[];
STRING CFLAGS[];
STRING CPPFLAGS[];
STRING ASFLAGS[];
STRING LDFLAGS[];
STRING APP_NAME[];
STRING COMPILER[];
STRING ASSEMBLER[];
STRING LINKER[];
},
FALSE
] BUILD = FALSE;
BOOLEAN [
TRUE {
ENUM [ FILE { STRING NAME; } ] METHOD;
ENUM [xml, txt, bin] FORMAT;
BOOLEAN TRACE_TASK = TRUE;
BOOLEAN TRACE_ISR = TRUE;
BOOLEAN TRACE_RESOURCE = TRUE;
BOOLEAN TRACE_ALARM = TRUE;
BOOLEAN TRACE_USER = TRUE;
BOOLEAN DESCRIPTION = TRUE;
},
FALSE
] TRACE = FALSE;
};
APPMODE {
};
TASK {
BOOLEAN [
TRUE {
APPMODE_TYPE APPMODE[];
},
FALSE
] AUTOSTART;
UINT32 PRIORITY;
UINT32 ACTIVATION;
ENUM [NON, FULL] SCHEDULE;
EVENT_TYPE EVENT[];
RESOURCE_TYPE RESOURCE[];
MESSAGE_TYPE MESSAGE[];
UINT32 STACKSIZE = 2000 ;
};
ISR {
UINT32 [1, 2] CATEGORY;
RESOURCE_TYPE RESOURCE[];
MESSAGE_TYPE MESSAGE[];
UINT32 PRIORITY;
UINT32 STACKSIZE = 2000 ;
};
COUNTER {
UINT32 MINCYCLE;
UINT32 MAXALLOWEDVALUE;
UINT32 TICKSPERBASE;
};
ALARM {
COUNTER_TYPE COUNTER;
ENUM [
ACTIVATETASK {
TASK_TYPE TASK;
},
SETEVENT {
TASK_TYPE TASK;
EVENT_TYPE EVENT;
}
] ACTION;
BOOLEAN [
TRUE {
UINT32 ALARMTIME;
UINT32 CYCLETIME;
APPMODE_TYPE APPMODE[];
},
FALSE
] AUTOSTART;
};
EVENT {
UINT64 WITH_AUTO MASK;
};
RESOURCE {
ENUM [
STANDARD,
LINKED {
RESOURCE_TYPE LINKEDRESOURCE;
},
INTERNAL
] RESOURCEPROPERTY;
};
MESSAGE {
ENUM [
SEND_STATIC_INTERNAL {
STRING CDATATYPE;
},
RECEIVE_UNQUEUED_INTERNAL {
MESSAGE_TYPE SENDINGMESSAGE;
UINT64 INITIALVALUE = 0;
},
RECEIVE_QUEUED_INTERNAL {
MESSAGE_TYPE SENDINGMESSAGE;
UINT32 QUEUESIZE;
}
] MESSAGEPROPERTY;
ENUM [
NONE,
ACTIVATETASK {
TASK_TYPE TASK;
},
SETEVENT {
TASK_TYPE TASK;
EVENT_TYPE EVENT;
},
COMCALLBACK {
STRING CALLBACKROUTINENAME;
MESSAGE_TYPE MESSAGE[];
},
FLAG {
STRING FLAGNAME;
}
] NOTIFICATION = NONE;
};
COM {
BOOLEAN COMERRORHOOK = FALSE;
BOOLEAN COMUSEGETSERVICEID = FALSE;
BOOLEAN COMUSEPARAMETERACCESS = FALSE;
BOOLEAN COMSTARTCOMEXTENSION = FALSE;
STRING COMAPPMODE[];
ENUM [
COMSTANDARD,
COMEXTENDED
] COMSTATUS = COMSTANDARD;
};
NM {
};
};
谷歌搜索'#include「implementation.oil」'發現,這通常指的是「針對特定平臺的系統對象的規範」。所以這是一個特定於一組目標硬件的文件。 – Ross 2014-09-05 13:14:55
謝謝羅斯,但我正在尋找一個能夠真正理解這個文件應該包含什麼的例子。 – 2014-09-05 13:24:15