Paxar Gold 6037EX User Manual

Size:
2.78 Mb
Download

Example

#include "mmsultra.h"

void main(void)

 

{

// An asterisk

int iCharacter = 42;

vidSetPage(0);

// Set page

vidScroll(0, 0, 7, 19, 0, 0x07);

// Clear screen

vidPutCursor(0, 0, 0);

// Position cursor

vidWriteC(iCharacter, 5, 0);

// Write character

}

 

Function Reference 4-115

v i d W r i t e C A

Description

Writes a character with an attribute at the specified display page’s current cursor location, overwriting any character (and attribute) that may already be there.

After calling this function, call vidPutCursor to move the cursor to a new position.

To write a character without an attribute, use vidWriteC.

If the application writes to a display page other than the current one, the written string does not appear until the application sets that page as the current one with vidSetPage. Strings written to the current page appear immediately.

Syntax

void far vidWriteCA(unsigned char uchChr, unsigned char uchAttr, short sCount,

short sPage);

Parameters

uchChr The ASCII character to write. Bell, backspace, carriage return, and line feed characters are invalid.

uchAttr The character’s attribute. Values are:

0x07 Normal video

0x70 Reverse video

sCount The number of times to write the character. This number must be less than or equal to the number of columns remaining in the current row.

4-116Programmer’s Manual

sPage The display page. For4-rowprinters, values are0- 3. For8-rowprinters, values are0-1.

Return Values

None

Example

#include "mmsultra.h"

void main(void)

 

{

// An asterisk

int iCharacter = 42;

vidSetPage(0);

// Set page

vidScroll(0, 0, 7, 19, 0, 0x07);

// Clear screen

vidPutCursor(0, 0, 0);

// Position cursor

vidWriteCA(iCharacter, 0x70, 5, 0);

// Write character

}

 

Function Reference 4-117

4-118Programmer’s Manual

D A T A S T R U C T U R E

5

R E F E R E N C E

 

Certain functions described in the last chapter require the application to use certain data structures. This chapter describes these structures. It lists them alphabetically. Following is an overview.

Name

Description

CODABARINFO

Scanner configuration for Codabar bar codes.

CODE128INFO

Scanner configuration for Code 128 bar codes.

CODE39INFO

Scanner configuration for Code 39 bar codes.

CODE93INFO

Scanner configuration for Code 93 bar codes.

D2OF5INFO

Scanner configuration for D 2 of 5 bar codes.

GENERALINFO

General scanner configuration.

I2OF5INFO

Scanner configuration for I 2 of 5 bar codes.

MSIINFO

Scanner configuration for MSI bar codes.

UPCEANINFO

Scanner Configuration for UPC/EAN bar codes.

 

 

 

 

The data structure names are casesensitive.

Data Structure Reference 5-1

C O D A B A R I N F O

The CODABARINFO data structure contains scanner configuration information about Codabar bar codes. To read these values, applications call scnGetCodabarInfo; to set these values, they call scnSetCodabarInfo.

typedef struct _CodabarInfo

{

unsigned char uchEnable; unsigned char uchLength1; unsigned char uchLength2; unsigned char uchEnableCLSIEdit; unsigned char uchEnableNOTISEdit;

} CODABARINFO;

Field

Description

 

uchEnable

Enable/disable the ability to scan Codabar

 

bar codes.

 

 

 

Default: SCN_DISABLE

 

uchLength1

Specifies lengths (including start and stop

uchLength2

characters) for Codabar bar codes. You

 

can specify one or two lengths, a range of

 

lengths, or that any length is valid. Enter

 

values as follows:

 

 

Option

uchLength1

uchLength2

 

1 Length

Value

0

 

2 Lengths

Higher Value Lower Value

 

Range

Min. Value

Max. Value

 

Any length

0

0

 

Default: 5(uchLength1) and 55

 

(uchLength2)

 

5-2Programmer’s Manual

Field

Description

 

 

uchEnableCLSIEdit

Enable/disable the ability to strip the start

 

and stop characters from 14-character

 

Codabar bar codes and insert a space

 

after the first, fifth, and tenth characters.

 

Default: SCN_DISABLE

uchEnableNOTISEdit

Enable/disable the ability to strip the start

 

and stop characters from Codabar bar

 

codes.

 

Default: SCN_DISABLE

Data Structure Reference 5-3

C O D E 1 2 8 I N F O

The CODE128INFO data structure contains scanner configuration information about Code 128 bar codes. To read these values, applications call scnGetCode128Info; to set these values, they call scnSetCode128Info.

typedef struct _Code128Info

{

unsigned char uchEnableUSS128; unsigned char uchEnableUCCEAN128; unsigned char uchEnableISBT128;

} CODE128INFO;

Field

Description

uchEnableUSS128

Enable/disable the ability to scan Code

 

128 bar codes.

 

Default: SCN_ENABLE

uchEnableUCCEAN128

Enable/disable the ability to scan

 

UCC/EAN-128bar codes.

 

Default: SCN_ENABLE

uchEnableISBT128

Enable/disable the ability to scan ISBT

 

128 bar codes.

 

Default: SCN_ENABLE

5-4Programmer’s Manual

C O D E 3 9 I N F O

The CODE39INFO data structure contains scanner configuration information about Code 39 bar codes. To read these values, applications call scnGetCode39Info; to set these values, they call scnSetCode39Info.

typedef struct _Code39Info

{

unsigned char uchEnable; unsigned char uchEnableTrioptic; unsigned char uchCvtC39toC32; unsigned char uchEnableC32Prefix; unsigned char uchLength1; unsigned char uchLength2; unsigned char uchVerifyCheckDigit; unsigned char uchXmitCheckDigit; unsigned char uchEnableFullASCII;

} CODE39INFO;

Field

Description

uchEnable

Enable/disable the ability to scan Code 39

 

bar codes.

 

Default: SCN_ENABLE

uchEnableTrioptic

Enable/disable the ability to scan Trioptic

 

Code 39 bar codes. Do not enable

 

uchEnableTrioptic and uchEnableFullASCII

 

at the same time.

 

Default: SCN_DISABLE

uchCvtC39toC32

Enable/disable the ability to convert Code

 

39 bar codes to Code 32 bar codes. You

 

must enable uchEnable when enabling this

 

parameter.

 

Default: SCN_DISABLE

Data Structure Reference 5-5

Field

Description

 

 

 

 

uchEnableC32Prefix

Enable/disable the ability to add “A” as a

 

prefix to all Code 32 bar codes. You must

 

enable uchCvtC39toC32 when enabling

 

this parameter.

 

 

Default: SCN_DISABLE

 

uchLength1

Specifies lengths (including check digits)

uchLength2

for Code 39 bar codes. You can specify

 

one or two lengths, a range of lengths, or

 

that any length is valid. If

 

uchEnableFullASCII is enabled, a range or

 

any length is preferred. Enter values as

 

follows:

 

 

 

Option

uchLength1 uchLength2

 

1 Length

Value

0

 

2 Lengths

High Value

Low Value

 

Range

Min. Value

Max. Value

 

Any length

0

0

 

Default: 2(uchLength1) and 55

 

(uchLength2)

 

uchVerifyCheckDigit

Enable/disable the ability to check the

 

integrity of Code 39 bar codes. When this

 

parameter is enabled, only Code 39

 

symbols with a modulo 43 check digit are

 

decoded.

 

 

 

Default: SCN_DISABLE

 

uchXmitCheckDigit

Enable/disable the ability to transmit check

 

digits with the data.

 

 

Default: SCN_DISABLE

 

uchEnableFullASCII

Enable/disable the ability to scan Full

 

ASCII Code 39 bar codes. The scanner

 

cannot distinguish Code 39 bar codes from

 

Full ASCII Code 39 bar codes. Do not

 

enable uchEnableTriopticand

 

uchEnableFullASCII at the same time.

 

Default: SCN_DISABLE

 

5-6Programmer’s Manual