PROFINET Device4.2.0
 
Loading...
Searching...
No Matches

◆ PN_API_IOD_startDevice()

uint32_t PN_API_IOD_startDevice ( PN_API_IOD_Handle_t *const  pnHandle)

Starts communication with an IO device instance.

Enables the IO device to accept connection requests from the IO controller. The IO device needs to be first created using either PN_API_IOD_openDevice() or PN_API_IOD_startup().

Warning
This function does not have to be called by the user application. For now, it's functionality is covered by PN_API_IOD_startup().
Parameters
[in]pnHandleProfinet API Handle.
Returns
result of the operation as uint32_t.
Return values
PN_API_OKSuccess.
PN_API_NOT_OKSomething went wrong.
PN_API_ERR_PARAMInvalid parameter.
Example
#include "pn_api_iod_device.h"
#include "pn_api_iod_startup.h"
PN_API_IOD_Handle_t* pnHandle = NULL;
uint32_t status;
pnHandle = PN_API_IOD_new();
//Prepare and call PN_API_IOD_startup()
...
status = PN_API_IOD_startDevice(pnHandle);
uint32_t PN_API_IOD_startDevice(PN_API_IOD_Handle_t *const pnHandle)
Starts communication with an IO device instance.
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