1.3.3.1.19 MAC_CommStatusIndication Typedef

C

typedef void (*MAC_CommStatusIndication)(MAC_COMM_STATUS_INDICATION_PARAMS *csParams);

Summary

Pointer to a Comm Status Indication Event handler function.

Description

This data type defines the required function signature for the MAC Comm Status Indication event handling callback function. A client must register a pointer using the event handling function whose function signature (parameter and return value types) matches the types specified by this function pointer in order to receive Comm Status Indication events back from module.

Comm Status events are specified in IEEE 802.15.4 standard. G3 implements a subset of them, as specified in G3-PLC standard.

Returns

None.

Example

App_CommStatusIndication(MAC_COMM_STATUS_INDICATION_PARAMS *params)
{
    // Send event to a handling module
    if (csParams->status == MAC_STATUS_ALTERNATE_PANID_DETECTION)
    {
        // Frame from other PAN Id received
        App_AlternateIDHandlingTool(params);
    }
    else
    {
        // Security related issue
        App_SecurityIssueHandlingTool(params);
    }
}

Remarks

None.