Browse
(440) 299-7778
Menu
(440) 299-7778
One-year parts and labor warranty30-day money-back guaranteeEnglishEspañolContact

The text of a manual · part 15 of 43

TRAKKER Antares 2455 Vehicle-Mount Terminal User's Manual, pages 141 to 150

Pages 141 to 150 of 422

The original document is the PDF (1.4 MB). This is its text as extracted, unedited; tables and drawings read best in the PDF, and each page heading opens it at that page.

For the Intermec 2455

Page 141

nugget CODE39 Operating the Terminal in a Network

4

To send and receive configuration data, you need to write an application for the host that can communicate with a T2455 directly via an access point or through the Ethernet network. You use the Terminal Message Format (TMF) protocol to send and receive transactions between the host application and the terminal. For more about developing an application, see “Transferring Files in a TCP/IP Direct Connect Network” later in this chapter. Note: You can continue running an application on the T2455 while configuring the terminal from the host. To set up the host computer •

Verify that you can communicate with the T2455.

To set up the application •

Prepare and write a host application that can communicate with the T2455. Configuration commands must be sent to network port 6000 on the terminal. Message transactions to and receive transactions from the T2455 on network port 6000 must conform to the following format: TMF field configuration command where: TMF field configuration command is a 2-byte field containing one of these values: CG

Configuration Get request sent from the host application.

Cg

Configuration Get response sent from the T2455 to the host.

CS

Configuration Set request sent from the host application.

Cs

Configuration Set response sent from the T2455 to the host.

is the reader or configuration command or commands you want to set on the terminal, or the current value you want to retrieve from the terminal. To save configuration changes in flash memory, send the reader command .+1 as the last command. For a list of commands, see Chapter 8, “Reader Command Reference,” or Chapter 9, “Configuration Command Reference.”

4-23

Page 142

TRAKKER Antares 2455 Vehicle-Mount Terminal User’s Manual nugget CODE39

Example 1 In the host application, you want to get the current values of two configuration commands from the T2455. Send this transaction from the host application: CG$+NABV

Note: The transaction header is not shown in this example. You do not need a transaction header for a host application in a TCP/IP network. where: CG is a TMF Configuration Get request.

$+ is the Change Configuration reader command.

NA is the Network Activate configuration command.

BV is the Beep Volume configuration command.

The T2455 returns this transaction to the host application. Cg$+NA1BV4 where: Cg is a TMF Configuration Get response.

$+ is the Change Configuration reader command.

NA1 means the Network Activate configuration command is currently set to a value of 1, which means that the 2.4 GHz RF network is enabled.

BV4 means the Beep Volume configuration command is currently set to a value of 4, which is a very loud beep volume.

Example 2 In the host application, you want to set the value for two configuration commands on the T2455. Send this transaction from the host application: CS$+BV3KA1

Note: The transaction header is not shown in this example. You do not need a transaction header for a host application in a TCP/IP network. where:

4-24

CS is a TMF Configuration Set request.

$+ is the Change Configuration reader command.

BV3 sets the Beep Volume configuration command to a value of 3, which is a very loud beep volume.

KA1 sets the Keypad Caps Lock configuration command to a value of 1, which enables the Keypad Caps Lock.

Page 143

nugget CODE39 Operating the Terminal in a Network

4

The T2455 returns this transaction to the host application. Cs$+BV3KA1 where: Cs is a TMF Configuration Set response.

$+ is the Change Configuration reader command.

BV3 means the Beep Volume configuration command has been changed to a value of 3, which is a loud beep volume.

KA1 means the Keypad Caps Lock configuration command has been changed to a value of 1, which enables the Keypad Caps Lock.

Transferring Files in a TCP/IP Direct Connect Network You can use an application on the host computer to transfer files and send data between the terminal and host in a TCP/IP direct connect network. To initiate file transfers from the host, you need to write a host application that can communicate directly with the T2455. You use the file management reader commands such as Receive File and Transmit File to transfer files between the T2455 and the host. For help, see Chapter 8, “Reader Command Reference.” To initiate file transfers from the terminal, you do not need to develop a host application as described in this section. You can use the Receive File and Transmit File within a terminal application or by scanning bar code labels. For help, see Chapter 8, “Reader Command Reference.” Note: You can continue running an application on the T2455 while configuring the terminal or transferring files from the host. To use the built-in TFTP client on the T2455, you need the following: •

TFTP (Trivial File Transfer Protocol) server must be running on the host.

•

TFTP server must be running on at least a Pentium processor or equivalent.

•

T2455 must be communicating with the host that is running the TFTP server.

•

The TFTP server or some other application on the host must be able to send the reader command on the network.

To transfer files or send configuration data from the host 1. Make sure the TFTP server is running on the host and the T2455 is communicating with the host. 2. Start the host application that can send reader commands to the terminal.

4-25

Page 144

TRAKKER Antares 2455 Vehicle-Mount Terminal User’s Manual nugget CODE39

3. Send the two-character TMF code, CS (Configuration Set request) followed by the reader or configuration command. For help on TMF, see “Configuring the T2455 in a TCP/IP Direct Connect Network” earlier in this chapter. For example, to send the application INVENTRY.BIN from drive C on the host to drive C on the T2455, enter this command: CS.%R,c:inventry.bin,c:inventry.bin

For command information, see Chapter 8, “Reader Command Reference,” or Chapter 9, “Configuration Command Reference.” CLIENT.CPP is the source for a sample application you can run on the host. You can use the CLIENT.CPP application to send reader commands to the T2455 and receive the resulting messages. The source code for the sample utilities CLIENT.CPP and the include file UTILS.H is shown on the next pages. You can build the application using Microsoft Visual C++ version 4.0 (or higher) and the Windows sockets library that is included with Microsoft Visual C++. You can also develop your own application to meet the needs of your host environment. You run the resulting application (CLIENT.EXE) from the DOS command line. The application expects NCM to be defined as the TRAKKER Antares terminal IP address in the hosts file. Once running, the application prompts you to enter a reader command, which it then sends to the T2455. The application also displays any return messages. Reader commands are handled by the TRAKKER Antares operating system, so you can continue running an application while you use the CLIENT.EXE application to send commands. To use the sample utility CLIENT.CPP 1. Make sure the TFTP server is running on the host and the T2455 is communicating with the host. 2. In the hosts file on the host, add the terminal IP addresses and the target name, NCM. For example, to send files or data to the T2455 with an IP address of 192.9.200.130, add this line to the hosts file: 192.9.200.130 ncm

3. Start the CLIENT.EXE application on the host. 4. When the “Enter Command” prompt appears on the host, enter the two-character TMF code, CS (Configuration Set request) followed by the reader or configuration command. For example, to send the application INVENTRY.BIN from drive C on the host to drive C on the T2455, enter this command: CS.%R,c:inventry.bin,c:inventry.bin

Or, to change the beep volume to very loud, enter this command: CS$+BV4

4-26

Page 145

nugget CODE39 Operating the Terminal in a Network

4

For command information, see Chapter 8, “Reader Command Reference,” or Chapter 9, “Configuration Command Reference.”

CLIENT.CPP Sample Application for a TCP/IP Direct Connect Network #include <windows.h> #include <stdio.h> #include "Utils.h" // our application uses a fixed port number const unsigned short SERVER_PORT = 6000; const unsigned short CLIENT_PORT = 6001; // we will default to the local host machine // unless argv[1] has a hostname const char SERVER_HOSTNAME[] = "ncm"; int main(int argc, char *argv[]) { // turn on the socket library for this process WSADATA wsad; int error = WSAStartup(MAKEWORD(1,1), &wsad); if (error != 0) ErrorMessage("WSAStartup", WSAGetLastError()); // create an unitialized connection-oriented socket SOCKET connection; connection = socket(PF_INET, SOCK_DGRAM, 0); if (connection == INVALID_SOCKET) ErrorMessage("socket", WSAGetLastError()); // lookup the IP address of the requested host HOSTENT *phostent = gethostbyname(argc == 2 ? argv[1] : SERVER_HOSTNAME); if (phostent == 0) ErrorMessage("gethostbyname", WSAGetLastError()); // define a SOCKADDR to contain the IP address of the // server and the port number of our application SOCKADDR_IN serverAddress; memset(&serverAddress, 0, sizeof(serverAddress)); serverAddress.sin_family = PF_INET; serverAddress.sin_port = htons(SERVER_PORT); memcpy(&serverAddress.sin_addr, phostent->h_addr_list[0], phostent->h_length); // Bind a well known port of 6000 to the socket SOCKADDR_IN clientAddress; memset(&clientAddress, 0, sizeof(clientAddress)); clientAddress.sin_family = PF_INET; clientAddress.sin_port = htons(CLIENT_PORT); clientAddress.sin_addr.s_addr = htonl(INADDR_ANY); if(!(bind(connection, (LPSOCKADDR)&clientAddress, sizeof(clientAddress)) ==0)) { ErrorMessage("bind", WSAGetLastError()); }

4-27

Page 146

TRAKKER Antares 2455 Vehicle-Mount Terminal User’s Manual nugget CODE39

CLIENT.CPP Sample Application for a TCP/IP Direct Connect Network (continued) // attempt to connect to the server error = connect(connection, (const SOCKADDR *)&serverAddress, sizeof(serverAddress)); if (error != 0) ErrorMessage("connect", WSAGetLastError()); // check the local name for the socket SOCKADDR_IN localName; memset(&localName, 0, sizeof(localName)); int localNameLength = sizeof(localName); error = getsockname(connection, (LPSOCKADDR)&localName, &localNameLength); // run the user-interface char sz[1024]; char rz[1024]; BOOL bConnectionAlive = TRUE; printf("> "); int Scount, Rcount; int cbRecv, cbSend; Scount = Rcount = 0; int cbLen, rcLen; unsigned char *psend = (unsigned char *)sz; // continue while not EOF on the console and the connection is alive while (bConnectionAlive) { // send the string entered by the user printf("Enter Command:\n"); printf("> "); gets(sz); if(sz[0] != 'q') { cbLen = strlen(sz); cbSend = send(connection, (const char *)psend, cbLen, 0); if (cbSend < 0) { Scount++; printf("send failed %d\n", Scount); bConnectionAlive = FALSE; ErrorMessage("send", WSAGetLastError()); } Sleep(2000); // receive the converted string from the server memset(&rz, 0, sizeof(rz)); rcLen = sizeof(rz); cbRecv = recv(connection, rz, rcLen, 0); if (cbRecv < 0) {

4-28

Page 147

nugget CODE39 Operating the Terminal in a Network

4

CLIENT.CPP Sample Application for a TCP/IP Direct Connect Network (continued) Rcount++; printf("receive failed %d\n", Rcount); ErrorMessage("receive", WSAGetLastError()); bConnectionAlive = FALSE; } // printf the converted string printf("response:%s\n",rz); printf("\n> "); Sleep(1000); } else bConnectionAlive = FALSE; } // release the resources held by the socket error = closesocket(connection); if (error != 0) ErrorMessage("closesocket", WSAGetLastError()); // release the resources held by the socket library error = WSACleanup(); if (error != 0) ErrorMessage("WSACleanup", WSAGetLastError()); return 0; }

UTILS.H Utility (Used by CLIENT.CPP) #include <windows.h> inline void ErrorMessage(LPCTSTR szFn, DWORD dwError = GetLastError()) { TCHAR szTitle[1024]; TCHAR szPrompt[1024]; BOOL bRet = FormatMessage(FORMAT_MESSAGE_FROM_SYSTEM, 0, dwError, 0, szPrompt, sizeof(szPrompt), 0); if (!bRet) lstrcpy(szPrompt, __TEXT("Unknown Error")); wsprintf(szTitle, __TEXT("%s failed with error code (0x%x)!"), szFn, dwError); int id = MessageBox(HWND_DESKTOP, szPrompt, szTitle, MB_ABORTRETRYIGNORE|MB_SETFOREGROUND); if (id != IDIGNORE) ExitProcess(0); }

4-29

Page 148

TRAKKER Antares 2455 Vehicle-Mount Terminal User’s Manual nugget CODE39

About Network Connectivity and Protocols The TRAKKER Antares 2455 terminal is a data collection terminal with network support. The T2455 communicates with a host computer or other serial device through the COM1 and COM4 serial ports. The T2455 also communicates with a host in the 2.4 GHz RF network either through the DCS 300 or directly through the access points. The access point acts as a bridge between the Ethernet or token ring network and the wireless 2.4 GHz RF network. Note: The T2455 will communicate with either the DCS 300 or the Model 200 Controller. The DCS 300 is a new data collection server that replaces the Model 200 Controller. In a UDP Plus network, the terminal communicates through the DCS 300 to a host on an Ethernet, token ring, twinaxial, coaxial, or SDLC network. In a TCP/IP network, the terminal communicates to the host on an Ethernet or token ring network. The communications protocol stack for the TRAKKER Antares terminal is developed using the Open Systems Interconnection (OSI) seven layer model. The illustration on the next page shows how the 2.4 GHz RF network and the serial port map into the OSI model. The terminal applications are on top of the protocol stack. Intermec provides a terminal communications API (application program interface) to interface to the protocol stack. The API provides a common interface to these Intermec value-added protocols: •

Terminal Message Format (TMF) is an Intermec proprietary protocol that is used to route data and network management messages between applications on the terminal and peer tasks on the DCS 300 or host.

•

UDP Plus is an Intermec protocol built on top of the User Datagram Protocol (UDP). It maximizes the performance of wireless (RF) networks and provides robust data communications.

•

Trivial File Transfer Protocol (TFTP) allows efficient file exchange between the terminal and the DCS 300 or host.

•

Configurable Serial Port (CSP) protocol allows efficient file exchange between the T2455 and the host through RS-232 serial communications. The terminal uses either the XMODEM or YMODEM protocol to transfer files via reader commands.

•

Network management provides network access to the terminal configuration, status, and statistics. Network management uses the Terminal Message Format to receive and send messages.

The remaining layers in the protocol stack are a series of standard protocols that interface with the drivers and hardware needed to support the 2.4 GHz RF network and serial communications.

4-30

Page 149

4 nugget CODE39 Operating the Terminal in a Network

TRAKKER Antares Terminal Protocol Stack and the OSI Model ayers

OSI L ns licatio

5 app

245 tares ation n

KER A

TRAK ns additio I and P A s on unicati Comm ssage al Me Termin at (TMF) Form lus

UDP P l File Trivia rotocol P r fe Trans FTP) (T rk Netwo nt e m urable anage Configl port m seria col proto

Applic n ntatio

Prese n

Sessio port

Trans rk

Netwo

UDP TCP ink

P, and

IP, AR

ICMP

Hz RF 2.4 G ol driver c proto io

Hz rad

2.4 G twork

Data L Serial port driver Serial port al

Physic

2

U.09

2455

Wiredk r Netwo

RF Ne

4-31

Page 150

TRAKKER Antares 2455 Vehicle-Mount Terminal User’s Manual nugget CODE39

The TRAKKER Antares 2455 terminal uses these protocols: Layer

Protocol

Description

Physical

2.4 GHz radio

Provides spread spectrum radio signal control.

Serial Port

Provides RS-232 serial communications.

2.4 GHz RF protocol driver

Provides RF media access control.

Serial port driver

Provides RS-232 (COM1 and COM4) serial communications control that uses CSP and the standard XMODEM or YMODEM protocol for data transfer.

IP, ARP, and ICMP

The Internet Protocol (IP) complies with the standard outlined in RFC 791.

Data Link

Network

The Address Resolution Protocol (ARP) complies with the standard outlined in RFC 826. The Internet Control Message Protocol (ICMP) complies with the standard outlined in RFC 826. Transport

Session and Presentation

UDP

The User Datagram Protocol (UDP) complies with the standard outlined in RFC 768.

TCP

Transmission Control Protocol (TCP) complies with the standard outlined in RFC 793.

UDP Plus

UDP Plus is an Intermec proprietary session layer protocol built on UDP. The UDP Plus session layer provides these services: • • • • • •

Presentation and Application

4-32 guaranteed delivery duplicated message removal link connection and status management network error recovery congestion control device error detection

TFTP

Trivial File Transfer Protocol (TFTP) allows efficient file exchange between the terminal and the DCS 300 or host. TFTP complies with the standard outlined in RFC 1350.

TMF

Terminal Message Format is an Intermec proprietary protocol that is used to route data, configuration, and network management messages between applications on the terminal and peer tasks on the DCS 300 or host.