![U.S. Converters USC520 Скачать руководство пользователя страница 13](http://html1.mh-extra.com/html/u-s-converters/usc520/usc520_user-manual_3092695013.webp)
USC520 / USC540 User Manual www.usconverters.com
U.S. Converters LLC 13 / 52 Copyrights © U.S.
Converters
3.1.5. TCP and UDP Comparison
TCP
UDP
Advantages
Stable, no loss
Reliable connection mechanism
Resend after data sending fails
No Connection mechanism, simple, flexible
Suit for small packet and high frequency
Accurate data sending interval
Disadvantages
Long packet starting
Jam for small packet and high frequency
Inaccurate interval resulted from check
and resend mechanism
More less under bad network environment
3.1.6. HTTPD Client
It is used to transmit data from USC520/USC540 to HTTP server or gain data from HTTP server.
USC520/USC540 can handle complex HTTP protocol so user just do programming for serial, and not need to
worry about HTTP.
When USC520/USC540 sends data to HTTP server via serial port, it only needs to send the header of
requested data; All the returned data will be transmitted by USC520/USC540, user need to analyze the
packets.
Test Example
:
1) Entry
http://192.168.0.7
(N520’s IP) to open its web page
1. SetUSC520/USC540 as HTTPD Client.
2. Set HTTPD packet Header.
<Note>:
HTTPD Client only support GET to request HTTPD Server. POST will be available in the following.
GET/ is fixed packet header.
1.php?data= is the visited/submitted the page
$ stands for data sent by serial (Serial port does not need to send “$”)
HTTP/1.1 is requested protocol.
Host is means requested IP address/ domain.
Enter twice
2) Save the parameters and restart USC520/USC540.
3) Open serial port to send data, then the data can be submitted onto our web page server.