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 16 of 36

Trakker Antares Application Development Tools System Manual: Part I - Trakker Antares PSK Reference Manual, pages 145 to 154

Pages 145 to 154 of 340, from Trakker Antares Application Development Tools System Manual

The original document is the PDF (1.6 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 2420, Intermec 2425, Intermec 2435 and Intermec 2481

Page 145

Chapter 5, PSK Function Descriptions im_overlay_status Purpose Syntax

IN Parameters OUT Parameters

This function returns the values that were specified in the last call of the im_overlay_setup function. #include "imt24lib.h" IM_STATUS *im_overlay_status (IM_UCHAR *start_font_scan_row, IM_UCHAR *start_video_scan_row, IM_UCHAR *scan_lines) ;

None start_font_scan_row start_video_scan_row scan_lines

Return Value

This function returns this code: IM_SUCCESS

Notes

Pointer to the starting scan row (0 to 15) of the glyph font to be displayed. Pointer to the starting scan row (0 to 15) of the 16 by 16 area of the display panel. Pointer to the number of scan rows (1 to 16) of the glyph font to be displayed.

Success

To cancel overlay mode, set the scan_lines input parameter to 0. The 2460 and 2461 terminals do not support this function.

See Also im_overlay_setup

Example /************************** im_overlay_status ******************************/ // Example of printing upper and lower part of a slash using overlay mode. #include "imt24lib.h" void main(void) { IM_USHORT iStartFontScanRow; IM_USHORT iStartVideoScanRow; IM_USHORT iNumberScanLines; //turn off cursor im_set_cursor(CURSOR_OFF) ; //setup overlay mode and read out im_overlay_setup(2, 1, 8) ; im_overlay_status(&iStartFontScanRow, &iStartVideoScanRow, &iNumberScanLines) ; //cancel the overlay mode im_overlay_setup(0,1,0); }

Trakker Antares PSK Reference Manual

125

Page 146

Chapter 5, PSK Function Descriptions im_put_text Purpose Syntax

This function places a rectangular section of text on the virtual screen at the specified starting row and column and ending row and column. #include "imt24lib.h" IM_STATUS im_put_text (IM_USHORT start_col, IM_USHORT start_row, IM_USHORT end_col, IM_USHORT end_row, IM_UCHAR far *text_array);

IN Parameters start_col start_row end_col end_row text_array text_array[n] text_array[m] OUT Parameters Return Value

Starting column. Starting row. Ending column. Ending row. Character array large enough to hold a character and an attribute for each character position in the display range. Contains the attribute, where n is an odd number. Contains the character, where m is an even number.

None This function returns one of these codes: IM_SUCCESS IM_INVALID_PAIR

IM_INVALID_START IM_INVALID_END Notes

Successfully placed the text The end row/column combination are before the start row/column combination. No data placed. The starting location is outside the virtual display. No data placed. The ending location is outside the virtual display. No data placed.

The placed data includes a one-byte character and a one-byte attribute for each screen position.

See Also im_get_screen_char, im_get_text

Example See example for im_get_text on page 96.

126

Trakker Antares PSK Reference Manual

Page 147

Chapter 5, PSK Function Descriptions im_putchar Purpose Syntax

This function places a character on the screen with the specified attributes. #include "imt24lib.h" IM_STATUS im_putchar (IM_UCHAR char, IM_ATTRIBUTES attrib);

IN Parameters char attrib

OUT Parameters

None

Return Value

Character to be displayed. Attribute mask and is any combination of these constants: IM_NORMAL Plain text IM_BLINK Blinking text IM_BOLD Bold text IM_INVERSE Inverse color text IM_UNDERLINE Underlined text

This function returns one of these codes: IM_SUCCESS IM_INVALID_PARAM_1

Success Invalid attribute value

See Also im_get_screen_char, im_get_text, im_puts

Example See examples of im_puts in im_get_text on page 96 or im_event_wait on page 61.

im_putchar_dbyte Purpose Syntax

IN Parameters

This function displays a double-byte international character on the screen with the specified attributes. #include "imt24lib.h" IM_STATUS im_putchar_dbyte (IM_USHORT char, IM_ATTRIBUTES attrib)

char attrib

Unsigned short that represents the double-byte international character to display. Any combination of these constants: IM_NORMAL Plain text IM_BLINK Blinking text IM_INVERSE Inverse color text IM_UNDERLINE Underlined text

Trakker Antares PSK Reference Manual

127

Page 148

Chapter 5, PSK Function Descriptions im_putchar_dbyte (continued) OUT Parameters Return Value

None This function returns one of these codes: IM_SUCCESS IM_INVALID_PARAM_1

Notes

Success Invalid attribute value

Double-byte characters are used in character sets (Chinese, Japanese, Korean) where the number of characters exceeds 256. You must have a double-byte character set installed on the host in order to use this function. Currently, the Application Simulator cannot simulate double-byte characters. The 2460 and 2461 terminals do not support this function.

im_putchar_kana_8x16 Purpose Syntax

This function places an 8x16 Kana character on the screen. #include "imt24lib.h" IM_USHORT far im_putchar_kana_8x16 (IM_UCHAR char, IM_ATTRIBUTES attrib);

IN Parameters char attrib

OUT Parameters

None

Return Value

Kana character to be displayed. Attribute mask and is any combination of these constants: IM_NORMAL Plain text IM_BLINK Blinking text IM_BOLD Bold text IM_INVERSE Inverse color text IM_UNDERLINE Underlined text

This function returns this code: IM_SUCCESS

Notes

Success

Currently, the Application Simulator cannot simulate double-byte characters. The 2460 and 2461 terminals do not support this function.

See Also im_putchar, im_puts, im_puts_kana_8x16, im_puts_mixed

128

Trakker Antares PSK Reference Manual

Page 149

Chapter 5, PSK Function Descriptions

Example /************************* im_putchar_kana_8x16 *********************/ // Example of placing 1/2 width Japanese Kana string and character #include "imt24lib.h" #include <conio.h> #include <stdio.h> void main(void) { char szKanaString[6] = {0xb7, 0xb8, 0xb9, 0xba, 0xbb, '\0'}; // A Kana string char szKanaChar = 0xb7; // Set font character size to 8x16 to display Kana characters in 1/2 width. // If the character size is 16x16, then the Kana characters will display the // same size as double byte characters. im_set_display_mode(IM_FONT_LARGE,0,0); im_puts_kana_8x16(szKanaString, IM_NORMAL); im_putchar_kana_8x16(szKanaChar, IM_NORMAL); getch(); } im_puts Purpose Syntax

This function places a string on the screen at the current cursor location and appends a carriage return and line feed after the string. #include "imt24lib.h" IM_STATUS im_puts (IM_UCHAR far *string, IM_ATTRIBUTES attrib);

IN Parameters string attrib

OUT Parameters

None

Far pointer to the text string to be displayed. Attribute mask and is any combination of these constants: IM_NORMAL Plain text IM_BLINK Blinking text IM_BOLD Bold text IM_INVERSE Inverse color text IM_UNDERLINE Underlined text

Trakker Antares PSK Reference Manual

129

Page 150

Chapter 5, PSK Function Descriptions im_puts (continued) Return Value

This function returns one of these codes: IM_SUCCESS IM_BAD_ADDRESS IM_INVALID_PARAM_2

Notes

Success Invalid string address Invalid attribute value

This function is similar to im_cputs, except that it appends a carriage return and linefeed.

See Also im_cputs, im_get_screen_char, im_get_text, im_putchar, im_putchar_kana_8x16, im_puts_kana_8x16, im_puts_mixed

Example See example for im_event_wait on page 61 or im_setup_follow_cursor on page 165.

im_puts_dbyte Purpose

Syntax

This function displays a string of double-byte characters on the screen at the current cursor location and appends a carriage return and a line feed after the string. IM_STATUS im_puts_dbyte (IM_USHORT far *string, IM_ATTRIBUTES attrib)

IN Parameters string attrib

OUT Parameters

None

Return Value

Far pointer to the double-byte text string to be displayed. Any combination of these constants: IM_NORMAL Plain text IM_BLINK Blinking text IM_INVERSE Inverse color text IM_UNDERLINE Underlined text

This function returns one of these codes: IM_SUCCESS IM_INVALID_PARAM_1

130

Success Invalid attribute value

Trakker Antares PSK Reference Manual

Page 151

Chapter 5, PSK Function Descriptions

Notes

Double-byte characters are used in character sets (Chinese, Japanese, Korean) where the number of characters exceeds 256. You must have a double-byte character set installed on the host in order to use this function. Currently, the Application Simulator cannot simulate double-byte characters. The 2460 and 2461 terminals do not support this function.

Example /************************* im_puts_dbyte ***************************/ // Example of placing double byte (BIG5) character and string

#include "imt24lib.h" #include <conio.h> #include <stdio.h> void main(void) { IM_BOOL iBool; int sX[6] = {'A', 'b', 'C', 'd', 'E', '\0'}; int sY[6] = {0xa4f4,0xa4f5, 'U', 'b', 0xbc42, '\0'}; int sU[6] = { 0xbb41, 'b', 0xbbf5, 'd', 0xaba5, '\0'}; int sW[6] = { 'A', 0xbb41, 'C', 0xbbf5, 'E', '\0'}; int sZ[6] = {0xa4f4, 0xa4f5, 0xa4f6, 0xa4f7, 0xa4f8, '\0'}; // Need to check for the font offset for the font you are using im_offset_dbyte( 0xa140); // This is BIG5 font offset im_set_display_mode(IM_FONT_SPECIAL,0,0); //display dbyte font at the locations. im_puts_mixed(sX, IM_NORMAL); im_puts_mixed(sY, IM_NORMAL); im_puts_mixed(sU, IM_NORMAL); im_puts_mixed(sW, IM_NORMAL); im_puts_dbyte(sZ, IM_NORMAL); //display mixed mode getch(); }

Trakker Antares PSK Reference Manual

131

Page 152

Chapter 5, PSK Function Descriptions im_puts_kana_8x16 Purpose Syntax

This function places an 8x16 Kana character string at the current cursor location and appends a carriage return and line feed after the string. #include "imt24lib.h" IM_USHORT far im_puts_kana_8x16 (IM_UCHAR far *string, IM_ATTRIBUTES attrib);

IN Parameters string attrib

OUT Parameters

None

Return Value

This function returns this code: IM_OK

Notes

Far pointer to the Kana character string to be displayed. Attribute mask and is any combination of these constants: IM_NORMAL Plain text IM_BLINK Blinking text IM_BOLD Bold text IM_INVERSE Inverse color text IM_UNDERLINE Underlined text

Success

Currently, the Application Simulator cannot simulate double-byte characters. The 2460 and 2461 terminals do not support this function.

See Also im_putchar, im_putchar_kana_8x16, im_puts, im_puts_mixed

Example See example for im_putchar_kana_8x16 on page 129.

132

Trakker Antares PSK Reference Manual

Page 153

Chapter 5, PSK Function Descriptions im_puts_mixed Purpose

Syntax

IN Parameters

This function displays a string of mixed single and double-byte characters on the screen at the current cursor location and appends a carriage return and a line feed after the string. #include "imt24lib.h" IM_STATUS im_puts_mixed (IM_USHORT far *string, IM_ATTRIBUTES attrib)

string attrib

OUT Parameters Return Value

Far pointer to the mixed single and double-byte text string to be displayed. Any combination of these constants: IM_NORMAL Plain text IM_BLINK Blinking text IM_INVERSE Inverse color text IM_UNDERLINE Underlined text

None This function returns one of these codes: IM_SUCCESS IM_INVALID_PARAM_1

Notes

Success Invalid attribute value

Double-byte characters are used in character sets (Chinese, Japanese, Korean) where the number of characters exceeds 256. You must have a double-byte character set installed on the host in order to use this function. If you are using Japanese Kana characters, you cannot mix half widths and full widths. You can use this function to display half width Japanese Kana characters only. Currently, the Application Simulator cannot simulate double-byte characters. The 2460 and 2461 terminals do not support this function.

See Also im_putchar, im_putchar_kana_8x16, im_puts, im_puts_kana_8x16, im_puts_mixed

Example See example for im_puts_dbyte on page 131.

Trakker Antares PSK Reference Manual

133

Page 154

Chapter 5, PSK Function Descriptions im_readdir Purpose Syntax

This function returns the contents of the current directory in the file system. A call to im_opendir must be made before using im_readdir. #include "imstdio.h" IM_DIR far *im_readdir (IM_READDIR *OpenDir)

IN Parameters

OpenDir

OUT Parameters

None

Pointer to the current directory structure. See imstdio.h for definitions of IM_READDIR.

Return Value

Far pointer to the current directory structure. See imstdio.h for definitions of IM_CLOSEDIR.

Notes

To read a directory in the file system, call im_opendir to open a directory. Then call im_readdir to read the contents of the current directory one entry at a time. An entry consists of a filename, date and time stamp, and file size. Repeat the call to im_readdir for each successive entry in the directory you want to read. This is a one-way function that reads from the first entry to the next entry in the file directory. You cannot jump entries or read backward through the file system. If the return pointer is NULL, you have reached the end of the directory. Use im_closedir to stop reading directories or when you have reached the end of the directory.

Example See example for im_opendir on page 123.

im_receive_buffer Purpose

Syntax

134

This function automatically opens a socket and receives the contents of a data buffer from a designated communications source. If the terminal is communicating in a TCP/IP network, you can also use the BSD sockets interface for network communications. However, the im_receive_buffer function uses power management; it is designed to conserve battery power better than the BSD sockets interface function. #include "imt24lib.h" IM_STATUS im_receive_buffer (IM_COM_PORT port_id, IM_USHORT length, IM_UCHAR far *data_buffer, IM_LTIME timeout, IM_USHORT far *comm_length);

Trakker Antares PSK Reference Manual