background image

Page 12 / 30

2.6.3. Module as UDP Server

Diagram 11 UDP Server

In this mode, the module opens the local designated port. Once receiving the data sent to this

port, the module will send the data to the serial port and record the remote IP and port. The module
will only record the remote information on the last connection, and the data sent by the serial port
will be directly sent to the recorded remote IP and port.

2.6.4. Module as UDP Client

Diagram 12

UDP Client

In this mode, the module sends the serial port data directly to the specified IP and port, and the

data returned from the server will be sent to the serial port.

UDP Server

UDP Client

UDP Client

UDP Server

Summary of Contents for HLK-B30

Page 1: ...Shenzhen Hi Link Electronic Co Ltd HLK B30 User Manual Version V1 1 Revised date 2017 1 16 Copr by Hi link Electronic Co Ltd...

Page 2: ...ode 6 1 12 WiFi output power in each mode 6 1 13 WiFi receive sensitivity in each mode 7 2 Functional description 7 2 1 The description of flashing WiFi indicator 7 2 2 One click network configuration...

Page 3: ...13 Set network connection parameters at net_ip 17 3 14 Query STA Mode Network Connection Status at WiFi_ConState 17 3 15 Query module MAC address at Get_MAC 17 3 16 Set the framing length at uartpackl...

Page 4: ...ing a complete and fast solution for users serial devices to transmit data over the network 1 2 Product Features Support 802 11b g n standards integrating ARM9 WLAN MAC Baseband BLE 4 2 Main frequency...

Page 5: ...connector Built in Built in PCB antenna Hardware parameters Hardware interface UART IIC PWM GPIO SPI Operating Voltage 3 3V GPIO drive capability Max 16ma Working current Send continuously Operating t...

Page 6: ..._SC I O P20 8 VBAT P 3 3V power supply 9 P28 I O Enter at command mode restore factory settings please pull up if not in use same as P22 10 P16 I O P16 11 P17 I O P17 12 P14 I O P14 13 P15 I O P15 14...

Page 7: ...Page 4 30 1 5 Product Encapsulation Diagram 1 HLK B30 encapsulation size 1 6 Block diagram Diagram 2 HLK B30 module architecture diagram...

Page 8: ...nts Power requirements Power input voltage DC 3 3 0 3V No load running current 130 50mA Supply current requirements 1000mA 1 9 WiFi Transmit power consumption WiFi Transmit power consumption Mode Rate...

Page 9: ...p connected router 101 342 ma Udp send After connecting to the AP UDP packets are sent at full speed 93 363 ma SoftAP SoftAP networking status 100 5 193 7 ma SmartConfig Module distribution network st...

Page 10: ...ckly and easily know the module s operating status The module s WiFi indicator has the following states 1 The WiFi indicator flashes twice periodically it indicates that the module is in One click net...

Page 11: ...e can capture all 802 11 frames in the air the APP sends the SSID and password to the WiFi module through UDP broadcast or multicast with certain coding rules the module parses them out and then conne...

Page 12: ...ck mode You can use the serial configuration tool to set the module to one click mode Diagram 5 Set to one click network mode 2 3 Serial to WiFi STA Diagram 6 Module as STA The module converts the ser...

Page 13: ...fault mode is transparent transmission mode By pulling down the ES0 PIN5 pin for more than 50ms to enter the at command mode the module will regard the received data as an at command and send the at c...

Page 14: ...all TCP Clients When the module is as TCP Server it supports up to 5 TCP Client connected to TCP Server 2 6 2 Module as TCP Client Diagram 10 TCP Client In this mode the module will actively connect t...

Page 15: ...P and port The module will only record the remote information on the last connection and the data sent by the serial port will be directly sent to the recorded remote IP and port 2 6 4 Module as UDP C...

Page 16: ...the serial port The instruction format is as follows at command value value value All commands start with at and end with r If the command is not encapsulated in this format it will not be processed...

Page 17: ...3 Set the serial port at uart Command type Grammar Syntax Return and description Executing command at uart 115200 8 n 1 at uart 115200 8 n 1 Ok Description Set serial parameters Query command at uart...

Page 18: ...and type Grammar Syntax Return and description Executing command at mode client at mode client Ok Description Set the module to client mode Query command at mode at mode client Description client clie...

Page 19: ...setting parameters 3 10 System restart exit at command mode at reconn Command type Grammar Syntax Return and description Executing command at reconn 1 at reconn 1 Description Exit at command mode Quer...

Page 20: ...net_ip 192 168 16 254 255 255 255 0 192 168 16 254 ok Description Set the module s ip gateway dns Query command at net_ip at net_ip 192 168 16 254 255 255 255 0 192 168 16 254 Description Query module...

Page 21: ...e Grammar Syntax Return and description Executing command at uartpacktimeout 200 at uartpacktimeout 200 ok Description Set the framing time of the module to 200ms Query command at uartpacktimeout at u...

Page 22: ...tepro r n Query socket connection protocol at mode r n Query TCP connection mode at uart r n Query serial port parameters at uartpacklen r n Query the frame length of the serial port at uartpacktimeou...

Page 23: ...5 255 255 0 192 168 11 1 r n Set the module s IP at remoteip 192 168 11 245 r n Set the IP to be connected to the remote end at remoteport 8080 r n Set the port to be connected at the remote end at re...

Page 24: ...i_ap at netmode 2 r n Set to wireless network card mode at WiFi_conf Hi Link_ wpa2_aes 0000000000 r n Set the hotspot name and password for WiFi connection at dhcpc 1 r n Using the method of dynamical...

Page 25: ...at uartpacktimeout 10 ok at net_commit 1 4 4 Restore factory settings Code char commands_device_default at default 1 r n Restore factory settings Com_send commands_device_default Returning returns at...

Page 26: ...to be sent 2 Serial port number selection 3 Work mode selection 4 WiFi name and password 5 Network protocol selection 6 Serial parameters 7 Commit configuration 8 Query configuration 9 Enter transpar...

Page 27: ...e please connect according to the following figure Diagram 14 Serial configuration interface Open the upgrade software select the corresponding serial port set the baud rate to 115200 and complete the...

Page 28: ...Page 25 30 Diagram 16 1 Burn Then short press the reset button again and the upgrade begins Diagram 17 2 Short press the reset button In progress of upgrading...

Page 29: ...h connection is successful the module will send the data received from Bluetooth through the serial port and the data received by the module serial port will be sent through Bluetooth The module Bluet...

Page 30: ...Page 27 30 Diagram 19 Bluetooth search list Then select the last item Diagram 20 Bluetooth attribute list...

Page 31: ...network Bluetooth network configuration is to connect the Bluetooth send the WiFi name and password to the module and then the module connects to the router according to the received WiFi name and pa...

Page 32: ...e and password and then click the Start Configuration button The phone will send the hotspot name and password to the module via Bluetooth After receiving the module will save and then restart it and...

Page 33: ...age 30 30 9 Appendix A Document Revision Record Version number Scope of revision Date V1 00 First edition 2019 6 27 V1 01 First edition Modify the description of the serial port upgrade tool 2019 12 2...

Reviews: