Initiates data read in Profinet stack and Performs one-time exchange of IO output data between the user application and Profinet stack for all ARs (RT, IRT).
The stack allocates the data buffer and subsequently invokes PN_API_IOD_dataReadCbf() for all submodules containing output data associated with an active IO-AR linked to an IO controller. The user application is responsible for retrieving the output data received from the IO controller through the stack and updating the submodule's output accordingly. The updated IO data is then conveyed to the controller during the next transfer cycle, along with the exchange of IOCS and IOPS.
- Warning
- This function operates synchronously, implying that it does not return until all PN_API_IOD_dataReadCbf() calls have been executed.
- Parameters
-
| [in] | pnHandle | Profinet API Handle. |
- Returns
- result of the operation as uint32_t.
- Return values
-
- Example
#include "pn_api_iod_data.h"
uint32_t status;
...
...
uint32_t PN_API_IOD_initiateDataRead(PN_API_IOD_Handle_t *const pnHandle)
Initiates data read in Profinet stack and Performs one-time exchange of IO output data between the us...
PN_API_IOD_Handle_t * PN_API_IOD_new(void)
Creates Profinet API handle.
struct PN_API_IOD_Handle PN_API_IOD_Handle_t
API handle instance which holds IO device's info.
Definition pn_api_iod_types.h:61