SNIP_CLASSIC_STD_SECTION_8_5_4_2_IocSend_IocWrite
Wortlaut
8.5.4.2 IocSend/IocWrite
The IocWrite API call is generated for "data" (unqueued) semantics and the IocSend API call is generated for "event" (queued) semantics.
[SWS_Os_00718] Definition of API function IocSend_<IocId>[_<SenderId>]
Upstream requirements: SRS_Os_80020
⌈
Service Name
IocSend_<IocId>[_<SenderId>]
Syntax
Std_ReturnType IocSend_<IocId>[_<SenderId>] (
<Data> IN,
[uint16 numberOfBytesIN]
)
Service ID [hex]
0x1e
Sync/Async
Asynchronous
Reentrancy
This function is generated individually for each sender. The individual function is not reentrant
(if called from different runnable entities that belong to the same sender), but different functions
can be called in parallel.
IN
Data value to be sent over a communication identified by the <Ioc
Id>. The parameter will be passed by value for primitive data
elements and by reference for all other types.
Example: Std_ReturnType IocSend_RTE_25 (const uint32 UI_
Value); Std_ReturnType IocSend_RTE_42 (const TASKParams3
*pStr_Value);
Parameters (in)
numberOfBytesIN
(optional) number of bytes to be send
Parameters (inout)
None
Parameters (out)
None
Return value
Std_ReturnType
IOC_E_OK: The data has been passed successfully to the
communication service.
IOC_E_LIMIT: IOC internal communication buffer is full (Case:
Receiver is slower than sender). This error produces an IOC_E_
LOST_DATA Overlayed Error on the receiver side at the next data
reception.
IOC_E_LENGTH: The <numberOfBytesIN> exceeds either the
internal buffer or is equal zero, so no data is send.
Description
Performs an "explicit" sender-receiver transmission of data elements with "event" semantic for a
unidirectional 1:1 or N:1 communication between OS-Applications located on the same or on
different cores.
<IocId> is a unique identifier that references a unidirectional 1:1 or N:1 communication.
<SenderId> is used only in N:1 communication. Together with <IocId>, it uniquely identifies the
sender. It is separated from <IocId> with an underscore. In case of 1:1 communication, it shall
be omitted.
Available via
Ioc.h
⌋
[SWS_Os_91003] Definition of API function IocWrite_<IocId>[_<SenderId>]
Upstream requirements: SRS_Os_80020
⌈
Service Name
IocWrite_<IocId>[_<SenderId>]
Syntax
Std_ReturnType IocWrite_<IocId>[_<SenderId>] (
<Data> IN,
[uint16 numberOfBytesIN]
)
Service ID [hex]
0x1f
Sync/Async
Asynchronous
Reentrancy
This function is generated individually for each sender. The individual function is not reentrant
(if called from different runnable entities that belong to the same sender), but different functions
can be called in parallel.
IN
Data value to be sent over a communication identified by the <Ioc
Id>. The parameter will be passed by value for primitive data
elements and by reference for all other types.
Example: Std_ReturnType IocWrite_RTE_25 (const uint32 UI_
Value); Std_ReturnType IocWrite_RTE_42 (const TASKParams3
*pStr_Value);
Parameters (in)
numberOfBytesIN
(optional) number of bytes to be send
Parameters (inout)
None
Parameters (out)
None
Return value
Std_ReturnType
IOC_E_OK: The data has been passed successfully to the
communication service.
IOC_E_LENGTH: The <numberOfBytesIN> exceeds either the
internal buffer or is equal zero, so no data is send.
Description
Performs an "explicit" sender-receiver transmission of data elements with "data" semantic for a
unidirectional 1:1 or N:1 communication between OS-Applications located on the same or on
different cores.
<IocId> is a unique identifier that references a unidirectional 1:1 or N:1 communication.
<SenderId> is used only in N:1 communication. Together with <IocId>, it uniquely identifies the
sender. It is separated from <IocId> with an underscore. In case of 1:1 communication, it shall
be omitted.
<numberOfBytesIN> specifies the size of the data to be transmitted (in bytes).
Available via
Ioc.h
⌋
General:
[SWS_Os_00719]
Upstream requirements: SRS_Os_80020
⌈IocSend/IocWrite is asynchronous in that way it shall not have to wait for the reception of the data on the receiving side to return from execution.⌋
[SWS_Os_00720]
Upstream requirements: SRS_Os_80020
⌈The IocSend/IocWrite function shall not return until the data given in parameter
have been completely physically sent over the communication medium.
For example in case of communication over shared RAM, an IocSend/IocWrite shall
return when all data have been copied in the target shared RAM.⌋
[SWS_Os_00721]
Upstream requirements: SRS_Os_80020
⌈In case of "event" (queued) semantic, the IocSend function shall guarantee the order
of delivery. In case of senders from different cores, the order in which messages are
received will be determined by the implementation.⌋
[SWS_Os_00722]
Upstream requirements: SRS_Os_80020
⌈The IocSend/IocWrite function shall support mechanism to guarantee data-Integrity during transmission.
The IocSend/IocWrite function shall solve the crossing of the protection boundaries
of OS-Applications. It has to be generated in case of intra-core and inter-core communication.⌋
[SWS_Os_00820]
Upstream requirements: SRS_Os_80020
⌈The IocSend/IocWrite resp. IocSendGroup/IocWriteGroup function shall be
wrapped with the memory allocation keywords mechanism
1
2
#define OS_START_SEC_<sadm>
3
#include "Os_MemMap.h"
4
5
<IocSend, IocSendGroup, IocWrite, IocWriteGroup >
6
7
#define OS_STOP_SEC_<sadm>
8
#include "Os_MemMap.h"
where <sadm> is the shortName of the SwAddrMethod referenced by the OsMemoryMappingCodeLocationRef of the sending OsApplication configured in OsIocSendingOsApplicationRef of the respective OsIocCommunication channel.
⌋
Parameters:
[SWS_Os_00723]
Upstream requirements: SRS_Os_80020
⌈The IN <Data> parameter of the IocSend/IocWrite function shall be passed
by value for primitive data types, as an pointer to the array base type for arrays and by
reference for all other types.⌋
[SWS_Os_00724]
Upstream requirements: SRS_Os_80020
⌈For data passed as an pointer to the array base type or by reference, the IocSend/
IocWrite function shall guarantee upon return that the parameter is safe for re-use.⌋
Returned values:
[SWS_Os_00725]
Upstream requirements: SRS_Os_80020
⌈The IocSend/IocWrite function shall return IOC_E_OK if the data was passed successfully to the communication service.⌋
[SWS_Os_00726]
Upstream requirements: SRS_Os_80020
⌈In case of "event" semantic the IocSend function shall return IOC_E_LIMIT if an
IOC internal transmission buffer became full (Case: Receiver is slower than sender or/
and configured internal IOC buffer size is too small).
If this error occurs the IOC internal buffer could not be filled with the parameter. In that
case this error shall produce an IOC_E_LOST_DATAOverlayed Error on the receiver
side at the next data reception (s. SWS_Os_00745).⌋
Internal structures:
[SWS_Os_00727]
Upstream requirements: SRS_Os_80020
⌈In case of "event" semantic the IOC shall configure its internal transmission buffer size
with the value of the attribute OsIocBufferLength.⌋
Versionen & Provenienz · Zugeordnete Anforderungen
Diese Angaben zeigt der Versions-Explorer.
Begründung & Zuweisungs-Evidenz
Cited verbatim in the snippet (deterministic citation).
Dokumenten-Herkunft & Rückverfolgbarkeit
| Spezifikations-Dokument | SWS_OS.pdf |
|---|---|
| Dokumentseite | Seite 219 |
| Ziel-Modul | std (classic) |
| Ziel-Anforderung | SWS_Std_00005 |
| Semantische Rolle | constitutive |
| Automatisierungs-Konfidenz | 0.95 |