FTP

File Transport Protocol

In general, FTP (File Transfer Protocol) is an old protocol, not really suitable for IoT applications. But, there are many systems working on FTP for data logging.

In principal, following are steps in file transfer in FTP:

  1. Create a local file (typically text or CSV file) with a given name and text content.

  2. Login to given FTP server (typically an IP address) using a login name and password.

  3. Change directory at destination FTP server

  4. Transfer the file from local device (YuDash IoT device) to FTP server

Selection of FTP as cloud protocol in YuDash IoT Device

For custom cloud server, please ensure "Use YuDash Cloud" is unchecked.

Custom FTP Server Settings

FTP settings are available within the Cloud Settings section.

There are two sections in FTP settings, which are covered in following sections:

  1. The FTP server details

  2. The FTP file details (file name and content).

Similar to all sub sections, you have to click on "Read FTP Settings" to load present FTP Settings. After updating, please click on "Update FTP Settings". New FTP settings block will be created if not present earlier.

FTP Server Configuration

FTP server includes following components:

ComponentDescription

FTP Server

The target FTP server, which is typically an IP address.

FTP User name

The user name for the given FTP server

FTP Password

The password to login to given FTP server

FTP Directory

The target FTP server directory where the payload fill will be uploaded by the YuDash IoT device.

It is advisable that FTP server credentials are verified using a FTP client PC software, for example coreFTP. In case of FTP server connection errors, it is mandatory for

FTP File Configuration

After FTP server details are configured, next step is to configure the file which will be transferred to FTP server. There are two parts to it:

  1. File content: The file will have text content with mix of telemetry, metadata and possibly timestamp.

  2. File Name: We need to define the file name, which will be created on given server directory. Typically, there a time stamp/snippet encoded in file name as we will uploading multiple files in same directory.

YuDash don't support appending of file in FTP. A new file is created on the FTP server. Please contact us at info@yudash.com if you have this requirement. We can surely do it, subject to business use-case!

There are two ways to create FTP files in the YuDash device. This is categorized by radio box FTP File Type".

  1. Default: This is a default format which make a 3 line file with pre-defined file naming convention. This is used for a specific compliance server.

  2. Generic: This is an extremely generic technique with flexibility of file name and content. In this case, file content is defined under payload setting.

Generic FTP File Settings

File Content in Generic FTP File Settings

The file content of generic FTP File Type is defined under Payload Settings. Basically, the payload is the content of file, which can be technically a text or JSON payload. In most of cases, text payload will be used in FTP configuration. For this, powerful YuTGT (YuDash Text Generator) is used to generate any kind of text payloads with mix of telemetry, separators and device meta-data. Please refer YuTGT TuDash Text Generator documentation to get familiar with semantics.

File Name is Generic FTP File Settings

The file name itself is generated using the YuTGT. Following two settings are defined under "Generic FTP File Settings"

  1. File Name Encoder: The input text to YuTGT to create the file name. The file name is created using semantics of YuTGT.

  2. File Name TimeStamp: The time stamp format (if required) to be used in the file name creation. This is intendent of TimeStamp format used in payload settings.

Generic FTP File Example

We will explain the FTP file creation using an example. This uses YuTGT Example#1 for payload generation.

File name encoder has following input

#YY #MM #DD #HH #NN #SS $_file.csv

Sample generated file and file name: 20240518101304_file.csv

FTP Troubleshooting guide

In case of connection errors to FTP server for first time, please refer to following trouble shooting guide:

I am new to FTP. How do I start?

First and foremost, in case you are not able to connect to FTP server from YuDash IoT device, first connect to the server using FTP client PC software, for example coreFTP. This will ensure that credentials and network access is correct.

I am not able to connect to FTP from my broadband (ethernet/WiF) from YuDash or PC

FTP works on TCP/IP port 20 (data) and 21 (control). In many cases, In many cases, these ports are disabled in router. Please enable these in your router settings.

In most of cases of 4G/LTE network, we have not observed this problem. So, a mobile wifi hotspot based on 4G/LTE may be good option to try.

My PC client is working, but YuDash is not working

Please check FTP settings within YuDash. Few points to check:

  • Don't put any prefix (ftp:// etc) in the IP address.

  • The FTP directory should start with slash /

  • Try some other network settings (WiFi/ 4G/Ethernet)

  • Ensure that target FTP directory has read/write access.

How to reach YuDash support

Please contact us on sales@yudash.com with your details. It is mandatory that FTP credentials are verified by customer through PC based client.

Last updated