ModeSwitchInterface

XML tag

<MODE-SWITCH-INTERFACE>

Module

autosar.portinterface

Inherits

autosar.portinterface.PortInteface

Representa a ModeSwitch interface.

Usage

import autosar

ws = autosar.workspace("4.2.2")
modePkg = ws.createPackage('ModeDclrGroups', role = 'ModeDclrGroup')
portInterfacePkg = ws.createPackage('PortInterfaces', role="PortInterface")

modePkg.createModeDeclarationGroup('BswM_Mode', ["POSTRUN",
                                                 "RUN",
                                                 "SHUTDOWN",
                                                 "STARTUP",
                                                 "WAKEUP"], "STARTUP")
portInterfacePkg.createModeSwitchInterface('BSWM_Mode_I', autosar.mode.ModeGroup('mode', '/ModeDclrGroups/BswM_Mode'))
ws.saveXML('PortInterfaces.arxml', filters=['/PortInterfaces'])

Factory Methods

Attributes

For inherited attributes see autosar.portinterface.PortInteface.

Name

Type

Description

modeGroup

:ref:`mode_modeGroup`

mode group

Public Methods

Method Description