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

◆ PN_API_IOD_sendRetOfSubAlarm()

uint32_t PN_API_IOD_sendRetOfSubAlarm ( PN_API_IOD_Handle_t *const  pnHandle,
const uint32_t  api,
PN_API_IOD_DevAddr_t *const  addr,
const uint32_t  userHandle 
)

The function sends a “Return of Submodule” alarm to the IO controller. The alarm is triggered when the status of IOPS/IOCS changes from “BAD” to “GOOD”. The IO controller does not reparameterize the submodule.

No alarm may be triggered if the state of IOPS/IOCS changes from “GOOD” to “BAD”.

Parameters
[in]pnHandleProfinet API Handle.
[in]apiApplication Process Identifier.
[in]addrGeographical address (slot/subslot) of the module/submodule.
[in]userHandleUser defined 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_alarm.h"
PN_API_IOD_Handle_t* pnHandle = NULL;
uint32_t status, api = 0, userHandle = 0;
addr.Type = PN_API_IOD_AddrGeo;
addr.address.geo.slot = 0;
addr.address.geo.subslot = 0;
pnHandle = PN_API_IOD_new();
status = PN_API_IOD_sendRetOfSubAlarm(pnHandle, api, &addr, userHandle);
uint32_t PN_API_IOD_sendRetOfSubAlarm(PN_API_IOD_Handle_t *const pnHandle, const uint32_t api, PN_API_IOD_DevAddr_t *const addr, const uint32_t userHandle)
The function sends a “Return of Submodule” alarm to the IO controller. The alarm is triggered when th...
PN_API_IOD_Handle_t * PN_API_IOD_new(void)
Creates Profinet API handle.
@ PN_API_IOD_AddrGeo
Definition pn_api_iod_types.h:155
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
union PN_API_IOD_DevAddr_t::@0 address
struct PN_API_IOD_DevAddr_t::@0::@1 geo
uint32_t slot
Definition pn_api_iod_types.h:452
Module/Submodule address (logical/geographical).
Definition pn_api_iod_types.h:445