ZPS_eAplZdpMatchDescRequest

ZPS\_teStatus ZPS\_eAplZdpMatchDescRequest\(
    PDUM\_thAPduInstance hAPduInst,
    ZPS\_tuAddress uDstAddr,
    bool bExtAddr,
    uint8 *pu8SeqNumber,
    ZPS\_tsAplZdpMatchDescReq *psZdpMatchDescReq);

Description

This function requests responses from network nodes with endpoints that match specified criteria in their Simple descriptors. More specifically, these criteria include: application profile, number of input clusters, number of output clusters, list of input clusters, and list of output clusters. The function sends out a Match_Desc_req command, as a broadcast to all network nodes. It might also be sent as a unicast to either a specific node of interest or to another node that may hold the required information in its primary discovery cache. The wildcard profile (0xFFFF) can be used to match any profile ID.

The request is represented by the structure below (further detailed in Section 9.2.2.10).

typedef struct {
    uint16 u16NwkAddrOfInterest;
    uint16 u16ProfileId;
    /* rest of message is variable length */
    uint8 u8NumInClusters;
    uint16* pu16InClusterList;
    uint8 u8NumOutClusters;
    uint16* pu16OutClusterList;
} ZPS_tsAplZdpMatchDescReq;

A node with matching endpoint criteria responds with a Match_Desc_rsp response, which should be collected using the function ZQ_bZQueueReceive() and stored in a structure of type ZPS_tsAplZdpMatchDescRsp(detailed in Section9.2.3.9).

Parent topic:ZPS_eAplZdpMatchDescRequest

Parameters

  • hAPduInst: Handle of APDU instance in which request is sent

  • uDstAddr: Address of destination node of request (can be 16- or 64-bit, as specified by bExtAddr)

  • bExtAddr: Type of destination address:

    • TRUE: 64-bit IEEE (MAC) address

    • FALSE: 16-bit network address

  • *pu8SeqNumber: Pointer to sequence number of request

  • *psZdpMatchDescReq: Pointer to request (see above).

Parent topic:ZPS_eAplZdpMatchDescRequest

Returns

  • ZPS_E_SUCCESS (request successfully sent)

  • APS return codes, listed and described in Section 11.2.2

  • NWK return codes, listed and described in Section 11.2.3

  • MAC return codes, listed and described in Section 11.2.4

Parent topic:ZPS_eAplZdpMatchDescRequest

Parent topic:Service Discovery functions