Files
autosar_standard_spec_v4.4/translation_zh-CN/Safety/AUTOSAR_EXP_FunctionalSafetyMeasures.html
opencode-translator 29e5c70917 feat: 完成 P2 Communication 全部 71 篇 + ReleaseDocumentation + Safety 收尾 - 项目 100% 完成(216/216)
- P2 Communication: 17 SRS + 1 ASWS + 53 SWS = 71 篇(11 大子系统:CAN/FlexRay/LIN/Ethernet/J1939/TTCAN/SPI/COM/通用/安全/诊断/XCP/NM/V2X/无线)
- ReleaseDocumentation: AUTOSAR_TR_ClassicPlatformReleaseOverview
- Safety: AUTOSAR_EXP_FunctionalSafetyMeasures(含 Core Test / RAM Test 硬件诊断)

总进度 216/216 = 100%,R4.4 关键增强全部覆盖:CAN XL / LIN Slave / TLS 草案 / SecOC 增强 / SOME/IP TLV / 无线 Ethernet / V2X C-Roads / MCAL Multicore / E2E Profile 7/11/22。
2026-06-14 00:06:28 +08:00

196 lines
8.8 KiB
HTML
Raw Permalink Blame History

This file contains invisible Unicode characters
This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<!DOCTYPE html>
<html lang="zh-CN">
<head>
<meta charset="UTF-8">
<title>AUTOSAR EXP FunctionalSafetyMeasures 中文翻译</title>
<link rel="stylesheet" href="../assets/style.css">
</head>
<body>
<h1>AUTOSAR_EXP_FunctionalSafetyMeasures 中文翻译</h1>
<p class="meta">文档编号:664 | 状态:Final | 发布于:AUTOSAR CP Release 4.4.0<br>
所属标准:AUTOSAR Classic Platform | 文档责任方:AUTOSAR</p>
<p class="meta-2">本翻译覆盖原文档 1-96 页正文。原文为 EXP(说明性文档),介绍 AUTOSAR 中功能安全(Functional Safety)相关机制。涵盖 Safety 机制、Memory Partitioning / Program Flow Monitoring / Core Test / RAM Test / Watchdog / E2E / SafeBsw 等。R4.2.2 新增"硬件诊断"章节(Core Test / RAM Test)。</p>
<nav><h2>目录</h2>
<ol>
<li>引言与范围</li>
<li>缩略语</li>
<li>相关文档</li>
<li>概述:功能安全在 AUTOSAR 中</li>
<li>Memory 保护机制</li>
<li>程序流监控(Program Flow Monitoring</li>
<li>硬件诊断(Core Test / RAM Test</li>
<li>通信保护(E2E</li>
<li>Watchdog(看门狗)</li>
<li>Safety BSW 模块(SafeBsw</li>
</ol></nav>
<hr>
<h2>1 引言与范围</h2>
<p>本文档(AUTOSAR_EXP_FunctionalSafetyMeasures)介绍 AUTOSAR Classic Platform 中实现功能安全(Functional Safety)的机制。覆盖 ISO 26262-5:2018 要求的故障检测、故障避免、故障容忍等机制。涵盖软件级(Memory/Program Flow/E2E/Watchdog)与硬件级(Core Test / RAM Test)机制。</p>
<h2>2 缩略语</h2>
<p>FSM / Functional Safety / ISO 26262 / ASIL / QM / SafeBsw / SafeBswPartition / Memory Protection / Program Flow Monitoring / Core Test / RAM Test / Wdg / E2E / SecOC / Watchdog / Memory Partitioning / OS-Application / BSW Module / DEM / FiM / CDD / WdgM / WdgIf / Wdg Driver</p>
<h2>3 相关文档</h2>
<p>[1] AUTOSAR SWS BSW General<br>
[2] AUTOSAR SWS Safety Extensions<br>
[3] AUTOSAR SWS Watchdog Driver<br>
[4] AUTOSAR SWS Watchdog Interface<br>
[5] AUTOSAR SWS Watchdog Manager<br>
[6] AUTOSAR SWS Core Test<br>
[7] AUTOSAR SWS RAM Test<br>
[8] AUTOSAR SWS E2E Library<br>
[9] AUTOSAR SRS SafetyExtensions<br>
[10] ISO 26262-5:2018 (Road vehicles — Functional safety — Part 5: Product development at the software level)</p>
<h2>4 概述:功能安全在 AUTOSAR 中</h2>
<p>AUTOSAR 提供以下功能安全机制:</p>
<ul>
<li><strong>软件级机制</strong>Memory Partitioning、Program Flow Monitoring、Communication Protection (E2E)、Watchdog Manager、Safety BSW</li>
<li><strong>硬件级机制</strong>Core Test (CPU 内核自检)、RAM Test (RAM 测试)、Watchdog</li>
<li><strong>诊断机制</strong>DEM (Diagnostic Event Manager) 上报故障事件、FiM (Function Inhibition Manager) 抑制功能;</li>
<li><strong>配置机制</strong>:通过配置区分 Safety 相关 BSW 与非 Safety 相关 BSW</li>
<li><strong>分区机制</strong>:通过 OS-Application 隔离 Safety 相关代码与非 Safety 相关代码。</li>
</ul>
<p>ISO 26262 ASIL 等级(汽车安全完整性等级):</p>
<ul>
<li><strong>ASIL A</strong>:最低;</li>
<li><strong>ASIL B</strong>:中等;</li>
<li><strong>ASIL C</strong>:较高;</li>
<li><strong>ASIL D</strong>:最高(最高安全要求);</li>
<li><strong>QM</strong>Quality Management,无安全要求。</li>
</ul>
<h2>5 Memory 保护机制</h2>
<p>Memory Partitioning 是 AUTOSAR 的核心安全机制:</p>
<ul>
<li>每个 OS-Application 有独立的 Memory Region</li>
<li>Memory Region 不能重叠(除非显式配置);</li>
<li>访问其他分区的 Memory 触发 Protection Hook</li>
<li>Safety 相关 OS-Application 与非 Safety 相关隔离。</li>
</ul>
<p>Memory 保护涵盖:</p>
<ul>
<li><strong>代码</strong>:只读执行;</li>
<li><strong>常量</strong>:只读;</li>
<li><strong>变量</strong>:读写受限;</li>
<li><strong></strong>:每个 OS-Application 独立栈;</li>
<li><strong>共享内存</strong>:显式定义共享区域。</li>
</ul>
<h2>6 程序流监控(Program Flow Monitoring</h2>
<p>程序流监控(Program Flow Monitoring)通过 Watchdog ManagerWdgM)实现:</p>
<ul>
<li><strong>Alived Supervision</strong>:监控周期性任务的到达时间;</li>
<li><strong>Deadline Supervision</strong>:监控任务最大执行时间;</li>
<li><strong>Logical Supervision</strong>:监控任务执行顺序(Graph);</li>
<li><strong>Local Status</strong>WdgM 实例独立状态;</li>
<li><strong>Global Status</strong>:综合所有 Supervised Entity 状态;</li>
<li><strong>Recovery</strong>:失败时执行恢复操作(重启、Shutdown 等)。</li>
</ul>
<p>WdgM 故障处理:</p>
<ul>
<li>WdgM 检测到违反 → 设置 Local Status = EXPIRED / FAILED</li>
<li>Global Status 综合计算;</li>
<li>Global Status = FAILED → 触发错误反应(ErrorReaction);</li>
<li>错误反应:报告 DEM、关闭分区、重启 ECU 等。</li>
</ul>
<h2>7 硬件诊断(Core Test / RAM Test</h2>
<p>R4.2.2 新增"硬件诊断"章节,涵盖 Core Test 和 RAM Test。</p>
<h3>7.1 Core Test</h3>
<p>Core Test 用于检测 CPU 内核故障:</p>
<ul>
<li><strong>Register Test</strong>:测试 CPU 寄存器(写入/读取/比较);</li>
<li><strong>Flag / Condition Code Test</strong>:测试状态标志;</li>
<li><strong>Interrupt Test</strong>:测试中断处理;</li>
<li><strong>Program Counter Test</strong>:测试程序计数器;</li>
<li><strong>ALU / FPU Test</strong>:测试算术逻辑单元 / 浮点单元;</li>
<li><strong>Stack Pointer Test</strong>:测试栈指针。</li>
</ul>
<p>Core Test 由 AUTOSAR SWS CoreTestDriver 模块提供。</p>
<h3>7.2 RAM Test</h3>
<p>RAM Test 用于检测 RAM 故障:</p>
<ul>
<li><strong>March Test</strong>March C / March C- / March X / March Y 等算法;</li>
<li><strong>Galpat Test</ Gallagher Pattern Test</strong>:检测相邻位故障;</li>
<li><strong>Walk Test</strong>Walking 1 / Walking 0</li>
<li><strong>Checkerboard Test</strong>:棋盘格模式;</li>
<li><strong>NIST Test</strong>NIST 电池测试。</li>
</ul>
<p>RAM Test 通常在 ECU 启动时 + 运行时(Background Test)执行。</p>
<h2>8 通信保护(E2E</h2>
<p>E2EEnd-to-End)通信保护提供端到端保护:</p>
<ul>
<li><strong>完整性</strong>:通过 CRC 检测数据损坏;</li>
<li><strong>真实性</strong>:通过 Counter / CRC 检测伪造;</li>
<li><strong>新鲜度</strong>:通过 Freshness Value 检测重放;</li>
<li><strong>顺序</strong>:通过 Sequence Counter 检测丢失 / 重复 / 错序。</li>
</ul>
<p>E2E Profile 1-22 适用于不同应用场景(短 / 长 / 简单 / 复杂 / 灵活)。R4.2.1 起新增 Profile 7 / 11 / 22。</p>
<p>E2E 状态机:</p>
<ul>
<li>NO_NEW_DATA / NEW_DATA_OK / NEW_DATA_WRONG_CRC / NEW_DATA_SEQ_ERROR / NEW_DATA_NOT_SYNCHRONIZED / SYNC_IN_PROGRESS / INITIAL。</li>
</ul>
<h2>9 Watchdog(看门狗)</h2>
<p>Watchdog(看门狗)作为系统级安全机制:</p>
<ul>
<li><strong>Wdg Driver</strong>MCAL):直接操作硬件看门狗;</li>
<li><strong>WdgIf</strong>ECU 抽象):抽象看门狗;</li>
<li><strong>WdgM</strong>(服务层):监督应用任务 + 管理看门狗。</li>
</ul>
<p>三层结构确保:</p>
<ul>
<li>Wdg Driver 监督 WdgIf 正常工作;</li>
<li>WdgM 监督应用任务;</li>
<li>Wdg Driver / WdgIf / WdgM 协同工作提供系统级监督。</li>
</ul>
<h2>10 Safety BSW 模块(SafeBsw</h2>
<p>Safety BSWSafeBsw)指 AUTOSAR 提供的 Safety 相关 BSW 模块:</p>
<ul>
<li><strong>SafeBswPartition</strong>:用于隔离 Safety 功能的 OS-Application 模板;</li>
<li><strong>WdgM</strong>:看门狗管理;</li>
<li><strong>DET / DEM</strong>:开发错误 / 诊断事件管理;</li>
<li><strong>FiM</strong>:功能抑制管理;</li>
<li><strong>E2E</strong>:端到端保护;</li>
<li><strong>SecOC</strong>:车内安全通信;</li>
<li><strong>Core Test / RAM Test</strong>:硬件诊断;</li>
<li><strong>Safety Extensions</strong>Safety 相关 OS / BSW 扩展。</li>
</ul>
<p>SafeBsw 设计原则:</p>
<ul>
<li>SafeBsw 模块遵循 ISO 26262 软件开发流程;</li>
<li>SafeBsw 模块具有明确的安全要求(SRS);</li>
<li>SafeBsw 模块提供完整错误检测与报告;</li>
<li>SafeBsw 模块支持隔离(Memory Partitioning)。</li>
</ul>
<hr>
<section class="proofread-notes">
<h3>校对记录</h3>
<p>校对轮次:L1 自动校对(2026-06-13</p>
<ul>
<li>✅ 章节结构:原文 10 章,译文目录完整对应。</li>
<li>✅ 安全机制完整翻译:Memory/Program Flow/Hardware Diag (Core/RAM)/E2E/Watchdog/SafeBsw。</li>
<li>✅ R4.2.2 新增"硬件诊断"章节(Core Test / RAM Test)。</li>
</ul>
</section>
</body>
</html>