---
title: "Implementing ECUs"
description: "Implement ECUs in RemotiveTopology as RemotiveBrokers, Python behavioral models, or your own containers, and attach them to the channels of the topology."
source: https://developer.remotivelabs.com/docs/remotive-topology/usage/ecus
last_updated: 2026-11-20
---

# Implementing ECUs

By default RemotiveTopology instantiates each ECU as a RemotiveBroker. The RemotiveBroker allows you to communicate as the ECU, for example using the correct IP address on a VLAN or using a CAN device. You decide what behavior the ECU should have, or replace RemotiveBroker with your own container.

| Option                                 | Use when                                                               | Runs as                                  |
| -------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------- |
| [Behavioral model](https://developer.remotivelabs.com/docs/remotive-topology/usage/ecus/behavioral-models.md) | You want a reusable component that emulates the behavior of a real ECU | RemotiveBroker and a model container     |
| [Mock](https://developer.remotivelabs.com/docs/remotive-topology/usage/ecus/mocks.md)                         | You need an ECU that sends its cyclic signals, for a realistic bus     | RemotiveBroker and a mock                |
| [Virtual ECU](https://developer.remotivelabs.com/docs/remotive-topology/usage/ecus/virtual-ecus.md)           | You want to run the production software of the ECU, or another implementation in a container | Your container instead of RemotiveBroker |
| [External](#external-ecus)             | The ECU runs as hardware or in a different runtime                     | Nothing, managed by you                  |

## External ECUs

An external ECU plays a part in the instantiated topology, but runs separately and isn't controlled by the topology, for example as hardware or in a different runtime. Defining it as external makes RemotiveTopology aware of it without trying to manage it.

```yaml
ecus:
  FLCM:
    external: {}
```

Since the instantiated ECUs decide which channels are instantiated, an external ECU also affects which channels are part of the topology.

> **Note**
>
> Marking ECUs as external is required to be able to use [TAP namespaces](https://developer.remotivelabs.com/docs/remotive-topology/usage/test/tap.md) that reference an external ECU.

## Namespaces

When working with the RemotiveTopology framework, for example in behavioral models, mocks, or test cases, you refer to namespaces. A namespace represents how an ECU sees a channel and is named `<ECU>-<Channel>`, for example `BCM-DriverCan`.

To list the available namespaces, start the topology and ask the TopologyBroker, which is forwarded to port 50051 on your host:

```sh
remotive broker signals namespaces --url http://localhost:50051
```

## ECU channel configuration

By default an ECU is connected to all channels according to the platform. You can [choose a subset of channels](https://developer.remotivelabs.com/docs/remotive-topology/concepts/instance.md#choosing-channels) for each ECU.

Some channel types also have optional configuration per ECU.

### Ethernet

When instantiating a RemotiveBroker-based ECU connected to Ethernet you can control which [sockets](https://developer.remotivelabs.com/docs/remotive-topology/concepts/platform.md#ethernet-pdus) and [SOME/IP services](https://developer.remotivelabs.com/docs/remotive-topology/concepts/platform.md#someip) are instantiated. By default all sockets and services belonging to the ECU according to the platform are instantiated. These settings only affect ECUs that are instantiated using RemotiveBroker.

```yaml
ecus:
  BCM:
    channels:
      BodyEth0:
        config:
          type: ethernet
          sockets:
            - BCM_socket1
            - BCM_socket2
          someip:
            provided_service_instances:
              - BCM_service1
            consumed_service_instances:
              - GWM_service2
```

- `sockets` - which sockets (ports) the ECU opens.
- `provided_service_instances` - which SOME/IP service instances the ECU provides.
- `consumed_service_instances` - which SOME/IP service instances the ECU consumes. Only these services need to be provided by other ECUs in the instance.

### VLAN trunk interface

When an Ethernet channel uses the [`remotivebus` driver](https://developer.remotivelabs.com/docs/remotive-topology/usage/channels/ethernet.md#vlan), the ECU gets both a trunk interface and a VLAN subinterface. For containers that need to handle VLAN tagging themselves and only require the trunk network interface, creation of the VLAN subinterface can be skipped:

```yaml
ecus:
  BCM:
    channels:
      BodyEth:
        config:
          type: ethernet
          create_vlan_interface: false
```
