Making a Client Request on a Port – ESDL
This instruction applies only to SWCs specified in ESDL code. |
If your software component uses a ClientServer interface
as Rport, you must define at least one runnable entity that acts as the client. You have to ensure that the client is triggered by an RTE event.
- Open the SWC you want to edit.
For a client request
without status inquiry, enter the following code:
<CSinterface>.<operation>(<argument(s)>);
- <CSinterface> is the ClientServer interface used as Rport
- <operation> is the operation you want to call
- <argument(s)> is a comma-separated list of the operation arguments
Or
For a client request
without status inquiry, proceed as follows.
Enter the following code:
<status_variable> = <CSinterface>.<operation>(<argument(s)>);
- <status_variable> is the variable of type Std_ReturnType that holds the returned status
- <CSinterface> is the ClientServer interface used as Rport
- <operation> is the operation you want to call
- <argument(s)> is a comma-separated list of the operation arguments
Specify the status inquiry as follows:
if (<status_variable> != RTE_E_OK)
{
... // your statement or statement block
}
See also
Making a Client Request on a Port – Block Diagram
Specifying a ClientServer Interface Prototype
Client-Server Communication
Enabling Concurrent Invocation of a Server Runnable
RTE Access Macros – Error Codes