API operation
Frame descriptions
XBee Wi-Fi RF Module User Guide
116
Transmit (TX) Request: IPv4 - 0x20
Description
This frame uses the serial data service. The frame gives greater control to the application over the IP
setting for the data.
Format
The following table provides the contents of the frame.
Frame data
fields
Offset
Description
Frame type
3
0x20
Frame ID
4
Set to a value that will be passed back in the Tx Status frame. 0 disables
the Tx Status frame.
IPv4 32-bit
destination
address
MSB 5
Use
0xFFFFFFFF
for broadcast when the protocol is UDP.
6
7
8
16-bit
destination port
MSB 9
UDP or TCP port number
LSB 10
16-bit source
port
MSB 11 UDP or TCP port number
To send a UDP packet, this must match the port number of the listening
port as specified by
C0
.
To send a TCP packet on a new connection, this must be
0
.
LSB 12
Protocol
13
Protocol use for the transmitted data:
0
= UDP
1
= TCP
Transmit
options bitfield
14
Bit fields are offset 0
Bit field 0 - 7. Bits 0, and 2-7 are reserved, bit 1 is not.
BIT 1 =
1
- Terminate the socket after transmission is complete
0
- Leave the socket open (use TCP timeout)
Ignore this bit for UDP packets.
All other bits are reserved and should be
0
.
RF data
15
Up to 1400 bytes of data. This is 8 bytes more than the maximum size
reported by
NP
because it does not require an application header.
16
17
18
19