Home Learning Paths ECU Lab Assessments Interview Preparation Arena Pricing Log In Sign Up

Capstone: Complete Vehicle Ethernet Architecture

DeliverableDescription
Network topology diagramZonal architecture: ECUs, switches, backbone; all links with speed
VLAN assignment tableVLAN per domain; PCP per traffic class; IP addressing per subnet
TSN stream specificationAll safety streams: period, max payload, latency budget, CBS/TAS selection
Security architectureMACsec coverage, firewall rules, TLS endpoints, TARA threat mapping

Exercise 1: Design a Compact Vehicle Ethernet Architecture

Pythonnetwork_design.py
#!/usr/bin/env python3
# Vehicle network design validator: check bandwidth utilisation and latency budgets

LINK_RATE_MBPS = 100  # 100BASE-T1 for zone links; 1000 for backbone

# Define streams (per zone controller port, egress to backbone)
streams = [
    # name, rate_mbps, priority, latency_req_ms, type
    ("front_camera_4k",     45.0, 6, 2.0,  "CBS_A"),
    ("radar_raw",            8.0, 6, 5.0,  "CBS_A"),
    ("brake_command",        0.1, 7, 1.0,  "TAS"),
    ("steering_feedback",    0.1, 7, 1.0,  "TAS"),
    ("someip_control",       2.0, 4, 50.0, "BEST_EFFORT"),
    ("doip_diag",            1.0, 3, 500.0,"BEST_EFFORT"),
    ("ota_download",        30.0, 0, None, "BEST_EFFORT"),
]

# Bandwidth check
total_bw = sum(s[1] for s in streams)
print(f"Total bandwidth: {total_bw:.1f} / {LINK_RATE_MBPS} Mbit/s "
      f"({100*total_bw/LINK_RATE_MBPS:.0f}% utilisation)")

# Check: CBS_A streams ≤ 75% of link (leave room for ST and best-effort)
cbs_bw = sum(s[1] for s in streams if s[4].startswith("CBS"))
print(f"CBS bandwidth:   {cbs_bw:.1f} Mbit/s ({100*cbs_bw/LINK_RATE_MBPS:.0f}%)")
if cbs_bw / LINK_RATE_MBPS > 0.75:
    print("WARNING: CBS streams exceed 75% — best-effort will starve")

# Check: TAS stream fits in reserved gate
tas_bw = sum(s[1] for s in streams if s[4] == "TAS")
gate_us = 50.0  # µs per 1ms cycle reserved for Q7
tas_max_bw = gate_us * LINK_RATE_MBPS / 1000.0  # Mbit/s
print(f"TAS bandwidth:   {tas_bw:.3f} Mbit/s (gate allows {tas_max_bw:.1f} Mbit/s)")
if tas_bw > tas_max_bw:
    print("ERROR: TAS streams exceed gate capacity — increase gate window")
else:
    print("OK: TAS streams fit within gate budget")

Exercise 2: TSN Stream Specification Table

Texttsn_stream_spec.txt
# TSN Stream Specification — Front Zone Controller Egress Port (100BASE-T1)
# Generated for: OEM Vehicle Platform X, Domain Controller 2025MY

Stream ID | Name              | Period | Max Payload | VLAN | PCP | Shaper | WCL Budget
----------|-------------------|--------|-------------|------|-----|--------|------------
0x0001    | brake_command     |  1 ms  |  100 bytes  |  10  |  7  |  TAS   |  < 1 ms
0x0002    | steer_feedback    |  1 ms  |  100 bytes  |  10  |  7  |  TAS   |  < 1 ms
0x0003    | front_camera_0    | 33 ms  | 1400 bytes  |  10  |  6  |  CBS-A |  < 2 ms
0x0004    | front_camera_1    | 33 ms  | 1400 bytes  |  10  |  6  |  CBS-A |  < 2 ms
0x0005    | radar_raw_0       | 10 ms  | 1200 bytes  |  10  |  6  |  CBS-A |  < 5 ms
0x0006    | someip_ctrl       | 10 ms  |  512 bytes  |  10  |  4  |  —     |  < 50 ms
0x0007    | doip_diag         | async  | 1400 bytes  |  30  |  3  |  —     |  < 500 ms
0x0008    | ota_firmware      | async  | 1400 bytes  |  10  |  0  |  —     |  none

# CBS parameters for camera streams (40 Mbit/s combined):
# idleSlope = 40 Mbit/s; sendSlope = -60 Mbit/s
# maxCredit = (40/100) * 1500 * 8 = 4800 bits = 600 bytes

# Guard band for TAS (Q7 gate):
# Max interfering frame = 1400 bytes @ 100Mbit = 112 µs
# Guard band = 112 µs; gate window = 50 µs → cycle overhead = 162/1000 = 16.2%

Summary

The capstone exercise integrates all concepts: physical layer selection drives bandwidth budget; VLAN design drives traffic isolation; TSN stream specification drives TAS gate scheduling and CBS parameters; security requirements drive MACsec/TLS/firewall configuration. The bandwidth validator catches the most common design errors: CBS streams exceeding 75% of link capacity (starves best-effort OTA), TAS streams exceeding the gate budget (safety streams miss their latency target), and missing guard bands (safety window violated by large interfering frames). A complete network specification document with this stream table is the primary deliverable for network integration reviews.

🔬 Deep Dive — Core Concepts Expanded

This section builds on the foundational concepts covered above with additional technical depth, edge cases, and configuration nuances that separate competent engineers from experts. When working on production ECU projects, the details covered here are the ones most commonly responsible for integration delays and late-phase defects.

Key principles to reinforce:

  • Configuration over coding: In AUTOSAR and automotive middleware environments, correctness is largely determined by ARXML configuration, not application code. A correctly implemented algorithm can produce wrong results due to a single misconfigured parameter.
  • Traceability as a first-class concern: Every configuration decision should be traceable to a requirement, safety goal, or architecture decision. Undocumented configuration choices are a common source of regression defects when ECUs are updated.
  • Cross-module dependencies: In tightly integrated automotive software stacks, changing one module's configuration often requires corresponding updates in dependent modules. Always perform a dependency impact analysis before submitting configuration changes.

🏭 How This Topic Appears in Production Projects

  • Project integration phase: The concepts covered in this lesson are most commonly encountered during ECU integration testing — when multiple software components from different teams are combined for the first time. Issues that were invisible in unit tests frequently surface at this stage.
  • Supplier/OEM interface: This is a topic that frequently appears in technical discussions between Tier-1 ECU suppliers and OEM system integrators. Engineers who can speak fluently about these details earn credibility and are often brought into critical design review meetings.
  • Automotive tool ecosystem: Vector CANoe/CANalyzer, dSPACE tools, and ETAS INCA are the standard tools used to validate and measure the correct behaviour of the systems described in this lesson. Familiarity with these tools alongside the conceptual knowledge dramatically accelerates debugging in real projects.

⚠️ Common Mistakes and How to Avoid Them

  1. Assuming default configuration is correct: Automotive software tools ship with default configurations that are designed to compile and link, not to meet project-specific requirements. Every configuration parameter needs to be consciously set. 'It compiled' is not the same as 'it is correctly configured'.
  2. Skipping documentation of configuration rationale: In a 3-year ECU project with team turnover, undocumented configuration choices become tribal knowledge that disappears when engineers leave. Document why a parameter is set to a specific value, not just what it is set to.
  3. Testing only the happy path: Automotive ECUs must behave correctly under fault conditions, voltage variations, and communication errors. Always test the error handling paths as rigorously as the nominal operation. Many production escapes originate in untested error branches.
  4. Version mismatches between teams: In a multi-team project, the BSW team, SWC team, and system integration team may use different versions of the same ARXML file. Version management of all ARXML files in a shared repository is mandatory, not optional.

📊 Industry Note

Engineers who master both the theoretical concepts and the practical toolchain skills covered in this course are among the most sought-after professionals in the automotive software industry. The combination of AUTOSAR standards knowledge, safety engineering understanding, and hands-on configuration experience commands premium salaries at OEMs and Tier-1 suppliers globally.

← PreviousNetwork Management for Automotive Ethernet