Page 4
USCDR404 User manual www.usconverters.com 4.1.10. Device Management ............................62 4.2. AT command ................................63 4.2.1. Serial AT Command ............................63 4.2.2. Net AT command .............................. 65 4.3.3 Command Format .............................. 66 4.3.4 AT command ..............................68 4.3.4.1. AT+E ............................... 71 4.3.4.2.
Page 7
USCDR404 User manual www.usconverters.com Features Support 802.11b/g/n wireless standards. Support usr-link. Support route and bridge modes. Support RS485 to Wifi/ Ethernet communication. Rich indicator LED: Power, link, RXD, TXD. Wide voltage DC 5~36V, support terminal power.
1. Product Overview 1.1. Brief Introduction USCDR404 supports bidirectional serial port to WIFI / Ethernet conversion. Enabling serial devices with a TCP / IP network interface, connecting to networks for data communication, extending the communication distance of serial devices, as below:...
TCP Web server +AT command configure User configure Custom application Support custom customize application software software Form 1 Parameters 2. Networking application USCDR404 supports wireless WIFI and wired Ethernet communication modes, flexible networking and network topology. U.S. Converters LLC...
2.1. Wireless Networking Configuration USCDR404 can be configured to be a STA or an AP device. It can be configured by AT commands or web page, as below example: (1) AT command setting: Set by AT + WMODE, it can be set to AP or STA.
USCDR404 User manual www.usconverters.com 2.2. Wireless networking application 2.2.1. Wireless networking application(AP) WIFI can do as a AP, other serial port device and PC as a STA can connect the WIFI, also it can connected to user device via RS485, as fellows: Diagram 3 AP mode The WIFI serial server works in AP mode.
2.2.2. STA Mode USCDR404 do as STA and connect to other APs to form a wireless network, all STA take the AP as wireless networking centre, mutual communication between STAs is completed through AP forwarding, as below: Diagram 4 STA mode...
Page 13
USCDR404 User manual www.usconverters.com Diagram 5 AP+ STA mode WIFI serial server parameter settings are as follows: (1) Enable AP + STA function of WIFI serial server AT+FAPSTA=on (2) Parameters take effect after resetting the module AT+RELD (3) Set the WIFI serial server to STA mode, the WIFI serial server AP interface is still valid...
After clicking “Apply”,restart to take affect. 2.2.4. Wireless Networking Applications (AP,STA) USCDR404 can be configured to be a STA and a AP , in theory support 2 wireless interface, one STA and one AP, other STA will connected to the network via this AP.
Page 15
USCDR404 User manual www.usconverters.com Diagram 6 Wireless Networking Application WIFI serial server parameter settings are as follows: The WIFI serial server numbered 1 works in STA mode, and the numbered 2 works in AP mode: (1) For No. 1 WIFI serial server, set to STA AT+WMODE=STA (2) For No.
USCDR404 User manual www.usconverters.com (4) Restart AT+Z 2.3. Wired Networking Related AT command: Item Description WMODE Setting/query WIFI operating mode(AP、STA) WSSSID Setting/query related AP SSID WSKEY Setting/query encryption under the WIFI STA mode WANN Setting/query net parameters of the STA...
WIFI, serial port and Ethernet port. In terms of networking, the USCDR404 serial server network port can be set to LAN port and WAN port; at the same time, it supports bridge mode and routing mode to correspond to different specific applications.
USCDR404 works in AP mode, set the Ethernet interface to WAN, connected to the router that can search the internet, and enable the DHCP. Now USCDR404 works as a second grade router, PC and pad connect to the AP(USR-DR404) can can be online, the default AP is USR-DR404_xxxx, no encryption, 000000000000which can be setting by web page or AT command.
Page 19
USCDR404 User manual www.usconverters.com USR-W610 USR-DR404 100M Eth Internet WIFI IP:10.10.100.100 IP: IP:192.168.1.10 IP: GateWay: 10.10.100.254 GateWay: 192.168.1.1 10.10.100.254 192.168.1.1 Diagram 9 AP+WAN Application WIFI serial server parameter settings: (1) Enable Ethernet interface AT+FEPHY=on (2) Set the working mode of Ethernet to WAN...
USCDR404 User manual www.usconverters.com 2.4.3. Wired Networking Applications (Router) DR404 works as a STA, in router mode(software is N-Ver). Connected to the AP and obtained an IP address from the AP such as 192.168.1.101 in the below diagram. DR404 forms a subnet(default 10.10.100.254) which distributes the IP address to the devices that connect to its Ethernet interface.
USCDR404 User manual www.usconverters.com Set the LAN parameters of the serial server to ensure that the LAN IP address cannot be on the same network segment as the WAN IP address obtained by the serial server from the AP. Since this example is not on a network segment, can keep the default: AT+LANN=10.10.100.254,255.255.255.0(Optional)
Page 22
USCDR404 User manual www.usconverters.com USR-W610 USR-DR404 STA Z-Ver WIFI RJ45 WIFI IP: IP:192.168.1.100 IP:192.168.1.101 IP:192.168.1.10 192.168.1.1 GateWay:192.168.1.1 GateWay:192.168.1.1 GateWay:192.168.1.1 Diagram 12 Bridge Application WIFI serial server parameter settings: (1) Set the serial server software version to Z-Ver AT+FVER=z (2) Enable Ethernet interface...
The first three modes can send “+++” and “a” successively through the serial port. USCDR404 will return the confirmation codes “a” and “+ ok” in order to switch to the AT command mode. AT + ENTM can return USCDR404 from AT command mode to the original working mode. For details, please refer to the related chapter of “Serial AT Command”.
3.1.2. Serial command mode In this mode ,when USCDR404 works in UDP client or TCP client, allow sending serial data to different servers. Diagram 14 Serial command mode The MCU sends data packets according to the following format. After the WIFI serial server has finished parsing, it only sends n bytes of data to the destination address.
Page 25
USCDR404 User manual www.usconverters.com Bit0:(UDP:0 ;TCP:1) Bit1:(long connection:0)Note: Only long connections are currently supported. Bit2:(IP: 0; domain name: 1) Bit7:(Simple protocol:0;Full protocol:1)Note: Only simple protocols are currently supported. Note: For Bit1, long connection, then after sending data, the connection will remain until the target address is changed again.
USCDR404 User manual www.usconverters.com Parity:0x00+0x00+0x00+0x21+0x00+0x85+0x00+0xA8+0xC0+0x01=0x0f 3.1.3. HTTPD Client Mode The HTTPD Client mode supports three HTTP request methods: POST, PUT, and GET. After setting the specific content of the HTTP header through the AT command or the web page, each time data is sent, the WIFI serial server will automatically encapsulate the sent data into HTTP protocol data and send it to the designated HTTP server.
Page 27
HTTP header according to their own needs(If the HTTP request type is POST / PUT, USCDR404 will automatically add Content-Length).The setting commands include "AT + HTPMODE, AT + HTPSV, AT + HTPTP, AT + HTPURL, AT + HTPHEAD". For specific command setting procedures, please refer to the “AT command” chapter.
Page 28
USCDR404 User manual www.usconverters.com Diagram 15 HTTPD Client requesting type (2) In “Application Setting”, select Httpdclient Mode as long/short. U.S. Converters LLC...
USCDR404 User manual www.usconverters.com Diagram 16 HTTPD Client mode settings If set to short connection mode, timeout can be set within the range of 3-65535 (s). Diagram 17 HTTPD Client short connection timeout setting AT command setting: (1) Setting/query the Httpdclient Mode (long/short), for example:...
USCDR404 User manual www.usconverters.com Diagram 18 modbus TCP <=> modbus RTU Setting by AT command: AT+TMODE=modbus Setting by web page: Diagram 19 Data transfer mode 3.1.5. AT command mode Under AT command, send AT command to query the current status and parameters of the W610.
Page 31
USCDR404 User manual www.usconverters.com Server 1 USR-DR404 Serial device USR-W610 UART 终端设备 WIFI WIFI Server 2 Server 3 Diagram 20 Multi TCP link data transmission diagram Socket A settings: AT+NETP/AT+TCPTO/AT+TCPLK/AT+TCPDIS Item Description NETP Setting / Query TCPA's network protocol parameters...
USCDR404 User manual www.usconverters.com Diagram 21 Set serial port parameters on web page AT command: If the user needs to modify the baud rate of the DR404 to 115200bps, as follows: AT+UART= 115200,8,1,None,NFC 3.3.2. UART Free framing Take sent data from serial device to the DR404 as an example to show the steps of the free framing: if n is the free frame interval, unit is ms, when T1 >n, T2<n, T3<n, T4<n, T5<n and T6>n, then take byte1 -byte5 as a frame, as bellow:...
1. Auto framing trigger frame length: USCDR404 receives the specified number of bytes from the serial port, forms a data frame, and forwards it to the network.
USCDR404 User manual www.usconverters.com Diagram 24 Trigger Time UART auto framing can be set through the built-in web page “Application Setting -- UART AutoFrame Setting” of DR404 or set by AT command. 3.4. Synchronous Band Rate (RFC2217) Synchronous baud rate is named RFC2217. USR Similar RFC2217 make adjustments on the basis of RFC2217 protocol to improve accuracy of transmission.
USCDR404 User manual www.usconverters.com (115200, 55 AA 55 01 C2 00 N,8,1) (9600, 55 AA 55 00 25 80 N,8,1) Serial parameter bit: Bit # Explanation Value Description 5 bits 6 bits Data bit selection 7 bits 8 bits 1 bit...
Page 37
USCDR404 User manual www.usconverters.com Packet Fixed value: 0xFF Header Length Number of all bytes after length (excluding length) and before parity (excluding parity) Command Command type, 0x01 is the query command Parity The accumulated sum of all bytes after the header (excluding the header) and before the parity (excluding the parity).
Page 38
USCDR404 User manual www.usconverters.com Parity The accumulated sum of all bytes after the header (excluding the header) and before the parity (excluding the parity). Form 10 Reply Command For example: Mobile phone sends to WIFI serial server (hexadecimal number): FF 00 01 01 02...
USCDR404 User manual www.usconverters.com Header Length Number of all bytes after length (excluding length) and before parity (excluding parity) Command Command type, 0x82 is the reply command corresponding to the setting command. Parity The parity result of the SSID. If the SSID can be found, the corresponding value is 0x01.
USCDR404 User manual www.usconverters.com 3.8. Heartbeat Packet Function In the network transparent transmission mode, the user can choose to enable the custom heartbeat packet function. The heartbeat packet can be sent to the network or serial device: Diagram 25 Heartbeat packet...
USCDR404 User manual www.usconverters.com (3) Set the heartbeat packet data (maximum 40 bytes). For example, to set the data to the string www.usr.cn, you need to first convert the string to hex 7777772E7573722E636E. AT+HEARTDT=7777772E7573722E636E (4) Set the interval for sending heartbeat packets. The setting range is 1-65535s, and the default is 30s. For example, set the sending interval to 30 seconds.
Page 42
USCDR404 User manual www.usconverters.com Format 14 Serial transmission format Header: 0x55 0xFD 0xAA Length: the total number of bytes from parameters(included) to parity (do not included), the high is in front. Parameters: the first byte:common parameters, it is connecting number(socket A and socket B); 0x61 is all the device connected to the socket A, 0x62 is all the device connected to the socket B.
Page 43
USCDR404 User manual www.usconverters.com If the DR404 data, return the operating code, details are as fellows: Return Description Note code 0x00 Header error 0x01 Length error 0x02 Parameters error 0x04 Parity error 0x10 Send failed(parameters is right but send failed) Format 16 Errors Parity: from the parameters( included) to parity(not include), add and take the last bytes as parity.
USCDR404 User manual www.usconverters.com Diagram 26 Socket Distribution AT command to enable the socket: AT+ TCPDPEN =on Others, if more function for the socket A and socket B, please refer to the 2.4. 3.10. Timeout Restart Under the transparent transmission mode, enable the timeout restart function. If the DR404 no WIFI connection or connected but no communication in set time, DR404 will restart.
USCDR404 User manual www.usconverters.com For example: AT+TIMEOUTT=100, if no connection or connected but no communication within 100s, module will restart; if there is connection or communication in 100s, the time will be cleared and regain to time. Item Description TIMEOUTEN...
USCDR404 User manual www.usconverters.com Diagram 27 Modbus polling (2) Setting by AT command: Enable/disable Modbus polling function, enable this function: AT+MODBPOLLEN=on/off Set the polling interval (50 ~ 65535) (ms), taking 200ms as an example: AT+MODBPOLLT=200 3.13. Remote Upgrade 3.13.1 Serial server configuration...
USCDR404 User manual www.usconverters.com Diagram 28 Remote upgrade The remote upgrade function is set to open, select the port of the remote server, enter the server address, and the default reporting interval is 30min. 3.13.2 Remote upgrade system configuration (1) User registration and login Log in to https://ycsj1.usriot.com, click Register to register your account (if you have an account, log in directly) as...
Page 48
USCDR404 User manual www.usconverters.com Diagram 29 Login After submitting the registration, the mailbox will receive an activation email, click on the link to activate. Diagram 30 Registration After activation, please contact our company to review the account. The account can be used normally after review.
Page 49
USCDR404 User manual www.usconverters.com Diagram 31 Version configuration The version config page can be used to add, delete, modify ftp and http addresses, modify serial numbers, etc. The ftp address and http address cannot be entered manually. Click to select a file. After selecting a file, click Upload.
USCDR404 User manual www.usconverters.com Diagram 32 Add device ① After the remote monitoring function is turned on, you can view the running status of the device and remotely send AT commands to control the device. Corresponding to the "device monitoring" function on the left menu, the "device monitoring"...
USCDR404 User manual www.usconverters.com Diagram 33 Websocket Webpage Click the “Connect” to realize a Websocket connection, then serial and webpage can transport data with each other. The Websocket server of the DR404 supports 8 clients to connect at most. People make webpage application and have high requirement for the respond speed can contact us.
USCDR404 User manual www.usconverters.com Subnet mask 255.255.255.0 Username admin Password admin Form 19 Basic Parameters 4.1.1. Open the Management Webpage Connecting the DR404 with the wireless net card of the PC, SSID is USR-DR404_xxxx. Enter the browser, fill the 10.10.100.254 (default IP address) and enter. Then fill the username and password( both are: admin) and enter the webpage.
USCDR404 User manual www.usconverters.com This webpage shows a way to quickly configure the USCDR404 for user. Configure the parameters and restart to make the DR404 work normal. Of course, please click the respond webpage to configure. 4.1.3. Mode Selection Diagram 35 Mode Selection In the first page choose the work mode of the DR404:AP/ STA.
USCDR404 User manual www.usconverters.com 4.1.4. AP Interface Setting Diagram 36 AP interface DR404 supports AP interface with which can management the DR404 easier and can realize the networking. Webpage is as above, including SSID, security mode and LAN setup. Both supports user defined.
USCDR404 User manual www.usconverters.com 4.1.5. STA Interface Setting Diagram 37 STA Interface DR404 supports STA interface and can access to other wireless network, setting as above. There are three lists in this webpage, the former one is STA interface parameters,including the SSID of the AP to connect, security mode and others.
Page 56
USCDR404 User manual www.usconverters.com Diagram 38 WIFI-Uart setting U.S. Converters LLC...
Page 57
Network setting: 4 modes can be set on the network side as TCP server, TCP client, UDP server and UDP client. When USCDR404 is configured as a UDP server, USCDR404 will remember the last UDP client and communicate with the last UDP client. The UDP Client mode only communicates with the target IP and port. When set to TCP Server, there is no need to enter an IP address.
USCDR404 User manual www.usconverters.com Note:working in the TCP server mode, when enable it, the first data send by the TCP client to the server is password and enter, the default password is “admin” so the first data should be:0x61 0x64 0x6D 0x69 0x6E 0x0D 0x0A(HEX).
USCDR404 User manual www.usconverters.com Diagram 42 HTTPD Client Mode Under the HTTPD client mode, the content of the protocol header, including: server address, server port, request type, header path, header Connection and header User-Agent. 4.1.9. Advanced Under the advanced webpage, user can setup port mapping. It only works at STA mode or Ethernet port sets as WAN.
Page 61
USCDR404 User manual www.usconverters.com Diagram 43 Advanced U.S. Converters LLC...
USCDR404 User manual www.usconverters.com 4.1.10. Device Management Diagram 44 Device Management Device management includes username / password settings, factory reset and software upgrade functions. Instr: Restart: when user setting parameters in different webpage, click Apply to make sure it, but these parameters will be effect after restart and DR404 will reboot to fresh the original parameters.
USCDR404 User manual www.usconverters.com 4.2. AT command 4.2.1. Serial AT Command UART parameters: 57600/none/8/1. AT command can be sent by the AT command software or by programming. Take SecureCRT as an example, change from the other mode to AT command mode there always be two steps.
Page 64
Note: The specific AT command requires a ENTER, but the "+++" and "a" sent by entering the AT command process do not need a ENTER. In AT command mode, you can view all AT commands and descriptions of USCDR404 through the following help commands, as follows:...
USCDR404 User manual www.usconverters.com Diagram 48 Search via serial port Click “Open”, send "+++ a", receive the response "+ ok", then enter the AT command to be sent in the left operation area. After the setting is completed, click "AT + Z" to restart the module, and the parameter settings can be completed.
USCDR404 User manual www.usconverters.com Diagram 50 Web search Click “Search”, the searched USCDR404 will be displayed, click the USR-DR404, and then set through the left operation area (the method is the same as the serial port setting) Diagram 51 AT command software 4.3.3 Command Format...
Page 67
USCDR404 User manual www.usconverters.com [ ]: the part can be select Command: AT+<CMD>[op][para-1,para-2,para-3,para-4…]<CR> AT+: command prefix [op]L: command operating code, parameters setting or query; “=”: parameters setting “NULL” : query [para-n] : fill when setting the parameters <CR>: end, enter, ASCII code,: 0x0a or 0xod Note: When echoing, the terminator is automatically converted to 0x0a0d.
USCDR404 User manual www.usconverters.com Invalid command Invalid Operator Invalid Parameters Operation not allowed 4.3.4 AT command Command Function Enable/Disable echo function(DR404 does not support) ENTM Enter transparent transmission mode NETP Query/Set Network protocol parameters UART Query/Set serial port parameters UARTF...
Page 69
USCDR404 User manual www.usconverters.com effect in TCP Client mode) WANN Query/Set network parameters in STA mode(WAN interface parameters) LANN Query/Set network parameters in AP mode(LAN interface parameters) TCPTO Query/Set timeout re-connection time of socket A MAXSK Query/Set maximum TCP Clients in TCP Server work mode...
Page 70
USCDR404 User manual www.usconverters.com HTPMODE Query/Set HTTP Client mode parameters configuration way(new/old) HTTPURL Query/Set HTTP Server address and port in HTTP Client mode(old) HTTPTP Query/Set HTTP requesting method in HTTP Client mode(old) HTTPPH Query/Set HTTP header path in HTTP Client mode(old)...
1.This AT command set is for onboard WIFI module, which can be used for query, setting WIFI serial server parameters。 2.USCDR404 can work in AP mode or STA mode, and the WIFI parameters need to be set with different commands.
USCDR404 User manual www.usconverters.com After the command is executed correctly, the module switches from command mode to transparent transmission mode. If need to enter the command mode again, enter "+++" and the confirmation code to return to the command mode.
USCDR404 User manual www.usconverters.com Httpdclient: HTTPD Client mode After restarting the module, parameters take effect. Note: After power on, works in transparent transmission mode by default. 4.3.4.9. AT+WMODE Function: Query/Set WIFI mode(AP or STA) Format: Query : AT+WMODE<CR> +ok=<mode><CR>< LF ><CR>< LF >...
USCDR404 User manual www.usconverters.com WPA2PSK encry: Encryption algorithm, including NONE: valid when auth=OPEN. WEP-H: valid when auth=OPEN or SHARED(WEP, HEX) WEP-A: valid when auth=OPEN or SHARED(WEP, ASCII) TKIP: valid when auth= WPAPSK/WPA2PSK AES: valid when auth= WPAPSK/WPA2PSK ...
USCDR404 User manual www.usconverters.com Parameters: ret: If not connected: Returns “Disconnected”. If connected: Returns "SSID of AP (MAC of AP)" This parameter only valid in STA mode. 4.3.4.13. AT+WEBU Function: Query/Set web server username and password. Format: Query : AT+WEBU<CR>...
USCDR404 User manual www.usconverters.com 11BGN ssid: SSID in AP mode channel: WIFI channel, AUTO or CH1~CH11 This parameter only valid in AP mode, after restarting the module, parameters take effect. But can also be set in STA mode.
USCDR404 User manual www.usconverters.com This parameter only valid in AP mode, after restarting the module, parameters take effect. But can also be set in STA mode. 4.3.4.16. AT+MSLP Function: Module enters sleep mode (whether the module works in AP or STA mode, WIFI is not available at this time) Format: Query : AT+ MSLP <CR>...
USCDR404 User manual www.usconverters.com 4.3.4.18. AT+TCPLK Function: Query whether TCP connection is established Format: AT+ TCPLK<CR> +ok=<sta><CR>< LF ><CR>< LF > Parameters: sta.: Returns whether TCP connection is established, for example: on, TCP connection is established off, TCP connection is not established 4.3.4.19.
USCDR404 User manual www.usconverters.com +ok=<time><CR>< LF ><CR>< LF > Setting: AT+ TCPTO=<time ><CR> +ok<CR>< LF ><CR>< LF > Parameters: time.: TCP timeout, <= 600 (600s), >=0 (0 means no timeout), default is 0. TCP timeout: The module TCP channel starts counting when no data is received, and clears the count when data is received.
USCDR404 User manual www.usconverters.com When querying, sta.: Returns whether socket B is enabled. on, enable off, disable After restarting the module, parameters take effect. 4.3.4.25. AT+TCPPTB Function: Query/Set TCPB port number Format: Query : AT+TCPPTB <CR> +ok=<port><CR>< LF ><CR>< LF >...
USCDR404 User manual www.usconverters.com After sending this command, enable the Ethernet interface. This command is not saved, that is, Ethernet is still disabled after restart. If need to save this setting, please use the factory setting command. If need to enable the Ethernet interface permanently, please use the “AT + FEPHY = on”...
USCDR404 User manual www.usconverters.com This command enables or disables DHCP server function of LAN port, default is enabled. 4.3.4.33. AT+HIDESSID Function: Enable/Disable hiding the SSID in AP mode. Format: AT+HIDESSID=on/off<CR> +ok<CR>< LF ><CR>< LF > This command enables or disables hiding the SSID of the module in AP mode. Default is disabled.
Need help?
Do you have a question about the USCDR404 and is the answer not in the manual?
Questions and answers