flync_4_topology

class FLYNCTopology

Bases: FLYNCBaseModel

Represents the complete FLYNC system topology, including ECU connections and multicast routing configuration.

Parameters

system_topologySystemTopology

The system-wide external connection topology between ECUs.

multicast_pathsMulticastConfig, optional

Optional collection of system-wide multicast paths, defining source and destination host pairs for each multicast route.

System Topology

Expand for Schematic
        classDiagram

    class SystemTopology {
        connections: list[ExternalConnection]
    }

    class FLYNCBaseModel {
    }

    class ExternalConnection {
        type: Literal['ecu_port_to_ecu_port'] = 'ecu_port_to_ecu_port'
        id: str
        ecu1_port_name: str
        ecu2_port_name: str
    }

    class ECUPort {
        name: str
        mdi_config: BASET1 | BASET1S | BASET = BASET1
        mii_config: MII | RMII | SGMII | RGMII | XFI | None = None
    }

    class OutputStrategy {
        <<Enumeration>>
        AUTO: int = 1
        FOLDER: int = 1
        SINGLE_FILE: int = 2
        OMMIT_ROOT: int = 4
        FIXED_ROOT: int = 8
    }

    class MulticastConfig {
        paths: list[MulticastPath]
    }

    class FLYNCTopology {
        system_topology: SystemTopology
        multicast_paths: MulticastConfig | None = None
    }

    ECUPort ..> XFI
    ECUPort ..> BASET1S
    ECUPort ..> MII
    ECUPort ..> BASET1
    ECUPort ..> BASET
    ECUPort ..> RMII
    ECUPort ..> SGMII
    ECUPort ..> RGMII
    MulticastConfig ..> MulticastPath
    SystemTopology ..> ExternalConnection
    FLYNCTopology ..> SystemTopology
    FLYNCTopology ..> MulticastConfig


    
Expand for a YAML example - 📄 system_topology.flync.yaml

Note

In system_topology the external connections between ECUs of the system are described (if more than one ECU is specified).

connections:
  - type: ecu_port_to_ecu_port
    id: conn1
    ecu1_port: hpc1_p1
    ecu2_port: z1_p1
  - type: ecu_port_to_ecu_port
    id: conn2
    ecu1_port: hpc1_p2
    ecu2_port: z2_p1
  - type: ecu_port_to_ecu_port
    id: conn3
    ecu1_port: hpc1_p3
    ecu2_port: eth_ecu_p1

Hint

All the connections listed in a system topology shall be of the type : ecu_port_to_ecu_port.

class SystemTopology

Bases: FLYNCBaseModel

Represents the system-wide topology consisting of external connections between ECUs.

Parameters

connectionslist of ExternalConnection

A list of ExternalConnection instances that define the links between ECU ports.

Private Attributes

_flync_modelFLYNCModel

Internal reference to the FLYNC model that owns this topology. Managed internally and not part of the public API.

class ExternalConnection

Bases: FLYNCBaseModel

Represents a connection between two ECU (Electronic Control Unit) ports.

This model captures a directed or undirected link between two named ports on separate ECUs.

Parameters

typeLiteral[“ecu_port_to_ecu_port”]

The type of the connection. Defaults to “ecu_port_to_ecu_port” for schema identification.

idstr

A unique identifier for the external connection.

ecu1_port_namestr

The name of the first ECU port (alias: “ecu1_port”).

ecu2_port_namestr

The name of the second ECU port (alias: “ecu2_port”).

Private Attributes

_ecu1_portECUPort

Runtime reference to the first ECUPort object.

_ecu2_portECUPort

Runtime reference to the second ECUPort object.

Multicast Paths

Expand for Schematic
        classDiagram

    class SwitchPort {
        name: str
        silicon_port_no: int
        default_vlan_id: int
        mii_config: MII | RMII | SGMII | RGMII | XFI | None = None
        ptp_config: PTPConfig | None = None
        ingress_streams: list[Stream] | None = []
        traffic_classes: list[TrafficClass] | None = []
        macsec_config: MACsecConfig | None = None
    }

    class FLYNCBaseModel {
    }

    class MulticastPath {
        vlan: int
        address: IPvAnyAddress | MacAddress
        src_interface: str
        dst_interface: list[str]
    }

    class ControllerInterface {
        name: str
        mac_address: MacAddress
        mii_config: MII | RMII | SGMII | RGMII | XFI | None = None
        virtual_interfaces: list[VirtualControllerInterface]
        ptp_config: PTPConfig | None = None
        macsec_config: MACsecConfig | None = None
        firewall: Firewall | None = None
        htb: HTBInstance | None = None
        ingress_streams: list[Stream] | None = []
        traffic_classes: list[TrafficClass] | None = list
    }

    class MulticastConfig {
        paths: list[MulticastPath]
    }

    ControllerInterface ..> MacAddress
    ControllerInterface ..> XFI
    ControllerInterface ..> Stream
    ControllerInterface ..> HTBInstance
    ControllerInterface ..> MACsecConfig
    ControllerInterface ..> VirtualControllerInterface
    ControllerInterface ..> TrafficClass
    ControllerInterface ..> Firewall
    ControllerInterface ..> PTPConfig
    ControllerInterface ..> SGMII
    ControllerInterface ..> RMII
    ControllerInterface ..> MII
    ControllerInterface ..> RGMII
    SwitchPort ..> XFI
    SwitchPort ..> Stream
    SwitchPort ..> MII
    SwitchPort ..> MACsecConfig
    SwitchPort ..> TrafficClass
    SwitchPort ..> PTPConfig
    SwitchPort ..> RMII
    SwitchPort ..> SGMII
    SwitchPort ..> RGMII
    MulticastPath ..> MacAddress
    MulticastPath ..> IPvAnyAddress
    MulticastConfig ..> MulticastPath


    
Expand for a YAML example - 📄 multicast_paths.flync.yaml

Note

In multicast_paths as the name suggests, any mulitcast addresses of the system are specified, including the source and sink controllers, respectively.

paths:
 - vlan: 40
   address: 239.0.0.1
   src_interface: eth_ecu_c1_iface1
   dst_interface:
   - hpc_c1_iface1
class MulticastConfig

Bases: FLYNCBaseModel

Represents the system-wide multicast paths.

This model aggregates all source and destination pairs that define each multicast route in the system.

Parameters

pathslist of MulticastPath

Instances representing individual multicast paths in the system.

class MulticastPath

Bases: FLYNCBaseModel

Represents a single multicast path in detail.

Describes how multicast traffic is sent from a source interface to one or more destination interfaces, including VLAN tagging and the multicast address.

Parameters

vlanint

VLAN ID over which the multicast traffic is sent (0-4095).

addressIPvAnyAddress or MacAddress

Multicast address for this path (IPv4, IPv6, or MAC).

src_interfacestr

Name of the source controller interface that originates the multicast.

dst_interfacelist of str

Names of destination controller interfaces that receive the multicast.

Private Attributes

_connected_component_listobject

Internal reference to the connected component for this multicast path.