RAK475 Instruction manual Content 1. Rapid usage............................ 4 1.1 Introduction to the development board................4 1.2 The method for the module to reset to Factory Defaults..........5 1.3 Inspection prior to powering on..................6 1.4 The status after powering on....................6 1.5 Transparent transmission data test..................
Page 3
RAK475 Instruction manual 4.7.9 Ping command.......................51 4.7.10 Query the connected network inFormation............52 4.8 Instruction for receiving and sending the data..............53 4.8.1 Send data........................53 4.8.2 Receive data......................54 4.9 Read and write NVM data....................56 4.9.1 Write data to NVM....................56 4.9.2 Read NVM data.....................57 4.10 Command for setting the certificate................58 4.10.1 Set ssl security certificate...................58...
RAK475 Instruction manual 1. Rapid usage 1.1 Introduction to the development board RAK475 serial port transparent transmission module focuses on transparent transmission supported by AT Command; it has the advantages of simple operation and rich functions and can meet the requirements of various kinds of customers. First, let's see the usage of RAK475 evaluation suits.
RAK475 Instruction manual Unconnected Normally off Connecting to the network Flash interval of 1 second STA Mode Getting IP Flash interval of 2 seconds Normally on The network is connected Normally on Socket event Flash for three times AP is not established Normally off AP is established, and not Periodically on and off in 1...
RAK475 Instruction manual 1.3 Inspection prior to powering on The evaluation suits mainly include: antenna of Micro USB line, development board, IPEX connector interface. If the module is external antenna module, please plug in the antenna. Connect the module’s serial port and computer’s serial port (the USB to serial port of the computer).
RAK475 Instruction manual Figure 1-4: Default IO communication page 1.5 Transparent transmission data test Open the serial port tools, select the COM port connected to the module. The default baud rate is 115200, data bit is 8, stop bit is 1, with no parity, no flow control.
Page 9
RAK475 Instruction manual Figure 1-5: Establish TCP Client After TCP is connected, the data can be sent to each other. At this time, the serial port of the module is changed into the virtual serial port of the network, and the serial port data and network data is interconnected.
RAK475 Instruction manual 2. Function features 2.1 Overview RAK475 module is an ultra-low power consumption WIFI module which fully supports IEEE802.11b/g/n wireless protocol, and has the advantages of small packaging and easy usage. The module is completely serial port transparent transmission module, inside which integrates TCP/IP protocol stack and driver, the usage is convenient, after simple configuration, it can be used regularly, the module connects the physical serial port and network, and access the connected equipment...
Page 11
RAK475 Instruction manual Support TCP, UDP, SSL and other communication protocols Support DHCP SERVER、DHCP CLIENT Support giving priority to the transparent transmission supplemented by AT commands Support the UART communication with the data flow, the maximum baud rate is ...
RAK475 Instruction manual 3. Instruction encyclopedia 3.1 Network configuration method The transparent transmission module aims at data communication in the end, WIFI communication is carried out under the preconditions of parameter configuration, the important thing is the network configuration (network name, PIN and IP address) and which kind of communication protocol socket set (TCP, UDP and SSL security) to use.
RAK475 Instruction manual The module supports the coexistence of AP and STA mode, i.e. users can not only connect the module to the router (Internet), but also access and look up the module and the like in the local net via the existing AP network, so as to be greatly convenient for users and enhance the user's experiences.
RAK475 Instruction manual Network settings 3.2.2 WLAN settings are divided into: the choice of the work mode, AP parameters and STA parameter settings. WLAN mode: AP, STA and AP+STA mode. AP mode: AP mode settings produce an encrypted WIFI wireless network, which ...
Page 16
RAK475 Instruction manual Establish the channel: 1-13 can be selected, and you can select automation, automatically select inside the module. whether to encrypt or not: open, the encryption can be selected. PIN: The length is less than 32 bit ...
Page 17
RAK475 Instruction manual configuration of 5 sets of recently connected routers, after enabling the function, the module will firstly connect the router connected last time, if the router connection is not successful, and the module will use the other routers in the list to try to connect. If the connection fails, repeat the above mentioned connection.
RAK475 Instruction manual Communication settings 3.2.3 Communication settings includes: UART parameter settings and socket parameter settings. UART parameters configuration The parameter settings of the serial port includes serial port baud rate, data bit, check bit and stop bit, settings of the flow control. Serial port’s free split interval is 10ms, if the timeout for the byte received from the serial port is 10ms, the serial port data with the interval greater than 10ms will be split and sent to the network.
Page 20
RAK475 Instruction manual the data of multiple client will be in turn sent from the serial port. TCP idle timeout parameter indicates that if the TCP connection has not data communication in the set time, the module will take the initiative to close the TCP connection at first and then carry out connection again.
RAK475 Instruction manual PC wireless tools upgrading Use the wireless upgrade tools of the following PC clients, as long as they are in the same network with module, click on the "scan" to find module, choose the firm ware to upgrade, click "start to upgrade", waiting for the upgrading to complete. Figure 3-11 PC wireless upgrading page 3.3 App wireless configuration APP wireless configuration parameters are similar to those of the WEB configuration,...
RAK475 Instruction manual Figure 3-12 APP configuration page 3.4 Instant configuration "RAK47X AP configuration & instant configuration” tool can instantly configure the modules under AP mode to the used network, and can also find and upgrade the module in the same network. The following demonstrates the instant configuration of RAK475, connect to the 2.4 required to configured, open the software and choose the "RAK475", enter into "Config"...
RAK475 Instruction manual 4. Aided AT commands 4.1 Basic flow chart Module’s work status gives priority to direct transparent transmission mode, but also provides an auxiliary command mode in order to manage and query the parameters for the module. Module interpret based on the MODE pin level, (high level by default) and enter into the transparent transmission mode.
RAK475 Instruction manual 4.2 AT command set Table 4-1 AT command set AT command Description Module management instruction at+ascii=<mode>\r\n Open ASCII display at+mac\r\n Query the module’s MAC address Enter into transparent at+easy_txrx\r\n transmission mode at+version\r\n Query the software version at+reset \r\n Reset the module at+restore\r\n Resect to Factory Defaults...
RAK475 Instruction manual at+ping=<host>, <count>, <size>\r\n Ping network host command at+tcp_status=0\r\n Query the connection status of TCP Query the connected network at+net_info\r\n inFormation Instruction for receiving and sending data at+send_data=0,dest_port,dest_ip,datalen,datab Send data from Socket uffer\r\n at+recv_data=0,dest_port,dest_ip,datalen,datab Receive data from Socket uffer\r\n Read and write NVM data at+nvm_write=<addr>,<len>,<data>\r\n...
RAK475 Instruction manual with the Format as shown below: If the command is successfully carried out, then the returned values shall be: OK\r\n or OK<parameter 1><parameter 2>....<parameter n>\r\n Note: Besides OK, the other parameters are all hexadecimal system one, for example: OK\r\n HEX=4F 4B 0D 0A-------------------------------- No parameter OK@\r\n HEX=4F 4B 64 0D 0A---------------------------- parameter =0x64...
Page 30
RAK475 Instruction manual Under the transparent transmission mode, open the aided command window, use the methods similar to shaking hands. The host computer (host MCU) send "+ + +", request to enter the command mode. Timing for 200ms, wait for the module to return “U”(0x55) , if the module did not return in the specified time, then the timing of 200ms will again send “+++”, and requests to enter the command mode until the module successfully return “U”(0x55) .It shows that the module is ready to enter into...
RAK475 Instruction manual 4.5 Module management instruction Open ASCII display 4.5.1 Command at+ascii=<mode>\r\n Description Convert all the command returned value with ASCII display, facilitate the users to debug and be familiar with the AT command. There is no need to open while programming.
RAK475 Instruction manual Description Query MAC address inFormation of the module, the coexistence of AP and STA is under STA mode, the MAC under the AP mode by default is MAC+1under the STA mode. Parameter instruction NULL Instruction for returned value Parameter Format Length (byte)
RAK475 Instruction manual Parameter instruction NULL Instruction for returned value Parameter Format Length (byte) Instruction The command is successfully carried out ASCII \r\n ASCII End character The command is unsuccessfully carried out ERROR ASCII ERROR <CODE> For details see ERROR list \r\n ASCII End character...
RAK475 Instruction manual Instruction for returned value Parameter Format Length(byte) Instruction The command is successfully carried out ASCII STRING Character string \r\n ASCII End character The command is unsuccessfully carried out ERROR ASCII ERROR <CODE> For details see ERROR list \r\n ASCII End character...
RAK475 Instruction manual ASCII The reset is successful \r\n ASCII End character The command is unsuccessfully carried out ERROR ASCII ERROR <CODE> For details see ERROR list \r\n ASCII End character Remarks Reset to Factory Defaults 4.5.6 Command at+restore\r\n Description Recover the module parameters to the Factory Defaults parameters Parameter instruction NULL...
RAK475 Instruction manual <CODE> For details see ERROR list \r\n ASCII End character Remarks 4.6 Parameter configuration instruction For the keywords and its parameters of the following configuration, please see the appendix - configuration parameters encyclopedia". Write user configuration 4.6.1 Command at+write_config=<data_length>...
RAK475 Instruction manual Example at+write_config=963,wlan_mode=1&ap_ssid=RAK475_AP&ap_channel=1&ap_s ec_mode=1&ap_psk=123456789&……\r\n Instruction for returned value Parameter Format Length(byte) Instruction The command is successfully carried out ASCII The reset is successful \r\n ASCII End character The command is unsuccessfully carried out ERROR ASCII ERROR <CODE> For details see ERROR list \r\n ASCII End character...
RAK475 Instruction manual OKwlan_mode=2&ap_ssid=RAK475_AP_38A55D&ap_channel=9&ap_sec_mode =0&ap_psk=123456789&ap_max_clts=0&ap_bdcast=1&ap_ip=192.168.7.1&sta_ssi d=RAK_2.4GHz&sta_sec_mode=1&sta_psk=rakwireless205&sta_dhcp=1&sta_ip=0. 0.0.0&sta_netmask=0.0.0.0&sta_gateway=0.0.0.0&sta_dns1=0.0.0.0&sta_dns2=0.0.0. 0&...\r\n Instruction for returned value Parameter Format Length(byte) Instruction The command is successfully carried out ASCII STRING Character string \r\n ASCII End character The command is unsuccessfully carried out ERROR ASCII ERROR <CODE> For details see ERROR list \r\n ASCII...
RAK475 Instruction manual Instruction for returned value Parameter Format Length(byte) Instruction The command is successfully carried out ASCII Open successfully \r\n ASCII End character The command is unsuccessfully carried out ERROR ASCII ERROR <CODE> For details see ERROR list \r\n ASCII End character Remarks...
RAK475 Instruction manual STRING Character string \r\n ASCII End character The command is unsuccessfully carried out ERROR ASCII ERROR <CODE> For details see ERROR list \r\n ASCII End character Remarks Read Factory Defaults 4.6.5 Command at+write_restoreconfig=<data_length>,<data_stream>\r\n Description Read Factory Defaults parameters configuration of the module, returning structure is the same with reading user's configuration.
RAK475 Instruction manual STRING Character string \r\n ASCII End character The command is unsuccessfully carried out ERROR ASCII ERROR <CODE> For details see ERROR list \r\n ASCII End character Remarks 4.7 AP STA operating instruction Query the connection status of STA 4.7.1 Command at+con_status\r\n...
RAK475 Instruction manual 0x00: unconnected \r\n ASCII End character The command is unsuccessfully carried out ERROR ASCII ERROR <CODE> For details see ERROR list \r\n ASCII End character Remarks Query the connection status of AP 4.7.2 Command at+ap_status\r\n Description If the module works under the AP mode , the command will be used for determining the connection status of the equipment.
RAK475 Instruction manual \r\n ASCII End character The command is unsuccessfully carried out ERROR ASCII ERROR <CODE> For details see ERROR list \r\n ASCII End character Remarks The wireless signal intensity of STA 4.7.3 Command at+rssi\r\n Description Querying the wireless network intensity under STA mode will be effective. Parameter instruction NULL Instruction for returned value...
RAK475 Instruction manual The command is unsuccessfully carried out ERROR ASCII ERROR When there is no network <CODE> 0XFE=-2 connection or the module works under AP mode. \r\n ASCII End character Remarks Scan the wireless network 4.7.4 Command at+scan=<channel>,<ssid>\r\n Description Scan the wireless network through this command, and access the wireless inFormation, including encryption inFormation, channel, signal strength, BSSID, etc.
Page 45
RAK475 Instruction manual Indicating the channel (1-13) to scan means channel 0 <channel> 0-13 refers to scan all the channels. The network <ssid> Indicate SSID (optional) name For example: at+scan=0 \r\n------------------------ Scan all the channels at+scan=0,RAKwireless\r\n------------- Scan the wireless network with the network name of “RAKwireless”...
RAK475 Instruction manual The command is unsuccessfully carried out ERROR ASCII ERROR the indicated ssid is not <CODE> 0XFE=-2 found \r\n ASCII End character Remark Get the wireless network 4.7.5 Command at+get_scan=<scan_num>\r\n Description Read the scanned inFormation from the command, this command must be called after the at+scan scan wireless network command.
Page 47
RAK475 Instruction manual <scan_num Read the scanned inFormation amount >0 > For example: at+get_scan=10\r\n------------------- Read 10 pieces of wireless network inFormation Instruction for returned value Length( Parameter Format Instruction byte) The command is successfully carried out ASCII Get the inFormation correctly <SSID>...
RAK475 Instruction manual canned inFormation have fully <CODE> 0XFE=-2 been read \r\n ASCII End character b7-b5: encryption method Remark b4-b3:encryption type b2-b0:encryption algorithm EasyConfig networking 4.7.6 Command at+easy_config\r\n Description Send the command, the module enters into an instant configuration mode, waiting for the phone to send configuration inFormation.
RAK475 Instruction manual <CODE> For details see ERROR list \r\n ASCII End character Remark WPS networking 4.7.7 Command at+wps\r\n Description Send the command; the module enters into the WPS configuration mode, while pressing the router's WPS button, generally WPS’s configuration timeout period is 2 minutes.
RAK475 Instruction manual Query IP inFormation 4.7.8 Command at+ipconfig\r\n Description Query the current module’s MAC address inFormation, IP address, subnet mask, gateway, DNS server, etc., if the DHCP is not assigned while setting; check out the module address of 127.0.0.1. Parameter instruction NULL Instruction for returned value...
RAK475 Instruction manual \r\n ASCII End character Remark Ping command 4.7.9 Command at+ping=<host>, <count>, <size>\r\n Description Execute Ping command, and test whether the network is connected or not. Parameter instruction Parameter Instruction <HOST> Indicated host <COUNT> Quantity of the data packets, with default value of 1 (optional) Size of data packet, the maximum data packet has 1000bytes with <SIZE>...
RAK475 Instruction manual target host. \r\n ASCII End character Remark Query the connected network inFormation 4.7.10 Command at+net_info\r\n Description Read the current network parameters, all the network parameters will be read at one time and returned back to the corresponding structure. Example OKwlan_mode=2&sta_ssid=RAK_2.4GHz&sta_bssid=8C:21:0A:D9:EB:7B&sta_se c_mode=1&sta_psk=rakwireless205&sta_dhcp=1&sta_ip=192.168.1.119&sta_netm...
RAK475 Instruction manual The command is unsuccessfully carried out ERROR ASCII ERROR <CODE> For details see ERROR list \r\n ASCII End character Remark 4.8 Instruction for receiving and sending the data Send data 4.8.1 Command at+send_data=<uuid>,<dest_port>,<dest_ip>,<data_length> ,<data_stream>\r\n Description Send data to the target connection (port identifier) through the command, with the maximum data length of 1024, wherein <data_stream>...
RAK475 Instruction manual <data_length> 1-1004 Data length (ASCII) <data_stream> data Data to sent (HEX) For example: at+send_data=0,0,0,4,ABCD\ r\n----------- send 4bytes data to the connection with the identifier of 0, the data content is “ABCD”. Instruction for returned value Length(b Parameter Format Instruction yte)
Page 55
RAK475 Instruction manual Command at+recv_data=<uuid>,<dest_port>,<dest_ip>,<data_length>,<data_stream>\r\n Description Receives the UUID data of the corresponding Socket (A, B), when the ASCII display is disabled, receive 16 Decimal system data. The sequence is the same. Suggest using ASCII to display disable mode when programming. If socket is set to the UDP type, the UDP receives a packet of less than 1024B per packet.
RAK475 Instruction manual \r\n ASCII End character The command is unsuccessfully carried out <CMD> ASCII Command header <CODE> For details see ERROR list \r\n ASCII End character Remark Read and write NVM data Write data to NVM 4.9.1 Command at+nvm_write=<addr>,<len>,<data>\r\n Description Write data to the indicated address in NVM via the command.
RAK475 Instruction manual at+nvm_write=1,4,ABCD\ r\n---------- Write the data “ABCD” to the unit with the initial address of 1. Instruction for returned value Parameter Format Length(byte) Instruction The command is successfully carried out ASCII Open successfully \r\n ASCII End character The command is unsuccessfully carried out ERROR ASCII ERROR...
RAK475 Instruction manual The maximum data length is 1024 byte <len> 1-1024 (ASCII) For Example: at+nvm_read=1,4\ r\n----------- Read 4 bytes of data from the unit of initial address of 1. Instruction for returned value Parameter Format Length(byte) Instruction The command is successfully carried out ASCII Open successfully <data_length>...
Page 59
RAK475 Instruction manual Description The command is used to set ssl security certificate Parameter instruction Parameter Parameter Instruction value SSL Client Private Key < cert_type> SSL Client Certificate SSL CA Certificate <file_len> <4*1024 Certificate length Instruction for returned value Forma Parameter Length(byte) Instruction...
RAK475 Instruction manual 4.11 InFormation storage commands for the user networking list Read the number of current list 4.11.1 Command at+read_userlist_num\r\n Description Read the number of currently saved networking inFormation list. Parameter instruction NULL Instruction for returned value Parameter Format Length(byte) Instruction The command is successfully carried out...
Page 61
RAK475 Instruction manual Description Read the networking inFormation in the current list Parameter instruction Parameter Parameter value Instruction Indicate list read <index> networking inFormation For example: OKsta_ssid=RAK_2.4GHz&sta_sec_mode=1&sta_psk=rakwireless205&sta_bssid =8C:21:0A:D9:EB:7B\r\n Instruction for returned value Parameter Format Length(byte) Instruction InFormation read successfully ASCII STRING Character string \r\n...
RAK475 Instruction manual Write the networking inFormation to the indicated lists 4.11.3 Command at+write_userlist=<index>,<len>,<data>\r\n Description Write the networking inFormation to the indicated lists Parameter instruction Parameter Parameter value Instruction Indicate list read <index> networking inFormation The data length of the networking <len>...
RAK475 Instruction manual ERROR ASCII ERROR <CODE> For details see ERROR list \r\n ASCII End character Remark Delete the networking inFormation in the indicated lists 4.11.4 Command at+delete_userlist =<index>\r\n Description Delete the networking inFormation in the current list Parameter instruction Parameter Parameter value Instruction...
RAK475 Instruction manual ERROR ASCII ERROR <CODE> 0XFE=-2 Invalid stored inFormation \r\n ASCII End character Remark 4.12 Upgrading of serial port firm ware Enter into the upgrading mode 4.12.1 Command at+upgrade\r\n Description The command is used to set the module to enter into the upgrading mode. The host computer (host MCU) send at+upgrade\r\n to the module, and request to enter into the upgrading mode.
RAK475 Instruction manual 5. Appendix-configuration parameter encyclopedia Table 5-1 Configuration parameter table Keywords Parameter Remarks Mode selection 0: STA mode wlan_mode 1: AP mode 2: Coexistence AP and STA mode AP mode parameter SSID name is ap_ssid RAK475_AP_SSID less than Channel ap_channel range (1-13)
Page 67
RAK475 Instruction manual sta_ip 192.168.1.100 sta_netmask 255.255.255.0 sta_gateway 192.168.1.1 sta_dns1 192.68.1.1 sta_dns2 0.0.0.0 UART communication parameter 9600,19200,38400,57600,115200,230400,460800,9 uart_baudrate 21600 uart_datalen (5-8) 0: No uart_parity_en 1: Odd parity check 3: Even parity check uart_stoplen (1-2) 0: disable uart_rtscts_en 1: enable Timeout time unit for the serial port...
Page 68
RAK475 Instruction manual 0: Disabled WEB configuration web_func_en unused 1: Enable WEB configuration Mdns 0: Local discovery is disabled function local_find_en 1: Local discovery is enabled opened default When user configured from Factory Defaults parameter to user parameter, 0: disable first_user_switch 1: enable configured...
Page 69
RAK475 Instruction manual parameter Socket communication parameter socket_multi_en 1: Double socket SocketA parameter 0: tcpc 1: ltcp socketA_type 2: udpc 3: ludp 4: tls/ssl 0: auto Tls version 1: SSLV3 Auto is the socketA_tls_v 2:TLSV1 mixture 3:TLSV1_1 TLS SSL 4:TLSV1_2 0: disable socketA_tls_ca certificate...
Page 70
RAK475 Instruction manual connecting number Tcp server socketB_localport 25001 (1-65535) socketB_destip 192.168.1.101 socketB_destport 25001 (1-65535) idle socketB_tcp_timeou 0: disable timeout time 1-600 : valid unit: s Interval time unit of socketB_tcp_reconv 0: disable 1-600 : valid reconnectio n: s Module name module_name RAK475 (16B)
Need help?
Do you have a question about the RAK475 UART and is the answer not in the manual?
Questions and answers