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状态返回的问题

我用协调器接收串口数据,然后通过无线发送出去,接受的无线数据通过串口发送,串口波特率115200无线每次发送7个数据,接收到串口数据后在SAPI_ReceiveDataIndication 中调用无线发送函数zb_SendDataRequest发送数据,请问当发送第十几次发送数据时,AF_DataRequest时状态会返回afStatus_MEM_FAIl |afStatus_FAILED,在zb_SendDataRequest中想重新调用AF_DataRequest发送,一直返回afStatus_MEM_FAIl |afStatus_FAILED。请指导一下哪里出了问题,该怎么就解决?谢谢

  • 申请不到动态内存了。

    你的数据是发给end device还是router的,如果是发给end device的,那么数据时buffer在底层,等待end device来data request的时候把数据发送出去。

    你可以把Heap加大

    #if !defined INT_HEAP_LEN
    #if defined RTR_NWK
    #define INT_HEAP_LEN 3072
    #else
    #define INT_HEAP_LEN 2048
    #endif

  • 非常感谢,问题解决了,我后来也看到了官方程序里也有一段注意:

    Note that when using interrupt service based UART configuration (as opposed to DMA)
    higher baudrate such as 115200bps may have problem when radio is operational at the same time.

  • 可是我的终端是处于始终接收状态,RFD_RCVC_ALWAYS_ON=TRUE,就不会存在buffer在底层了吧

  • VV,
    改变int-heap-len对我路由系统会有怎样的影响,会否出现无线层面无法通信的可能?最近新项目上增加了外部中断,频繁ADC等功能之后,发现会出现通信掉点不恢复的情况 ,重启一下就又恢复了