In this article will be described how to arrange log file upload of Ethernet data logger TCW220.
The Ethernet data logger TCW220 can upload periodically its log file via HTTP protocol to dedicated HTTP server. The log file is upload with HTTP Post.
There are many variants to organize HTTP server. Maybe, the most popular is Apache server. It has installations for WIN, Linux and OsX. In this article another variant for WIN will be shown.
TC Monitor is software for remote monitoring and control. For its normal operation it needs HTTP server. For customer convenience, HTTP server is included in installation package of software. This HTTP server can be used also for log file receiving.
To arrange log file upload of Ethernet data logger TCW220 follow the steps below:
1. Install TC Monitor software
TC Monitor installation package can be downloaded from www.teracom.cc.
The installation is quite simple – double click on the installation package, choose folder and press Install.
Note: The install path must not contain any spaces or Windows specific file system characters.
2. Start TC Monitor
TC Monitor can be activated from the start menu. The following window will appear:
Note: For proper operation TC Monitor should run.
3. Create destination folder for log files
The folder should be located in …\TCMonitor-1.4\web\www
In this article “http_post_log” will be used like a folder name.
4. PHP file
For proper operation dedicated PHP file should be available in created directory (step 3).
Our proposal for PHP file is HTTP_Post.php.
Download file, unzip and copy it in created directory (step 3).
This PHP add time stamp for every new file. In this case the new information doesn’t overwrite old one and all uploaded files are kept in the directory.
After a few uploads the directory will look like:
5. TCW220 settings
Following settings on page Services->Logger should be made:
- Logger – Enable;
- Logger mode – Time mode. Actually all variants are possible;
- Log interval – 30 seconds. All valid values are also possible;
- HTTP upload – Enable;
- Server – IP address of PC + :8181 + name of created folder + name of PHP file
TC Monitor listen on port 8181. It is mandatory in record.
In standard application a router with public static IP and port forwarding should be used.
6. Import log file to Excel
An uploaded file can be import in Excel and data can be viewed like a graph.