flync_4_ecu¶
ECU Config¶
- class ECU¶
Bases:
UniqueNameRepresents an Electronic Control Unit (ECU) in the network.
Parameters¶
- namestr
Name of the ECU.
- portslist of
ECUPort List of physical ECU ports. At least one port must be provided.
- controllerslist of
Controller Controllers associated with this ECU.
- switcheslist of
Switch, optional Switches integrated within the ECU. If not provided, the ECU contains no internal switches.
- socketslist of
SocketContainer, optional Socket containers within the ECU. If not provided, the ECU has no socket deployments configured.
- topology
InternalTopology Internal topology defining the connectivity between ECU components.
- ecu_metadata
ECUMetadata Metadata information describing the ECU.
ECU Ports Config¶
Hint
In case of a port with an external PHY, we need to include mdi_config (see Media-Dependent Interfaces), and mii_config (see Media-Independent Interfaces).
- class ECUPort¶
Bases:
NamedDictInstancesRepresents an ECU port and its configuration.
This class encapsulates both the media-dependent (MDI) and media-independent (MII) interface configurations for a port.
Parameters¶
Private Attributes¶
- _ecu :
The ECU of which the ECU Port is a part of.
- _connected_component:
The switch port, controller interface or ecu port connected to the controller interface. This attribute is managed internally and is not part of the public API.
- _type:
The type of the object generated. Set to ecu_port.
Controller Config¶
Hint
For controller interfaces that have an external PHY, the mii_config (see Media-Independent Interfaces) for that interface must be provided.
For controller interfaces with integrated PHY, no mii_config is needed.
Warning
In any case, the MDI configuration is never configured on the controller interface, but on the ECU Ports. See ECU Ports Config for more details.
- class Controller¶
Bases:
NamedListInstances[Controller]Represents a controller device that contains multiple interfaces.
Parameters¶
- meta
EmbeddedMetadata Metadata describing the embedded controller.
- typeLiteral[“Controller”]
Indicates the type of the device. Default is “Controller”.
- namestr
Name of the controller.
- interfaceslist of
ControllerInterface Physical interfaces of the controller.
Private Attributes¶
- _type:
The type of the object generated. Set to Controller.
- meta
- class ControllerInterface¶
Bases:
NamedDictInstancesRepresents a physical controller interface including virtual interfaces and optional PTP configuration.
Parameters¶
- namestr
Interface name.
- mac_address
MacAddress MAC address in standard notation.
- mii_config
MIIorRMIIorSGMIIorRGMII, optional Media-independent interface configuration.
- virtual_interfaceslist of
VirtualControllerInterface Virtual interfaces configured on top of the physical controller interface.
- ptp_config
PTPConfig, optional Precision Time Protocol configuration.
- macsec_config
MACsecConfig, optional MACsec configuration.
- firewall
Firewall, optional Firewall configuration for the interface.
- htb
HTBInstance, optional Hierarchical Token Bucket (HTB) configuration.
- ingress_streamslist of
Stream, optional Stream-based IEEE 802.1Qci configuration.
- traffic_classeslist of
TrafficClass, optional Traffic class definitions and traffic shaping configuration applied to egress queues.
Private Attributes¶
- _connected_component:
The switch port, controller interface or ecu port connected to the controller interface. This attribute is managed internally and is not part of the public API.
- _type:
The type of the object generated. Set to controller_interface.
- class VirtualControllerInterface¶
Bases:
FLYNCBaseModelRepresents a virtual interface on a controller.
Parameters¶
- namestr
Name of the virtual interface.
- vlanidint
VLAN identifier in the range 0-4095.
- addresseslist of
IPv4AddressEndpointorIPv6AddressEndpoint Assigned IPv4 and IPv6 address endpoints.
- multicastlist of
IPv4AddressorIPv6Addressor str, optional Allowed multicast addresses.
Switch Config¶
Hint
A switch configuration contains key details regarding the following parameters:
switch (logical) ports
VLAN configuration
multicast configuration
TimeSync configuration
QoS configuration
Hint
Similar to controller config, each port of switch with an external PHY has an mii_config (see Media-Independent Interfaces),
describing the various properties of the MII connected to that port.
For switch ports using an integrated PHY, no mii_config is needed.
- class Switch¶
Bases:
NamedListInstancesRepresents an automotive Ethernet network switch configuration.
Parameters¶
- meta
EmbeddedMetadata Metadata associated with the switch, such as vendor-specific or implementation-specific attributes.
- namestr
Name of the switch.
- portslist of
SwitchPort List of external (connected to ECU ports) or internal (connected to internal ECU interfaces) switch ports.
- vlanslist of
VLANEntry List of VLAN entries configured on the switch.
- host_controller
ControllerInterface, optional Switch host controller configuration, if the switch is managed by an internal controller.
- tcam_ruleslist of
TCAMRule, optional List of TCAM rules configured on the switch. These rules define packet-matching conditions and associated actions applied to ingress or egress traffic.
- meta
- class SwitchPort¶
Bases:
NamedDictInstancesRepresents a Switch Port and its configuration.
Parameters¶
- namestr
Name of the Switch Port.
- silicon_port_noint
Silicon hardware port number (vendor-specific).
- default_vlan_idint
VLAN ID to be added to an untagged frame ingressing on the port.
- mii_config
MIIorRMIIorSGMIIorRGMII, optional Media-independent interface configuration (e.g., MII or RMII).
- ptp_config
PTPConfig, optional Precision Time Protocol configuration.
- ingress_streamslist of
Stream, optional Stream-based IEEE 802.1Qci configuration.
- traffic_classeslist of
TrafficClass, optional Traffic class definitions and traffic shaping configuration applied to egress port queues.
- macsec_config
MACsecConfig, optional MACsec configuration for the port.
Private Attributes¶
- _type :
The type of the object generated. Set to controller_interface.
_mdi_config :
BaseT1orBaseT1SorBaseT- _connected_component:
The switch port, controller interface or ecu port connected to the switch port. This attribute is managed internally and is not part of the public API.
- class VLANEntry¶
Bases:
FLYNCBaseModelRepresents a VLAN entry for a switch.
Parameters¶
- namestr
Human-readable name for the VLAN.
- idint
VLAN ID (0-4095).
- default_priorityint
Default frame priority for the VLAN (0-7).
- portslist of str
List of switch port names members of this VLAN.
- multicastlist of
MulticastGroup, optional List of multicast group configurations associated with this VLAN.
- class MulticastGroup¶
Bases:
FLYNCBaseModelRepresents a multicast group configuration.
This class defines a multicast group by associating a multicast destination address with a set of switch ports that participate in the group.
Parameters¶
- address
IPv4AddressorIPv6AddressorMacAddress The multicast address. Must be a valid MAC or IP multicast address.
- portslist of str
A list of switch port names that are part of the multicast group.
- address
TCAM¶
- class TCAMRule¶
Bases:
FLYNCBaseModelDefinition of a TCAM (ternary content-addressable memory) rule for a switch.
Parameters¶
- namestr
Name for the description of the TCAM rule.
- idStrictInt
Unique TCAM rule ID.
- match_filter
FrameFilter Packet-matching filter used to decide whether the rule applies.
- match_portslist of str
Ports to which the rule is bound.
- actionlist of
DroporMirrororForceEgressorVLANOverwriteorRemoveVLAN One or more actions performed when the rule matches. The
typefield of each action class acts as the discriminating key for Pydantic.
- class Drop¶
Bases:
FLYNCBaseModelAction that discards traffic on the selected egress ports.
Parameters¶
- typeLiteral[“drop”]
Discriminator used by Pydantic.
- portslist of str
Egress ports where the drop action should be applied.
- class Mirror¶
Bases:
FLYNCBaseModelAction that mirrors incoming traffic to additional egress ports.
Parameters¶
- typeLiteral[“mirror”]
Discriminator used by Pydantic.
- portslist of str
Egress ports that will receive the mirrored traffic.
- class ForceEgress¶
Bases:
FLYNCBaseModelAction that forces a packet to leave through a given set of ports, bypassing the normal forwarding decision.
Parameters¶
- typeLiteral[“force_egress”]
Discriminator used by Pydantic.
- portslist of str
Egress ports to which the messages are force-forwarded.
- class VLANOverwrite¶
Bases:
FLYNCBaseModelAction that overwrites VLAN ID and/or PCP values on selected ports.
Parameters¶
- typeLiteral[“vlan_overwrite”]
Discriminator used by Pydantic.
- overwrite_vlan_idint, optional
New VLAN identifier (0-4095). If
None, the VLAN ID is left unchanged.- overwrite_vlan_pcpint, optional
New PCP value (0-7). If
None, the PCP value is left unchanged.- portslist of str
Egress ports at which the overwriting should take place.
- class RemoveVLAN¶
Bases:
FLYNCBaseModelAction that removes the VLAN tag from packets on the given ports.
Parameters¶
- typeLiteral[“remove_vlan”]
Discriminator used by Pydantic.
- portslist of str
Egress ports where the VLAN tag will be removed.
PHY Config¶
Media-Dependent Interfaces¶
- class BASET¶
Bases:
FLYNCBaseModelRepresents a BASE-T Ethernet interface configuration.
Parameters¶
- modeLiteral[“base_t”]
Interface mode. Defaults to
"base_t".- speedint
Supported link speed in megabits per second. Valid values are 100 or 1000.
- duplexLiteral[“full”]
Duplex mode. Defaults to
"full".- autonegotiationbool
Indicates whether autonegotiation is enabled.
- class BASET1¶
Bases:
FLYNCBaseModelRepresents a BASE-T1 Ethernet interface configuration.
Parameters¶
- modeLiteral[“base_t1”]
Interface mode. Defaults to
"base_t1".- speedint
Supported link speed in megabits per second. Valid values are 100 or 1000.
- duplexLiteral[“full”]
Duplex mode. Defaults to
"full".- roleLiteral[“master”, “slave”]
Role of the PHY, either master or slave.
- autonegotiationbool
Indicates whether autonegotiation is enabled.
- class BASET1S¶
Bases:
FLYNCBaseModelRepresents a BASE-T1S Ethernet interface configuration.
Parameters¶
- modeLiteral[“base_t1s”]
Interface mode. Defaults to
"base_t1s".- speedint
Supported link speed in megabits per second. Defaults to 10.
- duplexLiteral[“half”]
Duplex mode. Defaults to
"half".- roleLiteral[“master”, “slave”]
Role of the PHY, either master or slave.
- autonegotiationbool
Indicates whether autonegotiation is enabled.
Media-Independent Interfaces¶
- class MII¶
Bases:
FLYNCBaseModelRepresents a Media Independent Interface (MII) configuration.
Parameters¶
- typeLiteral[“mii”]
Interface type. Defaults to
"mii".- speedint
Supported link speed in megabits per second. Valid values are 10 or 100.
- modeLiteral[“mac”, “phy”]
Operating mode, either MAC or PHY.
- class RMII¶
Bases:
FLYNCBaseModelRepresents a Reduced Media Independent Interface (RMII) configuration.
Parameters¶
- typeLiteral[“rmii”]
Interface type. Defaults to
"rmii".- speedint
Supported link speed in megabits per second. Valid values are 10 or 100.
- modeLiteral[“mac”, “phy”]
Operating mode, either MAC or PHY.
- class SGMII¶
Bases:
FLYNCBaseModelRepresents a Serial Gigabit Media Independent Interface (SGMII or SGMII+) configuration.
Parameters¶
- typeLiteral[“sgmii”]
Interface type. Defaults to
"sgmii".- speedint
Supported link speed in megabits per second. Valid values are 10, 100, 1000, or 2500. Defaults to 1000 Mbps.
- modeLiteral[“mac”, “phy”]
Operating mode, either MAC or PHY.
- class RGMII¶
Bases:
FLYNCBaseModelRepresents a Reduced Gigabit Media Independent Interface (RGMII) configuration.
Parameters¶
- typeLiteral[“rgmii”]
Interface type. Defaults to
"rgmii".- speedint
Supported link speed in megabits per second. Valid values are 10, 100, or 1000. Defaults to 1000 Mbps.
- modeLiteral[“mac”, “phy”]
Operating mode, either MAC or PHY.
- class XFI¶
Bases:
FLYNCBaseModelRepresents a 10-Gigabit Ethernet (10GbE) serial electrical interface (XFI) configuration.
Parameters¶
- typeLiteral[“xfi”]
Interface type. Defaults to “xfi”.
- speedLiteral[10000]
Supported speed in Mbps. Defaults to 10000.
- modeLiteral[“mac”, “phy”]
Operating mode of the interface, either MAC or PHY.
ECU Internal Topology¶
Internal Connection¶
Note
The fields of a connection will be different, depending on the kind of connection.
Types of Internal Connections¶
|
1st Attribute |
2nd Attribute |
|---|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
- class InternalTopology¶
Bases:
FLYNCBaseModelParameters¶
- connectionslist of
InternalConnectionUnion List of internal connections between ECU components. Defaults to an empty list.
- connectionslist of
- class InternalConnectionUnion¶
Bases:
RootModelUnion type representing a connection between two internal ECU components.
This model wraps a union of different internal connection types and uses the
typefield as a discriminator to determine which specific connection type is present.Possible types¶
ECUPortToSwitchPortConnection from an ECU port to a switch port.
ECUPortToControllerInterfaceConnection from an ECU port to a controller interface.
SwitchPortToControllerInterfaceConnection from a switch port to a controller interface.
SwitchPortToSwitchPortConnection between two switch ports on the same ECU.
ControllerInterfaceToControllerInterfaceConnection between two controller interfaces.
- class InternalConnection¶
Bases:
FLYNCBaseModelRepresents a base internal connection between two ECU components.
Parameters¶
- typestr
The type of the connection.
- idstr
Unique identifier for the connection.
- component1_namestr, optional
Name of the first component in the connection.
- component2_namestr, optional
Name of the second component in the connection.
Private Attributes¶
- _ecu
ECU The ECU object to which this connection belongs. Managed internally.
- class ECUPortToXConnection¶
Bases:
InternalConnectionBase class for connections from an ECU port to another ECU component.
Parameters¶
- ecu_port_namestr
Name of the ECU port (alias:
ecu_port).
Private Attributes¶
- _ecu_port
ECUPort Internal reference to the actual ECU port object. Managed privately.
- class SwitchPortToXConnection¶
Bases:
InternalConnectionBase class for connections from an ECU switch port to another component.
Parameters¶
- switch_port_namestr
Name of the ECU switch port (alias:
switch_port).
Private Attributes¶
- _switch_port
SwitchPort Internal reference to the actual switch port object. Managed privately.
- class ECUPortToSwitchPort¶
Bases:
ECUPortToXConnectionRepresents a connection from an ECU port to a switch port.
Parameters¶
- typeLiteral[“ecu_port_to_switch_port”]
Type of the connection. Defaults to
"ecu_port_to_switch_port".- switch_port_namestr
Name of the switch port (alias:
switch_port).
Private Attributes¶
- _switch_port
SwitchPort Internal reference to the actual SwitchPort object. Managed privately.
- class ECUPortToControllerInterface¶
Bases:
ECUPortToXConnectionRepresents a connection from an ECU port to a controller interface.
Parameters¶
- typeLiteral[“ecu_port_to_controller_interface”]
Type of the connection. Defaults to
"ecu_port_to_controller_interface".- iface_namestr
Name of the controller interface (alias:
controller_interface).
Private Attributes¶
- _iface
ControllerInterface Internal reference to the actual ControllerInterface object. Managed privately.
- class SwitchPortToControllerInterface¶
Bases:
SwitchPortToXConnectionRepresents a connection from a switch port to a controller interface.
Parameters¶
- typeLiteral[“switch_port_to_controller_interface”]
Type of the connection. Defaults to
"switch_port_to_controller_interface".- iface_namestr
Name of the controller interface (alias:
controller_interface).
Private Attributes¶
- _iface
ControllerInterface Internal reference to the actual ControllerInterface object. Managed privately.
- class SwitchPortToSwitchPort¶
Bases:
SwitchPortToXConnectionRepresents a connection between two switch ports on the same ECU.
Parameters¶
- typeLiteral[“switch_to_switch_same_ecu”]
Type of the connection. Defaults to
"switch_to_switch_same_ecu".- switch2_port_namestr
Name of the second switch port (alias:
switch2_port).
Private Attributes¶
- _switch2_port
SwitchPort Internal reference to the second switch port object. Managed privately.
- class ControllerInterfaceToControllerInterface¶
Bases:
InternalConnectionRepresents a direct connection between two controller interfaces in an ECU.
Parameters¶
- typeLiteral[“controller_interface_to_controller_interface”]
Type of the connection. Defaults to
"controller_interface_to_controller_interface".- iface_namestr
Name of the first controller interface (alias:
controller_interface1).- iface2_namestr
Name of the second controller interface (alias:
controller_interface2).
Private Attributes¶
- _iface
ControllerInterface Internal reference to the first controller interface. Managed privately.
- _iface2
ControllerInterface Internal reference to the second controller interface. Managed privately.
Socket Config¶
- class SocketContainer¶
Bases:
FLYNCBaseModelRepresents a socket container for the ecu.
Parameters¶
- class Socket¶
Bases:
FLYNCBaseModelDefines a virtual-interface socket that is bound to a specific IP address.
Parameters¶
- namestr
A readable identifier for the socket.
- endpoint_address
IPv4AddressorIPv6Address The IP address assigned to the socket.
- port_noint
The port number the socket uses for communication.
- deploymentslist of
DeploymentUnion, optional Deployments of the socket.
- class SocketUDP¶
Bases:
SocketRepresents a UDP socket.
Parameters¶
- protocolLiteral[“udp”]
Transport protocol for the socket. Defaults to
"udp".- udp_options
UDPOption, optional The UDP options that can be configured for this socket.
- class SocketTCP¶
Bases:
SocketRepresents a TCP socket.
Parameters¶
- protocolLiteral[“tcp”]
Transport protocol for the socket. Defaults to
"tcp".- tcp_profileint
The unique identifier of the TCP profile whose options are applied to the socket.
Options¶
- class TCPOption¶
Bases:
DictInstancesTCP options that can be enabled for a connection.
Parameters¶
- tcp_profile_idint
Unique identifier of the TCP profile.
- naglestrict_bool
Enable or disable Nagle algorithm.
- keepalive_enabledbool
Enable or disable the TCP keep-alive option.
- keepidleint
Seconds the connection must stay idle before the first keep-alive probe is sent.
- keepcountint
Maximum number of keep-alive probes that may be sent before the connection is dropped.
- keepintvlint
Seconds between successive keep-alive probes.
- user_timeoutint
Maximum time in seconds that unacknowledged data may remain before the connection is closed.
- congestion_avoidancestr
Congestion-avoidance algorithm to use (e.g.,
Reno,cubic, orbbr).- tcp_maxsegint
Maximum segment size for outgoing TCP packets.
- tcp_quickackbool
Enable or disable the “quick-ack” feature.
- tcp_syncntint
Number of SYN retransmissions TCP may perform before aborting the connection attempt.
- class UDPOption¶
Bases:
FLYNCBaseModelUDP options that can be enabled for a connection.
Parameters¶
- udp_corkbool
Enables buffering of UDP messages before they are sent.
Endpoints¶
- class IPv4AddressEndpoint¶
Bases:
IPv4AddressEntryRepresents an IPv4 address endpoint for a network interface.
Parameters¶
- class IPv6AddressEndpoint¶
Bases:
IPv6AddressEntryRepresents an IPv6 address endpoint for a network interface.
Parameters¶
Deployments¶
- class DeploymentUnion¶
Bases:
RootModelUnion type representing a deployment configuration for a socket. This model wraps a union of different deployment models and uses the
deployment_typefield as a discriminator to determine which specific deployment model is present.Possible types¶
SOMEIPServiceConsumerorSOMEIPServiceProviderorSOMEIPSDDeployment