This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

终端通过AF_DataRequest发送数据

终端通过AF_DataRequest发送数据 ,设置AF_ACK_REQUEST接收确认, 假如成功接收到接收者的确认 ,AF_DATA_CONFIRM_CMD则响应么?如果没有接收到确认,终端还会发射么,如果发射会间隔多少时间发射,那么这个发射时间和发射次数在协议栈里哪里可以修改?

  • 重传次数和重传超时时间可由APSC_MAX_FRAME_RETRIES和APSC_ACK_WAIT_DURATION_POLLED控制

  • AF_DataRequestAPSC_MAX_FRAME_RETRIES次数后任然没有收到应答确认,又将如何处理

  • 这就表明发送失败了 消息可能会丢失

  • 我想问的是调用AF_DataRequest()来发送数据,

     AF_DataRequest( &GenericApp_DstAddr, &GenericApp_epDesc,
                           GENERICAPP_CLUSTERID,
                           (byte)osal_strlen( theMessageData ) + 1,
                           (byte *)&theMessageData,
                           &GenericApp_TransID,
                           AF_DISCV_ROUTE, AF_DEFAULT_RADIUS ) == afStatus_SUCCESS

    返回状态为afStatus_SUCCESS代表的是什么意思?只是代表通过天线发送出去了吗?还是发送出去了并且对方也接收到了?

    一直很疑惑。

    还有就是如果通过系统事件AF_DATA_CONFIRM_CMD:来判断消息是否发送成功这些参数是干啥用的(   afDataConfirm = (afDataConfirm_t *)MSGpkt;
              sentEP = afDataConfirm->endpoint;
              sentStatus = afDataConfirm->hdr.status;
              sentTransID = afDataConfirm->transID;
              (void)sentEP;
              (void)sentTransID;   )

    如果不成功我怎么把不成功的这条数据重新发送出去,在下面的if里面我应该添加些什么

               // Action taken when confirmation is received.
              if ( sentStatus != ZSuccess )
              {
                // The data wasn't delivered -- Do something
              }