DatabaseEthernet

Summary

Represents an Ethernet FIBEX Database

Methods
Properties

Structure

class DatabaseEthernet
compute_crc(payload: Array[uint8], service_id: uint16, method_id: uint16) uint32

Calculates the CRC parameter according to the service identifier of the desired profile and event or field.

Parameters
  • payload (Array[uint8]) – Payload used to compute the desired CRC.

  • service_id (uint16) – Service identifier.

  • method_id (uint16) – Method identifier.

Returns

The value of the CRC parameter

Return type

uint32

compute_origine_crc(payload: Array[uint8], service_id: uint16, method_id: uint16) uint32

Calculates the origin CRC parameter according to the service identifier of the desired profile and event or field.

Parameters
  • payload (Array[uint8]) – Payload used to compute the desired CRC.

  • service_id (uint16) – Service identifier.

  • method_id (uint16) – Method identifier.

Returns

CRC calculated

Return type

uint32

get_all_ecus() List[IECUEthernet]

Extracts all the ECUs from the database and returns them in a list.

Returns

List of all the ECUs of the database.

Return type

List[IECUEthernet]

get_all_services() List[IServiceInterface]

Extracts from the database all the service interfaces defined without taking into account to which ECUs they belong.

Returns

A list containing all the service interfaces defined in the database.

Return type

List[IServiceInterface]

get_channel(name: str) IChannelEthernet

Extracts from the database the channel specified by channel name.

Parameters

name (str) – Name of the channel that is extracted from the database.

Returns

Channel extracted.

Return type

IChannelEthernet

get_consumed_event_groups(service_id: uint16, ecu_name: str) List[IConsumedEventGroup]

Extracts from the database the complete list of services consumed with event groups by the given service identifier and ECU name.

Parameters
  • service_id (uint16) – Service identifier which contains the consumed services with event groups.

  • ecu_name (str) – Name of the ECU which contains the consumed services with event groups.

Returns

A list containing the consumed services with event groups of the given service identifier and ECU name.

Return type

List[IConsumedEventGroup]

get_consumed_instance_ids(service_id: uint16, ecu_name: str) List[uint16]

Extracts from the database the complete list of services consumed by the given service identifier and ECU name.

Parameters
  • service_id (uint16) – service identifier which contains the consumed services.

  • ecu_name (str) – name of the ECU which contains the consumed services.

Returns

A list containing the consumed services of the given service identifier and ECU name .

Return type

List[uint16]

get_consumed_instance_ids_by_ip(service_id: uint16, ecu_name: str, ip: str) List[uint16]

Extracts from the database the complete list of services consumed by the given service identifier, ECU name and IP address.

Parameters
  • service_id (uint16) – Service identifier which contains the consumed services.

  • ecu_name (str) – Name of the ECU which contains the consumed services.

  • ip (str) – IP address which contains the consumed services.

Returns

A list containing the consumed services of the given service identifier, ECU name and IP address.

Return type

List[uint16]

get_consumed_services(ecu_name: str, service_id: uint16) List[IConsumedService]

Extracts from the database the complete list of services consumed by the given ECU.

Parameters
  • ecu_name (str) – Name of the ECU which contains the consumed services.

  • service_id (uint16) – Service identifier.

Returns

A list containing the consumed services of the given ECU.

Return type

List[IConsumedService]

get_consumed_services_by_ecu_id(ECUID: str) Array[IConsumedService]

Extracts from the database the complete list of services consumed by the given ECU ID.

Parameters

ECUID (str) – Id of the ECU which contains the consumed services.

Returns

A list containing the consumed services of the given ECU ID.

Return type

Array[IConsumedService]

get_consumed_services_by_ecu_ip(ecu_name: str, ip: str) Array[IConsumedService]

Extracts from the database the complete list of services consumed by the given ECU name and IP address.

Parameters
  • ecu_name (str) – Name of the ECU which contains the consumed services.

  • ip (str) – IP address of the ECU in case this has several. If no IP address is provided, all the consumed services are returned, no matter from which IP.

Returns

A list containing the consumed services of the given parameters.

Return type

Array[IConsumedService]

get_consumed_services_by_ecu_name(ECUNAME: str) Array[IConsumedService]

Extracts from the database the complete list of services consumed by the given ECU name.

Parameters

ECUNAME (str) – Name of the ECU which contains the consumed services.

Returns

A list containing the consumed services of the given ECU name.

Return type

Array[IConsumedService]

get_consumed_services_by_ip(ecu_name: str, ip: str, service_id: uint16) List[IConsumedService]

Extracts from the database the complete list of services consumed by the given parameters.

Parameters
  • ecu_name (str) – name of the ECU which contains the consumed services.

  • ip (str) – IP address of the ECU in case this has several addresses. If no IP address is provided, all the consumed services are returned, no matter from which IP.

  • service_id (uint16) – service identifier.

Returns

A list containing the consumed services of the given parameters(ECU name,ip address,service id).

Return type

List[IConsumedService]

get_consumed_services_with_eventgroups_by_ecu_id(ECUID: str) List[IConsumedService]

Extracts from the database the complete list of services consumed with event groups by the given ECU identifier.

Parameters

ECUID (str) – Identifier of the ECU which contains the provided services with event groups.

Returns

List of services consumed with event groups

Return type

List[IConsumedService]

get_consumed_services_with_eventgroups_by_ecu_ip(ecu_name: str, ip: str) List[IConsumedService]

Extracts from the database the complete list of services consumed with event groups by the given ECU name and IP address.

Parameters
  • ecu_name (str) – Name of the ECU which contains the provided services with event groups.

  • ip (str) – IP address of the ECU which contains the provided services with event groups.

Returns

A list containing the provided services with event groups of the given ECU name and IP address.

Return type

List[IConsumedService]

get_consumed_services_with_eventgroups_by_ecu_name(ECUNAME: str) List[IConsumedService]

Extracts from the database the complete list of services consumed with event groups by the given ECU name.

Parameters

ECUNAME (str) – Name of the ECU which contains the provided services with event groups.

Returns

A list containing the provided services with event groups of the given ECU name.

Return type

List[IConsumedService]

get_e2e(service_id: uint16, method_id: uint16) IE2EInformation

Extracts from the database the Configuration of End-to-End Communication Protection according to the given service and event or field.

Parameters
  • service_id (uint16) – Service identifier.

  • method_id (uint16) – Method identifier.

Returns

CRC profile of the given identifier.

Return type

IE2EInformation

get_ecu_by_identifier(id: str) IECUEthernet

Extracts from the database the ECU specified by its ID.

Parameters

id (str) – ID of the ECU that is extracted from the database.

Returns

ECU object found in the database with the given ID.

Return type

IECUEthernet

get_ecu_by_name(name: str) IECUEthernet

Extracts from the database the ECU specified by its name.

Parameters

name (str) – Name of the ECU that is extracted from the database.

Returns

ECU object found in the database with the given name.

Return type

IECUEthernet

get_ecus_by_ip(ip: str) Array[IECUEthernet]

Extracts from the database a list with all the defined ECUs containing the given IP address.

Parameters

ip (str) – IP address of the ECUs that is extracted from the database.

Returns

A list containing all the ECU objects found in the database with the given IP address.

Return type

Array[IECUEthernet]

get_event_by_id(service_id: uint16, method_id: uint16) Event

Extracts from the database a list of event for the given service and method identifiers.

Parameters
  • service_id (uint16) – Service identifier.

  • method_id (uint16) – Method identifier.

Returns

A list containing all the event objects found in the database for the given service and method identifiers.

Return type

Event

get_event_group_by_id(service_id: uint16, event_group_id: uint16) IEventGroup

Extracts from the database a list of event group for the given service and event group identifiers.

Parameters
  • service_id (uint16) – Service identifier.

  • event_group_id (uint16) – Event group identifier.

Returns

A list containing all the event group objects found in the database for the given service and event group identifiers.

Return type

IEventGroup

get_eventgroups_by_service(ServiceID: uint16) Array[IEventGroup]

Extracts from the database a list of event groups for the given service identifier.

Parameters

ServiceID (uint16) – Service identifier.

Returns

A list containing all the event groups objects found in the database for the given service identifier.

Return type

Array[IEventGroup]

get_events_by_service(ServiceID: uint16) Array[Event]

Extracts from the database a list of event for the given service identifier.

Parameters

ServiceID (uint16) – Service identifier.

Returns

A list containing all the event objects found in the database for the given service identifier.

Return type

Array[Event]

get_field_by_id(service_id: uint16, method_id: uint16) Field

Extracts from the database a list of Field for the given service and method identifiers.

Parameters
  • service_id (uint16) – Service identifier.

  • method_id (uint16) – Method identifier.

Returns

A list containing all the Field objects found in the database for the given service and method identifiers.

Return type

Field

get_fields_by_service(ServiceID: uint16) Array[Field]

Extracts from the database a list of Field for the given service and method identifiers.

Parameters

ServiceID (uint16) – Service identifier.

Returns

A list containing all the Field objects found in the database for the given service identifier.

Return type

Array[Field]

get_find_entries(ecu_name: str, service_id: uint16, including_all_services: bool) Array[Entry]

Extracts from the database a list of Entry for the given service identifier.

Parameters
  • ecu_name (str) – Name of the desired ECU.

  • service_id (uint16) – service identifier.

  • including_all_services (bool) – True if search is in all services, False if not.

Returns

A list containing all the Entry objects found in the database for the given service identifier.

Return type

Array[Entry]

get_find_entries_by_ip(ecu_name: str, ip: str, service_id: uint16, including_all_services: bool) Array[Entry]

Extracts from the database a list of Entry for the given service and method identifiers.

Parameters
  • ecu_name (str) – Name of the desired ECU.

  • ip (str) – IP address of the desired ECU.

  • service_id (uint16) – service identifier.

  • including_all_services (bool) – True if search is in all services, False if not.

Returns

A list containing all the Entry objects found in the database for the given service and method identifiers.

Return type

Array[Entry]

get_input_parameters_by_identifier(service_id: uint16, method_id: uint16) Array[Parameter]

Extracts from the database a list of input parameters for a certain method by the identifier.

Parameters
  • service_id (uint16) – Service identifier.

  • method_id (uint16) – Method identifier.

Returns

A list containing all the input parameters objects found in the database for the given identifier.

Return type

Array[Parameter]

get_instance_id_by_service(ServiceID: uint16) Array[uint16]

Gets a list of valid instance IDs for a certain service.

Parameters

ServiceID (uint16) – Service identifier.

Returns

A list containing the instance IDs for the given service.

Return type

Array[uint16]

get_mac_multicast_group(name: str) IMacMulticastGroup

Extracts from the database the mac multicast group specified by mac name.

Parameters

name (str) – Name of the mac that is extracted from the database.

Returns

Mac multicast group.

Return type

IMacMulticastGroup

get_mac_multicast_groups() List[IMacMulticastGroup]

Extracts from the database all of the mac multicast addresses from mac multicast groups

Returns

Mac multicast group.

Return type

List[IMacMulticastGroup]

get_method_by_id(service_id: uint16, method_id: uint16) Method

Gets a list of Method for the given service and method identifiers.

Parameters
  • service_id (uint16) – Service identifier.

  • method_id (uint16) – Method identifier.

Returns

A list containing methods for the given service and method identifiers.

Return type

Method

get_methods_by_service(ServiceID: uint16) Array[Method]

Gets a list of Method for the given service identifier.

Parameters

ServiceID (uint16) – Service identifier.

Returns

A list containing methods for the given service identifier.

Return type

Array[Method]

get_offer_entries(ecu_name: str, service_id: uint16, including_all_services: bool) Array[Entry]

Gets a list of the offer entries.If including_all_services = True, you will have all offer entries of consumed and provided services, if including_all_services = False you will have only the offer entries of the provided services

Parameters
  • ecu_name (str) – Name of the desired ECU .

  • service_id (uint16) – Identifier of the service containing the method.

  • including_all_services (bool) – True if search is in all services, False if not.

Returns

A list of offer entries.

Return type

Array[Entry]

get_offer_entries_by_ip(ecu_name: str, ip: str, service_id: uint16, including_all_services: bool) Array[Entry]

Gets a list of the offer entries.If including_all_services = True, you will have all offer entries of consumed and provided services, if including_all_services = False you will have only the offer entries of the provided services

Parameters
  • ecu_name (str) – Name of the desired ECU .

  • ip (str) – IP address of the desired ECU.

  • service_id (uint16) – Identifier of the service containing the method.

  • including_all_services (bool) – True if search is in all services, False if not.

Returns

A list of the offer entries.

Return type

Array[Entry]

get_output_parameters_by_identifier(service_id: uint16, method_id: uint16) Array[Parameter]

Extracts from the database the complete list of Parameters by the given service identifier and method identifier.

Parameters
  • service_id (uint16) – Service identifier.

  • method_id (uint16) – Method identifier.

Returns

A list of the parameters.

Return type

Array[Parameter]

get_path() str

Gets the path of the database.

Returns

The path of the database

Return type

str

get_provided_instance_ids(service_id: uint16, ecu_name: str) List[uint16]

Gets the instance ids associated with a service that is contained in the list of the provided services by an ECU.

Parameters
  • service_id (uint16) – Identifier of the service to search.

  • ecu_name (str) – Name of the ECU for which the list of provided instances is requested.

Returns

A list of instance ids provided by the ECU for the given service.

Return type

List[uint16]

get_provided_instance_ids_by_ip(service_id: uint16, ecu_name: str, ip: str) List[uint16]

Gets the instance ids associated with a service that is contained in the list of provided services by an ECU.

Parameters
  • service_id (uint16) – Identifier of the service to search.

  • ecu_name (str) – Name of the ECU for which the list of provided instances is requested.

  • ip (str) – IP address of the ECU for which the list of provided instances is requested

Returns

A list of instance ids provided by the ECU for the given service.

Return type

List[uint16]

get_provided_service_by_identifier(serviceID: uint16, instanceID: uint16) IProvidedService

Extracts from the database the complete list of services provided by the given service and instance identifiers.

Parameters
  • serviceID (uint16) – Identifier of the service which contains the provided services.

  • instanceID (uint16) – Identifier of the instance which contains the provided services.

Returns

A list containing the provided services of the given service identifier and instance identifier.

Return type

IProvidedService

get_provided_service_by_service(serviceID: uint16) Array[IProvidedService]

Extracts from the database the complete list of services provided by the given service.

Parameters

serviceID (uint16) – ServiceID, identifier of the service which contains the provided services.

Returns

A list containing the provided services of the given service identifier.

Return type

Array[IProvidedService]

get_provided_services(ecu_name: str, service_id: uint16) List[IProvidedService]

Extracts from the database the complete list of services provided by the given ECU.

Parameters
  • ecu_name (str) – Name of the ECU which contains the provided services.

  • service_id (uint16) – Service identifier.

Returns

A list containing the provided services of the given ECU.

Return type

List[IProvidedService]

get_provided_services_by_ecu_id(ECUID: str) Array[IProvidedService]

Extracts from the database the complete list of services provided by the given ECU identifier.

Parameters

ECUID (str) – Identifier of the ECU which contains the provided services.

Returns

list containing the provided services of the given ECU identifier.

Return type

Array[IProvidedService]

get_provided_services_by_ecu_ip(ecu_name: str, ip: str) Array[IProvidedService]

Extracts from the database the complete list of services provided by the given ECU name and IP address.

Parameters
  • ecu_name (str) – Name of the ECU which contains the provided services.

  • ip (str) – IP address of the ECU which contains the provided services.

Returns

A list containing the provided services of the given ECU name and IP address.

Return type

Array[IProvidedService]

get_provided_services_by_ecu_name(ECUNAME: str) Array[IProvidedService]

Extracts from the database the complete list of services provided by the given ECU name.

Parameters

ECUNAME (str) – Name of the ECU which contains the provided services.

Returns

A list containing the provided services of the given ECU name.

Return type

Array[IProvidedService]

get_provided_services_by_ip(ecu_name: str, ip: str, service_id: uint16) List[IProvidedService]

Extracts from the database the complete list of services provided by the given ECU name and IP address and service identifier.

Parameters
  • ecu_name (str) – name of the ECU which contains the provided services.

  • ip (str) – IP address of the ECU which contains the provided services.

  • service_id (uint16) – service identifier of the ECU which contains the provided services.

Returns

A list containing the provided services of the given ECU name, IP address and service identifier.

Return type

List[IProvidedService]

get_provided_services_with_eventgroups_by_ecu_id(ECUID: str) List[IProvidedService]

Extracts from the database the complete list of services provided with event groups by the given ECU identifier.

Parameters

ECUID (str) – Identifier of the ECU which contains the provided services with event groups.

Returns

A list containing the provided services with event groups of the given ECU identifier.

Return type

List[IProvidedService]

get_provided_services_with_eventgroups_by_ecu_ip(ecu_name: str, ip: str) List[IProvidedService]

Extracts from the database the complete list of services provided with event groups by the given ECU name and IP address.

Parameters
  • ecu_name (str) – The name of the specific ECU.

  • ip (str) – IP address of the specific ECU.

Returns

A list of the provided services with eventgroups.

Return type

List[IProvidedService]

get_provided_services_with_eventgroups_by_ecu_name(ECUNAME: str) List[IProvidedService]

Extracts from the database the complete list of services provided with event groups by the given ECU name.

Parameters

ECUNAME (str) – The name of the specific ECU.

Returns

A list of the provided services with eventgroups.

Return type

List[IProvidedService]

get_service_by_identifier(identifier: uint16) IServiceInterface

Gets from the database the formal description of a service, i.e. the service interface, of the given ID.

Parameters

identifier (uint16) – Service identifier.

Returns

Service interface of the given service ID.

Return type

IServiceInterface

get_signal_by_shortname(name: str) ISignal

Extracts from the database a signals object with the given name.

Parameters

name (str) – Name of the signal.

Returns

Signal object found in database with the given name.

Return type

ISignal

get_signals_by_identifier(service_id: uint16, method_id: uint16) List[ISignal]

Extracts from the database the signals of a field by the given identifier.

Parameters
  • service_id (uint16) – Service identifier.

  • method_id (uint16) – Method identifier.

Returns

A list containing all the signal objects found in the database for the given identifier.

Return type

List[ISignal]

get_stop_find_entries(ecu_name: str, service_id: uint16, including_all_services: bool) Array[Entry]

Gets a list of the stop entries by the given parameters. If including_all_services = True, you will have all the stop entries of the consumed and provided services, if including_all_services = False you will have only the stop entries of the consumed services.

Parameters
  • ecu_name (str) – Name of the desired ECU.

  • service_id (uint16) – Identifier of the service containing the method.

  • including_all_services (bool) – True if search is in all services, False if not.

Returns

A list of the stop entries.

Return type

Array[Entry]

get_stop_find_entries_by_ip(ecu_name: str, ip: str, service_id: uint16, including_all_services: bool) Array[Entry]

Gets a list of the stop entries by the given parameters. If including_all_services = True, you will have all the stop entries of the consumed and provided services, if including_all_services = False you will have only the stop entries of the consumed services.

Parameters
  • ecu_name (str) – Name of the desired ECU.

  • ip (str) – ip of the desired ECU.

  • service_id (uint16) – Identifier of the service containing the method.

  • including_all_services (bool) – True if search is in all services, False if not.

Returns

A list of the stop entries by IP.

Return type

Array[Entry]

get_stop_offer_entries(ecu_name: str, service_id: uint16, including_all_services: bool) Array[Entry]

Gets a list of the stop offer entries. If including_all_services = True, you will have all the stop offer entries of the consumed and provided services, if including_all_services = False you will have only the stop offer entries of the provided services.

Parameters
  • ecu_name (str) – Name of the desired ECU.

  • service_id (uint16) – Identifier of the service containing the method.

  • including_all_services (bool) – True if search is in all services, False if not.

Returns

A list of the stop offer entries.

Return type

Array[Entry]

get_stop_offer_entries_by_ip(ecu_name: str, ip: str, service_id: uint16, including_all_services: bool) Array[Entry]

Gets a list of the stop offer entries. If including_all_services = True, you will have all the stop offer entries of the consumed and provided services, if including_all_services = False you will have only the stop offer entries of the provided services.

Parameters
  • ecu_name (str) – Name of the desired ECU.

  • ip (str) – IP address of the desired ECU .

  • service_id (uint16) – Identifier of the service containing the method.

  • including_all_services (bool) – True if search is in all services, False if not.

Returns

A list of the stop offer entries by IP.

Return type

Array[Entry]

get_stop_subscribe_event_group_entries(ecu_name: str, service_id: uint16, including_all_services: bool) Array[Entry]

Gets a list of the stop subscribe event group entries. If including_all_services = True, you will have all stop subscribe eventgroup entries of consumed and provided services, if including_all_services = False you will have only the stop subscribe eventgroup entries of the provided services.

Parameters
  • ecu_name (str) – Name of the desired ECU.

  • service_id (uint16) – Identifier of the service containing the method.

  • including_all_services (bool) – True if search is in all services, False if not.

Returns

A list of the stop which subscribes event group entries.

Return type

Array[Entry]

get_stop_subscribe_event_group_entries_by_ip(ecu_name: str, ip: str, service_id: uint16, including_all_services: bool) Array[Entry]

Gets a list of the stop which subscribes event group entries. If including_all_services = True, you will have all the stop that subscribes event group entries of the consumed and provided services, if including_all_services = False, you will have only the stop which subscribes event group entries of the provided services.

Parameters
  • ecu_name (str) – Name of the desired ECU.

  • ip (str) – IP address of the desired ECU.

  • service_id (uint16) – Identifier of the service containing the method.

  • including_all_services (bool) – True if search is in all services, False if not.

Returns

A list of the stop that subscribes event group entries.

Return type

Array[Entry]

get_subscribe_event_group_entries(ecu_name: str, service_id: uint16, including_all_services: bool) Array[Entry]

Gets a list of the subscribe event group entries. If including_all_services = True, you will have all the event group entries of the consumed and provided services, if including_all_services = False you will have only the event groups entries of the provided services.

Parameters
  • ecu_name (str) – Name of the desired ECU.

  • service_id (uint16) – Identifier of the service containing the method.

  • including_all_services (bool) – True if search is in all services, False if not.

Returns

A list of the subscribe event group entries.

Return type

Array[Entry]

get_subscribe_event_group_entries_by_ip(ecu_name: str, ip: str, service_id: uint16, including_all_services: bool) Array[Entry]

Gets a list of the stop entries. If including_all_services = True, you will have all the stop entries of the consumed and provided services, if including_all_services = False, you will have only the stop entries of the provided services.

Parameters
  • ecu_name (str) – Name of the desired ECU. find_provided_service_instances

  • ip (str) – ip of the desired ECU.

  • service_id (uint16) – Identifier of the service containing the method.

  • including_all_services (bool) – True if search is in all services, False if not.

Returns

A list of the subscribe event group entries.

Return type

Array[Entry]

couplings

Extracts from the database the list of coupling elements.

Type

IReadOnlyCollection[CouplingElement]