Connect to the Daytime server
The Daytime server reports the current Coordinated Universal Time (UTC) value responding to any user input.
Note For help with debugging, see Debugging.
The following table explains the AT commands that you use in this example.
| At command | Value | Description |
|---|---|---|
|
IP (IP Protocol) |
1 |
Set the expected transmission mode to TCP communications. |
|
DL (Destination Address) |
52.43.121.77 |
The target IP of the Daytime server. Note Some carriers may require whitelisted IP addresses. If this IP is not whitelisted by your carrier you will not be able to run this example. |
|
DE (Destination Port) |
232A (0x232A) |
The target port number of the Daytime server. |
|
TD (Text Delimiter)
|
0 |
The text delimiter to be used for Transparent mode, as an ASCII hex code. No information is sent until this character is entered, unless the maximum number of characters has been reached. Set to zero to disable text delimiter checking. |
To communicate with the Daytime server:
- Ensure that the device is set up correctly with the SIM card installed and the antennas connected as described in Connect the hardware.
- Open XBee Studio and Add a device (this should happen automatically).
-
Navigate to the device settings page by one of the following methods:
- Hover over your device and then click Open Settings.
- Click on your device and then click Settings in the left menu.
- Click Configuration in the sidebar, then click Settings, then finally click on your device.
- To switch to TCP communication, in the IP field, select 1 and click the Write button
. - To enter the destination address of the daytime server, in the DL field, type 52.43.121.77 and click the Write button.
- To enter the destination IP port number, in the DE field, type 232A and click the Write button.
- To disable text delimiter checking, in the TD field, type 0 and click the Write button.
-
Navigate to the XBee Console by one of the following methods:
-
Hover over your device and then click Open Device Console.
-
Click on your device and then click XBee Console in the left menu.
-
Click Development in the sidebar, then click XBee Console, then finally click on your device.
Note For instructions on using the Console, see the XBee console topic in the XBee Studio User Guide.
-
- Click the Open button
to open a serial connection to the device. -
Click the Console log, then type in the Console to query the Daytime server.
PDF
