User Manual SOMEIP
User Manual SOMEIP
User Manual SOMEIP
Part 1. Introduction
V1.0 | 2023-07-18
Agenda
u Overview
Communication Setup
Technical References
Summary
2
Overview
2 perspectives on SOME/IP communication
Switch
ECU 1 ECU 2
SOME/IP Data
ECU 2
Service
Signals PDU (Static Layout) PDU (Dynamic Layout) Consumer
3
Overview
SOME/IP Support in CANoe
CANoe
4
Overview
SOME/IP in Communication Setup
Calculator
Consumer
u Service Communication Object is defined by
u Service interface type interface Calculator {
> Method method float Add(int, int);
> Event
method float Substract(int, int);
> Field
method float Multiply(int, int);
u End points method float Divide(int, int);
> Provider / Consumer
field int32 CalcResult {get;set;notify;}
> Switched to simulated or real
event struct State {
int AddCount;
int SubstractCount;
int MultiplyCount;
int DivideCount;
}
} Calculator
Provider
Any pair of endpoints may:
… connect distinct physical devices, or
… share a MAC address on the same PHY, or
… share an IP address, or
… connect abstract simulation code.
5
Overview
SOME/IP in Communication Setup
6
Overview
SOME/IP in Communication Setup
u SOME/IP Binding
u Enables transmission between endpoints base on SOME/IP via TCP/UDP/IP and Ethernet
u Supports SOME/IP, SOME/IP Service Discovery protocol
u Communication Object can be linked with SOME/IP Binding through Abstract Binding
7
Overview
SOME/IP in Communication Setup
8
Overview
Terms in CANoe
- Data Source - vCDL The acronym vCDL stands for Vector Communication Descrip
tion Language and is a domain-specific language (DSLClosed
) for the description of communication objects in CANoe.
Interaction layer Binding The binding replaces the interaction layer concept. It links ab
stract communication objects and distributed objects to conc
rete bus systems and protocols.
Simulation Node Application Model Application Logic is implemented as a Application Model via
CAPL programming
9
Agenda
Overview
u Communication Setup
Technical References
Summary
10
Communication Setup
Overview
u The Communication Setup is the central starting point for communication configuration.
u the application layer (application models)
u the communication layer (communication, bindings)
u the transmission medium (hardware, bindings)
11
Communication Setup
Window Layout
u System View
u Application Layer Objects : Display ‘Namespaces – Participants – Services’
u Application Models : Programming ‘CAPL’ or ‘C#’
u Data Sources : ‘vCDL’ which includes SOME/IP configuration
12
Communication Setup
Workflow Example
Step 0
Prepare Sample vCDL, CAPL Step 1
files -> Download
Start by creating a new
Ethernet configuration
Step 2
Switch to tab Simulation
Step 3
Open dialog by clicking
Communication Setup
14
Communication Setup
Workflow 1 – Import Data Source
Step 4
Click Data Sources to
open the import view
Step 5
Click „Load Data Source” Button
and select vCDL file
15
Communication Setup
Workflow 1 – Check Import Result
Step 7 (optional)
Step 6
Imported services
A successful import is
and data types can
indicated by the green
be modified via this
button
Button
Step 9
Switch Participant to
Simulated(CANoe) or
Real(Device) Mode
Step 8
The imported
elements are shown
in a Details
16
Communication Setup
Workflow 1 – Configure Application Models
Step 10
Assign the application
models(CAPL, C#)
Step 11
Edit the application
models(CAPL, C#)
17
Communication Setup
Workflow 1 – Implement Application Models
consumer.can provider.can
// Call method 'Add' of service 'Calculator' when key 'c' is pressed on start
on key 'c' {
{ // Set timer to cyclic interval of 1000 milliseconds
CommunicationObjects::Calculator[Consumer,Provider].Add.CallAsync(3,6); setTimerCyclic(stateEventTimer, 1000);
} }
// This handler is called when the return value of method 'Add' of service 'Calculator' is on timer stateEventTimer
received
{
on fct_returned CommunicationObjects::Calculator[Consumer,Provider].Add
// Update state event. This will also trigger the transmission of the event
{
$CommunicationObjects::Calculator[Provider].State.AddCount = gAddCount;
// Print result in the Write Window of CANoe
$CommunicationObjects::Calculator[Provider].State.SubtractCount = gSubtractCount;
write("Result of Add method: %f", this.result);
$CommunicationObjects::Calculator[Provider].State.MultiplyCount = gMultiplyCount;
}
$CommunicationObjects::Calculator[Provider].State.DivideCount = gDivideCount;
}
Implement the following application // Update CalcResult Field. This will also trigger the transmission of the field notification
18
Communication Setup
Workflow 1 – Implement Application Models
Step 13
Step 14
Start measurement
Switch to
Communication
Object column
view
Step 15
Press key „c“
You can observe the method call
from Consumer in the trace
window
19
Communication Setup
Workflow 2 – Partial Simulation with a Real Target
20
Agenda
Overview
Communication Setup
u Technical References
Summary
21
Technical References
Video Recording
22
Technical References
Calculator Example
23
Technical References
CANoe Help Manual
24
Agenda
Overview
Communication Setup
Technical References
u Summary
25
Summary
This document is for …
26
For more information about Vector
and our products please visit
www.vector.com
Author:
Lee, Jaecheol
Vector Korea
27 © 2023. Vector Korea IT Inc. All rights reserved. Any distribution or copying is subject to prior written approval by Vector. V1.0 | 2023-07-18