{{{ #!html
OS
}}} [[BR]] = 概要 = * AUTOSARプラットフォームにおけるリアルタイムOS * 主にタスクスケジューリング、割込み管理などを行う * MCAL層が無いため、マイコンに依存した実装が伴う * [http://ja.wikipedia.org/wiki/OSEK OSEK/VDX]仕様OSの上位互換とされ、OSEK仕様書に記載されている内容については、AUTOSAR仕様書には記載されていない * OSEK仕様書もAUTOSAR同様、Webで[http://www.osek-vdx.org/ 公開]されている * OSEK仕様とAUTOSAR仕様で若干の矛盾等も存在する * コンフィギュレーション方法は、AUTOSAR準拠のXML方式に統合される * OSの機能セット毎に、4つのスケーラビリティクラスが規定されている * スケーラビリティクラス1(SC1) * 基本セット * スケーラビリティクラス2(SC2) * 基本セット + タイミング保護 * スケーラビリティクラス3(SC3) * 基本セット + メモリ保護 * スケーラビリティクラス4(SC4) * 基本セット + タイミング保護 + メモリ保護 * すべてのSCをマルチコアに拡張可能である * API一覧 ||= OSEK仕様API =||= ID[[BR]][Dec] =||= ID[[BR]][Hex] =|| ||= AUTOSAR仕様API =||= ID[[BR]][Dec] =||= ID[[BR]][Hex] =|| || [#ActivateTask ActivateTask] || --|| --|| || [#GetApplicationID GetApplicationID] || 0|| 0x00|| || [#TerminateTask TerminateTask] || --|| --|| || [#GetISRID GetISRID] || 1|| 0x01|| || [#ChainTask ChainTask] || --|| --|| || [#CallTrustedFunction CallTrustedFunction] || 2|| 0x02|| || [#Schedule Schedule] || --|| --|| || [#CheckISRMemoryAccess CheckISRMemoryAccess] || 3|| 0x03|| || [#GetTaskID GetTaskID] || --|| --|| || [#CheckTaskMemoryAccess CheckTaskMemoryAccess] || 4|| 0x04|| || [#GetTaskState GetTaskState] || --|| --|| || [#CheckObjectAccess CheckObjectAccess] || 5|| 0x05|| || [#EnableAllInterrupts EnableAllInterrupts] || --|| --|| || [#CheckObjectOwnership CheckObjectOwnership] || 6|| 0x06|| || [#DisableAllInterrupts DisableAllInterrupts] || --|| --|| || [#StartScheduleTableRel StartScheduleTableRel] || 7|| 0x07|| || [#ResumeAllInterrupts ResumeAllInterrupts] || --|| --|| || [#StartScheduleTableAbs StartScheduleTableAbs] || 8|| 0x08|| || [#SuspendAllInterrupts SuspendAllInterrupts] || --|| --|| || [#StopScheduleTable StopScheduleTable] || 9|| 0x09|| || [#ResumeOSInterrupts ResumeOSInterrupts] || --|| --|| || [#NextScheduleTable NextScheduleTable] || 10|| 0x0A|| || [#SuspendOSInterrupts SuspendOSInterrupts] || --|| --|| || [#StartScheduleTableSynchron StartScheduleTableSynchron] || 11|| 0x0B|| || [#GetResource GetResource] || --|| --|| || [#SyncScheduleTable SyncScheduleTable] || 12|| 0x0C|| || [#ReleaseResource ReleaseResource] || --|| --|| || [#SetScheduletableAsync SetScheduletableAsync] || 13|| 0x0D|| || [#SetEvent SetEvent] || --|| --|| || [#GetScheduleTableStatus GetScheduleTableStatus] || 14|| 0x0E|| || [#ClearEvent ClearEvent] || --|| --|| || [#IncrementCounter IncrementCounter] || 15|| 0x0F|| || [#GetEvent GetEvent] || --|| --|| || [#GetCounterValue GetCounterValue] || 16|| 0x10|| || [#WaitEvent WaitEvent] || --|| --|| || [#GetElapsedValue GetElapsedValue] || 17|| 0x11|| || [#GetAlarmBase GetAlarmBase] || --|| --|| || [#TerminateApplication TerminateApplication] || 18|| 0x12|| || [#GetAlarm GetAlarm] || --|| --|| || [#AllowAccess AllowAccess] || 19|| 0x13|| || [#SetRelAlarm SetRelAlarm] || --|| --|| || [#GetApplicationState GetApplicationState] || 20|| 0x14|| || [#SetAbsAlarm SetAbsAlarm] || --|| --|| || [#GetNumberOfActivatedCores GetNumberOfActivatedCores] || 21|| 0x15|| || [#CancelAlarm CancelAlarm] || --|| --|| || [#GetCoreID GetCoreID] || 22|| 0x16|| || [#GetActiveApplicationMode GetActiveApplicationMode] || --|| --|| || [#StartCore StartCore] || 23|| 0x17|| || [#StartOS StartOS] || --|| --|| || [#StartNonAutosarCore StartNonAutosarCore] || 24|| 0x18|| || [#ShutdownOS ShutdownOS] || --|| --|| || [#GetSpinlock GetSpinlock] || 25|| 0x19|| || || || || || [#ReleaseSpinlock ReleaseSpinlock] || 26|| 0x1A|| || || || || || [#TryToGetSpinlock TryToGetSpinlock] || 27|| 0x1B|| || || || || || [#ShutdownAllCores ShutdownAllCores] || 28|| 0x1C|| || || || || || [#IocSend IocSend] || 30|| 0x1E|| || || || || || [#IocWrite IocWrite] || 31|| 0x1F|| || || || || || [#IocSendGroup IocSendGroup] || 32|| 0x20|| || || || || || [#IocWriteGroup IocWriteGroup] || 33|| 0x21|| || || || || || [#IocReceive IocReceive] || 34|| 0x22|| || || || || || [#IocRead IocRead] || 35|| 0x23|| || || || || || [#IocReceiveGroup IocReceiveGroup] || 36|| 0x24|| || || || || || [#IocReadGroup IocReadGroup] || 37|| 0x25|| || || || || || [#IocEmptyQueue IocEmptyQueue] || 38|| 0x26|| ---- = API仕様(OSEK) = == !ActivateTask == {{{ StatusType ActivateTask(TaskType TaskID) }}} == !TerminateTask == {{{ StatusType TerminateTask(void) }}} == !ChainTask == {{{ StatusType ChainTask(TaskType TaskID) }}} == Schedule == {{{ StatusType Schedule(void) }}} == GetTaskID == {{{ StatusType GetTaskID(TaskRefType TaskID) }}} == !GetTaskState == {{{ StatusType GetTaskState(TaskType TaskID, TaskStateRefType State) }}} == !EnableAllInterrupts == {{{ void EnableAllInterrupts(void) }}} == !DisableAllInterrupts == {{{ void DisableAllInterrupts(void) }}} == !ResumeAllInterrupts == {{{ void ResumeAllInterrupts(void) }}} == !SuspendAllInterrupts == {{{ void SuspendAllInterrupts(void) }}} == ResumeOSInterrupts == {{{ void ResumeOSInterrupts(void) }}} == SuspendOSInterrupts == {{{ void SuspendOSInterrupts(void) }}} == !GetResource == {{{ StatusType GetResource(ResourceType ResID) }}} == !ReleaseResource == {{{ StatusType ReleaseResource(ResourceType ResID) }}} == !SetEvent == {{{ StatusType SetEvent(TaskType TaskID, EventMaskType Mask) }}} == !ClearEvent == {{{ StatusType ClearEvent(EventMaskType Mask) }}} == !GetEvent == {{{ StatusType GetEvent(TaskType TaskID, EventMaskRefType Event) }}} == !WaitEvent == {{{ StatusType WaitEvent(EventMaskType Mask) }}} == !GetAlarmBase == {{{ StatusType GetAlarmBase(AlarmType AlarmID, AlarmBaseRefType Info) }}} == !GetAlarm == {{{ StatusType GetAlarm(AlarmType AlarmID, TickRefType Tick) }}} == !SetRelAlarm == {{{ StatusType SetRelAlarm(AlarmType AlarmID, TickType increment, TickType cycle) }}} == !SetAbsAlarm == {{{ StatusType SetAbsAlarm(AlarmType AlarmID, TickType start, TickType cycle) }}} == !CancelAlarm == {{{ StatusType CancelAlarm(AlarmType AlarmID) }}} == !GetActiveApplicationMode == {{{ AppModeType GetActiveApplicationMode(void) }}} == StartOS == {{{ void StartOS(AppModeType Mode) }}} == ShutdownOS == {{{ void ShutdownOS(StatusType Error) }}} ---- = API仕様(AUTOSAR) = == GetApplicationID == {{{ ApplicationType GetApplicationID(void) }}} == GetISRID == {{{ ISRType GetISRID(void) }}} == !CallTrustedFunction == {{{ StatusType CallTrustedFunction(TrustedFunctionIndexType FunctionIndex, TrustedFunctionParameterRefType FunctionParams) }}} == CheckISRMemoryAccess == {{{ AccessType CheckISRMemoryAccess(ISRType ISRID, MemoryStartAddressType Address, MemorySizeType Size) }}} == !CheckTaskMemoryAccess == {{{ AccessType CheckTaskMemoryAccess(TaskType TaskID, MemoryStartAddressType Address, MemorySizeType Size) }}} == !CheckObjectAccess == {{{ ObjectAccessType CheckObjectAccess(ApplicationType ApplID, ObjectTypeType ObjectType, void ...) }}} == !CheckObjectOwnership == {{{ ApplicationType CheckObjectOwnership(ObjectTypeType ObjectType, void ...) }}} == !StartScheduleTableRel == {{{ StatusType StartScheduleTableRel(ScheduleTableType ScheduleTableID, TickType Offset) }}} == !StartScheduleTableAbs == {{{ StatusType StartScheduleTableAbs(ScheduleTableType ScheduleTableID, TickType Start) }}} == !StopScheduleTable == {{{ StatusType StopScheduleTable(ScheduleTableType ScheduleTableID) }}} == !NextScheduleTable == {{{ StatusType NextScheduleTable(ScheduleTableType ScheduleTableID_From, ScheduleTableType ScheduleTableID_To) }}} == !StartScheduleTableSynchron == {{{ StatusType StartScheduleTableSynchron(ScheduleTableType ScheduleTableID) }}} == !SyncScheduleTable == {{{ StatusType SyncScheduleTable(ScheduleTableType ScheduleTableID, TickType Value) }}} == !SetScheduletableAsync == {{{ StatusType SetScheduletableAsync(ScheduleTableType ScheduleTableID) }}} == !GetScheduleTableStatus == {{{ StatusType GetScheduleTableStatus(ScheduleTableType ScheduleTableID, ScheduleTableStatusRefType ScheduleStatus) }}} == !IncrementCounter == {{{ StatusType IncrementCounter(CounterType CounterID) }}} == !GetCounterValue == {{{ StatusType GetCounterValue(CounterType CounterID, TickRefType Value) }}} == !GetElapsedValue == {{{ StatusType GetElapsedValue(CounterType CounterID, TickRefType Value, TickRefType ElapsedValue) }}} == !TerminateApplication == {{{ StatusType TerminateApplication(ApplicationType Application, RestartType RestartOption) }}} == !AllowAccess == {{{ StatusType AllowAccess(void) }}} == !GetApplicationState == {{{ StatusType GetApplicationState(ApplicationType Application, ApplicationStateRefType Value) }}} == !GetNumberOfActivatedCores == {{{ uint32 GetNumberOfActivatedCores(void) }}} == GetCoreID == {{{ CoreIdType GetCoreID(void) }}} == !StartCore == {{{ void StartCore(CoreIdType CoreID, StatusType* Status) }}} == !StartNonAutosarCore == {{{ void StartNonAutosarCore(CoreIdType CoreID, StatusType* Status) }}} == !GetSpinlock == {{{ StatusType GetSpinlock(SpinlockIdType SpinlockId) }}} == !ReleaseSpinlock == {{{ StatusType ReleaseSpinlock(SpinlockIdType SpinlockId) }}} == !TryToGetSpinlock == {{{ StatusType TryToGetSpinlock(SpinlockIdType SpinlockId, TryToGetSpinlockType* Success) }}} == !ShutdownAllCores == {{{ void ShutdownAllCores(StatusType Error) }}} == !IocSend == {{{ Std_ReturnType IocSend_[_]( IN) }}} == !IocWrite == {{{ Std_ReturnType IocWrite_[_]( IN) }}} == !IocSendGroup == {{{ Std_ReturnType IocSendGroup_( IN1, IN2, ...) }}} == !IocWriteGroup == {{{ Std_ReturnType IocWriteGroup_( IN1, IN2, ...) }}} == !IocReceive == {{{ Std_ReturnType IocReceive_( OUT) }}} == !IocRead == {{{ Std_ReturnType IocRead_( OUT) }}} == !IocReceiveGroup == {{{ Std_ReturnType IocReceiveGroup_( OUT1, OUT2, ...) }}} == !IocReadGroup == {{{ Std_ReturnType IocReadGroup_( OUT1, OUT2, ...) }}} == !IocEmptyQueue == {{{ Std_ReturnType IocEmptyQueue_(void) }}} ---- = コンフィギュレーション仕様 =