Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 6 Current »

Establishes a connection to a FTP server.

Files

ftp-c.h/ftp-c.c

Prototype

Arguments

p_conn

Pointer to FTPc Connection object.

p_cfg

Pointer to FTPc Configuration object.

p_secuce_cfg

Pointer to FTPc Secure Configuration object.
DEF_NULL, if secured connection is not required

p_host_server

Pointer to hostname or IP address string of the server.

port_nbr 

Server TCP port number.

p_user 

Username of the FTP server.

p_pass 

Password for specified FTP user.

p_err 

Pointer to variable that will receive the return error code from this function.

TFTPc_ERR_NONE
FTPc_ERR_CONN_FAIL
FTPc_ERR_TX_CMD
FTPc_ERR_RX_CMD_RESP_FAIL
FTPc_ERR_LOGGEDIN       

Returned Values

DEF_OK,     FTP connection successfully established
DEF_FAIL, otherwise.

Required Configuration

  • The network security manager MUST be available and enabled to open a secure FTP connection (i.e: in “net_cfg.h”, NET_SECURE_CFG_EN should be DEF_ENABLED AND NET_TCP_CFG_EN should be DEF_ENABLED). See µC/TCPIP user manual for more information about the network security manager.
  • A network security module MUST be included in the project (i.e: Mocana’s NanoSSL) to use the network security manager functionalities.

Notes / Warnings

  • None.

Example Usage

  • No labels