question

LicioMAPELLI-4995 avatar image
0 Votes"
LicioMAPELLI-4995 asked asergaz commented

NetX Duo FTP client packet pool

Hello, when calling

 nx_ftp_client_file_read(&ftp_client, &my_packet, 5*NX_IP_PERIODIC_RATE); 

the packet returned is allways from the IP packet pool despite the FTP client was created passing as argument its own packet pool:

 nx_packet_pool_create(&ftp_client_pkt_pool, "FTP Client Packet Pool", FTP_PACKET_SIZE, ftp_client_memory, sizeof(ftp_client_memory));
 nx_ftp_client_create(&ftp_client, "FTP Client", &ip_0, 2000, &ftp_client_pkt_pool);

is this normal ?
Thank you, regards

azure-rtos
· 3
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

@LicioMAPELLI-4995 Thanks for your query. Community SME's on this topic or our team will review your scenario and circle back at the possible earliest time.

0 Votes 0 ·

Hello @LicioMAPELLI-4995,
I was checking the sample demo here: netx/samples/demo_netx_ftp.c

When you set up the FTP Client are you creating an IP instance for the FTP client nx_ip_create before calling nx_ftp_client_create ?

Thanks,



0 Votes 0 ·

yes,
regards

1 Vote 1 ·

1 Answer

BoChen-0401 avatar image
0 Votes"
BoChen-0401 answered asergaz commented

Hi @LicioMAPELLI-4995 thanks for your query, the ftp own packet pool is used by nx_ftp_client_packet_allocate() for sending data. For the reading operation (RETRIEVE command), this command causes the server to transfer a copy of the file, the data is from network (server), the client driver allocates the packet from IP packet pool for receiving data. For the writing operation (STOR), this command causes the server to accept the data, the ftp client may call nx_ftp_client_packet_allocate() to allocate the packet pool from FTP own packet pool, then sends data to server.

· 1
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Hello @LicioMAPELLI-4995 ,
Please share with us if you have any other questions related with your original post. Otherwise could you go ahead and mark the above as answer?

Thank you so much.

Remember:
- Please accept an answer if correct. Original posters help the community find answers faster by identifying the correct answer. Here is how.

0 Votes 0 ·