Skip to main content
Visitor II
March 10, 2021
Question

AzureRTOS, how to transmit TCP large data buffers?

  • March 10, 2021
  • 2 replies
  • 735 views

Hi,

I did the function below to transmit TCP data: But I only can transmit up to 4K bytes using this function. If len is bigger than 4K bytes, nx_tcp_socket_send fails.

void TCP_Send(void *buf, uint32_t len)

{

 UINT ret;

 NX_PACKET *send_packet;

nx_packet_allocate(&AppPool,&send_packet,NX_TCP_PACKET,NX_WAIT_FOREVER);  

nx_packet_data_append(send_packet,buf,len,&AppPool,NX_WAIT_FOREVER);

ret = nx_tcp_socket_send(&TCPSocket, send_packet, NX_WAIT_FOREVER);

if(ret) nx_packet_release(send_packet);

}  

    This topic has been closed for replies.

    2 replies

    Visitor II
    June 10, 2021

    Hello @Community member​ ,

    Your problem has been reported internally. I will keep you updated.

    Thank you for your understanding.

    BeST Regards,

    Walid

    Visitor II
    June 16, 2021

    Hello @Community member​ 

    We have increased the buffer size to more 4096, but we don't see any problems.

    Could you please share your example to reproduce your issue?

    Thanks in advance.

    Walid