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 27 of 40

700 Series Color Mobile Computer User's Manual: Section 7 - Programming, pages 220 to 229

Pages 220 to 229 of 346, from 700 Series Color Mobile Computer User's Manual

The original document is the PDF (2.9 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.

Filed in the catalog under the Intermec Model 720, Intermec Model 740, Intermec Model 741, Intermec Model 751, Intermec Model 760, Intermec Model 710, Intermec Model 730 and Intermec Model 761

Page 220

Programming

SECTION 7

Creating CAB Files with CAB Wizard After you create the .INF file and the optional SETUP.DLL file, use the CAB Wizard to create the .CAB file. The command-line syntax for the CAB Wizard is as follows: cabwiz.exe “inf_file” [/dest dest_directory] [/err error_file] [/cpu cpu_type [cpu_type]]

A batch file, located in <program> directory, with the following commands, works well: cd\“Windows CE Tools”\WCE211\”MS HPC Pro”\support\appinst\bin cabwiz.exe c:\appsoft\<program>\<inf_file_name> cd \appsoft\<program>

“inf_file” The SETUP.INF file path. dest_directory The destination directory for the .CAB files. If no directory is specified, the .CAB files are created in the “inf_file” directory. error_file The file name for a log file that contains all warnings and errors that are encountered when the .CAB files are compiled. If no file name is specified, errors are displayed in message boxes. If a file name is used, the CAB Wizard runs without the user interface (UI); this is useful for automated builds. cpu_type Creates a .CAB file for each specified microprocessor tag. A microprocessor tag is a label used in the Win32 SETUP.INF file to differentiate between different microprocessor types. The /cpu parameter, followed by multiple cpu_type values, must be the last qualifier in the command line. EXAMPLE:

This example creates .CAB files for the SH3 and MIPS microprocessors, assuming that the Win32 SETUP.INF file contains the SH3 and MIPS tags: cabwiz.exe “c:\myfile.inf” /err myfile.err /cpu sh3 mips

" NOTE:

CABWIZ.EXE, MAKECAB.EXE, and CABWIZ.DDF (Windows CE files available on the Windows CE Toolkit) must be installed in the same directory on the desktop computer. Call CABWIZ.EXE using its full path for the CAB Wizard application to run correctly.

Troubleshooting the CAB Wizard To identify and avoid problems that might occur when using the CAB Wizard, follow these guidelines: "

"

"

" "

"

Use %% for a percent sign (%) character when using this character in an .INF file string, as specified in Win32 documentation. This will not work under the [Strings] section. Do not use .INF or .CAB files created for Windows CE to install applications on Windows-based desktop platforms. Ensure the MAKECAB.EXE and CABWIZ.DDF files, included with Windows CE, are in the same directory as CABWIZ.EXE. Use the full path to call CABWIZ.EXE. Do not create a .CAB file with the MAKECAB.EXE file included with Windows CE. You must use CABWIZ.EXE, which uses MAKECAB.EXE to generate the .CAB files for Windows CE. Do not set the read-only attribute for .CAB files. 700 Series Color Mobile Computer User’s Manual

7-11

Page 221

Programming

SECTION 7

FTP Server FTP support is provided through the FTP Server application FTPDCE.EXE (MS Windows CE Versions) which is provided as part the base system. FTPDCE is the Internet File Transfer Protocol (FTP) server process. The server can be invoked from an application or command line. Besides servicing FTP client requests the FTP Server also send a “network announcement” to notify prospective clients of server availability. Synopsis: ftpdce [ options ] Options: –Aaddr

" NOTE:

Sets the single target address to which to send the network announcement. Default is broadcast.

–Bbyte

Sets the FTP data block size. Smaller sizes may be useful over slower links. Default is 16384.

–Cname

Sets the device name. Used by Intermec management software.

- Fvalue

Disables the default Intermec account. A value of “0” disables the account. Default is “1”.

Disabling the default account without providing a working access control list on the server will result in a device that will not accept any FTP connections.

–Hsec

Sets the interval between network announcements in seconds. A value of “0” turns the network announcement off. Default is 30 seconds.

–Iip

Sets the preferred 6920 Communications Server. [optional]

–Llog

Sets the state of logging. Default is 0 (disabled).

–Nsec

Specifies the number of seconds to wait before starting FTP server services.

–Pport

Sets the UDP port on which the network announcement will be sent. Default port is 52401.

–Qport

Sets the port on which the FTP Server will listen for connections. Default port is 21.

–Rdir

Sets the FTP mount point to this directory. Default is the root directory of the drive from which the FTP Server program was executed.

–Tscript

Sets the script name for the 6920 Communications Server to process.

–Uurl

Sets the default URL for this device.

–Z“parms”

Sets extended parameters to be included in the network announcement.

The File Transfer Protocol (FTP) server transfers files over TCP/IP networks. The FTPDCE.EXE program is a version that does not display a window, but can run in the background.

7-12

700 Series Color Mobile Computer User’s Manual

Page 222

Programming

SECTION 7

FTPDCE is the Internet File Transfer Protocol (FTP) server process. The server can be invoked from an application or command line. Besides servicing FTP client requests, the FTP Server also sends a “network announcement” to notify prospective clients of server availability. Remarks: The FTP Server currently supports the following FTP requests: ACCT (Ignored) Specifies account. CDUP Changes to the parent directory of the current working directory. CWD Changes working directory. DELE Deletes a file. HELP Gives help information. LIST (This FTP request is the same as the ls - lgA command). Gives list files in a directory. MKD Makes a directory. MODE (Always Uses Binary). Specifies data transfer mode. NLST Gives a name list of files in directory (this FTP request is the same as the ls command). NOOP Does nothing. PASS Specifies a password. PORT Specifies a data connection port. PWD Prints the current working directory. QUIT Terminates session. RETR Retrieves a file. RMD Removes a directory. RNFR Specifies rename--from file name. RNTO Specifies rename--to file name. STOR Stores a file. SYST Shows the operating system type of server system. 700 Series Color Mobile Computer User’s Manual

7-13

Page 223

Programming

SECTION 7

TYPE (Binary transfers only.) Specifies the data transfer type with the Type parameter. USER Specifies user name. XCUP (Not Normally Used) Changes the parent directory of the current working directory. XCWD (Not Normally Used) Changes the current directory. XMKD (Not Normally Used) Creates a directory. XPWD (Not Normally Used) Prints the current working directory. XRMD (Not Normally Used) Removes a directory. SITE The following nonstandard or operating system (OS)-specific commands are supported by the SITE request. For Microsoft FTP clients, you can send site commands by preceding the command with “quote” such as “quote site status.” ATTRIB Gets or sets the attributes of a given file. (SITE ATTRIB) Usage: QUOTE SITE ATTRIB [+R | - R] [+A | - A ] [+S | - S] [+H | - H] [[path] filename] + Sets an attribute. – Clears an attribute. R Read-only file attribute. A Archive file attribute. S System file attribute. H Hidden file attribute. To retrieve the attributes of a file, only specify the file. The server response will be: 200- AD SHRCEIX filename If the flag exists in its position shown above, it is set. Also, in addition to the values defined above, there is also defined: C Compressed file attribute. E Encrypted file attribute. I INROM file attribute. X XIP file attribute (execute in ROM, not shadowed in RAM). BOOT Reboots the server OS. This will cause the system on which the server is executing to reboot. The FTP Server will shut down cleanly before reboot. All client connections will be terminated. Cold boot is default except for the PocketPC build in which the default is warm boot. (SITE BOOT) Usage: QUOTE SITE BOOT [WARM | COLD] COPY Copies a file from one location to another. (SITE COPY) Usage: QUOTE SITE COPY [source] [destination] EXAMPLE: 7-14

QUOTE SITE COPY ‘\Storage Card\one.dat’ ‘\Storage Card\two.dat’

700 Series Color Mobile Computer User’s Manual

Page 224

Programming

SECTION 7

EXIT Exits the FTP Server. This command will shut down the FTP Server thus terminating all client connections. (SITE EXIT) Usage: QUOTE SITE EXIT HELP Gives site command help information. (SITE HELP) Usage: QUOTE SITE HELP [command] KILL Terminates a running program. (SITE KILL) Usage: QUOTE SITE KILL [program | pid] LOG Opens or closes the program log. (SITE LOG) Usage: QUOTE SITE LOG [open [filename]| close] PLIST Lists the running processes (not supported on all platforms). (SITE PLIST) Usage: QUOTE SITE PLIST RUN Starts a program running. If the program to run has spaces in path or filename, wrapping the name with single quotes is required. Usage: QUOTE SITE RUN [program] EXAMPLE:

QUOTE SITE RUN ‘\Storage Card\app.exe’

STATUS Returns the current settings of the FTP Server. MAC, serial number, model, IP address, network announcement information as well as OS memory usage are returned. (SITE STATUS) Usage: QUOTE SITE STATUS TIMEOUT Toggles idle timeout between 120 to 1200 seconds (2 to 20 minutes). If this timer expires with no activity between the client and the server, the client connection will be disconnected. If the optional seconds argument is supplied, the server will set the connection timeout to the number of seconds specified. Default is 120 seconds or 2 minutes. (SITE TIMEOUT) Usage: QUOTE SITE TIMEOUT [seconds] The remaining FTP requests specified in RFC 959 are recognized, but not implemented. The banner returned in the parenthetical portion of its greeting shows the version number of the FTP Server as well as the MAC address, serial number and OS of the machine hosting the server. 700 Series Color Mobile Computer User’s Manual

7-15

Page 225

Programming

SECTION 7

The FTP Server supports browsing from the latest Netscape and Microsoft web browsers. Drag-and-drop capability is available using this environment. The FTPDCMDS subdirectory contains commands that can be used from the web browser. Click EXITME.BIN to execute a SITE EXIT command. " Click REBOOTME.BIN to execute SITE BOOT command. " Use the GET command on these files to have the FTP Server execute these commands. Security: A customer configurable access control list may be installed on the 700 Series Computer. This list will allow customers to restrict access via the FTP Server to the users they wish. This is in addition to the default Intermec account which can be disabled using the - F0 option at runtime. "

The access control list is named FTPDCE.TXT and is placed in the same directory on the 700 Series Computer as the FTPDCE.EXE server. The FTP Server will encrypt this file to keep the information safe from unauthorized users. This file is encrypted when the FTP Server is started so a file that is placed onto the 700 Series Computer after the FTP Server starts will require a restart of the FTP Server to take effect. The format of the FTPDCE.TXT is as follows: FTPDCE:user1!passwd1<cr><lf>user2!passwd2<cr><lf>user3!passwd3<cr><lf>...

" NOTE:

The user accounts and passwords are case sensitive.

Once the access control list is encrypted on the 700 Series Computer, the FTP Server will hide this file from users. Once an access control list has been installed on the 700 Series Computer, a new one will not be accepted by the FTP Server until the previous one is removed. Encrypted access control lists are not portable between 700 Series Computers.

Stopping the FTP Server from your Application

To allow application programmers the ability to programmatically shut down the FTP Server, the FTP Server periodically tests to see if a named event is signaled. The name for this event is “ITC_IFTP_STOP” (no quotes). For examples on how to use this event, consult the Microsoft Developer Network Library at http://www.msdn.com. The MSDN Library is an essential resource for developers using Microsoft tools, products, and technologies. It contains a bounty of technical programming information, including sample code, documentation, technical articles, and reference guides.

7-16

700 Series Color Mobile Computer User’s Manual

Page 226

Programming

SECTION 7

Autostart FTP This automatically starts the FTP Server (FTPDCE.EXE) when the 700 Series Computer is powered on. This is provided with the NDISTRAY program, which displays the popup menu that currently allows you to load and unload the network drivers. Tap the antenna icon in the System Tray of the Today screen (a sample antenna icon is circled below) to get this pop-up menu.

The default is to start the FTP Server at boot time, unless the following registry entry is defined and set to “0” which disables AutoFTP. “1” enables the AutoFTP. The entry can be set from the NDISTRAY pop-up menu by selecting either AutoFTP On or AutoFTP Off. HKEY_LOCAL_MACHINE\Software\Intermec\Ndistray\StartupIFTP

These new entries are located below the selections to load the network drivers. If the StartupIFTP registry key is not defined, the FTP Server is loaded by default, to provide “out-of-the-box” capability for customers who want to begin loading files to the 700 Series Computer without any prior configuration. " NOTE:

If a network driver is unloaded using the NDISTRAY popup menu, and the FTP Server is running, the FTP Server is stopped.

On a resume, if AutoFTP is enabled and the FTP Server is running, it is stopped and restarted. NDISTRAY uses a helper application named RESETIFTP to implement the restart on resume feature. To do an AutoFTP Installation Check: 1. Ensure the FTP Server is running “out-of-the-box” the first time. 2. Tap Start → Today to access the Today screen, then tap the antenna icon in the System Tray to bring up the NDISTRAY pop-up menu. Select AutoFTP Off to disable AutoFTP. Do a warm boot and confirm the FTP Server is not running.

700 Series Color Mobile Computer User’s Manual

7-17

Page 227

Programming

SECTION 7

3. Tap Start → Today to access the Today screen, then tap the antenna icon in the System Tray to bring up the NDISTRAY pop-up menu. Select AutoFTP On to enable AutoFTP, reboot and confirm it is running.

4. Unload the network driver when the FTP Server is running and confirm that it is not running any more. 5. Load the FTP Server, establish a connection, then suspend and resume. The server should still be running, but the FTP connection to the client should be dropped.

7-18

700 Series Color Mobile Computer User’s Manual

Page 228

Programming

SECTION 7

Full Screen Pocket PC is a hardware specification created by Microsoft Corporation. Devices that wish to carry the Pocket PC logo must meet the minimum hardware requirements set in the Pocket PC specification. Manufacturers are free to add extra hardware functionality. Pocket PC 2002 devices also use a specialized version of the CE operating system. This OS is built from Windows CE 3.0 but contains customizations, most notably the lack of a desktop and the addition of the Today Screen. To carry the Pocket PC logo, all devices must be tested at an Independent Test Laboratory. The ITL testing is done based on Microsoft requirements. The test lab then reports the findings back to Microsoft Corporation and Intermec Technologies. If the 700 Series Computer passed all tests, Intermec is allowed to ship the device with the Pocket PC logo. Each time the operating system is modified, Intermec must resubmit to ITL testing. This means we cannot change the operating system much and still be a Pocket PC device. For example, if we remove Word from the Start menu, the device would fail ITL testing and we would not be able to ship devices with the Pocket PC logo. Although many customers want a Pocket PC device, some customers would prefer that their users not have access to all of the Pocket PC features. Intermec cannot customize the operating system in any way but a custom application can: Delete items from the Start menu, and Programs folder. These items are just shortcuts in the file system so the application is not really being deleted. Cold booting the device will bring these items back so the application will need to be run on every cold boot. " Use the RegFlushKey() API to save a copy of the registry to a storage device. See Section 3, “Installing Applications and Updating System Software,” for more information on how to do this. Saving a copy of the registry will allow most system settings to be restored in a cold boot situation. " Use the SHFullScreen() API in conjunction with other APIs to make the application take up the entire display and prevent the start menu from being available. " Remap keys and disable keys on the keypad. " Create a custom SIP. " Make changes to the registry to configure the device. Should you want your 700 Series Computer to display a full screen, keep in mind that your computer is Pocket-PC certified by Microsoft Corporation. Check out resources on programming for the Pocket PC, using the following links. These instructions give full instructions on how to display full screen. "

Instructions on how to create a full screen application for eVC++ applications using an SHFullScreen() API: http://support.microsoft.com/support/kb/articles/Q266/2/44.ASP Instructions on how to create a full screen application for eVB applications also using the SHFullScreen() API: http://support.microsoft.com/support/kb/articles/Q265/4/51.ASP

700 Series Color Mobile Computer User’s Manual

7-19

Page 229

Programming

SECTION 7

Kernel I/O Controls This describes the KernelIoControl() functions available to application programmers. Most C++ applications will need to prototype the function as the following to avoid link and compile errors. extern “C” BOOL KernelIoControl(DWORD dwIoControlCode, LPVOID lpInBuf, DWORD nInBufSize, LPVOID lpOutBuf, DWORD nOutBufSize, LPDWORD lpBytesReturned);

IOCTL_HAL_GET_DEVICE_INFO This IOCTL returns either the platform type or the OEMPLATFORM name based on an input value. Syntax: BOOL KernelIoControl( IOCTL_HAL_GET_DEVICE_INFO, LPVOID lpInBuf, DWORD nInBufSize, LPVOID lpOutBuf, DWORD nOutBufSize, LPDWORD lpBytesReturned ); Parameters: lpInBuf

Points to a DWORD containing either the SPI_GETPLATFORMTYPE or SPI_GETOEMINFO value.

lpInBufSize

Must be set to sizeof(DWORD).

lpOutBuf

Must point to a buffer large enough to hold the return data of the function. If SPI_GETPLATFORMTYPE is specified in lpInBuf, then the “PocketPC\0” Unicode string is returned. If SPI_GETOEMINFO is specified in lpInBuf, then the “Intermec 700\0” Unicode string is returned.

nOutBufSize

The size of lpOutBuf in bytes. Must be large enough to hold the string returned.

lpBytesReturned The actual number of bytes returned by the function for the data requested. Return Values: Returns TRUE if function succeeds. Returns FALSE if the function fails. GetLastError() may be used to get the extended error value.

7-20

700 Series Color Mobile Computer User’s Manual