平台类型规范(Specification of Platform Types)

📄 文档 ID:048 🏷 类型:SWS(软件规范) 📅 版本:AUTOSAR CP 4.4.0 📑 页数:36 📌 状态:Final 🔗 原 PDF:AUTOSAR_SWS_PlatformTypes.pdf

目录

1 介绍与功能概述(Introduction and functional overview)

本规范定义了 AUTOSAR 平台类型头文件。它包含所有平台相关的类型和符号。这些类型必须被抽象,以实现平台和编译器的无关性。

要求所有平台类型文件在 AUTOSAR 社区内保持唯一,以保证每个平台的类型唯一性,并避免将软件模块从平台 A 迁移到平台 B 时类型发生变化。

2 缩略语与术语(Acronyms and abbreviations)

仅在本文件局部使用、因而未收录到 AUTOSAR 术语表中的缩略语与术语,必须在本节"局部术语表"中列出。

缩略语说明
Rollover mechanism(回绕机制)以下示例序列称为"回绕":
· 一个无符号字符的值为 255;
· 加 1;
· 结果为 0。
SDUService Data Unit(服务数据单元,即有效载荷)
缩写说明
intInteger(整数)

3 相关文档(Related documentation)

3.1 输入文档

编号文档名原 PDF
[1]General Requirements on Basic Software ModulesAUTOSAR_SRS_BSWGeneral.pdf
[2]Basic Software Module Description TemplateAUTOSAR_TPS_BSWModuleDescriptionTemplate.pdf
[3]List of Basic Software ModulesAUTOSAR_TR_BSWModuleList.pdf
[4]Cosmic C Cross Compiler User's Guide for Motorola MC68HC12, V4.5
[5]ARM ADS compiler manual
[6]Greenhills MULTI for V850 V4.0.5
[7]TASKING for ST10 V8.5
[8]Wind River (Diab Data) for PowerPC Version 5.2.1
[9]TASKING for TriCore TC1796 V2.1R1
[10]Metrowerks CodeWarrior 4.0 for Freescale HC9S12X/XGATE (V5.0.25)
[11]General Specification of Basic Software ModulesAUTOSAR_SWS_BSWGeneral.pdf

3.2 相关标准与规范

3.3 相关规范

AUTOSAR 提供了通用基础软件模块规范 [11](SWS BSW General),该规范对平台类型同样适用。

因此,SWS BSW General 应被视为平台类型的附加且必需的规范

4 约束与假设(Constraints and assumptions)

4.1 限制(Limitations)

无限制。

4.2 对汽车领域的适用性(Applicability to car domains)

无限制。

4.3 对功能安全相关环境的适用性(Applicability to safety related environments)

若 AUTOSAR boolean 类型的正确使用(见 SWS_Platform_00027)已通过正式代码审查或经过验证的静态分析工具的检查,则可使用。

若优化的 AUTOSAR 整数数据类型(*_least)的正确使用(见 7.4 节)已通过正式代码审查或经过验证的静态分析工具的检查,则可使用。

5 对其他模块的依赖(Dependencies to other modules)

无。

5.1 文件结构(File structure)

5.1.1 源文件结构(Code file structure)

无。

5.1.2 头文件结构(Header file structure)

有两种适用的头文件结构。一种与"通信相关"的基础软件模块相关,另一种与"非通信相关"的基础软件模块相关。

6 需求追溯(Requirements traceability)

SRS 需求描述由以下满足
SRS_BSW_00304 所有 AUTOSAR 基础软件模块应当使用以下数据类型,而非原生 C 数据类型 SWS_Platform_00013SWS_Platform_00014SWS_Platform_00015SWS_Platform_00016SWS_Platform_00017SWS_Platform_00018SWS_Platform_00020SWS_Platform_00021SWS_Platform_00022SWS_Platform_00023SWS_Platform_00024SWS_Platform_00025
SRS_BSW_00378 AUTOSAR 应当提供一个 boolean 类型 SWS_Platform_00026SWS_Platform_00027SWS_Platform_00034
其余 ~110+ SRS 需求 SWS_Platform_00063 声明"不适用"(见 第 12 节 SWS_Platform_00063

7 功能规范(Functional specification)

7.1 通用问题(General issues)

[SWS_Platform_00002]

本文件不得添加任何扩展。任何扩展都将使 AUTOSAR 一致性失效。

7.2 CPU 类型(CPU Type)

[SWS_Platform_00044]

对于每个平台,应当通过定义 CPU_TYPE 来指示所用 CPU 的寄存器宽度。

[SWS_Platform_00045]

根据所用 CPU 的寄存器宽度,CPU_TYPE 应当被赋值为 CPU_TYPE_8CPU_TYPE_16CPU_TYPE_32CPU_TYPE_64 之一。

7.3 字节序(Endianess)

本机类型(如整数)中位、字节和字的排列模式称为字节序(endianess)。

[SWS_Platform_00043]

对于每个平台,寄存器级别的位序应当使用符号 CPU_BIT_ORDER 在平台类型头文件中指示。

[SWS_Platform_00046]

对于每个平台,内存级别的字节序应当使用符号 CPU_BYTE_ORDER 在平台类型头文件中指示。

7.3.1 位序(寄存器)(Bit Ordering (Register))

[SWS_Platform_00048]

对于大端位序,CPU_BIT_ORDER 应当在平台类型头文件中被赋值为 MSB_FIRST

[SWS_Platform_00049]

对于小端位序,CPU_BIT_ORDER 应当在平台类型头文件中被赋值为 LSB_FIRST

重要说明:位命名约定(Bit0、Bit1 等)与位在字节、字中的意义是不同的概念,不应混淆。 在 Motorola µC 架构(大端位序)中,Bit0 表示最高有效位;而所有其他使用小端位序的 µC 中,Bit0 表示最低有效位! 累加器中的 MSB 始终作为最左边的位存储,与 CPU 类型无关。因此,大端和小端的位序意味着不同的位命名约定。

7.3.2 字节序(内存)(Byte Ordering (Memory))

[SWS_Platform_00050]

对于大端字节序,CPU_BYTE_ORDER 应当被赋值为 HIGH_BYTE_FIRST

[SWS_Platform_00051]

对于小端字节序,CPU_BYTE_ORDER 应当被赋值为 LOW_BYTE_FIRST

说明图示命名约定
· 16 位宽数据中的最高有效字节命名为 Byte1
· 16 位宽数据中的最低有效字节命名为 Byte0
大端(HIGH_BYTE_FIRST)
地址数据顺序
nByte1最高有效字节(HIGH_BYTE_FIRST)
n+1Byte0最低有效字节
小端(LOW_BYTE_FIRST)
地址数据顺序
nByte0最低有效字节(LOW_BYTE_FIRST)
n+1Byte1最高有效字节
重要说明Byte0Byte1 的命名约定不唯一,在特定 µC 的厂商参考文档中可能不同。

7.4 优化整数数据类型(Optimized integer data types)

详情参见 SWS_BSWGeneral 中第 7.1.19.2.1 节"AUTOSAR 整数数据类型"。

使用示例

7.5 布尔数据类型(Boolean data type)

[SWS_Platform_00027]

标准 AUTOSR 类型 boolean 应当实现为一个无符号整数,其位长度是平台原生支持的最短位数(通常为 8 位)。

参考:SRS_BSW_00378

[SWS_Platform_00034]

标准 AUTOSAR 类型 boolean 只能与标准符号 TRUEFALSE 一起使用。对 boolean 类型变量的赋值不得使用算术或逻辑运算符(+++---*/%<<>>~&)。只允许的赋值形式是:

boolean var = TRUE;
…
var = TRUE;
var = FALSE;
var = (a < b)   /* same for ">", "<=", ">=" */
var = (c && d) /* same for "!", "||" */
var = (e != f) /* same for "==" */

只允许的比较形式是:

boolean var = FALSE;
…
if (var == TRUE) …
if (var == FALSE) …
if (var != TRUE) …
if (var != FALSE) …
if (var) …
if (!var) …

参考:SRS_BSW_00378

8 API 规范(API specification)

8.1 导入类型(Imported types)

不适用。

8.2 类型定义(Type definitions)

[SWS_Platform_00061]

对于有符号整数类型,AUTOSAR 在编译器和目标实现中只支持二进制补码算术。这直接影响这些类型的取值范围。

8.2.1 boolean

[SWS_Platform_00026]

名称(Name)boolean
种类(Kind)Type
派生自(Derived from)uint
说明(Description)该标准 AUTOSAR 类型只能TRUEFALSE 定义一起使用。
取值(Range)FALSE     0     —
TRUE     1     —
变化(Variation)
可获取于(Available via)PlatformTypes.h

参考:SRS_BSW_00378

实现与使用见 SWS_Platform_00027

[SWS_Platform_00060]

boolean 类型应当始终映射到一个可应用指针的特定平台类型,以便通过 API 传递参数。

某些硬件平台有特定的高效 BIT 类型,但不能应用指针。

8.2.2 uint8

[SWS_Platform_00013]

名称(Name)uint8
种类(Kind)Type
派生自(Derived from)uint
说明(Description)该标准 AUTOSAR 类型应当为 8 位无符号。
取值(Range)0..255     0x00..0xFF
变化(Variation)
可获取于(Available via)PlatformTypes.h

参考:SRS_BSW_00304

8.2.3 uint16

[SWS_Platform_00014]

名称(Name)uint16
种类(Kind)Type
派生自(Derived from)uint
说明(Description)该标准 AUTOSAR 类型应当为 16 位无符号。
取值(Range)0..65535     0x0000..0xFFFF
变化(Variation)
可获取于(Available via)PlatformTypes.h

参考:SRS_BSW_00304

8.2.4 uint32

[SWS_Platform_00015]

名称(Name)uint32
种类(Kind)Type
派生自(Derived from)uint
说明(Description)该标准 AUTOSAR 类型应当为 32 位无符号。
取值(Range)0..4294967295     0x00000000..0xFFFFFFFF
变化(Variation)
可获取于(Available via)PlatformTypes.h

参考:SRS_BSW_00304

8.2.5 uint64

[SWS_Platform_00066]

名称(Name)uint64
种类(Kind)Type
派生自(Derived from)uint
说明(Description)该标准 AUTOSAR 类型应当为 64 位无符号。
取值(Range)0..18446744073709551615     0x0000000000000000..0xFFFFFFFFFFFFFFFF
变化(Variation)
可获取于(Available via)PlatformTypes.h

8.2.6 sint8

[SWS_Platform_00016]

名称(Name)sint8
种类(Kind)Type
派生自(Derived from)sint
说明(Description)该标准 AUTOSAR 类型应当为 8 位有符号。
取值(Range)-128..+127     0x80..0x7F
变化(Variation)
可获取于(Available via)PlatformTypes.h

参考:SRS_BSW_00304

8.2.7 sint16

[SWS_Platform_00017]

名称(Name)sint16
种类(Kind)Type
派生自(Derived from)sint
说明(Description)该标准 AUTOSAR 类型应当为 16 位有符号。
取值(Range)-32768..+32767     0x8000..0x7FFF
变化(Variation)
可获取于(Available via)PlatformTypes.h

参考:SRS_BSW_00304

8.2.8 sint32

[SWS_Platform_00018]

名称(Name)sint32
种类(Kind)Type
派生自(Derived from)sint
说明(Description)该标准 AUTOSAR 类型应当为 32 位有符号。
取值(Range)-2147483648..+2147483647     0x80000000..0x7FFFFFFF
变化(Variation)
可获取于(Available via)PlatformTypes.h

参考:SRS_BSW_00304

8.2.9 sint64

[SWS_Platform_00067]

名称(Name)sint64
类型(Type)sint
取值(Range)-9223372036854775808..9223372036854775807     0x8000000000000000..0x7FFFFFFFFFFFFFFF
说明(Description)该标准 AUTOSAR 类型应当为 64 位有符号。
可获取于(Available via)PlatformTypes.h

8.2.10 uint8_least

[SWS_Platform_00020]

名称(Name)uint8_least
类型(Type)uint
取值(Range)至少 0..255     0x00..0xFF
说明(Description)该优化的 AUTOSAR 类型应当为至少 8 位无符号。
可获取于(Available via)PlatformTypes.h

参考:SRS_BSW_00304

实现与使用见 7.4 节。

8.2.11 uint16_least

[SWS_Platform_00021]

名称(Name)uint16_least
类型(Type)uint
取值(Range)至少 0..65535     0x0000..0xFFFF
说明(Description)该优化的 AUTOSAR 类型应当为至少 16 位无符号。
可获取于(Available via)PlatformTypes.h

参考:SRS_BSW_00304

8.2.12 uint32_least

[SWS_Platform_00022]

名称(Name)uint32_least
类型(Type)uint
取值(Range)至少 0..4294967295     0x00000000..0xFFFFFFFF
说明(Description)该优化的 AUTOSAR 类型应当为至少 32 位无符号。
可获取于(Available via)PlatformTypes.h

参考:SRS_BSW_00304

8.2.13 sint8_least

[SWS_Platform_00023]

名称(Name)sint8_least
类型(Type)sint
取值(Range)至少 -128..+127     0x80..0x7F
说明(Description)该优化的 AUTOSAR 类型应当为至少 8 位有符号。
可获取于(Available via)PlatformTypes.h

参考:SRS_BSW_00304

8.2.14 sint16_least

[SWS_Platform_00024]

名称(Name)sint16_least
类型(Type)sint
取值(Range)至少 -32768..+32767     0x8000..0x7FFF
说明(Description)该优化的 AUTOSAR 类型应当为至少 16 位有符号。
可获取于(Available via)PlatformTypes.h

参考:SRS_BSW_00304

8.2.15 sint32_least

[SWS_Platform_00025]

名称(Name)sint32_least
类型(Type)sint
取值(Range)至少 -2147483648..+2147483647     0x80000000..0x7FFFFFFF
说明(Description)该优化的 AUTOSAR 类型应当为至少 32 位有符号。
可获取于(Available via)PlatformTypes.h

参考:SRS_BSW_00304

8.2.16 float32

[SWS_Platform_00041]

名称(Name)float32
种类(Kind)Type
派生自(Derived from)float
说明(Description)该标准 AUTOSAR 类型应当遵循 IEEE 754-2008 中 3.6 节表 3.5 "binary32" 列指定的 32 位二进制交换格式。
取值(Range)-3.4028235e+38..+3.4028235e+38
变化(Variation)
可获取于(Available via)PlatformTypes.h

8.2.17 float64

[SWS_Platform_00042]

名称(Name)float64
类型(Type)double
取值(Range)-1.7976931348623157e+308..+1.7976931348623157e+308
说明(Description)该标准 AUTOSAR 类型应当遵循 IEEE 754-2008 中 3.6 节表 3.5 "binary64" 列指定的 64 位二进制交换格式。
可获取于(Available via)PlatformTypes.h

8.3 符号定义(Symbol definitions)

8.3.1 CPU_TYPE

[SWS_Platform_00064]

名称(Name)CPU_TYPE
类型(Type)Enumeration
取值(Range)CPU_TYPE_8     —     表示 8 位处理器
CPU_TYPE_16     —     表示 16 位处理器
CPU_TYPE_32     —     表示 32 位处理器
CPU_TYPE_64     —     表示 64 位处理器
说明(Description)该符号应当被定义为 #define,并根据平台取 CPU_TYPE_8CPU_TYPE_16CPU_TYPE_32CPU_TYPE_64 之一。
可获取于(Available via)PlatformTypes.h

8.3.2 CPU_BIT_ORDER

[SWS_Platform_00038]

名称(Name)CPU_BIT_ORDER
类型(Type)Enumeration
取值(Range)MSB_FIRST     —     最高有效位是位序列的第一位。
LSB_FIRST     —     最低有效位是位序列的第一位。
说明(Description)该符号应当被定义为 #define,并根据平台取 MSB_FIRSTLSB_FIRST 之一。
可获取于(Available via)PlatformTypes.h

8.3.3 CPU_BYTE_ORDER

[SWS_Platform_00039]

名称(Name)CPU_BYTE_ORDER
类型(Type)Enumeration
取值(Range)HIGH_BYTE_FIRST     —     在 uint16 中,高字节位于低字节之前。
LOW_BYTE_FIRST     —     在 uint16 中,低字节位于高字节之前。
说明(Description)该符号应当被定义为 #define,并根据平台取 HIGH_BYTE_FIRSTLOW_BYTE_FIRST 之一。
可获取于(Available via)PlatformTypes.h

8.3.4 TRUEFALSE

[SWS_Platform_00056]

名称(Name)TRUE_FALSE
类型(Type)Enumeration
取值(Range)FALSE     0x00     —
TRUE     0x01     —
说明(Description)符号 TRUEFALSE 应当按下述方式定义:
#ifndef TRUE
#define TRUE 1
#endif

#ifndef FALSE
#define FALSE 0
#endif
可获取于(Available via)PlatformTypes.h

[SWS_Platform_00054]

若编译器已内建支持这些符号,则应当使用条件检查以避免重复定义。

[SWS_Platform_00055]

这些符号只能Platform_Types.h 中定义的 boolean 类型一起使用。

8.4 函数定义(Function definitions)

不适用。

8.5 回调通知(Call-back notifications)

不适用。

8.6 调度函数(Scheduled functions)

不适用。

8.7 期望接口(Expected Interfaces)

不适用。

9 时序图(Sequence diagrams)

不适用。

10 配置规范(Configuration specification)

10.1 发布参数(Published parameters)

详情参见 SWS_BSWGeneral 中的 10.3 节"发布信息"。

11 附录(Annex)

11.1 类型定义 – 通用

所有平台的平台类型文件可包含以下符号:

#define CPU_TYPE_8                  8
#define CPU_TYPE_16                 16
#define CPU_TYPE_32                 32
#define CPU_TYPE_64                 64

#define MSB_FIRST                   0
#define LSB_FIRST                   1

#define HIGH_BYTE_FIRST             0
#define LOW_BYTE_FIRST              1

11.2 类型定义 – S12X(Freescale)

Freescale S12X 的平台类型可按如下方式映射到 ANSI C 类型:

/* 符号 */
#define CPU_TYPE                        CPU_TYPE_16
#define CPU_BIT_ORDER                   LSB_FIRST
#define CPU_BYTE_ORDER                  HIGH_BYTE_FIRST

/* 类型 */
typedef unsigned char                   boolean;

typedef signed char                     sint8;
typedef unsigned char                   uint8;
typedef signed short                    sint16;
typedef unsigned short                  uint16;
typedef signed long                     sint32;
typedef signed long long                sint64;
typedef unsigned long                   uint32;
typedef unsigned long long              uint64;

typedef signed char                     sint8_least;
typedef unsigned char                   uint8_least;
typedef signed short                    sint16_least;
typedef unsigned short                  uint16_least;
typedef signed long                     sint32_least;
typedef unsigned long                   uint32_least;

typedef float                           float32;
typedef double                          float64;

11.3 类型定义 – ST10(STMicroelectronics)

/* 符号 */
#define CPU_TYPE                     CPU_TYPE_16
#define CPU_BIT_ORDER                LSB_FIRST
#define CPU_BYTE_ORDER               LOW_BYTE_FIRST

/* 类型 */
typedef unsigned char                boolean;

typedef signed char                  sint8;
typedef unsigned char                uint8;
typedef signed short                 sint16;
typedef unsigned short               uint16;
typedef signed long                  sint32;
typedef signed long long             sint64;
typedef unsigned long                uint32;
typedef unsigned long long           uint64;

typedef unsigned short               uint8_least;
typedef unsigned short               uint16_least;
typedef unsigned long                uint32_least;
typedef signed short                 sint8_least;
typedef signed short                 sint16_least;
typedef signed long                  sint32_least;

typedef float                        float32;
typedef double                       float64;

11.4 类型定义 – ST30(STMicroelectronics)

/* 符号 */
#define CPU_TYPE                     CPU_TYPE_32
#define CPU_BIT_ORDER                LSB_FIRST
#define CPU_BYTE_ORDER               LOW_BYTE_FIRST

/* 类型 */
typedef unsigned char                boolean;

typedef signed char                  sint8;
typedef unsigned char                uint8;
typedef signed short                 sint16;
typedef unsigned short               uint16;
typedef signed long                  sint32;
typedef signed long long             sint64;
typedef unsigned long                uint32;
typedef unsigned long long           uint64;

typedef unsigned long                uint8_least;
typedef unsigned long                uint16_least;
typedef unsigned long                uint32_least;
typedef signed long                  sint8_least;
typedef signed long                  sint16_least;
typedef signed long                  sint32_least;

typedef float                        float32;
typedef double                       float64;

11.5 类型定义 – V850(NEC)

/* 符号 */
#define CPU_TYPE                    CPU_TYPE_32
#define CPU_BIT_ORDER               LSB_FIRST
#define CPU_BYTE_ORDER              LOW_BYTE_FIRST

/* 类型 */
typedef unsigned char               boolean;

typedef signed char                 sint8;
typedef unsigned char               uint8;
typedef signed short                sint16;
typedef unsigned short              uint16;
typedef signed long                 sint32;
typedef signed long long            sint64;
typedef unsigned long               uint32;
typedef unsigned long long          uint64;

typedef unsigned long               uint8_least;
typedef unsigned long               uint16_least;
typedef unsigned long               uint32_least;
typedef signed long                 sint8_least;
typedef signed long                 sint16_least;
typedef signed long                 sint32_least;

typedef float                       float32;
typedef double                      float64;

11.6 类型定义 – MPC5554(Freescale)

/* 符号 */
#define CPU_TYPE                    CPU_TYPE_32
#define CPU_BIT_ORDER               MSB_FIRST
#define CPU_BYTE_ORDER              HIGH_BYTE_FIRST

/* 类型 */
typedef unsigned char               boolean;

typedef signed char                 sint8;
typedef unsigned char               uint8;
typedef signed short                sint16;
typedef unsigned short              uint16;
typedef signed long                 sint32;
typedef signed long long            sint64;
typedef unsigned long               uint32;
typedef unsigned long long          uint64;

typedef unsigned long               uint8_least;
typedef unsigned long               uint16_least;
typedef unsigned long               uint32_least;
typedef signed long                 sint8_least;
typedef signed long                 sint16_least;
typedef signed long                 sint32_least;

typedef float                       float32;
typedef double                      float64;

11.7 类型定义 – TC1796/TC1766(Infineon)

/* 符号 */
#define CPU_TYPE                    CPU_TYPE_32
#define CPU_BIT_ORDER               LSB_FIRST
#define CPU_BYTE_ORDER              LOW_BYTE_FIRST

/* 类型 */
typedef unsigned char               boolean;

typedef signed char                 sint8;
typedef unsigned char               uint8;
typedef signed short                sint16;
typedef unsigned short              uint16;
typedef signed long                 sint32;
typedef signed long long            sint64;
typedef unsigned long               uint32;
typedef unsigned long long          uint64;

typedef unsigned long               uint8_least;
typedef unsigned long               uint16_least;
typedef unsigned long               uint32_least;
typedef signed long                 sint8_least;
typedef signed long                 sint16_least;
typedef signed long                 sint32_least;

typedef float                       float32;
typedef double                      float64;

11.8 类型定义 – MB91F(Fujitsu)

/* 符号 */
#define CPU_TYPE                     CPU_TYPE_32
#define CPU_BIT_ORDER                LSB_FIRST
#define CPU_BYTE_ORDER               HIGH_BYTE_FIRST

/* 类型 */
typedef unsigned char                boolean;

typedef signed char                  sint8;
typedef unsigned char                uint8;
typedef signed short                 sint16;
typedef unsigned short               uint16;
typedef signed long                  sint32;
typedef signed long long             sint64;
typedef unsigned long                uint32;
typedef unsigned long long           uint64;

typedef unsigned long                uint8_least;
typedef unsigned long                uint16_least;
typedef unsigned long                uint32_least;
typedef signed long                  sint8_least;
typedef signed long                  sint16_least;
typedef signed long                  sint32_least;

typedef float                        float32;
typedef double                       float64;

11.9 类型定义 – M16C/M32C(Renesas)

/* 符号 */
#define CPU_TYPE                    CPU_TYPE_16
#define CPU_BIT_ORDER               LSB_FIRST
#define CPU_BYTE_ORDER              LOW_BYTE_FIRST

/* 类型 */
typedef unsigned char               boolean;

typedef signed char                 sint8;
typedef unsigned char               uint8;
typedef signed short                sint16;
typedef unsigned short              uint16;
typedef signed long                 sint32;
typedef signed long long            sint64;
typedef unsigned long               uint32;
typedef unsigned long long          uint64;

typedef unsigned short              uint8_least;
typedef unsigned short              uint16_least;
typedef unsigned long               uint32_least;
typedef signed short                sint8_least;
typedef signed short                sint16_least;
typedef signed long                 sint32_least;

typedef float                       float32;
typedef double                      float64;

11.10 类型定义 – SHx(Renesas)

/* 符号 */
#define CPU_TYPE                    CPU_TYPE_32
#define CPU_BIT_ORDER               LSB_FIRST
#define CPU_BYTE_ORDER               HIGH_BYTE_FIRST

/* 类型 */
typedef unsigned char               boolean;

typedef signed char                 sint8;
typedef unsigned char               uint8;
typedef signed short                sint16;
typedef unsigned short              uint16;
typedef signed int                  sint32;
typedef signed long long            sint64;
typedef unsigned int                uint32;
typedef unsigned long long          uint64;

typedef unsigned long               uint8_least;
typedef unsigned long               uint16_least;
typedef unsigned long               uint32_least;
typedef signed long                 sint8_least;
typedef signed long                 sint16_least;
typedef signed long                 sint32_least;

typedef float                       float32;
typedef double                      float64;

11.11 类型定义 – ARM Cortex A53(小端)

/* 符号 */
#define CPU_TYPE                     CPU_TYPE_64
#define CPU_BIT_ORDER                LSB_FIRST
#define CPU_BYTE_ORDER               LOW_BYTE_FIRST

/* 类型 */
typedef unsigned char                boolean;

typedef unsigned char                uint8;
typedef unsigned short               uint16;
typedef unsigned int                 uint32;
typedef unsigned long long           uint64;

typedef signed char                  sint8;
typedef signed short                 sint16;
typedef signed int                   sint32;
typedef signed long long             sint64;

typedef unsigned int                 uint8_least;
typedef unsigned int                 uint16_least;
typedef unsigned int                 uint32_least;
typedef signed int                   sint8_least;
typedef signed int                   sint16_least;
typedef signed int                   sint32_least;

typedef float                        float32;
typedef double                       float64;

12 不适用的需求(Not applicable requirements)

[SWS_Platform_00063]

以下需求对本规范不适用

SRS_BSW_00344SRS_BSW_00404SRS_BSW_00405SRS_BSW_00345SRS_BSW_00159SRS_BSW_00167SRS_BSW_00171SRS_BSW_00170SRS_BSW_00419SRS_BSW_00381SRS_BSW_00412SRS_BSW_00383SRS_BSW_00384SRS_BSW_00387SRS_BSW_00388SRS_BSW_00389SRS_BSW_00390SRS_BSW_00391SRS_BSW_00392SRS_BSW_00393SRS_BSW_00394SRS_BSW_00395SRS_BSW_00396SRS_BSW_00397SRS_BSW_00398SRS_BSW_00399SRS_BSW_00400SRS_BSW_00375SRS_BSW_00101SRS_BSW_00416SRS_BSW_00406SRS_BSW_00168SRS_BSW_00407SRS_BSW_00423SRS_BSW_00429SRS_BSW_00432SRS_BSW_00336SRS_BSW_00337SRS_BSW_00338SRS_BSW_00369SRS_BSW_00339SRS_BSW_00422SRS_BSW_00420SRS_BSW_00417SRS_BSW_00323SRS_BSW_00409SRS_BSW_00385SRS_BSW_00386SRS_BSW_00161SRS_BSW_00162SRS_BSW_00005SRS_BSW_00415SRS_BSW_00164SRS_BSW_00325SRS_BSW_00326SRS_BSW_00342SRS_BSW_00343SRS_BSW_00160SRS_BSW_00007SRS_BSW_00300SRS_BSW_00413SRS_BSW_00347SRS_BSW_00305SRS_BSW_00307SRS_BSW_00310SRS_BSW_00373SRS_BSW_00327SRS_BSW_00335SRS_BSW_00350SRS_BSW_00408SRS_BSW_00410SRS_BSW_00411SRS_BSW_00346SRS_BSW_00158SRS_BSW_00314SRS_BSW_00370SRS_BSW_00348SRS_BSW_00361SRS_BSW_00301SRS_BSW_00302SRS_BSW_00328SRS_BSW_00312SRS_BSW_00357SRS_BSW_00377SRS_BSW_00355SRS_BSW_00306SRS_BSW_00308SRS_BSW_00309SRS_BSW_00371SRS_BSW_00358SRS_BSW_00414SRS_BSW_00376SRS_BSW_00359SRS_BSW_00360SRS_BSW_00329SRS_BSW_00330SRS_BSW_00331SRS_BSW_00009SRS_BSW_00401SRS_BSW_00172SRS_BSW_00010SRS_BSW_00333SRS_BSW_00374SRS_BSW_00379SRS_BSW_00321SRS_BSW_00341SRS_BSW_00334

📋 校对记录

校对轮次:L1 自动校对(2026-06-13)