Receive Socket Status Indicating Closed Connection; Extended Socket Example: Udp; Send A Socket Create Frame - Digi XBee 3 Cellular LTE-M User Manual

Smart modem
Table of Contents

Advertisement

Extended Socket frames
7E 01 C5 CD 00 00 00 48 54 54 50 2F 31 2E 31 20 32 30 30 20 4F 4B 0D 0A 53 65 72 76 65 72 3A 20
6E 67 69 6E 78 2F 31 2E 34 2E 36 20 28 55 62 75 6E 74 75 29 0D 0A 44 61 74 65 3A 20 54 68 75 2C 20
31 38 20 4A 75 6C 20 32 30 31 39 20 31 36 3A 31 33 3A 34 37 20 47 4D 54 0D 0A 43 6F 6E 74 65 6E 74
2D 54 79 70 65 3A 20 74 65 78 74 2F 70 6C 61 69 6E 3B 20 63 68 61 72 73 65 74 3D 22 55 54 46 2D 38
22 3B 20 63 68 61 72 73 65 74 3D 75 74 66 2D 38 0D 0A 43 6F 6E 74 65 6E 74 2D 4C 65 6E 67 74 68
3A 20 35 33 0D 0A 43 6F 6E 6E 65 63 74 69 6F 6E 3A 20 63 6C 6F 73 65 0D 0A 58 2D 50 6F 77 65 72
65 64 2D 42 79 3A 20 45 78 70 72 65 73 73 0D 0A 41 63 63 65 73 73 2D 43 6F 6E 74 72 6F 6C 2D 41
6C 6C 6F 77 2D 4F 72 69 67 69 6E 3A 20 2A 0D 0A 41 63 63 65 73 73 2D 43 6F 6E 74 72 6F 6C 2D 41
6C 6C 6F 77 2D 48 65 61 64 65 72 73 3A 20 58 2D 52 65 71 75 65 73 74 65 64 2D 57 69 74 68 0D 0A
58 2D 4E 75 6D 62 65 72 73 2D 41 50 49 2D 4E 75 6D 62 65 72 3A 20 32 37 30 0D 0A 58 2D 4E 75 6D
62 65 72 73 2D 41 50 49 2D 54 79 70 65 3A 20 74 72 69 76 69 61 0D 0A 50 72 61 67 6D 61 3A 20 6E 6F
2D 63 61 63 68 65 0D 0A 43 61 63 68 65 2D 43 6F 6E 74 72 6F 6C 3A 20 6E 6F 2D 63 61 63 68 65 0D
0A 45 78 70 69 72 65 73 3A 20 30 0D 0A 0D 0A 32 37 30 20 69 73 20 74 68 65 20 61 76 65 72 61 67 65
20 6E 75 6D 62 65 72 20 6F 66 20 64 61 79 73 20 69 6E 20 68 75 6D 61 6E 20 70 72 65 67 6E 61 6E 63
79 2E 8B

Receive Socket Status indicating closed connection

Finally, due to the "Connection" header in the request, the server should remotely close the
connection.
Field
Frame type
Socket ID
Status
Example Socket Status received from XBee indicating connection lost:
7E 00 03 CF 00 07 29
When Socket Status indicating a connection close is received, the socket ID will have been de-
allocated by the XBee and no further operations are possible or necessary using that ID.

Extended Socket example: UDP

UDP is connection-less, so this example demonstrates that a Socket Connect frame is not required to
begin communication and that multiple peers can be used with a single socket.

Send a Socket Create frame

Field
Frame type
Frame ID
Protocol
UDP Socket Create frame data:
7E 00 03 40 01 00 BE
Digi XBee® 3 Cellular LTE-M/NB-IoT Global Smart Modem User Guide
Value
0xCF
(TX Status)
0x00
0x07 (Connection lost)
Value
0x40
(Socket Create)
0x01
0x00 (UDP)
Extended Socket example: UDP
168

Advertisement

Table of Contents
loading

This manual is also suitable for:

Xbee 3 cellular nb-iot

Table of Contents