100% found this document useful (1 vote)
4K views30 pages

Startup: Davinci Developer

Uploaded by

Vinay Logun
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
100% found this document useful (1 vote)
4K views30 pages

Startup: Davinci Developer

Uploaded by

Vinay Logun
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 30

Startup

DaVinci Developer
Content Startup with DaVinci Developer

Content

1 About This Manual 1

1.1 Finding Information Quickly 1

1.2 Conventions 1

1.3 Certification 2

1.4 Warranty 2

1.5 Support 3

1.6 Trademarks 3

1.7 What Do You Learn from This Manual 3

2 DaVinci Developer 1

2.1 DaVinci Developer Workspace 1

2.1.1 Standalone Workspace 1

2.1.2 Workspace Part of a DaVinci Project 2

3 Software Component (SWC) Design 4

3.1 About Application Components, Ports, Connections, Runnables and More… 4

3.2 Application Components 4

3.2.1 The Object Browser – Types, Packages and Files 5

3.2.2 New Application Components 8

3.2.3 Understand Types, Prototypes and Interfaces 12

3.3 Ports, Port Init Values and Data Elements 13

3.4 Configure Service Ports within your Application Components 17

3.5 Define your Runnables 18

3.6 Triggers for the Runnables 19

3.7 Port Access of the Runnables 21

3.8 Templates and Contract Phase Headers 22

© Vector Informatik GmbH Version 1.0.0 - 1-


About This User Manual Startup with DaVinci Developer

1 About This Manual

1.1 Finding Information Quickly

The user manual provides the following access help:

> You can see in the footer to which version the user manual refers,
> At the end of the user manual you will find an index to find information quickly,
> Also at the end of the user manual you will find a glossary of the used technical terms

1.2 Conventions

In the following two charts you will find the conventions used in the user manual regarding utilized
spellings and symbols.

Style Style Utilization


bold Blocks, surface elements, window- and dialog names of the software. Accentuation
of warnings and advices.

[OK] Push buttons in brackets

File|Save Notation for menus and menu entries


MICROSAR Legally protected proper names and side notes.
Source Code File name and source code.
Hyperlink Hyperlinks and references.
<CTRL>+<S> Notation for shortcuts.

© Vector Informatik GmbH Version 1.0.0 - 1-


About This User Manual Startup with DaVinci Developer

Symbol Symbol Utilization


Here you can obtain supplemental information.

This symbol calls your attention to warnings.

Here you can find additional information.

Here is an example that has been prepared for you.

Instructions on editing files are found at these points.

This symbol warns you not to edit the specified file.

This icon indicates multimedia files like e.g. video clips.

This icon indicates an introduction into a specific topic.

This icon indicates text areas containing basic knowledge.

This icon indicates text areas containing expert knowledge.

This icon indicates that something has changed.

1.3 Certification

Vector Informatik GmbH has ISO 9001:2008 certification. The ISO standard is a globally recognized
standard.

1.4 Warranty

We reserve the right to modify the contents of the documentation or the software without notice.
Vector disclaims all liabilities for the completeness or correctness of the contents and for damages

© Vector Informatik GmbH Version 1.0.0 - 2-


About This User Manual Startup with DaVinci Developer

which may result from the use of this documentation.

1.5 Support

Germany
And all other countries, not listed here.

+ 49 711 80670 3900


[email protected]
BR CN
Brazil, Argentina, Bolivia, Chile, Ecuador, Colombia, China
Paraguay, Peru, Uruguay, Venezuela

+55 11 5180 2350 +86 21 6432 5353


[email protected] [email protected]
FR IN
France India

+33 1 42 31 40 10 +91 20 6634 6634


[email protected] [email protected]
IT JP
Italia Japan

+39 2 678171 10 TOKYO +81 3 5769 6972


[email protected] NAGOYA +81 52 238 5014
[email protected]
KR Scandinavia
South Korea Sweden, Denmark, Finland, Iceland, Norway

+82 2 807 0600 +46 31 764 76 00


[email protected] [email protected]
UK North America
United Kingdom & Ireland USA, Canada, Mexico

+44 121 7887 902 +1 248 449 9290, Option 2


[email protected] [email protected]

1.6 Trademarks

All brand names in this documentation are either registered or non registered trademarks of their
respective owners.

1.7 What Do You Learn from This Manual

Use this document to

> Set up your project in just a few steps


> Learn how to work with AUTOSAR means like software components, runnables, etc.

© Vector Informatik GmbH Version 1.0.0 - 3-


About This User Manual Startup with DaVinci Developer

Note

If you habe a SIP from Vector you also find the same content in the SIP Startup Guide.

© Vector Informatik GmbH Version 1.0.0 - 4-


DaVinci Developer Startup with DaVinci Developer

2 DaVinci Developer

DaVinci Developer is a Vector tool for designing the architecture of a software component (SWC) for
AUTOSAR ECUs.

Via a graphical view or textual grid views you can design software components including ports, data
types, connectors and internal behavior. With the consistency check you verify the AUTOSAR com-
pliance of your SWC design.

2.1 DaVinci Developer Workspace

DaVinci Developer operates on a workspace (DCF file).

2.1.1 Standalone Workspace

If you don’t work in combination with DaVinci Configurator Pro you start with creating a new work-
space via the File menu. It is recommended to create the new workspace in a blank folder on your
disk.

© Vector Informatik GmbH Version 1.0.0 - 1-


DaVinci Developer Startup with DaVinci Developer

Note

Some editors of the DaVinci Developer, e.g. the Data Mapping Editor, will not be available
in such standalone workspaces.

2.1.2 Workspace Part of a DaVinci Project

If you work in combination with DaVinci Configurator Pro, the DaVinci project created with DaVinci
Configurator Pro already contains a DaVinci Developer workspace. You don’t need to create it sep-
arately.

You edit the content of the workspace with DaVinci Developer. After saving the workspace, DaVinci
Configurator Pro will detect the change and reload the data automatically.

© Vector Informatik GmbH Version 1.0.0 - 2-


DaVinci Developer Startup with DaVinci Developer

Caution!

Keep in mind that the DaVinci Configurator Pro is not able to write to DCF file.

© Vector Informatik GmbH Version 1.0.0 - 3-


Software Component Design Startup with DaVinci Developer

3 Software Component (SWC) Design

3.1 About Application Components, Ports, Connections, Runnables and More…

Learn all about application components, ports, connection and runnables, how they work and how to
exchange information between application components.

1. Application Components

2. Ports, Port Init Values and Data Elements

3. Connections

4. Runnables

5. Triggers

6. Port Access

7. Data Mapping

Cross Reference

To get basic tool handling information, refer to the online help of the DaVinci Developer.

3.2 Application Components

To create application components use the DaVinci Developer.

© Vector Informatik GmbH Version 1.0.0 - 4-


Software Component Design Startup with DaVinci Developer

3.2.1 The Object Browser – Types, Packages and Files

The Object Browser is the central view of all design objects in the workspace. Open it via the toolbar.

Types, Package or Files?

The Object Browser you use in the following steps can basically be used in different ways.

> Type-oriented
> Package-oriented
> File-oriented

The type-oriented workflow is shown in the following steps. But you can also choose the package-ori-
ented or file-oriented one. This concept will now be described briefly.

Packages

With Packages you can pack elements together like:

> Application Component Types


> Service Component Types
> Data Types
> Constants
> Mode Declaration Groups
> Application Port Interfaces
> Service Port Interfaces

It is like a kind of grouping with its own name space. A name of an object has to be unique within a
package but can be used more than once within the project.

© Vector Informatik GmbH Version 1.0.0 - 5-


Software Component Design Startup with DaVinci Developer

These packages can be exported and imported for round-tripping with other tools also supporting the
packages.

Switch to package view

At the bottom of the Object Browser you can select Types view, Packages view or Files view. Select
the Package.
You need a Root Package first? Create it via right-click in the Packages view.

New Child Package…

Then right-click the root (e.g. MyECU_PartA) and you will get to the context menu. Use New Child Pack-
age to nest the packages or you put the objects plain below the root package.

Context Menu for the Packages

© Vector Informatik GmbH Version 1.0.0 - 6-


Software Component Design Startup with DaVinci Developer

Files

Within the Files tab you

> can see all AUTOSAR design objects, which are loaded from the particular file.
> move objects to other files.

© Vector Informatik GmbH Version 1.0.0 - 7-


Software Component Design Startup with DaVinci Developer

Note

The Files tab is not editable, if you want to add or delete files you have to move to the File
Browser.

3.2.2 New Application Components

Right-click on Application Component Types in the Object Browser and select New Application Com-
ponent Type....

© Vector Informatik GmbH Version 1.0.0 - 8-


Software Component Design Startup with DaVinci Developer

It is good to give a speaking name to see what kind of component it is. e.g. AP – Application, SA –
Sensor / Actuator

Enter a Name for the Application Component Type. Select Composition if the SWC should contain other
SWC or select Atomic. Select its Type and confirm with [OK]. All application software component types
are displayed in the Object Browser.

© Vector Informatik GmbH Version 1.0.0 - 9-


Software Component Design Startup with DaVinci Developer

Note

To get fast information about any element in the Object Browser just select one and see
its Properties, Port Prototypes (if available) and Description in the Properties view (right
side).

© Vector Informatik GmbH Version 1.0.0 - 10-


Software Component Design Startup with DaVinci Developer

Component types become component prototypes by being used.

Double-click the SWC in the Object Browser or click Software Design to open the Software Design
view for your ECU project (e.g. MyECU).

Note

In the graphical representation of an application component prototype you can change its
size using the little squares shown at the angles and in the middle of the sides.

An application component type becomes an application component prototype when it is used. It also
needs a name. Using drag’n’drop, both names are the same. Open the properties window from the con-
text menu for a component prototype to change the prototype name.

© Vector Informatik GmbH Version 1.0.0 - 11-


Software Component Design Startup with DaVinci Developer

Note

Drag’n’drop is not possible within Tabbed Layout.

Define and use as many application software components as you need for your ECU.

Note

The notation of the software component starts with the software component prototype fol-
lowed by the software component type.

3.2.3 Understand Types, Prototypes and Interfaces

This illustration will help you to understand working with the DaVinci Developer. You have to deal with

> Prototype
> Type
> Interface

When is a software component a software component type, when a software component prototype?
When is a port a port interface, when a port prototype?

In theObject Browser, the software components are types, the ports are interfaces. As soon as you
use them, they become prototypes.

> Port Interface used by a component type â Port Prototype


> Component Type in Object Browser used in software design view âComponent Prototype

Runnables are always connected to the component type.

© Vector Informatik GmbH Version 1.0.0 - 12-


Software Component Design Startup with DaVinci Developer

3.3 Ports, Port Init Values and Data Elements

To communicate and to exchange information the components need so-called ports (S/R ports).

For communication between software component ports have to be defined.

There are different kinds of application/service ports,

> Sender Ports to provide information


> Receiver Ports to receive information
> Sender/Receiver Ports to provide and receive information within one port

> Server Ports to provide services (operations)


> Client Ports to use services (operations)

The following ports are listed here for completeness.

> Calibration Ports to hand over calibration parameters


> Mode Ports to e.g. trigger or not trigger runnables within certain modes

Before you can use application ports you have to define application port interfaces. To completely
define the port interfaces you have to define data types first, if you don’t want to use the predefined
ones.

Predefined data types in Object Browser

Just right-click and select from the list.

Caution!

You can handle application port interfaces like application component types. Define the
application port interfaces in the Object Browser and then use them as application port pro-
totypes for each application component. The same applies for data types and data ele-
ments.

Create Port Interface

To define a new application port interface, right-click the Application Port Interface in the Object
Browser and select New S/R Port Interface….

© Vector Informatik GmbH Version 1.0.0 - 13-


Software Component Design Startup with DaVinci Developer

Then the window for the S/R Port Interface opens. Enter a name, select the tab Data Element Pro-
totypes and define the content of the port. In this case it is just one data element called OnOff with
the Data Type Boolean, use the button […] to select Data Type.

Note

Data elements are the contents of ports.

© Vector Informatik GmbH Version 1.0.0 - 14-


Software Component Design Startup with DaVinci Developer

Note

A port interface can carry many data elements of different data types.

Provide software components with ports

> You have created your application software components.


> You have created necessary application ports interfaces and their content (data element pro-
totypes).

Now you have to define which application component needs which application ports.

© Vector Informatik GmbH Version 1.0.0 - 15-


Software Component Design Startup with DaVinci Developer

Add ports to the application components via drag’n’drop

Select an application port interface from the Object Browser and place it onto the application com-
ponent via drag’n’drop. This transfers a port interface into a port prototype.

Note

Press <Ctrl> while drag’n’drop to change between sender or receiver port.

Interfaces

The ports are added to the components as graphical element together with the name of the port.

> Sender port


> Receiver port

Note

Ports need Init Values.

© Vector Informatik GmbH Version 1.0.0 - 16-


Software Component Design Startup with DaVinci Developer

Port Init Values

You have to assign an initial value to every used application port.

3.4 Configure Service Ports within your Application Components

Your Service Components will be loaded automatically to the DaVinci Developer workspace .

Note

The DaVinci Configurator stores the service components within the folder <Project Folder-
>\Config\ServiceComponents.

The content of the service components are not part of the DaVinci Developer workspace.

Service Port Interface name and content depend on the BSW configuration and version of
the service component within the DaVinci Configurator, so it is not stable.

If you want to connect one of your Application Component to a Service Component, you have to define
a Service Port Prototype based on a Service Port Interface.

To avoid implicit modification of the Application Components, they should not use these Service Port
Interfaces directly. Instead, they should use an own copy of the Service Port Interfaces.

The Service Port Interface definition from the loaded Service Component is always in read-only status.
These Service Port Interfaces are marked with a read-only icon within the Object Browser.

You have currently not defined your Service Port Interfaces?

Then copy and paste the definition from the Service Component. Assign the definition to an own pack-
age, so it is possible to use the same name as before. Therefore open the Service Port Interface,
select Package tab and choose a package via [...].

© Vector Informatik GmbH Version 1.0.0 - 17-


Software Component Design Startup with DaVinci Developer

Assign your copied Service Port Interface to your Application Component. Therefore open your Applic-
ation Component Prototype, select Port Prototype List1, open Service Ports tab and add your Service
Port via [New] | From Port Interface. Now the Service Port used by your Application Component is
independent from the Service Component description.

Note

If incompatible changes apply these will be reported by RTE checks.

3.5 Define your Runnables

Now configure runnables that will carry your code.

There are four important topics for a runnable:

> SYMBOL and NAME – what the runnable skeleton is called in the template file
> TRIGGER – when is the runnable executed
> PORT ACCESS – what data can the runnable access
> MAPPING – in which task context does the runnables work?

Caution!

Runnables can only be defined for atomic application components types.

Note

The runnable skeletons are generated by the DaVinci Configurator Pro/the RTE and can then
be accomplished with your code. Find more details follow in the next chapters.

Check also later hints to template generation

© Vector Informatik GmbH Version 1.0.0 - 18-


Software Component Design Startup with DaVinci Developer

1. Open a software component via the Object Browser or the Software Design view.
2. Click on the runnable icon [fx].
3. Click [New] and select Runnable.
4. Enter Name and Symbol for the new runnable on the Properties tab.

If you leave the Symbol field empty, the runnables (functions) will be named according to the entry in
the Name field.

Minimum Start Interval


Define the minimum time interval between the successive triggering of this runnable.

Can Be Invoked Concurrently

A runnable can be marked as Can be invoked concurrently if it can be executed while it is already
running. In other words it can be safely executed concurrently (re-entrant). There are a few criteria
for your implementation code:

> No static (or global) non-constant data


> No return of address to static (or global) non-constant data
> Only work on data provided by caller
> No modification of own code at runtime
> No call of non-re-entrant runnables

3.6 Triggers for the Runnables

The trigger decides when a runnable is executed.

© Vector Informatik GmbH Version 1.0.0 - 19-


Software Component Design Startup with DaVinci Developer

Select the tab Trigger. On this tab you select when your runnable should be executed.

Note

A runnable can be triggered periodically or via an event.

Periodical: Select the checkbox and enter the cycle time.

On Data Reception: As soon as data is received at the appropriate port the runnable is
activated. (Indication)

The trigger On Operation Invocation belongs to service ports and will be explained later.

The runnable of the demo application only needs to be called when the state of the doors is changed.
This can be realized via a cyclic polling or directly by a trigger from the doors. In the demo, Peri-
odical… is chosen.

Note

When experimenting with the demo, replace the cyclic trigger with two triggers On Data
Reception…, one for the left and one for the right front door.

© Vector Informatik GmbH Version 1.0.0 - 20-


Software Component Design Startup with DaVinci Developer

3.7 Port Access of the Runnables

Define which port information each runnable should be able to read or write. Select the tab Port
Access. You only get displayed accessible ports.

You can define access to

> Read Data… and


> Write Data…
> and later when using client server port also to operations (Invoke Operations).

Click e.g. Read Data… and the Port Access Definition:Read Data window will open.

© Vector Informatik GmbH Version 1.0.0 - 21-


Software Component Design Startup with DaVinci Developer

Summary

Summary of the settings for your runnable MySWC_Code:

> The runnable is called MySWC_Code


> Its functional representation is called: MySWC_Code.
> It is triggered periodically
> The runnable has access to the state of the left and right door and to the data of the front interior
light. It also has access to the LightDimControl.

3.8 Templates and Contract Phase Headers

If you plan to implement the SWC manually (rather than with a model-based code generator), you
may generate a SWC Templates and Contract Header Files.

To generate code you select the SWC in the Object Browser and call the code generator via the context
menu.

Note

DaVinci Developer Option CPG is required for the generation.

© Vector Informatik GmbH Version 1.0.0 - 22-


Software Component Design Startup with DaVinci Developer

The design of the SWC including ports, runnables and port access influences the SWC Templates and
Contract Header Files you generate with DaVinci Developer.

In the header of the runnable’s skeleton you will find a list with all available API functions for this run-
nable. If any access is missing, check whether the Port Access is set correctly.

© Vector Informatik GmbH Version 1.0.0 - 23-


Get more Information!

Visit our Website for:


> News
> Products
> Demo Software
> Support
> Training Classes
> Addresses

www.vector.com

You might also like