# Diagnostics library test faults
# These faults do not represent real robot faults or reactions
# Highly Confidential and Proprietary Zoox Information. Copyright (c) Zoox.

component: BodyManager
source_enum: kEmuBodyManager
namespace: zoox
can_messages:
  - status_msg: EMU_driveAlertStatus
    log_msg: EMU_driveAlertLog
can_import: firmware/common/can/generated/vh6/emu.h
can_namespace: vh6
proto_imports:
  - "base/diag/core/tests/test.proto"
  - "vehicle/common/proto/emu_diagnostics.proto"
# Metric Nanopb type, separated by `::`, used in generated .h for EMU.
metric: zoox::diag::TestMetric
faults:
  - id: 0
    name: TestFault0
    severity: ERROR
    description: Test Fault 0
    reaction:
      trajectory: NoGo
  - id: 1
    name: TestFault1
    severity: ERROR
    description: Test Fault 1
    # Freeze Frame Proto type, separated by `.`, used in _pcu generated .proto
    freeze_frame: zoox.common.proto.TestFF
  - id: 2
    name: TestFault2
    severity: ERROR
    description: Test Fault 2
    threshold_ms: 5
  - id: 3
    name: TestLatchingExplicitFalse
    severity: ERROR
    description: Test Fault 3
    threshold_ms: 5
    latching: false
  - id: 4
    name: TestLatchingExplicitTrue
    severity: ERROR
    description: Test Fault 4
    threshold_ms: 5
    latching: true
  - id: 5
    name: TestCrashSignalL0
    severity: ERROR
    description: Test Fault 5
    reaction:
      crash_level: Level0
  - id: 6
    name: TestCrashSignalL1
    severity: ERROR
    description: Test Fault 6
    reaction:
      crash_level: Level1
  - id: 7
    name: TestCrashSignalL2
    severity: ERROR
    description: Test Fault 7
    reaction:
      crash_level: Level2
  - id: 8
    name: TestCrashSignalExplicitNone
    severity: ERROR
    description: Test Fault 8
    reaction:
      crash_level: None
  - id: 9
    name: TestAutonomyExplicitFalse
    severity: ERROR
    description: Test Fault 9
    requires_autonomy: false
  - id: 10
    name: TestAutonomyExplicitTrue
    severity: ERROR
    description: Test Fault 10
    requires_autonomy: true
  - id: 11
    name: TestDeprecatedFault
    severity: ERROR
    description: Test Fault 11
    deprecated: true
    # NOTE:
    # Add new test faults here and increment the num_faults_in_yaml constant in
    # emu_fault_generation_test.cpp. This is because a unit test there checks
    # if the deprecated fault (id=9) is compiled into the faultList.
