The text of a manual · part 9 of 25
TRAKKER T2090 Batch Hand-Held Computer User's Manual, pages 81 to 90
Pages 81 to 90 of 246
The original document is the PDF (737 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 T2090
Page 81
im_get_system_julian_date
4 im_get_system_julian_date Purpose
This function generates the current date in the Julian Date format, where each day in the year is numbered from 1 to 365 (or 366 in a leap year).
Syntax
#include "imt209x.h" void im_get_system_julian_date (IM_USHORT digits_in_year, (IM_CHAR *julian_date);
IN Parameters OUT Parameters Return Value Example digits_in_year Number of digits to specify the year: 0, 1, 2, 3, or 4. julian_date Current date in Julian Date format. None. #include "im209x.h" void main () { IM_USHORT digitsInYear = 4; IM_CHAR *juliandate;
//4-digit year im_get_system_julian_date(digitsInYear, juliandate); printf(“Julian Date is %s\n”, julianDate); }
4-21
Page 82
im_input_status im_input_status Purpose
This function provides compatibility with the JANUS PSK functions. This function checks to see if any input buffers have data and returns the buffer identification.
Syntax
#include "imt209x.h" IM_ORIGIN im_input_status (void);
IN Parameters
None.
OUT Parameters
None.
Return Value
This function returns one or more of these constants: IM_NO_SELECT No input buffer has data. IM_KEYBOARD_SELECT Keypad was pressed. IM_COM1_SELECT COM1 selected. IM_ALL_SELECT
Notes
See Also
4-22
All input buffers are selected.
To avoid entering a battery-wasting infinite loop waiting for input, use an input function instead. im_receive_input, im_receive_field
Page 83
im_irl_a
4 im_irl_a Purpose
This function returns input from bar code labels or the keypad in the same manner as IRL command A (ASCII input). This function returns the input data to the buffer and displays the data.
Syntax
#include "imt209x.h" IM_USHORT im_irl_a (IM_USHORT timeout, IM_LENGTH_SPEC test_table[], IM_UCHAR mask_string[], IM_UCHAR *instring, IM_USHORT *cmd_count, IM_DECTYPE *symbology);
IN Parameters timeout
Currently, the only receive timeout period is the constant:
IM_INFINITE_TIMEOUT Wait forever - the function does not return until the end of message character has been received. test_table Specifies acceptable lengths for input. Data is returned only if its length matches one of the five lengths specified in the test_table. The test_table parameter is a matrix in the form shown to the right: a
{a, b, c, d}, {a, b, c, d}, {a, b, c, d}, {a, b, c, d}, {a, b, c, d},
This position in the matrix is one of these values: IM_NO_LENGTH Accept data of any length. Set any unused table entries to {IM_NO_LENGTH,0,0,0}. IM_LENGTH Accept data with a specific length. The actual length of the data string is placed in the d position (and b and c are not used). IM_RANGE Accept data within a length range. The data length must be within the range of b and c (and d is not used).
mask_string Sets up a data mask that the received data must match. mask_string can accept a string of constants or wildcard characters. For example, use the string ### - #### to accept only phone numbers. If you define a mask, the computer beeps when input does not fit the mask. You can use one or more of these wildcard characters to define the mask: # Numeric @
Alpha
? Alphanumeric printable NULL (CHR$(0)) No mask OUT Parameters instring Input string.
4-23
Page 84
im_irl_k cmd_count Returns a 0. symbology Returns IM_UNKNOWN_DECODE. Return Value
This function returns the status code: IM_SUCCESS Successfully received input.
Notes
See Also
TRAKKER T2090 computers do not support IRL. This function provides compatibility with previous versions of PSK and is not recommended for new development. For more information on IRL and command A, refer to the IRL Programming Reference Manual. im_irl_k, im_irl_n, im_irl_v, im_irl_y im_irl_k Purpose
This function receives input from the keypad in any format in the same manner as IRL command K (ASCII input). This function returns the input data to the buffer and displays the data.
Syntax
#include "imt209x.h" IM_USHORT im_irl_k (IM_USHORT timeout, IM_LENGTH_SPEC test_table[], IM_UCHAR mask_string[], IM_UCHAR *instring, IM_USHORT *cmd_count);
IN Parameters timeout
Currently, the only receive timeout period is the constant:
IM_INFINITE_TIMEOUT Wait forever - the function does not return until the end of message character has been received. test_table Specifies acceptable lengths for input. Data is returned only if its length matches one of the five lengths specified in the test_table. The test_table parameter is a matrix in the form shown to the right:
4-24
{a, b, c, d}, {a, b, c, d}, {a, b, c, d}, {a, b, c, d}, {a, b, c, d},
Page 85
im_irl_k a
4
This position in the matrix is one of these values: IM_NO_LENGTH Accept data of any length. Set any unused table entries to {IM_NO_LENGTH,0,0,0}. IM_LENGTH Accept data with a specific length. The actual length of the data string is placed in the d position (and b and c are not used). IM_RANGE Accept data within a length range. The data length must be within the range of b and c (and d is not used).
mask_string Sets up a data mask that the received data must match. mask_string can accept a string of constants or wildcard characters. For example, use the string ### - #### to accept only phone numbers. If you define a mask, the computer beeps when input does not fit the mask. You can use one or more of these wildcard characters to define the mask: # Numeric @
Alpha
? Alphanumeric printable NULL (CHR$(0)) No mask OUT Parameters instring
Input string.
cmd_count Returns a 0. Return Value
This function returns the status code: IM_SUCCESS Successfully received input.
Notes
See Also
TRAKKER T2090 computers do not support IRL. This function provides compatibility with previous versions of PSK and is not recommended for new development. For more information on IRL and command K, refer to the IRL Programming Reference Manual. im_irl_a, im_irl_n, im_irl_v, im_irl_y
4-25
Page 86
im_irl_n im_irl_n Purpose
This function receives numeric input from the keypad or a label in the same manner as IRL command N (numeric input). Nonnumeric data is not accepted as valid input. This function returns the input data to the buffer and displays the data.
Syntax
#include "imt209x.h" IM_USHORT im_irl_n (IM_USHORT timeout, IM_LENGTH_SPEC test_table[], IM_UCHAR *instring, IM_USHORT *cmd_count, IM_DECTYPE *symbology);
IN Parameters timeout Specifies the receive timeout period. The return status indicates whether the function was successful or a timeout occurred. Either enter a number from 1 to 65,534 to indicate the length of the timeout in milliseconds, or choose one of these constants: IM_ZERO_TIMEOUT No wait. IM_INFINITE_TIMEOUT Wait forever - the function does not return until the end of message character has been received. test_table Specifies acceptable lengths for input. Data is returned only if its length matches one of the five lengths specified in the test_table. The test_table parameter is a matrix in the form shown to the right: a
This position in the matrix is one of these values: IM_NO_LENGTH Accept data of any length. Set any unused table entries to {IM_NO_LENGTH,0,0,0}. IM_LENGTH Accept data with a specific length. The actual length of the data string is placed in the d position (and b and c are not used). IM_RANGE Accept data within a length range. The data length must be within the range of b and c (and d is not used).
4-26
{a, b, c, d}, {a, b, c, d}, {a, b, c, d}, {a, b, c, d}, {a, b, c, d},
Page 87
im_irl_n
4 mask_string Sets up a data mask that the received data must match. mask_string can accept a string of constants or wildcard characters. For example, use the string ### - #### to accept only phone numbers. If you define a mask, the computer beeps when input does not fit the mask. You can use one or more of these wildcard characters to define the mask: # Numeric @
Alpha
? Alphanumeric printable NULL (CHR$(0)) No mask instring Input string. OUT Parameters cmd_count Returns a 0. symbology Returns IM_UNKNOWN_DECODE. Return Value
This function returns one of these codes: IM_SUCCESS Successfully received input. IM_TIMEDOUT A timeout occurred. IM_EDIT_ERROR Error occurred in a computer command.
Notes
See Also
TRAKKER T2090 computers do not support IRL. This function provides compatibility with previous versions of PSK and is not recommended for new development. For more information on IRL and command N, refer to the IRL Programming Reference Manual. im_irl_a, im_irl_k, im_irl_v, im_irl_y
4-27
Page 88
im_irl_v im_irl_v Purpose
This function receives input from any specified source in any format, in the same manner as an IRL command V (universal input).
Syntax
#include "imt209x.h" IM_USHORT im_irl_v (IM_USHORT timeout, IM_CONTROL edit, IM_LABEL_BEEP_CONTROL beep, IM_CONTROL display, IM_ORIGIN *source, IM_UCHAR *instring, IM_USHORT *cmd_count, IM_DECTYPE *symbology);
IN Parameters timeout Specifies the receive timeout period. The return status indicates whether the function was successful or a timeout occurred. Either enter a number from 1 to 65,534 to indicate the length of the timeout in milliseconds, or choose one of these constants: IM_ZERO_TIMEOUT No wait. IM_INFINITE_TIMEOUT Wait forever - the function does not return until the end of message character has been received. edit Determines the amount of data to accept. Choose one of these constants: IM_DISABLE Accepts one character of keypad data. IM_ENABLE Accepts strings of data from the keypad. beep Determines whether the IRL V command beeps or not when data is entered. Choose one of these constants: IM_APPLI_BEEP Application controls the beep - you code the application to sound a beep when your program design requires one. IM_WEDGE_BEEP Beeps occur automatically - the reader always beeps when data is entered. display Determines if the data is displayed as it is entered. Choose one of these constants: IM_DISABLE Disable display of data. IM_ENABLE Enable display of data.
4-28
Page 89
im_irl_v
IN/OUT Parameters
4 source Determines which input sources are allowed. When the IRL V command returns, source indicates where the data came from. The source parameter is one of these constants: IM_NO_SELECT No source selected. IM_LABEL_SELECT Label selected. IM_KEYBOARD_SELECT Keypad selected. IM_COM1_SELECT COM1 selected. IM_ALL_SELECT All sources are selected.
OUT Parameters instring Input string. cmd_count Returns a 0. symbology
Specifies the type of bar code and is one of these constants:
IM_UNKNOWN_DECODE Unknown bar code. IM_CODABAR Codabar bar code. IM_CODE_39 Code 39 bar code. IM_CODE_128 Code 128 bar code. IM_I_2_OF_5
Interleaved 2 of 5.
IM_MSI MSI bar code. IM_UPC Universal Product code. Return Value
This function returns one of these codes: IM_SUCCESS Successfully received input. IM_TIMEDOUT A timeout occurred.
Notes
See Also
TRAKKER T2090 computers do not support IRL. This function provides compatibility with previous versions of PSK and is not recommended for new development. For more information on IRL and command V, refer to the IRL Programming Reference Manual. im_irl_a, im_irl_k, im_irl_n, im_irl_y
4-29
Page 90
im_irl_y im_irl_y Purpose
The im_irl_y function receives input from the designated communications port the same as IRL command Y (ASCII input). This function receives a single block, not an entire file. This function always clears input from the host and checks the data for computer commands from input. Unlike the other IRL-type instructions, the data is not automatically displayed.
Syntax
IN Parameters
#include "imt209x.h" IM_STATUS im_irl_y (IM_USHORT timeout, IM_COM_PORT port_id, IM_UCHAR *eom_char, IM_PROTOCOL_CMD protocol, IM_UCHAR *instring, IM_USHORT *cmd_count); timeout Specifies the receive timeout period. The return status indicates whether the function was successful or a timeout occurred. Either enter a number from 1 to 65,534 to indicate the length of the timeout in milliseconds, or choose one of these constants: IM_ZERO_TIMEOUT No wait. IM_INFINITE_TIMEOUT Wait forever - the function does not return until the end of message character has been received. port_id
Identifies the communications port. Use this constant:
IM_COM1 COM1. eom_char Provides compatibility with the JANUS PSK. This parameter is ignored on the TRAKKER T2090 computer. protocol Provides compatibility with the TRAKKER Antares and JANUS PSK. This parameter is ignored on the TRAKKER T2090 computer. Use the im_command to control protocol on the computer. OUT Parameters instring Input string. cmd_count Returns a 0.
Return Value
This function returns one of these codes: IM_SUCCESS Successfully received input. IM_TIMEDOUT A timeout occurred.
4-30