Udp Server - RAK RAK411 Programming Manual

Spi-wifi module
Table of Contents

Advertisement

dest_port
local_port
Description:
This command is to create a UDP port on the module and set remote IP address and
port number, if you create successful, the module will return a hexadecimal identifier that is
used to manage the connection. This command can create up to eight connections. Port
numbers are in sorted in ascending order.
Return Value:
Parameter
<CODE>
<SOCKET_FLAG>
<STATUS>

4.3.4 UDP Server

Command:
rak_udp_server
Syntax:
typedef struct {
uint32_t cmd;
uint16_t dummy;
uint16_t port;
}rak_server_t;
Parameter:
Parameter
cmd
dummy
port
2
1-65535
2
0-65535
Bytes
Value
2
0xB1,0x00
2
0--7
0
1
-2
-3
-4
Bytes
Value
4
0xB2,0x00,0x00,0x00
2
2
1-65535
Target port number
Local port number
Description
Response Code
Socket identifier
Command successful
Failed to create
Failed to bind
Target port connection
error
Description
Command Code
Invalid data
Local port number
SHENZHEN RAKWIRELESS TECHNOLOGY CO., LTD
38
RAK411 PROGRAMMING MANUAL
COPYRIGHT ©
ETDX1603021415
V1.7

Advertisement

Table of Contents
loading

Table of Contents