DEENESPTFRRUARHIKOZHNL

Standard Types (Std_Types)

ModulStd (Standard Types)
BSW-Modul-ID197
Standard-Header#include "Std_Types.h"
SWS-SpezifikationAUTOSAR_SWS_StandardTypes.pdf
ClusterGeneral & Standard Types

Module guideAI-GENERATED

Provides uniform return, version, transformer, and constant types for all Classic modules.
AI-GENERATED unreviewed Model: claude-opus-5-5 · Effort: high · Temperature: not controllable · Prompt: 4fcc802ced39 Provenance Open questions (4)
Causal anchor: R20-11 Valid from R20-11 Synthesized for this specification release.
translated from the German guidegemini-3.8-flash-low · 2026-10-13 · German original

Provides uniform return, version, transformer, and constant types for all Classic modules.

The module std provides platform-wide uniform types and constants via Std_Types.h, but contains neither code nor configuration. Central is Std_ReturnType (uint8) with E_OK and E_NOT_OK. Modules may define their own values only in the range 0x02–0x3F with module prefix, because bit 7 and bit 8 are reserved for the RTE [SWS_Std_00011]. In addition, the module provides the constants STD_HIGH/STD_LOW, STD_ON/STD_OFF, and STD_ACTIVE/STD_IDLE, the type Std_VersionInfoType for version querying, as well as transformer and message types for client-server communication. In R20-11, the header also includes Compiler.h SRS BSWGeneral p. 62.

The module std is a pure type header. Via Std_Types.h it provides types and symbols, but no functions [SWS_Std_00005]. In R20-11, the header includes Platform_Types.h and Compiler.h and defines Std_ReturnType as well as the values E_OK/E_NOT_OK and the STD_* constants. Every module that uses these types includes it SRS BSWGeneral p. 62. According to a later version of the specification, there is no configuration and no dedicated error handling; this is likely to apply to R20-11 as well (interpretation) SWS StandardTypes p. 27. Question (open)

kontext std Std_Types.h (Modul std) plat Platform_Types.h std->plat #include comp Compiler.h (in R20-11 gefordert) std->comp #include bsw BSW-Module (z. B. Can, CanIf, Adc, NvM) bsw->std #include cdd Complex Device Driver cdd->std #include rte RTE (Rte_Call, Rte_Read, Rte_Send, …) rte->std nutzt Std_ReturnType, Std_TransformerError xf Transformer (SomeIpXf, E2EXf) xf->std nutzt Std_MessageTypeType, Std_MessageResultType swc SW-C swc->rte RTE APIs with Std_ReturnType / transformerError

Context diagram: Std_Types.h as a common type base for BSW modules, CDDs, RTE, and transformers. Sources: SRS BSWGeneral p. 62, CDD Guideline p. 14

The core of the module is Std_ReturnType (uint8) with the values E_OK (0) and E_NOT_OK (1). The range 0x02–0x3F is intended for module-specific errors with module prefix; bit 7 and bit 8 are defined by the RTE specification [SWS_Std_00011]. Examples of such extensions are CAN_BUSY and Csm_ReturnType BSWUML Guide p. 29. Due to OSEK, E_OK is guarded via STATUSTYPEDEFINED [SWS_Std_00006].

returntype rt Std_ReturnType (abgeleitet von uint8) ok E_OK = 0x00 (kein Fehler) rt->ok Standardwert nok E_NOT_OK = 0x01 (generischer Fehler) rt->nok Standardwert user 0x02–0x3F module-specific values (6 low-order bits, module prefix) rt->user erweiterbar rtebits Bit 7 and bit 8 reserved, defined by RTE specification rt->rtebits reserviert csm Csm_ReturnType «extra_literals» CSM_E_BUSY = 2 CSM_E_SMALL_BUFFER = 3 CSM_E_ENTROPY_EXHAUSTION = 4 csm->rt erbt von csm->user belegt can CAN_BUSY = 0x02 (Can_Write: kein Sendeobjekt frei) can->user belegt

Context diagram (type structure): default values, module-specific range, and RTE-reserved bits of Std_ReturnType. Sources: [SWS_Std_00005], [SWS_Std_00011], SWS StandardTypes p. 15

In addition, there are three pairs of constants, each with 0x01u/0x00u: STD_HIGH/STD_LOW for physical levels, STD_ON/STD_OFF as switches, and STD_ACTIVE/STD_IDLE for logical states ([SWS_Std_00007], [SWS_Std_00010], [SWS_Std_00013]). Std_VersionInfoType transports vendor ID, module ID, and software version for the synchronous, reentrant function <Ma>_GetVersionInfo [SWS_Std_00015].

For data transformation, std defines two types for transformer errors: Std_TransformerError, a structure consisting of error code and transformer class, and Std_TransformerClass [SWS_Std_00021]. The RTE passes this error on via the optional parameter transformerError SWS RTE p. 731. For client-server communication, Std_MessageTypeType and Std_MessageResultType encode request/response and OK/ERROR. A function pointer of type Std_ExtractProtocolHeaderFieldsType reads both values from a transformer header [SWS_Std_91003]. The forward types are still draft in R20-11 [SWS_Std_00029].

Role and system boundary: a pure type header without runtime behavior

The std module (Standard Types) contains no functions. It exclusively provides types and symbols that are available via Std_Types.h. Every requirement of the module names this header as its source, such as [SWS_Std_00005] and [SWS_Std_00015]. The specification explicitly states: the header provides no code and requires no other BSW modules; it has no configuration and no error handling of its own SWS StandardTypes p. 27. These wordings originate from the version starting with R23-11. The same is likely to apply to R20-11 because the R20-11 requirements contain exclusively type and symbol definitions (interpretation). Question Q-8e4c66ae80752d38 (open)

The purpose is standardized, platform-wide access to standard types. The BSW requirement for the standard type header therefore demands: every module that uses AUTOSAR integer types or the standard return type includes Std_Types.h SRS BSWGeneral p. 62. The return type Std_ReturnType is explicitly shared between the RTE and BSW modules [SWS_Std_00005]. In the methodology, the standard types are additionally described as the ARXML artifact "AUTOSAR Standard Types" Methodology p. 400.

kontext std Std_Types.h (Modul std) plat Platform_Types.h std->plat #include comp Compiler.h (in R20-11 gefordert) std->comp #include bsw BSW-Module (z. B. Can, CanIf, Adc, NvM) bsw->std #include cdd Complex Device Driver cdd->std #include rte RTE (Rte_Call, Rte_Read, Rte_Send, …) rte->std nutzt Std_ReturnType, Std_TransformerError xf Transformer (SomeIpXf, E2EXf) xf->std nutzt Std_MessageTypeType, Std_MessageResultType swc SW-C swc->rte RTE APIs with Std_ReturnType / transformerError

Context diagram: Std_Types.h includes platform and compiler headers and is used by BSW modules, CDDs, RTE, and transformers as a common type base. Sources: SRS BSWGeneral p. 62, CDD Guideline p. 14, [SWS_Std_00005], [SWS_Std_00021]

Structure of Std_Types.h and inclusion in the header tree

For R20-11, the BSW requirement defines what Std_Types.h must provide SRS BSWGeneral p. 62:

  • include the platform-specific type header Platform_Types.h,
  • include the compiler-specific header Compiler.h,
  • define Std_ReturnType,
  • specify values for E_OK, E_NOT_OK, STD_ON, STD_OFF, STD_HIGH, STD_LOW, STD_ACTIVE, and STD_IDLE.

In the later version of the same requirement, the inclusion of Compiler.h is missing RS BSWGeneral p. 60. This matches the change history: in R22-11, the obsolete compiler abstraction was removed from a Std requirement, and NULL_PTR was only added with R21-11 SWS StandardTypes p. 1. For R20-11, Compiler.h is therefore part of the include chain, whereas a NULL_PTR from Std_Types.h is not yet.

A special case concerns E_OK. The symbol is already defined in OSEK and must therefore be shared. [SWS_Std_00006] prescribes protection via STATUSTYPEDEFINED: within the protection, E_OK (0x00u) and StatusType are defined; E_NOT_OK (0x01u) is outside. The BSW requirement contains the same implementation note with reference to ISO 17356-3 SRS BSWGeneral p. 62. How a Complex Device Driver places the header into its include structure is shown in the diagram of the CDD header structure CDD Guideline p. 14.

Std_ReturnType: Value range, bit layout, and module-specific extensions

Std_ReturnType is derived from uint8. The default values are E_OK (0) and E_NOT_OK (1); the range 0x02–0x3F is available for user-specific errors [SWS_Std_00005]. [SWS_Std_00011] refines this rule:

  • Normally, the type is used with E_OK or E_NOT_OK.
  • If these values are not sufficient, custom values may be defined in the six low-order bits, named with the module prefix.
  • Bit 7 and bit 8 are reserved. Like the overall layout, they are defined by the RTE specification.

The diagram of the layout shows exactly this division SWS StandardTypes p. 15.

The RTE specification describes Std_ReturnType as the type for status and error values of API functions; the value 0 is reserved for "no error occurred" SWS RTE p. 675. According to the BSW modeling guide, it is the only return type permitted in client-server operations of service interfaces BSWUML Guide p. 28. An example of a module-specific extension is CAN_BUSY (0x02) of the CAN driver. Can_Write() returns this value if no transmit object is free SWS CANDriver p. 54.

returntype rt Std_ReturnType (abgeleitet von uint8) ok E_OK = 0x00 (kein Fehler) rt->ok Standardwert nok E_NOT_OK = 0x01 (generischer Fehler) rt->nok Standardwert user 0x02–0x3F module-specific values (6 low-order bits, module prefix) rt->user erweiterbar rtebits Bit 7 and bit 8 reserved, defined by RTE specification rt->rtebits reserviert csm Csm_ReturnType «extra_literals» CSM_E_BUSY = 2 CSM_E_SMALL_BUFFER = 3 CSM_E_ENTROPY_EXHAUSTION = 4 csm->rt erbt von csm->user belegt can CAN_BUSY = 0x02 (Can_Write: kein Sendeobjekt frei) can->user belegt

Context diagram (type structure): Std_ReturnType is divided into default values, a module-specific range 0x02–0x3F, and two bits reserved by the RTE; module extensions such as Csm_ReturnType or CAN_BUSY occupy only the free range. Sources: [SWS_Std_00005], [SWS_Std_00011], SWS StandardTypes p. 15, BSWUML Guide p. 29, SWS CANDriver p. 54

In the UML model of the BSW, such an extension is modeled as class <Ma>_ReturnType with the stereotype «extra_literals». Its values bear the module prefix and lie in the range 0x02–0x3f BSWUML Guide p. 28. The example Csm_ReturnType with CSM_E_BUSY, CSM_E_SMALL_BUFFER, and CSM_E_ENTROPY_EXHAUSTION illustrates the pattern BSWUML Guide p. 29. If several modules of a stack require the same extension, it does not have to be defined separately for each module BSWUML Guide p. 33. The R23-11 version provides a generic class with «generic_type» for this purpose, from which the module-specific extensions are derived TR BSWUML Guide p. 37.

erweiterung start Start: module defines return values q1 Are E_OK / E_NOT_OK sufficient? start->q1 std Use Std_ReturnType with E_OK / E_NOT_OK q1->std yes q2 Do multiple modules of a stack require the same extension? q1->q2 no ende End: bits 7/8 remain reserved for the RTE std->ende gen generische Erweiterung «extra_literals» «generic_type» (Fassung R23-11) q2->gen yes own <Ma>_ReturnType als Klasse «extra_literals» modellieren q2->own no derive Derive <Ma>_ReturnType from it, add own literals if applicable gen->derive lit Define literals with module prefix in the range 0x02–0x3F derive->lit own->lit lit->ende

Activity diagram: decision whether and how a module extends Std_ReturnType with custom values. Sources: [SWS_Std_00011], BSWUML Guide p. 28, BSWUML Guide p. 33, TR BSWUML Guide p. 37

Symbolic constants for levels, switches, and states

In addition to the return values, Std_Types.h defines three pairs of constants. All three use the numerical values 0x01u and 0x00u, but are commented differently ([SWS_Std_00007], [SWS_Std_00010], [SWS_Std_00013]):

PairValuesMeaning according to definition
STD_HIGH / STD_LOW0x01u / 0x00uphysical state 5 V or 3.3 V / 0 V
STD_ON / STD_OFF0x01u / 0x00uOn/Off, without further comment
STD_ACTIVE / STD_IDLE0x01u / 0x00ulogical state active / idle

A typical user of STD_HIGH/STD_LOW is the DIO driver: its read service returns exactly one of these two levels SWS DIO p. 37. STD_ON/STD_OFF serve as pre-compile switches. One example is EEP_21_LDEXT_VERSION_INFO_API STD_ON in the general BSW specification SWS BSWGeneral p. 76; another is the optional API switches of the GPT driver SWS GPT p. 48.

Version query via Std_VersionInfoType

Std_VersionInfoType is a structure with the following elements: vendorID and moduleID (uint16 each) as well as sw_major_version, sw_minor_version, and sw_patch_version (uint8 each). It is used via <Module name>_GetVersionInfo() to query the version of a BSW module [SWS_Std_00015]. The general BSW specification defines for this function SWS BSWGeneral p. 76:

  • It operates synchronously and is reentrant.
  • It has exactly one parameter of this type.
  • Its availability is configured per module at pre-compile time via <Ma>VersionInfoApi.

The naming rule GetVersionInfo is stated in the BSW requirement with the example Eep_21_LDExt_GetVersionInfo SRS BSWGeneral p. 60.

Concrete implementations exist in many modules. When development error detection is enabled, Can_GetVersionInfo rejects a null pointer with CAN_E_PARAM_POINTER SWS CANDriver p. 57. Adc_GetVersionInfo checks accordingly for ADC_E_PARAM_POINTER SWS ADCDriver p. 80. The NVRAM manager shows the call as a simple synchronous exchange between user and module SWS NvM p. 158.

Version query with Std_VersionInfoTypeNutzerBSW-Modul <Ma>DetAPI only present if<Ma>VersionInfoApi = STD_ON (Pre-compile)<Ma>_GetVersionInfo(&versioninfo)altversioninfo == NULL and development error detection activeEntwicklungsfehler melden(z. B. CAN_E_PARAM_POINTER)Valid pointervendorID, moduleID,sw_major/minor/patch_version eintragenReturn (void; synchronous, reentrant)

Sequence diagram: A user queries the version of a module synchronously; in case of a null pointer and active development error detection, the module reports an error, otherwise it populates Std_VersionInfoType. Sources: [SWS_Std_00015], SWS BSWGeneral p. 76, SWS CANDriver p. 57, SWS NvM p. 158

Transformer and message types for data transformation

std provides several types for transformer chains. In R20-11, Std_TransformerError is a structure consisting of errorCode (uint8) and transformerClass of type Std_TransformerClass [SWS_Std_00021]. Std_TransformerClass is derived from uint8 and knows five values [SWS_Std_00024]: STD_TRANSFORMER_UNSPECIFIED (0x00), STD_TRANSFORMER_SERIALIZER (0x01), STD_TRANSFORMER_SAFETY (0x02), STD_TRANSFORMER_SECURITY (0x03), and STD_TRANSFORMER_CUSTOM (0xFF).

The short signature in the API directory lists Std_TransformerError as typedef uint8. However, the structure definition of the requirement is authoritative. Later versions type errorCode as a separate type Std_TransformerErrorCode, whose meaning is determined per transformer chain SWS StandardTypes p. 17.

The RTE passes this type as an optional OUT parameter transformerError to its APIs, such as in Rte_Call SWS RTE p. 731, Rte_Read SWS RTE p. 720, and Rte_Result SWS RTE p. 750. The plug-in interfaces describe it as the error that occurred during the execution of the transformer chain SWS RTE p. 969.

Std_TransformerForward and Std_TransformerForwardCode are marked as draft in R20-11. The forward code recognizes E_OK, E_SAFETY_INVALID_REP, E_SAFETY_INVALID_SEQ, and E_SAFETY_INVALID_CRC ([SWS_Std_00027], [SWS_Std_00029]). In later versions, Rte_Send accepts an optional forwardedCode of this type SWS RTE p. 704. It presumably serves to re-map received safety errors during forwarding, as described by the E2E forward functions SWS E2ELibrary p. 107 (interpretation). According to the change history, the structure Std_TransformerForward was removed in R22-11 SWS StandardTypes p. 1. Question Q-f0d374b3b793c868 (open)

Report transformer error via Std_TransformerErrorSW-CRTETransformer-KettetransformerError exists only forerrorHandling = transformerErrorHandlingRte_Call_<p>_<o>(…, OUT transformerError)Execute transformer chainaltTransformer meldet FehlerFehlercode (Interpretation)Fill Std_TransformerError:errorCode, transformerClass (z. B. STD_TRANSFORMER_SAFETY)Std_ReturnType + transformerErrorkein Transformer-FehlerResult without errorStd_ReturnType (z. B. E_OK)

Sequence diagram: In addition to Std_ReturnType, a transformer error reaches the SW-C as Std_TransformerError with error code and transformer class. Sources: [SWS_Std_00021], [SWS_Std_00024], SWS RTE p. 731, SwCluster Guideline p. 245, SWS RTE p. 774

For client-server communication, there are two encoding types, in which 0x02–0x3F are each reserved for future values:

  • Std_MessageTypeType distinguishes request (STD_MESSAGETYPE_REQUEST, 0x00) and response (STD_MESSAGETYPE_RESPONSE, 0x01) ([SWS_Std_91001], [SWS_Std_00017]).
  • Std_MessageResultType encodes the result of a response: STD_MESSAGERESULT_OK (0x00) or STD_MESSAGERESULT_ERROR (0x01) ([SWS_Std_91002], [SWS_Std_00019]).

The function pointer type Std_ExtractProtocolHeaderFieldsType describes a synchronous, reentrant function. It extracts both values from the protocol header of a transformer in a buffer and returns a Std_ReturnType [SWS_Std_91003]. Transformers optionally receive such a pointer as an argument to their inverse function ASWS TransformerGeneral p. 40. The SOME/IP transformer provides a suitable implementation with SomeIpXf_ExtractProtocolHeaderFields SWS SOMEIPTransformer p. 61. The E2E profiles 4m, 7m, 8m, and 44m evaluate both values in their check functions SWS E2ELibrary p. 108.

Protokoll-Header-Felder extrahieren (E2E, Profil PXXm)RTEE2EXf (inverse Funktion)SomeIpXfE2E-BibliothekE2EXf_Inv_<transformerId>(extractProtocolHeaderFields,buffer, bufferLength, …)optProfile == PXXmextractProtocolHeaderFields(buffer, bufferLength,&messageType, &messageResult)= SomeIpXf_ExtractProtocolHeaderFields (Beispiel)Std_ReturnType ok,Std_MessageTypeType, Std_MessageResultTypealtok == E_OKsourceID = config->sourceIDE2E_P04mSourceCheck(…, SourceID,MessageType, MessageResult, …) (Beispiel)Std_ReturnTypeok == E_NOT_OK (z. B. falsche Protokollversion, Puffer zu kurz)Abort processing with error terminationuint8 (result of inverse transformation)

Sequence diagram: For PXXm profiles, the E2E transformer extracts the message type and result via the passed function pointer and continues checking only for E_OK. Sources: [SWS_Std_91003], ASWS TransformerGeneral p. 40, SWS E2ETransformer p. 45, SWS SOMEIPTransformer p. 61, SWS E2ELibrary p. 108

Behavior in the event of an error

The module itself neither detects nor reports errors. The version starting with R23-11 states that the standard types provide no error handling and support no security events SWS StandardTypes p. 27; the same is likely to apply to R20-11 (interpretation). Question (open) Therefore, error behavior only arises in the modules that use the types. The basic signal is E_NOT_OK [SWS_Std_00006]; its concrete meaning is defined by the respective API. For Adc_ReadGroup, it means "no results available or development error" SWS ADCDriver p. 61; for CanIf_Transmit, "transmit request not accepted" SWS CANInterface p. 87.

More detailed error patterns are reported via module-specific values in the range 0x02–0x3F [SWS_Std_00011], for example CAN_BUSY SWS CANDriver p. 54. Callers must therefore expect a Std_ReturnType to assume more than two values. A special case is callbacks routed via the RTE as AUTOSAR services: although the caller may assume E_OK, such callbacks can fail, for instance, in partitioned systems SWS BSWGeneral p. 69.

In transformer chains, an error is reported in addition to the return value via Std_TransformerError with error code and transformer class [SWS_Std_00021]. The RTE generates the optional parameter transformerError only if the error handling transformerErrorHandling is configured for the port SWS RTE p. 774. If extracting the header fields fails, SomeIpXf_ExtractProtocolHeaderFields returns E_NOT_OK, such as in the case of an incorrect protocol version or a buffer that is too short SWS SOMEIPTransformer p. 61. The E2E transformer logic continues checking only upon E_OK SWS E2ETransformer p. 45.

Further detailed evidence

AI-generated module guide for std (classic, R20-11), created solely on the basis of the autodocs payload. Many document passages originate from other releases; the R20-11 requirements are normative. Check against the specification prior to binding use.

Standard Types (Std_Types)

Standard types, return codes (Std_ReturnType, E_OK, E_NOT_OK), version info structures, and error codes shared across the entire AUTOSAR architecture.

Typen — Übersicht

Typen — Detailansicht

type Std_ReturnType [SWS_Std_00005] 📄 PDF

typedef uint8 Std_ReturnType;

This type can be used as standard API return type which is shared between the RTE and the BSW modules. It shall be defined as follows: typedef uint8 Std_ Return Type;

AI-GENERATED unreviewed Model: gemini-3.8-flash-medium · Effort: medium · Temperature: not controllable · Prompt: 6f8f9add55f9 Provenance Open questions (1)
translated from the German guidegemini-3.8-flash-low · 2026-10-13 · German original

The type Std_ReturnType serves as a standardized return type for API functions and is shared by the RTE and BSW modules ([SWS_Std_00005]). It is available via the header Std_Types.h and defined as uint8 ([SWS_Std_00005]).

By default, Std_ReturnType is assigned the values E_OK (value 0) or E_NOT_OK (value 1) ([SWS_Std_00005], [SWS_Std_00011]). If these two standard return values are not sufficient, the standard allows defining module-specific error values:

  • Value range for user errors: For user-defined error codes, the range 0x02 to 0x3F is available ([SWS_Std_00005]). Here, the six least significant bits are used ([SWS_Std_00011]).
  • Naming convention: When naming user-specific error values, the respective module prefix must strictly be prepended in accordance with the BSW guidelines ([SWS_Std_00011]).
  • RTE reservation: Bit 7 and Bit 8 are reserved and are defined by the RTE specification, which the general layout of the return type also follows ([SWS_Std_00011]). Interpretation: These are presumably the two most significant bits of the 8-bit representation, completing the six lower bits to form one byte. Question Q-d97256956c510f58 (open)

Specific error handling mechanisms such as DET or DEM as well as reentrancy requirements are not defined in the sources for the base type itself, but are the responsibility of the respective APIs that use this type as a return value.

This usage note was generated by an AI and is based on the specifications of AUTOSAR Classic Release R20-11.

Implementer's Guide to follow (complexity I1)

type Std_TransformerError [SWS_Std_00021] 📄 PDF

typedef uint8 Std_TransformerError;

-

AI-GENERATED unreviewed Model: gemini-3.8-flash-medium · Effort: medium · Temperature: not controllable · Prompt: 534a10ed1c56 Provenance Open questions (2)
translated from the German guidegemini-3.8-flash-low · 2026-10-13 · German original

According to requirement [SWS_Std_00021], the data type Std_TransformerError is provided as a standardized type via the header file Std_Types.h for the AUTOSAR Classic Platform. Structurally, the element is defined in the specification as a structure and is composed of two components: the element errorCode with the base type uint8 and the element transformerClass with the type Std_TransformerClass [SWS_Std_00021].

Regarding practical use, the specification contains no concrete function signatures, parameter descriptions, or return values. The structure type presumably serves as a uniform data container for the structured transmission of errors that occur during data transformation (interpretation). Question Q-6e0938f276d60fd3 (open) Here, the field errorCode likely conveys the actual numeric error code, while transformerClass identifies the causing or associated transformer class (interpretation). Question Q-d8806698683ec00e (open)

Specific error handling mechanisms such as DET or DEM notifications are not defined in [SWS_Std_00021]. Requirements regarding concurrency, reentrancy, or synchronous versus asynchronous semantics are also missing from the source material. Since it is a pure type definition in Std_Types.h, the type itself is not subject to runtime restrictions; these arise exclusively from the respective context of the using modules.

This text was generated by an AI based on the AUTOSAR specification R20-11.

type Std_MessageType [SWS_Std_91001] 📄 PDF

This type is used to encode the different type of messages. - Currently this encoding is limited to the distinction between requests and responses in C/ S c ommunication.

AI-GENERATED unreviewed Model: gemini-3.8-flash-medium · Effort: medium · Temperature: not controllable · Prompt: 3a61d74dd0cf Provenance
translated from the German guidegemini-3.8-flash-low · 2026-10-13 · German original

According to [SWS_Std_91001], the standard type Std_MessageType is used to encode various message types. In the present specification, this encoding is limited to distinguishing between requests and responses within the scope of client/server communication ([SWS_Std_91001]).

The data type is derived from the base type uint8 and is provided to software components and basic software modules via the header file Std_Types.h ([SWS_Std_91001]). The following values and constants are specified for assignment and evaluation:

  • STD_MESSAGETYPE_REQUEST (value 0x00): Designates a request message ([SWS_Std_91001]).
  • STD_MESSAGETYPE_RESPONSE (value 0x01): Designates a response message ([SWS_Std_91001]).
  • Value range 0x02 to 0x3F: This range is reserved for future message types ([SWS_Std_91001]).

Regarding application and boundary conditions, implementing modules should exclusively use the defined identifiers. Since the values from 0x02 to 0x3F are reserved for future AUTOSAR extensions, they must not be arbitrarily assigned for other purposes ([SWS_Std_91001]). Specific error codes, return values, asynchronous sequences, or notifications to DET or DEM are not defined for this data type in the specification ([SWS_Std_91001]).

This text was generated by an AI curation assistant and is based on the specification of AUTOSAR R20-11.

type Std_MessageResultType [SWS_Std_91002] 📄 PDF

typedef uint8 Std_MessageResultType;

This type is used to encode different types of results for response messages. - Currently this encoding is limited to the distinction between OK and ERROR responses.

AI-GENERATED unreviewed Model: gemini-3.8-flash-medium · Effort: medium · Temperature: not controllable · Prompt: 48b18d78d865 Provenance Open questions (1)
translated from the German guidegemini-3.8-flash-low · 2026-10-13 · German original

The fundamental data type Std_MessageResultType serves in the AUTOSAR Classic Platform to encode various result types for response messages [SWS_Std_00019]. The type is provided via the standard header file Std_Types.h and is defined as a scalar type based on uint8 [SWS_Std_91002].

Usage and Value Range

The specification requires the use of Std_MessageResultType for standardized identification of response messages [SWS_Std_00019]. Currently, the intended scope of functionality of this encoding is restricted to the basic distinction between successful and erroneous responses [SWS_Std_91002]. For this purpose, the following fixed result values are defined:

  • STD_MESSAGERESULT_OK (value 0x00): Identifies the regular, error-free result of a response message [SWS_Std_91002].
  • STD_MESSAGERESULT_ERROR (value 0x01): Signals the result of an erroneous response message (error response) [SWS_Std_91002].

Limitations and Future Extensions

The value range from 0x02 to 0x3F is explicitly reserved for future message results [SWS_Std_91002]. Interpretation: Since the specification currently does not foresee any other valid return values, evaluating modules will likely need to be programmed defensively to safely intercept unexpected or not yet assigned values in this range [SWS_Std_00019]. Question Q-5f652f73800b7d94 (open)

This text was created by an AI and summarizes the requirements of the AUTOSAR specification for developers.

type Std_ExtractProtocolHeaderFieldsType [SWS_Std_91003] 📄 PDF

typedef Std_ReturnType (* Std_ExtractProtocolHeaderFieldsType)(const uint8* buffer, uint32 bufferLength, Std_MessageTypeType* messageType, Std_MessageResultType* messageResult);

Type for the function pointer to extract the relevant protocol header fields of the message and the type of the message result of a transformer. - At the time being, this is limited to the types used for C/ S communication (i.e., REQUE ST and RESPONSE and OK and ERROR).

type E_OK / E_NOT_OK [SWS_Std_00006] 📄 PDF

#define E_OK 0x00u #define E_NOT_OK 0x01u

Because E_ OK is already defined within OSEK, the symbol E_ OK has to be shared. To avoid name clashes and redefinition problems, the symbols have to be defined in the following way (approved within implementation): #ifndef STATUSTYPEDEFINED #define STATUSTYPEDEFINED #define E_ OK 0x00u typedef unsigned char Status Type; /* OSEK compliance */ #endif #define E_ NOT_ OK 0x01u

type STD_HIGH / STD_LOW [SWS_Std_00007] 📄 PDF

#define STD_HIGH 0x01u #define STD_LOW 0x00u

The symbols STD_ HIGH and STD_ LOW shall be defined as follows: #define STD_ HIGH 0x01u /* Physical state 5V or 3.3V */ #define STD_ LOW 0x00u /* Physical state 0V */

type STD_ACTIVE / STD_IDLE [SWS_Std_00013] 📄 PDF

#define STD_ACTIVE 0x01u #define STD_IDLE 0x00u

The symbols STD_ ACTIVE and STD_ IDLE shall be defined as follows: #define STD_ ACTIVE 0x01u /* Logical state active */ #define STD_ IDLE 0x00u /* Logical state idle */

type STD_ON / STD_OFF [SWS_Std_00010] 📄 PDF

#define STD_ON 0x01u #define STD_OFF 0x00u

The symbols STD_ ON and STD_ OFF shall be defined as follows: #define STD_ ON 0x01u #define STD_ OFF 0x00u

Request a governed re-review of this record. The record is not changed immediately.

Record
AUTOSAR/AP/record/CP_MOD_Std
Status
unspecified
Version
AUTOSAR/AP/record/CP_MOD_Std@rel:R20-11#4f00bf09
Content hash
4f00bf09
Source
https://www.autosar.org/fileadmin/standards/R20-11/CP/AUTOSAR_SWS_StandardTypes.pdf#nameddest=SWS_Std_00005

Types

Because E_ OK is already defined within OSEK, the symbol E_ OK has to be shared. To avoid name clashes and redefinition problems, the symbols have to be defined in the following way (approved within implementation): #ifndef STATUSTYPEDEFINED #define STATUSTYPEDEFINED #define E_ OK 0x00u typedef unsigned char Status Type; /* OSEK compliance */ #endif #define E_ NOT_ OK 0x01u

#define E_OK 0x00u #define E_NOT_OK 0x01u

The symbols STD_ ACTIVE and STD_ IDLE shall be defined as follows: #define STD_ ACTIVE 0x01u /* Logical state active */ #define STD_ IDLE 0x00u /* Logical state idle */

#define STD_ACTIVE 0x01u #define STD_IDLE 0x00u

Type for the function pointer to extract the relevant protocol header fields of the message and the type of the message result of a transformer. - At the time being, this is limited to the types used for C/ S communication (i.e., REQUE ST and RESPONSE and OK and ERROR).

typedef Std_ReturnType (* Std_ExtractProtocolHeaderFieldsType)(const uint8* buffer, uint32 bufferLength, Std_MessageTypeType* messageType, Std_MessageResultType* messageResult);

The symbols STD_ HIGH and STD_ LOW shall be defined as follows: #define STD_ HIGH 0x01u /* Physical state 5V or 3.3V */ #define STD_ LOW 0x00u /* Physical state 0V */

#define STD_HIGH 0x01u #define STD_LOW 0x00u

This type is used to encode different types of results for response messages. - Currently this encoding is limited to the distinction between OK and ERROR responses.

This type is used to encode the different type of messages. - Currently this encoding is limited to the distinction between requests and responses in C/ S c ommunication.

The symbols STD_ ON and STD_ OFF shall be defined as follows: #define STD_ ON 0x01u #define STD_ OFF 0x00u

#define STD_ON 0x01u #define STD_OFF 0x00u

This type can be used as standard API return type which is shared between the RTE and the BSW modules. It shall be defined as follows: typedef uint8 Std_ Return Type;

- Tags: atp.Status=draft

- Tags: atp.Status=draft

This type shall be used to request the version of a BSW module using the _ Get Version Info() function.

typedef struct { uint16 vendorID; uint16 moduleID; uint8 sw_major_version; uint8 sw_minor_version; uint8 sw_patch_version; } Std_VersionInfoType;