Skip to content

Commit

Permalink
Clarify usage of super-dense time instants (#106)
Browse files Browse the repository at this point in the history
* Clarify usage of super-dense time instants

---------

Co-authored-by: Benedikt Menne <BenediktM@dspace.de>
  • Loading branch information
bmenne-dspace and Benedikt Menne authored Jan 28, 2025
1 parent 2aa2a4e commit c2c0fba
Show file tree
Hide file tree
Showing 6 changed files with 26 additions and 20 deletions.
2 changes: 1 addition & 1 deletion ls-bus-guide/0___preamble.adoc
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
The FMI LS Bus Implementers' Guide is a free resource intended to give non-normative recommendations and guidance to implementers of the Functional Mock-up Interface layered standard Network Communication (FMI-LS-BUS).
The FMI-LS-BUS Implementers' Guide is a free resource intended to give non-normative recommendations and guidance to implementers of the Functional Mock-up Interface layered standard Network Communication (FMI-LS-BUS).
This document is continually revised based on implementer and user feedback and input.
All of the content is to be considered non-normative and shall not be considered to supplant any normative statement in the FMI 3.0 standard, the FMI-LS-BUS layered standard, or any other standard or layered standard.
https://github.com/modelica/fmi-guides/releases[Releases] and https://github.com/modelica/fmi-guides/issues[issues] can be found on https://github.com/modelica/fmi-guides[github.com/modelica/fmi-guides].
Expand Down
8 changes: 7 additions & 1 deletion ls-bus-guide/4____network_abstraction.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ This chapter contains details on common topics of the network abstraction layer.
This chapter contains details on CAN, CAN FD, CAN XL specific topics.

==== Getting Started with CAN, CAN FD and CAN XL [[low-cut-can-getting-started-with-can]]
This section shows the exemplary implementation in conjunction with the provided header files of the fmi-ls-bus layered standard.
This section shows the exemplary implementation in conjunction with the provided header files of the FMI-LS-BUS layered standard.

===== Provided Header Files [[low-cut-can-getting-started-provided-header-files]]
Besides the textual specification for FMUs with bus support, the Layered Standard for Network Communication also provides a C API to make the creation of FMUs with bus support as easy and generalized as possible.
Expand Down Expand Up @@ -350,6 +350,9 @@ FMU 1 receives a `Confirm` operation, because the specified frame with CAN ID 15
[#figure-can-arbitration-overview]
image::can_arbitration_overview.svg[width=80%, align="center"]

_[Note: The path shown represents the intended approach.
Other implementations may also be valid according to the FMI specification.]_

===== CAN Arbitration with Buffering [[low-cut-can-example-can-arbitration-with-buffering]]
<<#figure-can-arbitration-overview-with-buffer>> shows the realization of a CAN arbitration by using the `Arbitration Lost Behavior` option `BUFFER_AND_RETRANSMIT` within the `Configuration` operation.
At the beginning, FMU 1 and FMU 2 each send network data at the same time.
Expand All @@ -366,6 +369,9 @@ FMU 1 gets a `Confirm` operation, because the specified frame with CAN ID 15 was
[#figure-can-arbitration-overview-with-buffer]
image::can_arbitration_overview_with_buffer.svg[width=80%, align="center"]

_[Note: The path shown represents the intended approach.
Other implementations may also be valid according to the FMI specification.]_

==== Realization of CAN Error Handling [[low-cut-can-realization-of-can-error-handling]]
This chapter describes a possible implementation of the CAN error handling within Network FMUs using a rule set based on `Bus Error` operations.
According to the original CAN error confinement rules, each Network FMU provides its own Transmit Error Counter (TEC), Receive Error Counter (REC) and current CAN node state.
Expand Down
18 changes: 9 additions & 9 deletions ls-bus-guide/images/can_arbitration_overview.drawio
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<mxfile host="app.diagrams.net" modified="2023-06-02T10:24:10.376Z" agent="Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/113.0.0.0 Safari/537.36 Edg/113.0.1774.57" etag="tiokunncOhl7-qi8kyrO" version="21.3.6" type="device">
<mxfile host="app.diagrams.net" modified="2024-01-02T12:29:44.336Z" agent="Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36 Edg/120.0.0.0" etag="1SIBh2Jsx8kAh2hStAYL" version="22.1.16" type="device">
<diagram id="kgpKYQtTHZ0yAKxKKP6v" name="Page-1">
<mxGraphModel dx="546" dy="308" grid="1" gridSize="10" guides="1" tooltips="1" connect="1" arrows="1" fold="1" page="1" pageScale="1" pageWidth="850" pageHeight="1100" math="0" shadow="0">
<mxGraphModel dx="458" dy="255" grid="1" gridSize="10" guides="1" tooltips="1" connect="1" arrows="1" fold="1" page="1" pageScale="1" pageWidth="850" pageHeight="1100" math="0" shadow="0">
<root>
<mxCell id="0" />
<mxCell id="1" parent="0" />
Expand Down Expand Up @@ -50,7 +50,7 @@
<mxPoint as="offset" />
</mxGeometry>
</mxCell>
<mxCell id="Ct78ly6aTw_c9TOjw8sM-1" value="Transmit (ID = 15)" style="verticalAlign=bottom;endArrow=block;entryX=0;entryY=0;shadow=0;strokeWidth=1;exitX=1.24;exitY=0.039;exitDx=0;exitDy=0;exitPerimeter=0;" parent="1" edge="1" source="3nuBFxr9cyL0pnOWT2aG-2">
<mxCell id="Ct78ly6aTw_c9TOjw8sM-1" value="Transmit (ID = 15)" style="verticalAlign=bottom;endArrow=block;entryX=0;entryY=0;shadow=0;strokeWidth=1;exitX=1.24;exitY=0.039;exitDx=0;exitDy=0;exitPerimeter=0;" parent="1" source="3nuBFxr9cyL0pnOWT2aG-2" edge="1">
<mxGeometry relative="1" as="geometry">
<mxPoint x="500" y="179" as="sourcePoint" />
<mxPoint x="648" y="179" as="targetPoint" />
Expand Down Expand Up @@ -97,7 +97,7 @@
<mxPoint as="offset" />
</mxGeometry>
</mxCell>
<mxCell id="3nuBFxr9cyL0pnOWT2aG-7" value="Confirm(ID = 15)" style="verticalAlign=bottom;endArrow=block;endSize=8;exitX=0;exitY=0.95;shadow=0;strokeWidth=1;endFill=1;entryX=1.32;entryY=0.943;entryDx=0;entryDy=0;entryPerimeter=0;" parent="1" edge="1" target="3nuBFxr9cyL0pnOWT2aG-2">
<mxCell id="3nuBFxr9cyL0pnOWT2aG-7" value="Confirm(ID = 15)" style="verticalAlign=bottom;endArrow=block;endSize=8;exitX=0;exitY=0.95;shadow=0;strokeWidth=1;endFill=1;entryX=1.32;entryY=0.943;entryDx=0;entryDy=0;entryPerimeter=0;" parent="1" target="3nuBFxr9cyL0pnOWT2aG-2" edge="1">
<mxGeometry relative="1" as="geometry">
<mxPoint x="480" y="612" as="targetPoint" />
<mxPoint x="647" y="611.9999999999998" as="sourcePoint" />
Expand All @@ -109,14 +109,14 @@
<mxCell id="TJ8cURRopO99HcsGI5Q8-3" value="" style="shape=curlyBracket;whiteSpace=wrap;html=1;rounded=1;labelPosition=left;verticalLabelPosition=middle;align=right;verticalAlign=middle;strokeWidth=2;" parent="1" vertex="1">
<mxGeometry x="401" y="504" width="20" height="80" as="geometry" />
</mxCell>
<mxCell id="TJ8cURRopO99HcsGI5Q8-4" value="Super-dense&#xa;time iteration&#xa;(1)" style="text;align=center;fontStyle=0;verticalAlign=middle;spacingLeft=3;spacingRight=3;strokeColor=none;rotatable=0;points=[[0,0.5],[1,0.5]];portConstraint=eastwest;fontSize=11;fillColor=none;" parent="1" vertex="1">
<mxCell id="TJ8cURRopO99HcsGI5Q8-4" value="Super-dense&#xa;time iteration&#xa;(t, 1)" style="text;align=center;fontStyle=0;verticalAlign=middle;spacingLeft=3;spacingRight=3;strokeColor=none;rotatable=0;points=[[0,0.5],[1,0.5]];portConstraint=eastwest;fontSize=11;fillColor=none;" parent="1" vertex="1">
<mxGeometry x="327" y="268" width="80" height="26" as="geometry" />
</mxCell>
<mxCell id="TJ8cURRopO99HcsGI5Q8-5" value="Super-dense&#xa;time iteration&#xa;(2)" style="text;align=center;fontStyle=0;verticalAlign=middle;spacingLeft=3;spacingRight=3;strokeColor=none;rotatable=0;points=[[0,0.5],[1,0.5]];portConstraint=eastwest;fontSize=11;fillColor=none;" parent="1" vertex="1">
<mxCell id="TJ8cURRopO99HcsGI5Q8-5" value="Super-dense&#xa;time iteration&#xa;(t, 2)" style="text;align=center;fontStyle=0;verticalAlign=middle;spacingLeft=3;spacingRight=3;strokeColor=none;rotatable=0;points=[[0,0.5],[1,0.5]];portConstraint=eastwest;fontSize=11;fillColor=none;" parent="1" vertex="1">
<mxGeometry x="327" y="531" width="80" height="26" as="geometry" />
</mxCell>
<mxCell id="TJ8cURRopO99HcsGI5Q8-6" value="Event Mode" style="text;align=left;fontStyle=0;verticalAlign=middle;spacingLeft=3;spacingRight=3;strokeColor=none;rotatable=0;points=[[0,0.5],[1,0.5]];portConstraint=eastwest;fontSize=11;fillColor=none;" parent="1" vertex="1">
<mxGeometry x="247" y="267" width="80" height="26" as="geometry" />
<mxGeometry x="247" y="266" width="80" height="26" as="geometry" />
</mxCell>
<mxCell id="TJ8cURRopO99HcsGI5Q8-7" value="" style="strokeWidth=2;html=1;shape=mxgraph.flowchart.annotation_2;align=left;labelPosition=right;pointerEvents=1;fontSize=11;fillColor=none;" parent="1" vertex="1">
<mxGeometry x="315" y="420" width="17" height="20" as="geometry" />
Expand All @@ -127,13 +127,13 @@
<mxCell id="WQ29GB5LsVI4mir2wNij-3" value="" style="shape=curlyBracket;whiteSpace=wrap;html=1;rounded=1;labelPosition=left;verticalLabelPosition=middle;align=right;verticalAlign=middle;strokeWidth=2;" parent="1" vertex="1">
<mxGeometry x="401" y="591" width="20" height="40" as="geometry" />
</mxCell>
<mxCell id="WQ29GB5LsVI4mir2wNij-16" value="Super-dense&#xa;time iteration&#xa;(3)" style="text;align=center;fontStyle=0;verticalAlign=middle;spacingLeft=3;spacingRight=3;strokeColor=none;rotatable=0;points=[[0,0.5],[1,0.5]];portConstraint=eastwest;fontSize=11;fillColor=none;" parent="1" vertex="1">
<mxCell id="WQ29GB5LsVI4mir2wNij-16" value="Super-dense&#xa;time iteration&#xa;(t, 3)" style="text;align=center;fontStyle=0;verticalAlign=middle;spacingLeft=3;spacingRight=3;strokeColor=none;rotatable=0;points=[[0,0.5],[1,0.5]];portConstraint=eastwest;fontSize=11;fillColor=none;" parent="1" vertex="1">
<mxGeometry x="328" y="598" width="80" height="26" as="geometry" />
</mxCell>
<mxCell id="WQ29GB5LsVI4mir2wNij-17" value="" style="shape=curlyBracket;whiteSpace=wrap;html=1;rounded=1;labelPosition=left;verticalLabelPosition=middle;align=right;verticalAlign=middle;strokeWidth=2;" parent="1" vertex="1">
<mxGeometry x="401" y="458" width="20" height="40" as="geometry" />
</mxCell>
<mxCell id="WQ29GB5LsVI4mir2wNij-18" value="Super-dense&#xa;time iteration&#xa;(1)" style="text;align=center;fontStyle=0;verticalAlign=middle;spacingLeft=3;spacingRight=3;strokeColor=none;rotatable=0;points=[[0,0.5],[1,0.5]];portConstraint=eastwest;fontSize=11;fillColor=none;" parent="1" vertex="1">
<mxCell id="WQ29GB5LsVI4mir2wNij-18" value="Super-dense&#xa;time iteration&#xa;(t, 1)" style="text;align=center;fontStyle=0;verticalAlign=middle;spacingLeft=3;spacingRight=3;strokeColor=none;rotatable=0;points=[[0,0.5],[1,0.5]];portConstraint=eastwest;fontSize=11;fillColor=none;" parent="1" vertex="1">
<mxGeometry x="328" y="465" width="80" height="26" as="geometry" />
</mxCell>
</root>
Expand Down
Loading

0 comments on commit c2c0fba

Please sign in to comment.