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 2 of 42

JANUS PSK for C/C++ Reference Manual, Version 2.1, pages 11 to 20

Pages 11 to 20 of 414

The original document is the PDF (690 KB). 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 J2020, Intermec J2010 and Intermec J2050

Page 11

Contents

CPU Busy 4-25 CPU Idle 4-26 Enable/Disable Power Management 4-27 Get PM Event 4-28 Get Power Status 4-30 Interface Connect 4-31 Interface Disconnect 4-32 Protected Mode 16-Bit Interface Connect 4-33 Protected Mode 32-Bit Interface Connect 4-35 Restore System BIOS Power-On Defaults 4-37 Set Power State 4-38 Suspend System 4-39 System Standby 4-40

5

Using the PSK With DCM Accessing a Database Server Through DCM 5-3 Defining a Database Transaction 5-4 Configuring DCM 5-5 Sending a Transaction to the Database 5-6 Checking the Return Status Codes 5-7 Return Codes Listed by Calling Parameter 5-9 Return Codes Listed in Numerical Order 5-12 Symbolic Return Codes 5-14 Using a Standby File 5-15 Standby File Structure 5-16 Sample Program 5-17 xi

Page 12

JANUS PSK for C/C++ Reference Manual

A

Status Codes Status Code Bit Values A-3 Status Codes Listed Numerically A-4 Status Codes Listed by Subsystem A-22 Subsystem 0100 RS (Reader Services) A-23 Subsystem 0200 CM (Configuration Management) A-24 Subsystem 0300 SC (Scanner) A-27 Subsystem 0400 DC (Decodes) A-28 Subsystem 0500 RW (Reader Wedge) A-30 Subsystem 0600 CU (Communications) A-32 Subsystem 0800 PM (Power Management) A-34 Subsystem 0A00 TM (Timer) A-35 Subsystem 0B00 BP (Beep) A-36 Subsystem 0E00 IM (Intermec Library) A-37 Subsystem 0F00 LG (Event Logger) A-38 Subsystem 1000 KB (Keyboard Buffer) A-39 Subsystem 1100 SS (System Configuration) A-40 Subsystem 1200 KP (Keypad Services) A-41 Subsystem 1300 DP (Display) A-42 Subsystem 1A00 EX (DCM Support) A-43 xii

Page 13

Contents

B

I

Sample Interrupt Programs Using the Sample Programs B-3 apmif.c B-4 appbreak.cpp B-7 backlite.cpp B-9 contrast.cpp B-10 ctlkey.cpp B-12 exstat.cpp B-14 fifo.cpp B-19 jbeep.cpp B-22 jboot.cpp B-23 keybuff.cpp B-24 keyclick.cpp B-26 keystat.cpp B-28 numpad.cpp B-30 phterm.cpp B-32 vp_cur.cpp B-38

Index xiii

Page 14

This page is a scan with no text; see it in the PDF.

Page 15

Before You Begin

Before You Begin This section introduces you to standard warranty provisions, safety precautions, warnings and cautions, document formatting conventions, and sources of additional product information.

Warranty Information To receive a copy of the standard warranty provision for this product, contact your local Intermec sales organization. In the U.S. call (800) 755-5505, and in Canada call (800) 688-7043. Otherwise, refer to the Worldwide Sales & Service list shipped with this manual for the address and telephone number of your Intermec sales organization.

Cautions The cautions in this manual use the following format.

CAUTION

Caution A caution alerts you to an operating procedure, practice, condition, or statement that must be strictly observed to prevent equipment damage or destruction, or corruption or loss of data. Conseil Une précaution vous alerte d’une procédure de fonctionnement, d’une méthode, d’un état ou d’un rapport qui doit être strictement respecté pour empêcher l’endommagement ou la destruction de l’équipement, ou l’altération ou la perte de données.

xv

Page 16

JANUS PSK for C/C++ Reference Manual

About This Manual This manual is part of the JANUS Programmer’s Software Kit manual set. It describes the special features and methods needed for programming the JANUS family of PC-compatible readers. If you plan to write programs in C or C++, the information in this manual is very valuable. If you plan to write programs in QuickBasic or Visual Basic for DOS, refer to the JANUS Programmer’s Software Kit for Basic Reference Manual, Part No. 063191. If you plan to write programs in Ada, refer to the JANUS Programmer’s Software Kit for Ada Reference Manual, Part No. 062038. If you plan to write programs using Interactive Reader Language (IRL), refer to the IRL Programming Reference Manual, Part No. 048609, and your JANUS user’s manual for programming guidelines.

Organization The JANUS Programmer’s Software Kit for C/C++ Reference Manual is divided into five chapters and two appendixes as described below:

xvi

Chapter

What You Will Find

1

Getting Started This chapter describes the capabilities of and programming methods for the JANUS readers. It also explains how to install the Programmer’s Software Kit Language Libraries disk that is provided with this manual.

2

C Language Support This chapter describes how to write C applications using the Programmer’s Software Kit (PSK) library functions.

3

Software Interrupts This chapter explains how to use software interrupts in your programs.

4

Advanced Programming This chapter explains the various reader input modes and how to use the power management software functions.

5

Using the PSK With DCM This chapter explains how to program the reader to access a remote database connected through Intermec DCM software.

Page 17

Before You Begin

Chapter

What You Will Find

Appendix A Status Codes This appendix lists status codes that are returned by the PSK functions. Appendix B Sample Interrupt Programs This appendix lists C language programs that demonstrate how to use software interrupts.

Terms and Conventions • A reader is the JANUS 2010, 2020, or 2050 PC-compatible bar code reader. • An operator is anyone who runs applications on the reader. • A programmer is anyone who writes applications for the reader. • A normal PC is assumed to be a DOS-based PC/AT-compatible 386, with a hard disk, 14-inch monitor, full-size keyboard, floppy disk drives, and at least two communications ports. • Reader services are the functional abilities that distinguish the JANUS readers from a normal PC. For example, the reader’s ability to decode bar code data as if it came from a PC keyboard is a typical reader service. • Software interrupts are the synchronous triggering of interrupts used for application program interfaces. • Library functions are the Intermec-specific functions provided in the language libraries you use to invoke various reader services. • PSK means the Programmer’s Software Kit and refers to the language libraries and the associated manuals. • The Programmer’s Software Kit Language Libraries is the disk shipped with this manual. It contains sample programs and library functions for interfacing with the reader. • The keypad is the custom JANUS keyboard. Throughout this manual, specific references to the JANUS keyboard use the term keypad. • The keyboard buffer is the machine-level buffer that stores key presses and scanned labels. Throughout this manual, specific references to this buffer and its status flags use the term keyboard.

xvii

Page 18

JANUS PSK for C/C++ Reference Manual

Keypad Input • Keys that you press on the keypad are emphasized in bold. For example, “press Enter” means you press the key labeled “Enter” on the reader keypad. • All key names use first-letter capitalization. For example: Ctrl = Control key Enter = Enter key F3 = F3 key • When you are required to press and release a series of keys in order, the keys are listed in order with no connectors. For example, to enter the uppercase character A, press Shift A. To enter this character, you press and release the Shift key, and then press the key marked A. • When you are required to press more than one key at the same time, the keys are connected by a dash in the text. For example, press Ctrl-Alt-Del to perform a warm boot on a standard PC. When the keys are connected by a dash, it is important that you press and hold the keys in the order they are listed in the text.

Commands • DOS commands are printed in Courier, exactly as you must type them. For example: COPY INTERMEC.* E:\ • Code examples are printed in 8-point Courier. For example: if(step != 0) level = step; if(level >= 31) level = 0;

// use step value if provided // keep level within bounds

Other Conventions • Italic type identifies a syntax parameter where it is defined in text. Italic type is also used to indicate references to other manuals and to indicate important terminology. • Hexadecimal numbers in text are followed by an uppercase H. For example, 03 hex is shown as 03H. • Hexadecimal numbers in C language code segments begin with 0x. For example, AX_REG = 0x5300.

xviii

Page 19

Before You Begin

Other Intermec Manuals You may need additional information for working with the PSK in a data collection system. To order additional manuals, contact your local Intermec representative or distributor. The following publications contain useful information for programming the JANUS family of PC-compatible readers:

Manual

Intermec Part No.

JANUS PSK for Basic Reference Manual

063191

JANUS PSK for Ada Reference Manual

062038

JANUS 2010 Hand-Held Computer User’s Manual

058426

JANUS 2020 Hand-Held Computer User’s Manual

059951

JANUS 2050 Vehicle Mount Unit User's Guide

062874

JANUS Application Simulator User's Manual

062778

IRL Programming Reference Manual

048609

Data Communications Reference Manual

044737

The Bar Code Book

051241

DCM for OS/2 Manual Kit

057433

DCM for HP-UX Manual Kit

062223

DCM for SCO Manual Kit

062765

For additional programming information, see the software development kit manuals provided with your language. Note: The Programmer’s Software Kit Language Libraries disk accompanying this manual includes a file called README.TXT. This file contains updates to this document and other important notes.

xix

Page 20

This page is a scan with no text; see it in the PDF.