Skip to content

DEV Statement

The DEV statements tell Thoroughbred Basic what kinds of printers, terminals, directories, and tasks are available to Thoroughbred Basic applications and programs.

The last argument on DEV records can be up to 128 characters.

DEV statements must appear after the PRM statements and before the IPL statement. If the IPL file does not contain PRM statements, DEV statements must be placed between the PTN statement and the IPL statement.

There must be at least one DEV statement to define the individual task and there must be at least one logical disk directory or communications port defined to provide for program and data access.

The DEV statement has the following generic format:

DEV dev-ID,type,param-1,param-2,param-3, param-4,param-5,string

The DEV statement is used to define the following types of devices to Thoroughbred Basic:

  • Disk or directory devices
  • ODBC-compliant server devices (Thoroughbred Basic ODBC Client Compatibility)
  • Network server devices (TS Network DataServer)
  • ORACLE server devices (TS DataServer for Oracle)
  • MS SQL server devices (TS DataServer for MS SQL Server)
  • MySQL server devices (TS DataServer for MySQL)
  • Terminal devices
  • Printer devices
  • Ghost tasks

Each type of DEV statement will be described in the following subsections.

DEV statement syntax for a disk or directory

Section titled “DEV statement syntax for a disk or directory”

DEV DX,type,param-1,param-2,subdirflg, hierflg,param-5,dirname

DEV
begins the DEV statement. The statement begins in the leftmost column.
DX
is the device ID, which Thoroughbred Basic uses to reference the disk or directory. Valid values range from D0 through D9, DA through DZ and Da through Dz.. You can specify up to 62 logical and physical devices.

Disk or directory device specifications do not have to follow a set order. For example, you can specify the D0 disk after you specify the D1 disk.

type
specifies the device type. For a disk or directory, the only valid value is 1.
param-1
is a positional parameter. For disk or directory devices, do not specify a value for this parameter.
param-2
is a positional parameter. For disk or directory devices, do not specify a value for this parameter.
subdirflg
is a positional parameter. For disk or directory devices, this parameter specifies that this directory can contain subdirectories and specifies the length of each subdirectory name. Valid values for this parameter are 1 through 9. If you specify 1 for subdirflg, each subdirectory name must be three characters long, so specifying 1 is equivalent to specifying 3.

Setting this attribute does not automatically create subdirectories. You must use operating system commands to create subdirectories.

Even if the defined length of subdirectory names is not three characters, you should create a USR subdirectory. If the first characters of a filename do not match any of the subdirectory names, the file will be placed in the USR subdirectory; if the USR subdirectory does not exist, Thoroughbred Basic will issue an error.

For more information on subdirectories, please refer to TERMINAL File in this manual.

hierflg
is a positional parameter. For disk or directory devices, this parameter specifies whether Thoroughbred Basic will consider the disk a hierarchical directory. Valid values are:

0 The disk is not a hierarchical directory. This is the default.

1 The disk is a hierarchical directory.

A hierarchical directory specification enables Thoroughbred Basic to access all of the directories on the disk, and provides more flexibility in specifying directories and files. Directives such as SET PREFIX rely on the specification of a hierarchical directory. You can only specify one hierarchical directory in an IPL file.

For more information on the SET PREFIX directive, please refer to the Thoroughbred Basic Language Reference.

ofilesflag
is a positional parameter. For disk or directory devices, this parameter enables or disables the open files caching and file sharing features. Valid values are:

0 The setting from the CNF statement is used. This is the default.

1 Open files caching is disabled; file sharing is enabled.

2 Open files caching is disabled; file sharing is enabled.

3 Open files caching is enabled; file sharing is disabled.

4 Open files caching is disabled; file sharing is disabled.

Use this parameter to override the ofilesflag setting on the CNF statement. This may be necessary for removable media such as USB drives. This parameter is automatically set to 1 for hierarchical directories. The open files caching and file sharing features are described in the CNF statement ofilesflag parameter.

dirname
is a positional parameter. For disk or directory devices, this parameter specifies the name of the directory that will be used to locate files or subdirectories. The directory name does not have to be relative to the current working directory. The name can be absolute, relative, or logical.

Maximum dirname length is 64-characters. Longer specifications will be truncated, but no error message will be generated.

Examples of the DEV statement for disk or directory devices

Example: DEV statement for a logical disk directory

DEV D0,1,,,0,,,UTILS

DEV
Begins the DEV statement.
DEV D0
Specifies that the device is called D0.
DEV D0,1
Specifies the device type for D0. Valid values are:
1logical disk directory
4standard dot matrix, character printer, or laser printer
5terminal that uses Thoroughbred Basic Windows
6terminal that uses a video card
7terminal that does not use Thoroughbred Basic Windows
8ghost task

D0 is defined as a logical disk directory.

DEV D0,1,,,0
Specifies that there are no subdirectories in this directory. The default is 0.
DEV D0,1,,,0,,,UTILS
Specifies that the system name for D0 is UTILS. If UTILS does not exist, you must use operating system commands to create it.

Thoroughbred Basic can refer to this device as D0, logical disk directory number 0 (based on the name D0), or by its name, UTILS.

Example: DEV statement for a logical disk directory with subdirectories

DEV D1,1,,,1,,,IDL4

DEV
Begins the DEV statement.
DEV D1
Specifies that the device is called D1.
DEV D1,1
Specifies the device type for D1. Valid values are:
1logical disk directory
4standard dot matrix, character printer, or laser printer
5terminal that uses Thoroughbred Basic Windows
6terminal that uses a video card
7terminal that does not use Thoroughbred Basic Windows
8ghost task

D1 is defined as a logical disk directory.

DEV D1,1,,,1
Specifies that this directory contains subdirectories. Placing files in subdirectories can increase Thoroughbred Basic execution speed by reducing the time required to find a file.

Valid values for the subdirectory flag are 1 through 9. The flag tells Thoroughbred Basic that subdirectories exist and, with one exception, specifies the length of each subdirectory name. The exception is illustrated in the above example: if you specify 1 for the subdirectory flag, each subdirectory name must be three characters long, so specifying 1 is equivalent to specifying 3.

In this example, each subdirectory must have a 3-character name. Each subdirectory will contain files with names that start with those three characters. For example, if the WOR subdirectory existed under D1 on a UNIX system, a file named WORKFILE would be placed in IDL4/WOR/WORKFILE.

You should create a USR subdirectory. If the first characters of a filename do not match any of the subdirectory names, the file will be placed in the USR subdirectory.

Setting this attribute does not automatically create subdirectories. You must use operating system commands to create subdirectories.

For more information on subdirectories, please refer to the TERMINAL File section of this manual.

DEV D1,1,,,1,,,IDL4
Specifies that the system name for D1 is IDL4. If IDL4 does not exist, you must use operating system commands to create it.

Thoroughbred Basic can refer to this device as D1, logical disk directory number 1 (based on the name D1), or by its name, IDL4.

Example: DEV statement for a Microsoft Windows directory

DEV D7,1,,,,,,D:\COMPANY\ACTG

DEV
Begins the DEV statement.
DEV D7
Specifies that the device is called D7.
DEV D7,1
Specifies the device type for D7. Valid values are:

1 logical disk directory

4 standard dot matrix, character printer, or laser printer

5 terminal that uses Thoroughbred Basic Windows

6 terminal that uses a video card

7 terminal that does not use Thoroughbred Basic Windows

8 ghost task. Background tasks are not available to Thoroughbred Basic under Microsoft Windows.

D7 is defined as a logical disk directory.

DEV D7,1,,,,,,D:\COMPANY\ACTG
Specifies that the system name for D7 is D:\COMPANY\ACTG. If this directory does not exist, you must use operating system commands to create it.

Thoroughbred Basic can refer to this device as D7, logical disk directory number 7 (based on the name D7), or by its name, D:\COMPANY\ACTG.

Example: DEV statement for hierarchical disk directory DEV D8,1,,,,1,,

DEV
Begins the DEV statement.
DEV D8
Specifies that the device is called D8.
DEV D8,1
Specifies the device type for D8. Valid values are:
1logical disk directory
4standard dot matrix, character printer, or laser printer
5terminal that uses Thoroughbred Basic Windows
6terminal that uses a video card
7terminal that does not use Thoroughbred Basic Windows
8ghost task

D8 is defined as a logical disk directory.

DEV D8,1,,,,1,,
Specifies that Thoroughbred Basic will consider the disk a hierarchical directory. Valid values for this parameter are:

0 The disk is not a hierarchical directory. This is the default.

1 The disk is a hierarchical directory.

A hierarchical directory specification enables Thoroughbred Basic to access all of the directories on the disk, and provides more flexibility in specifying directories and files. Directives such as SET DIR and SET PREFIX rely on the specification of a hierarchical directory. You can only specify one hierarchical directory in an IPL file.

For more information on the directives mentioned above, please refer to the Thoroughbred Basic Language Reference.

DEV DX,type,param-1,server-flag,param-3,param-4,param-5,server-ID:arguments

DEV
begins the DEV statement. The statement begins in the leftmost column.
DX
is the device ID, which Thoroughbred Basic uses to reference the ODBC server. Valid values range from D0 through D9, DA through DZ and Da through Dz. You can specify up to 62 logical and physical devices.

ODBC server specifications do not have to follow a set order. For example, you can specify the D0 disk after you specify the D1 disk.

Note: The DX specification means that ODBC servers are regarded as disk or directory devices. You can specify up to 62 disk or directory devices.

For more information on how ODBC servers work with Thoroughbred products, please refer to TERM.MAP File in this manual.

type
specifies the device type. For an ODBC server, the only valid value is 1.
param-1
is a positional parameter. For ODBC servers, do not specify a value for this parameter.
server-flag
is a positional parameter. It specifies that the disk directory is located on a server, and specifies the server type. For ODBC servers, the only valid value is 3.
param-3
is a positional parameter. For ODBC servers, do not specify a value for this parameter.
param-4
is a positional parameter. For ODBC servers, do not specify a value for this parameter.
param-5
is a positional parameter. For ODBC servers, do not specify a value for this parameter.
server-ID[:arguments
] is a positional parameter. It specifies the ODBC, and any information needed to establish a connection to the ODBC-compliant database. Valid values are:
server-ID
is the two-character specification assigned to the ODBC server. The server-ID specification in the DEV statement must match an entry in the SERVER.MAP file.

The :arguments syntax element varies depending upon the server-ID. Some ODBC-compliant databases require only a valid server-ID specification.

:
separates server-ID from the arguments specification.
arguments
vary depending upon the server-ID. Some databases do not require arguments.

Some databases may require arguments that take the form of login/password:

login
is the login used to connect to the database. The login/password specification is optional.
/
separates ID from password.
password
is the password used to connect to the database. The login/password specification is optional.

For more information on arguments, please refer to the documentation for the relevant ODBC-compliant database management system.

Example: DEV statement for an ODBC server (Thoroughbred Basic ODBC Client Capability)

DEV D8,1,,3,,,,S1

DEV
Begins the DEV statement.
DEV D8
Specifies that the device is called D8.
DEV D8,1
Specifies the device type for D8. Valid values are:
1logical disk directory
4standard dot matrix, character printer, or laser printer
5terminal that uses Thoroughbred Basic Windows
6terminal that uses a video card
7terminal that does not use Thoroughbred Basic Windows
8ghost task

D8 is defined as a logical disk directory.

DEV D8,1,,3
Specifies that the disk directory is located on an ODBC server.

DEV D8,1,,3,,,,S1 Specifies that the server-ID is S1. No further arguments are required.

Note: For more information on how to configure Thoroughbred products for use with ODBC servers and databases, please refer to the Thoroughbred Basic ODBC Client Capability Customization Supplement.

DEV statement syntax for a server (TS Network DataServer)

Section titled “DEV statement syntax for a server (TS Network DataServer)”

DEV DX,type,param-1,server-flag,param-3,param-4,param-5,server-ID:path

DEV
begins the DEV statement. The statement begins in the leftmost column.
DX
is the device ID, which Thoroughbred Basic uses to reference the server. Valid values range from D0 through D9, DA through DZ and Da through Dz . You can specify up to 62 logical and physical devices.

Network server specifications do not have to follow a set order. For example, you can specify the D0 disk after you specify the D1 disk.

Note: The DX specification means that servers are regarded as disk or directory devices. You can specify up to 62 disk or directory devices.

For more information on how network servers work with Thoroughbred products, please refer to TS Network DataServer documentation.

type
specifies the device type. For a server, the only valid value is 1.
param-1
is a positional parameter. For network servers, do not specify a value for this parameter.
server-flag
is a positional parameter. It specifies that the disk directory in located on a server, and specifies the server type. For Thoroughbred network servers, the only valid value is 2.
param-3
is a positional parameter. For servers, do not specify a value for this parameter.
param-4
is a positional parameter. For servers, do not specify a value for this parameter.
param-5
is a positional parameter. For servers, do not specify a value for this parameter.
server-ID:path
is a positional parameter. It specifies the server and the location of the server. Valid values are:
server-ID
is the two-character specification assigned to the server. The server-ID specification in the DEV statement must match an entry in the SERVER.MAP file.
:
separates server-ID from the path specification.
path
is the directory on the server that contains required data. The path specification can be fully qualified. If it is not fully qualified, the path specification is interpreted as relative to the directory that contains the server executable.

Examples of the DEV statement for server devices (TS Network DataServer)

Example: DEV statement with a fully qualified path specification

DEV D1,1,,2,,,,S1:/home/data/user

DEV
Begins the DEV statement.
DEV D1
Specifies that the device is called D1.
DEV D1,1
Specifies the device type for D1. Valid values are:

1 logical disk directory

4 standard dot matrix, character printer, or laser printer

5 terminal that uses Thoroughbred Basic Windows

6 terminal that uses a video card

7 terminal that does not use Thoroughbred Basic Windows

8 ghost task

D1 is defined as a logical disk directory.

DEV D1,1,,2
Specifies that the disk directory is located on a network server.
DEV D1,1,,2,,,,S1:/home/data/user
Specifies that the server-ID is S1, and the path is /home/data/user. The files on the D1 device are located in the /home/data/user directory on the S1 server.

Example: DEV statement with a relative path specification DEV D2,1,,2,,,,S2:data/user

DEV
Begins the DEV statement.
DEV D2
Specifies that the device is called D2.
DEV D2,1
Specifies the device type for D2. Valid values are:

1 logical disk directory

4 standard dot matrix, character printer, or laser printer

5 terminal that uses Thoroughbred Basic Windows

6 terminal that uses a video card

7 terminal that does not use Thoroughbred Basic Windows

8 ghost task

D2 is defined as a logical disk directory.

DEV D2,1,,2
Specifies that the disk directory is located on a network server.
DEV D2,1,,2,,,,S2:data/user
Specifies that the server-ID is S2, and the path is data/user, a relative path specification. For example, if the server executable is located in the /usr/lib/basic directory, the files on the D2 device are located in the usr/lib/basic/data/user directory on the S2 server.

Note: For more information on how to configure Thoroughbred products for use with network servers, please refer to TS Network DataServer documentation.

DEV statement syntax for an ORACLE server (TS DataServer for Oracle)

Section titled “DEV statement syntax for an ORACLE server (TS DataServer for Oracle)”

DEV DX,type,param-1,server-flag,param-3,logon-cachecase-sensitivity,param-5,server-ID:login/password

DEV
begins the DEV statement. The statement begins in the leftmost column.
DX
is the device ID, which Thoroughbred Basic uses to reference the ORACLE server. Valid values range from D0 through D9, DA through DZ and Da through Dz . You can specify up to 62 logical and physical devices.

ORACLE server specifications do not have to follow a set order. For example, you can specify the D0 disk after you specify the D1 disk.

Note: The DX specification means that ORACLE servers are regarded as disk or directory devices. You can specify up to 62 disk or directory devices.

For more information on how ORACLE servers work with Thoroughbred products, please refer to TS DataServer for Oracle documentation.

type
specifies the device type. For an ORACLE server, the only valid value is 1.
param-1
is a positional parameter. For ORACLE servers, do not specify a value for this parameter.
server-flag
is a positional parameter. It specifies that the disk directory is located on a server, and specifies the server type. For ORACLE servers, the only valid value is 1.
param-3
is a positional parameter. For ORACLE servers, do not specify a value for this parameter.
logon-cache
is a positional parameter. It specifies the maximum number of concurrent active logins to the ORACLE database. Valid values are numeric. This parameter is optional.
case-sensitivity
is a positional parameter. It specifies the case sensitivity of the key comparison performed on key values returned during READ, KEY= operations. Values for this parameter are as follows:
0
Basic will perform a case sensitive comparison ( the default ).
1
Basic will perform a case insensitive comparison.
server-ID:login/password
is a positional parameter. It specifies the ORACLE server, and the login and password used to enter the database. Valid values are:
server-ID
is the two-character specification assigned to the ORACLE server. The server-ID specification in the DEV statement must match an entry in the SERVER.MAP file.
:
separates server-ID from the login/password specification.
login
is the ORACLE login used to connect to the database. The login/password specification is optional.
/
separates ID from password.
password
is the ORACLE password used to connect to the database. The login/password specification is optional.

Note: If multiple ORACLE servers are configured, and the login and password are identical for each server, the PRM ORACLE-LOGIN statement can replace multiple login and password specifications in DEV statements.

For more information on the PRM ORACLE-LOGIN statement, on the SERVER.MAP file, and on DEV statements relevant to TS DataServer for Oracle, please refer to TS DataServer for Oracle documentation.

Example of the DEV statement for ORACLE server devices (TS DataServer for Oracle)

Example: DEV statement for an ORACLE server

DEV D8,1,,1,,,,O1:jill/jij

DEV
Begins the DEV statement.
DEV D8
Specifies that the device is called D8.
DEV D8,1
Specifies the device type for D8. Valid values are:
1logical disk directory
4standard dot matrix, character printer, or laser printer
5terminal that uses Thoroughbred Basic Windows
6terminal that uses a video card
7terminal that does not use Thoroughbred Basic Windows
8ghost task

D8 is defined as a logical disk directory.

DEV D8,1,,1
Specifies that the disk directory is located on an ORACLE server.
DEV D8,1,,1,,,,O1:jill/jij
Specifies that the server-ID is O1, the login is jill, and the password is jij.

Note: For more information on how to configure Thoroughbred products for use with ORACLE servers and databases, please refer to TS DataServer for Oracle documentation.

DEV statement syntax for a MS SQL Server (TS DataServer for MS SQL Server)

Section titled “DEV statement syntax for a MS SQL Server (TS DataServer for MS SQL Server)”

DEV DX,type,paran-1,server-flag,parm-3, logon-cache,case-sensitivity,server-
ID:login//password

DEV
begins the DEV statement. The statement begins in the leftmost column.
DX
is the device ID, which Thoroughbred Basic uses to reference the MS SQL Servers. Valid values range from D0 through D9, DA through DZ and Da through Dz. You can specify up to 62 logical and physical devices.

SQL Server specifications do not have to follow a set order. For example, you can specify the D0 disk after you specify the D1 disk.

Note: The DX specification means that MS SQL Servers are regarded as disk or directory devices. You can specify up to 62 disk or directory devices.

For more information on how MS SQL Servers work with the Thoroughbred products, please refer to the TS DataServer for MS SQL Server documentation.

type
specifies the device type. For MS SQL Servers, the only valid value is 1.
param-1
is a positional parameter. For MS SQL Servers, do not specify a value for this parameter.
server-flag
is a positional parameter. It specifies that the disk directory is located on a server, and specifies the server type. For MS SQL Servers, the only valid value is 4.
parm-3
is a positional parameter. For MS SQL Servers, do not specify a value for this parameter.
logon-cache
is a positional parameter. It specifies the maximum number of concurrent active logins to the database. Valid values are numeric. This parameter is optional.
case-sensitivity
is a positional parameter. It specifies the case sensitivity of the key comparison performed on key values returned during READ, KEY= operations. Values for this parameter are as follows:
0
Basic will perform a case sensitive comparison ( the default ).
1
Basic will perform a case insensitive comparison.
server-ID:login/password
is a positional parameter. It specifies the MS SQL Server, and the login and password used to enter the database. Valid values are:
server-ID
is the two-character specification assigned to the MS SQL Server. The server-ID specification in the DEV statement must match an entry in the SERVER.MAP file.
:
separates server-ID from the login/password specification.
login
is the MS SQL Server login used to connect to the database. The login/password specification is optional.
/
separates ID from password.
password
is the MS SQL Server password used to connect to the database. The login/password specification is optional.

Note: If multiple MS SQL Servers are configured, and the login and password are identical for each server, the PRM MSSQL-LOGIN statement can replace multiple login and password specifications in DEV statements.

For more information on the PRM MSSQL -LOGIN statement, on the SERVER.MAP file, and on DEV statements relevant to TS DataServer for MS SQL Server, please refer to TS DataServer for MS SQL Server documentation.

Example of the DEV statement for MS SQL Server devices (TS DataServer for MS SQL Server)

Example: DEV statement for SQL Server

DEV D8,1,,4,,,,O1:jill/jij

DEV
Begins the DEV statement.
DEV D8
Specifies that the device is called D8.
DEV D8,1
Specifies the device type for D8. Valid values are:
1logical disk directory
4standard dot matrix, character printer, or laser printer
5terminal that uses Thoroughbred Basic Windows
6terminal that uses a video card
7terminal that does not use Thoroughbred Basic Windows
8ghost task

D8 is defined as a logical disk directory.

DEV D8,1,,4
Specifies that the disk directory is located on MS SQL Server.
DEV D8,1,,4,,,,O1:jill/jij
Specifies that the server-ID is O1, the login is jill, and the password is jij.

Note: For more information on how to configure Thoroughbred products for use with MS SQL Servers and databases, please refer to the TS DataServer for MS SQL Server documentation.

DEV statement syntax for a MySQL server (TS DataServer for MySQL)

Section titled “DEV statement syntax for a MySQL server (TS DataServer for MySQL)”

DEV DX,type,paran-1,server-flag,parm-3, logon-cache,case-sensitivity,server-
ID:login/password

DEV
begins the DEV statement. The statement begins in the leftmost column.
DX
is the device ID, which Thoroughbred Basic uses to reference the MySQL server. Valid values range from D0 through D9, DA through DZ and Da through Dz. You can specify up to 62 logical and physical devices.

My SQL server specifications do not have to follow a set order. For example, you can specify the D0 disk after you specify the D1 disk.

Note: The DX specification means that MySQL servers are regarded as disk or directory devices. You can specify up to 62 disk or directory devices.

For more information on how MySQL servers work with the Thoroughbred products, please refer to the TS DataServer for MySQL documentation.

type
specifies the device type. For MySQL server, the only valid value is 4.
param-1
is a positional parameter. For MySQL servers, do not specify a value for this parameter.
server-flag
is a positional parameter. It specifies that the disk directory is located on a server, and specifies the server type. For MySQL servers, the only valid value is 5.
parm-3
is a positional parameter. For MySQL servers, do not specify a value for this parameter.
logon-cache
is a positional parameter. It specifies the maximum number of concurrent active logins to the database. Valid values are numeric. This parameter is optional.
case-sensitivity
is a positional parameter. It specifies the case sensitivity of the key comparison performed on key values returned during READ, KEY= operations. Values for this parameter are as follows:
0
Basic will perform a case sensitive comparison ( the default ).
1
Basic will perform a case insensitive comparison.
server-ID:login/password
is a positional parameter. It specifies the MySQL server, and the login and password used to enter the database. Valid values are:
server-ID
is the two-character specification assigned to the MySQL server. The server-ID specification in the DEV statement must match an entry in the SERVER.MAP file.
:
separates server-ID from the login/password specification.
login
is the MySQL server login used to connect to the database. The login/password specification is optional.
/
separates ID from password.
password
is the MySQL server password used to connect to the database. The login/password specification is optional.

Note: If multiple MySQL servers are configured, and the login and password are identical for each server, the PRM MYSQL-LOGIN statement can replace multiple login and password specifications in DEV statements.

For more information on the PRM MYSQL -LOGIN statement, on the SERVER.MAP file, and on DEV statements relevant to TS DataServer for MySQL, please refer to TS DataServer for MySQL documentation.

Example of the DEV statement for MySQL server devices (TS DataServer for MySQL)

Example: DEV statement for MySQL server

DEV D8,1,,5,,,,Y1:jill/jij

DEV
Begins the DEV statement.
DEV D8
Specifies that the device is called D8.
DEV D8,1
Specifies the device type for D8. Valid values are:
1logical disk directory
4standard dot matrix, character printer, or laser printer
5terminal that uses Thoroughbred Basic Windows
6terminal that uses a video card
7terminal that does not use Thoroughbred Basic Windows
8ghost task

D8 is defined as a logical disk directory.

DEV D8,1,,5
Specifies that the disk directory is located on MySQL server.
DEV D8,1,,5,,,,Y1:jill/jij
Specifies that the server-ID is Y1, the login is jill, and the password is jij.

Note: For more information on how to configure Thoroughbred products for use with MySQL servers and databases, please refer to the TS DataServer for MySQL documentation.

DEV TX,type,baud,parity,width,stopbits,nullstrip,driver|port

DEV
begins the DEV statement. The statement begins in the leftmost column.
TX
is the device ID, which Thoroughbred Basic uses to reference the device. Valid values may be 2, 3, or 4 characters long. In most cases, the first character is a T. Please refer to the Naming Devices at the beginning of this manual for valid values.
type
specifies the device type. Valid values are:

5 for a terminal that uses Thoroughbred Basic Windows.

6 for a terminal that uses a video card. Most systems running under MS-DOS require this specification.

7 for a terminal that does not use Thoroughbred Basic Windows.

To configure serial ports when you use the TTYn device under Microsoft Windows, specify 7.

baud
is a positional parameter that specifies baud rate. Most terminal devices do not require you to specify a value for this parameter.

To configure serial ports when you use the TTYn device under Microsoft Windows, you can specify one of the following values for baud:

110
150
300
600
1200
2400
4800
9600
14400
19200
38000
56000
115200
128000
256000

The default is the value specified by the Microsoft Windows MODE command.

parity
is a positional parameter that specifies parity. Most terminal devices do not require you to specify a value for this parameter.

To configure serial ports when you use the TTYn device under Microsoft Windows, you can specify one of the following values for parity:

0No parity
1Odd parity
2Even parity

The default is the value specified by the Microsoft Windows MODE command.

width
is a positional parameter that specifies width. Most terminal devices do not require you to specify a value for this parameter.

To configure serial ports when you use the TTYn device under Microsoft Windows, You can specify one of the following values for width:

7
8

The default is the value specified by the Microsoft Windows MODE command.

stopbits
is a positional parameter that specifies the number of stop bits. Most terminal devices do not require you to specify a value for this parameter.

To configure serial ports when you use the TTYn device under Microsoft Windows, you can specify one of the following values for stopbits:

1
2

The default is the value specified by the Microsoft Windows MODE command.

nullstrip
is a positional parameter that specifies how null characters are treated and whether bit 8 will be stripped. Most terminal devices do not require you to specify a value for this parameter.

To configure serial ports when you use the TTYn device, you can specify one of the following values for nullstrip:

0 means discard nulls and strip bit 8. This value is valid under Microsoft Windows.

1 means discard nulls but do not strip bit 8. This value is valid under Microsoft Windows.

2 means do not discard nulls but strip bit 8. This value is valid under UNIX.

3 means do not discard nulls and do not strip bit 8. This value is valid under UNIX.

Under Microsoft Windows, the default is the value specified by the Microsoft Windows MODE command. The value can be 0 or 1.

driver|port is a positional parameter that specifies the name of a terminal driver or system port. You must

specify a value for this parameter.

Examples of the DEV statement for terminal devices

Example: DEV statement for a terminal DEV T0,7,,,,,,tty

DEV
Begins the DEV statement.
DEV T0
Specifies that the device is called T0. You must make sure that this device name does not conflict with a task ID.
DEV T0,7
Specifies the device type for T0. Valid values are:
1logical disk directory
4standard dot matrix, character printer, or laser printer
5terminal that uses Thoroughbred Basic Windows
6terminal that uses a video card
7terminal that does not use Thoroughbred Basic Windows
8ghost task

T0 is defined as a terminal that will not use Thoroughbred Basic Windows.

DEV T0,7,,,,,,tty
Specifies the tty terminal driver. In most cases, tty is a generic terminal driver. Thoroughbred Basic will change the T0 device name based on the position of the tty specification in the TERMINAL file.

For more information on the TERMINAL file, please refer to IPLINPUT File section.

Note:
If 5 were specified as a device type the terminal would be defined as a terminal that uses Thoroughbred Basic Windows. In this case, Thoroughbred Basic uses the Thoroughbred Basic Windows Manager to communicate with the terminal.

Thoroughbred Basic Windows enables you to create a windowing interface for your application. It may slow terminal output. Thoroughbred Basic Windows may have display problems on terminals where character attributes occupy a physical position on the screen.

For more information on Thoroughbred Basic Windows, please refer to the Thoroughbred Basic Developer Guide.

Example: DEV statement for a monitor under Microsoft Windows

DEV T0,6,,,,,,CON

DEV
Begins the DEV statement.
DEV T0
Specifies that the device is called T0. You must make sure that this device name does not conflict with a task ID.
DEV T0,6
Specifies the device type for T0. Valid values are:
1logical disk directory
4standard dot matrix, character printer, or laser printer
5terminal that uses Thoroughbred Basic Windows
6terminal that uses a video card
7terminal that does not use Thoroughbred Basic Windows
8ghost task

T0 is defined as a monitor that uses a video card. This monitor will not run Thoroughbred Basic Windows.

Note:
Under Microsoft Windows, device types 6 and 7 are roughly equivalent. Neither specification enables you to use Thoroughbred Basic Windows.

To use Thoroughbred Basic Windows under Microsoft Windows you must specify 5 as the device type.

For more information on Thoroughbred Basic Windows, please refer to the Thoroughbred Basic Developer Guide.

DEV T0,6,,,,,,CON
Specifies that the name of the terminal is CON, which is short for console.

Under Microsoft Windows, you can specify communication ports in place of CON. You can specify COM1 or COM2 for standard communication. For interrupt-driven communication support, you can specify TTY1 or TTY2.

Example: DEV statement to configure a serial port when using the TTYn device under Microsoft Windows

DEV T0,7,9600,2,8,1,1,TTY1

DEV
Begins the DEV statement.
DEV T0
Specifies that the device is called T0. You must make sure that this device name does not conflict with a task ID.
DEV T0,7
Specifies the device type for T0. Valid values are:

1 logical disk directory

4 standard dot matrix, character printer, or laser printer

5 terminal that uses Thoroughbred Basic

6 terminal that uses a video card

7 terminal that does not use Thoroughbred Basic Windows 8 ghost task

T0 is defined as a terminal that does not run Thoroughbred Basic Windows. To configure a serial port when using the TTYn device under Microsoft Windows, you must specify 7.

DEV T0,7,9600
Specifies the baud rate. Valid values are:

110
150
300
600
1200
2400
4800
9600
14400
19200
38000
56000
115200
128000
256000

Baud is set to 9600.

DEV T0,7,9600,2
Specifies parity. Valid values are:
0No parity
1Odd parity
2Even parity

Parity is set to even parity.

DEV T0,7,9600,2,8
Specifies width, the number of data bits in a character. Valid values are:

7
8

Width is set to 8 bits.

DEV T0,7,9600,2,8,1
Specifies the number of stop bits. Valid values are:

1
2

The number of stop bits is set to 1.

DEV T0,7,9600,2,8,1,1
Specifies how nulls are treated and whether bit 8 is stripped. Valid values are:

0 means discard nulls and strip bit 8. This value is valid under Microsoft Windows.

1 means discard nulls but do not strip bit 8. This value is valid under Microsoft Windows.

2 means do not discard nulls but strip bit 8. This value is valid under UNIX.

3 means do not discard nulls and do not strip bit 8. This value is valid under UNIX.

Null characters will be discarded, but bit 8 will not be stripped.

DEV T0,7,9600,2,8,1,1,TTY1 Specifies the name of the TTYn device as TTY1.

Example: DEV statement for a terminal-oriented device

DEV T1,7,,,,,,tty05b

DEV
Begins the DEV statement.
DEV T1
Specifies that the device is called T1. You must make sure that this device name does not conflict with a task ID.
DEV T1,7
Specifies the device type for T1. Valid values are:
1logical disk directory
4standard dot matrix, character printer, or laser printer
5terminal that uses Thoroughbred Basic Windows
6terminal that uses a video card
7terminal that does not use Thoroughbred Basic Windows
8ghost task

T1 is defined as a monitor that will not run Thoroughbred Basic Windows.

DEV T1,7,,,,,,tty05b
Specifies the tty05b system port.

This specification enables this task to communicate to another terminal or to a modem attached to that port. This type of terminal-oriented device must be specified with a device type of 7. It cannot use the Thoroughbred Basic Windows Manager.

DEV dev-ID,type,param-1,width,lockflag, spooler,time-out,devicename

DEV
begins the DEV statement. The statement begins in the leftmost column.
dev-ID
is the device ID, which Thoroughbred Basic uses to reference the printer device. In most cases, you will use one of the following formats to specify dev-ID:
LX
is a printer device. Printer devices include dot matrix printers, character printers, laser printers, print spoolers, and slave printers. Valid values for X are 0 through 9, A through Z, and a through z.
PX
is a printer device. Printer devices include dot matrix printers, character printers, laser printers, print spoolers, and slave printers. Valid values for X are 0 through 9, A through Z, and a through z.
type
specifies the device type. For a printer device, the only valid value is 4.
param-1
is a positional parameter. For printer devices, do not specify a value for this parameter.
width
is a positional parameter that specifies the line width. The largest valid value is the maximum number of characters that can be printed on one line. The default is 132.
lockflag
is a positional parameter that specifies whether the printer will be available to more than one task at the same time. Valid values are:

0 Printer locking is in effect. The printer is only available to one task at a time. This is the default.

Thoroughbred Basic, not the operating system, maintains printer locking. Under UNIX, when an OPEN directive is issued, Thoroughbred Basic creates two files, one to link the printer to the task and one to lock the printer. In the case of a printer named lp and a task ID named T5, the files would be named /tmp/lp.T5 and /tmp/lp.lck. When the CLOSE directive is issued, Thoroughbred Basic erases these two files.

1 Printer sharing is in effect. The printer is available to more than one task at a time.

Because a value of 1 enables multiple tasks to use the printer at the same time, this specification can result in merged output printing. In most cases, this specification is used for spooled printing.

For more information on the directives mentioned above, please refer to the Thoroughbred Basic Language Reference.

spooler
is a positional parameter that specifies what type of printer device is associated with the dev-ID. Valid values are:

0 A directly connected printer. There is no spooling. This is the default.

The name of the printer is specified in the devicename parameter.

1 A spooler that uses piped input. A pipe is created between Thoroughbred Basic and an executable program specified by the devicename parameter. Output will be sent through the pipe to the program. The program can be a shell script or a binary executable.

Under Microsoft Windows

Under Microsoft Windows, this specifies pass-through Print Manager mode. All output will be spooled to the Microsoft Windows Print Manager. Pass-through mode uses existing Dictionary-IV printer tables. If you use the Windows Print Setup facility to change printer type, you must reassign your printer table to the new type.

Programs that use escape sequences or mnemonics that the Print Manager does not recognize will generate errors.

To use the Print Setup facility, click the File option on the menu bar. For more information on Dictionary-IV printer tables, please refer to the Dictionary-IV Reference Manual.

2 A slave printer, which is a printer connected to a terminal’s auxiliary or printer port and available only to that terminal. Output can be sent to the secondary port by using the ‘PS’ and ‘PE’ terminal mnemonics. For more information on slave printers and terminal mnemonics, please refer to TCONFIG File.

The terminal device is specified in the devicename parameter.

3 A spooler that uses a temporary file. Thoroughbred Basic will create a temporary file to contain output. After the file is closed, its contents will be released to an executable program specified by the devicename parameter. The program can be a shell script or a binary executable.

Under Microsoft Windows

Under Microsoft Windows, 3 specifies standard Print Manager mode. All output will be spooled to the Microsoft Windows Print Manager. Standard mode uses a standard printer table, which enables you to use the Windows Print Setup facility to change printer type without having to reassign your printer table to the new type.

To use a standard printer table, you must create a printer table that contains a set of escape sequences. For more information on how to create the printer table, please refer to the TS Environment for Windows Supplemental Guide.

Programs that use escape sequences or mnemonics that the Print Manager does not recognize will generate errors.

To use the Print Setup facility, click the File option on the menu bar. For more information on Dictionary-IV printer tables, please refer to the Dictionary-IV Reference Manual.

4 Under Microsoft Windows, specifies an append to a file.

time-out
is a positional parameter that specifies the printer time-out. Valid values are numbers, which specify seconds. If the printer does not respond within the specified number of seconds, Thoroughbred Basic generates a time-out error. The default is 15 seconds.
devicename
is a positional parameter that contains the name of a printer device, terminal device, system port, or program. For more information on valid specifications, please refer to the description of the spooler parameter.

Examples of the DEV statement for printer devices

Example: DEV statement for a printer

DEV LP,4,,142,1,1,,lp -dP4

DEV
Begins the DEV statement.
DEV LP
Specifies that the device is called LP.
DEV LP,4
Specifies the device type for LP. Valid values are:

1 logical disk directory

4 standard dot matrix, character printer, or laser printer

5 terminal that uses Thoroughbred Basic Windows

6 terminal that uses a video card

7 terminal that does not use Thoroughbred Basic Windows

8 ghost task

LP is defined as a printer.

DEV LP,4,,142
Specifies the maximum line width. In this example, the maximum line width is 142 characters. The default is 132.
DEV LP,4,,142,1
Specifies the printer lock flag. Valid values are:

0 The printer is only available to one task at a time. This is the default.

1 The printer is available to more than one task at a time.

Because a value of 1 enables multiple tasks to use the printer at the same time, this specification can result in merged output printing. In most cases, this specification is used for special printers or point-of-sale stations.

Thoroughbred Basic, not the operating system, maintains printer locking. When an OPEN directive is issued, Thoroughbred
Basic creates two files, one to link the printer to the task and one to lock the printer. In the case of a printer named lp and a task ID named T5, the files would be named /tmp/lp.T5 and
/tmp/lp.lck. When the CLOSE directive is issued,
Thoroughbred Basic erases these two files.

For more information on the directives mentioned above, please refer to the Thoroughbred Basic Language Reference.

DEV LP,4,,142,1,1
Specifies the print spooler flag. Valid values are:

0 A directly connected printer. There is no spooling. This is the default.

1 A spooler that uses piped output

2 A slave printer, which is attached to printer port of the terminal this task is using.

3 A spooler. Thoroughbred Basic will create a /tmp file. After the file is closed, it will be released to the spooler.

4 Under Microsoft Windows, specifies an append to a file.

LP will use a spooler that expects piped output.

DEV LP,4,,142,1,1,,lp -dP4
Specifies lp as the system name of the print spooler and -dP4 as the parameters that will be sent to the spooler with the piped output.

For more information on print spoolers and print parameters, please refer to your operating system documentation.

Example: DEV statement for a slave printer

DEV P1,4,,132,,2,5,tty

DEV
Begins the DEV statement.
DEV P1
Specifies that the device is called P1.
DEV P1,4
Specifies the device type for P1. Valid values are:
1logical disk directory
4standard dot matrix, character printer, or laser printer
5terminal that uses Thoroughbred Basic Windows
6terminal that uses a video card
7terminal that does not use Thoroughbred Basic Windows
8ghost task

P1 is defined as a printer.

DEV P1,4,,132
Specifies the maximum line width. In this example, the maximum line width is 132 characters, which is also the default.
DEV P1,4,,132,,2
Specifies the print spooler flag. Valid values are:

0 A directly connected printer. There is no spooling. This is the default.

1 A spooler that uses piped output

2 A slave printer, which is attached to printer port of the terminal this task is using.

3 A spooler. Thoroughbred Basic will create a /tmp file. After the file is closed, it will be released to the spooler.

4 Under Microsoft Windows, specifies an append to a file.

P1 is defined as a slave printer. For more information on slave printers, please refer to TCONFIG File.

DEV P1,4,,132,,2,5
Specifies the printer response time. In this example, the time is 5 seconds. The default is 15.

The printer will generate a time-out error if it does not respond within 5 seconds.

DEV P1,4,,132,,2,5,tty
Specifies the generic terminal driver. A slave printer can only be used by the task associated with the terminal. It is not classed as a system printer.

Example: DEV statement for pass-through Print Manager mode under Microsoft Windows

DEV LP,4,,,,1,,LPT1

DEV
Begins the DEV statement.
DEV LP
Specifies that the device is called LP.
DEV LP,4
Specifies the device type for LP. Valid values are:
1logical disk directory
4standard dot matrix, character printer, or laser printer
5terminal that uses Thoroughbred Basic Windows
6terminal that uses a video card
7terminal that does not use Thoroughbred Basic Windows
8ghost task

LP is defined as a printer.

DEV LP,4,,,,1
Specifies the print spooler flag. Valid values are:

0 A directly connected printer. There is no spooling. This is the default.

1 A spooler that uses piped output

2 A slave printer, which is attached to printer port of the terminal this task is using.

3 A spooler. Thoroughbred Basic will create a /tmp file. After the file is closed, it will be released to the spooler.

4 Under Microsoft Windows, specifies an append to a file.

LP is defined as a printer that expects spooled output.

Under Microsoft Windows, 1 specifies pass-through Print Manager mode. All output would be spooled to the Microsoft Windows Print Manager. Pass-through mode uses existing Dictionary-IV printer tables. If you use the Windows Print Setup facility to change printer type, you must reassign your printer table to the new type.

Programs that use escape sequences or mnemonics that the Print
Manager does not recognize will generate errors.

To use the Print Setup facility, click the File option on the menu bar. For more information on Dictionary-IV printer tables, please refer to the Dictionary-IV Reference Manual.

DEV LP,4,,,,1,,LPT1
Specifies the LPT1: system port. This example assumes that the Microsoft Windows Print Manager will spool output to this parallel port.

Example: DEV statement for standard Print Manager mode under Microsoft Windows

DEV LP,4,,,,3,,LPT1

DEV
Begins the DEV statement.
DEV LP
Specifies that the device is called LP.
DEV LP,4
Specifies the device type for LP. Valid values are:
1logical disk directory
4standard dot matrix, character printer, or laser printer
5terminal that uses Thoroughbred Basic Windows
6terminal that uses a video card
7terminal that does not use Thoroughbred Basic Windows
8ghost task

LP is defined as a printer.

DEV LP,4,,,,3
Specifies the print spooler flag. Valid values are:

0 A directly connected printer. There is no spooling. This is the default.

1 A spooler that uses piped output

2 A slave printer, which is attached to printer port of the terminal this task is using.

3 A spooler. Thoroughbred Basic will create a /tmp file. After the file is closed, it will be released to the spooler.

4 Under Microsoft Windows, specifies an append to a file.

LP is defined as a spooler.

Under Microsoft Windows, 3 specifies standard Print Manager mode. All output will be spooled to the Microsoft Windows Print Manager. Standard mode uses a standard printer table, which enables you to use the Windows Print Setup facility to change printer type without having to reassign your printer table to the new type.

To use a standard printer table, you must create a printer table that contains a set of escape sequences. For more information on how to create the printer table, please refer to the TS Environment for Windows Supplemental Guide.

Programs that use escape sequences or mnemonics that the Print
Manager does not recognize will generate errors.

To use the Print Setup facility, click the File option on the menu bar. For more information on Dictionary-IV printer tables, please refer to the Dictionary-IV Reference Manual.

DEV LP,4,,,,3,,LPT1
Specifies the LPT1: system port. This example assumes that the Microsoft Windows Print Manager will spool output to this parallel port.

Example: DEV statement for printer and intelligent I/O communications board

DEV P2,4,,,,,,ttp8e

DEV
Begins the DEV statement.
DEV P2
Specifies that the device is called P2.
DEV P1,4
Specifies the device type for P2. Valid values are:
1logical disk directory
4standard dot matrix, character printer, or laser printer
5terminal that uses Thoroughbred Basic Windows
6terminal that uses a video card
7terminal that does not use Thoroughbred Basic Windows
8ghost task

P2 is defined as a printer.

DEV P2,4,,,,,,ttp8e
Specifies a system port named ttp8e. By default, the line width is 132 characters, the printer is directly connected to the system port, and the printer response time is 15 seconds.
Note:
Some manufacturers of intelligent I/O communication boards provide the ability to address a printer attached to the back of a terminal by using separate drivers for the I/O board.

In this example, the ttp8e port name is assigned by the Stargate Serial I/O Xenix Drivers for the Stargate ACL board. The board specifies a slave printer attached to a terminal connected to the tty8e serial port, which enables the printer to be a system printer. The printer is available to any task provided this DEV statement is specified in its associated IPL file.

DEV GX,type

DEV
begins the DEV statement. The statement begins in the leftmost column.
GX
is the device ID, which Thoroughbred Basic uses to reference the ghost task. Valid values are G0 through G9 and GA through GZ. You can specify up to 36 ghost tasks.

Ghost task device specifications must follow ascending order. For example, if you plan to specify 36 ghost tasks you must specify G0 through G9, then GA through GZ.

type
specifies the device type. For a ghost task, the only valid value is 8.

Examples of the DEV statement for ghost tasks

Example: DEV statement for the first ghost task

DEV G0,8

DEV
Begins the DEV statement.
DEV G0
Specifies that the device is called G0. The only valid names for ghost tasks are G0 through G9 and GA through GZ.

The first ghost task defined in an IPL file must be named G0.

DEV G0,8
Specifies the device type for G0. Valid values are:
1logical disk directory
4standard dot matrix, character printer, or laser printer
5terminal that uses Thoroughbred Basic Windows
6terminal that uses a video card
7terminal that does not use Thoroughbred Basic Windows
8ghost task

G0 is defined as a ghost task.

For more information on ghost tasks, please refer to TERM.MAP File in this manual and to the Thoroughbred Basic Developer Guide.

Example: DEV statement for the second ghost task

DEV G1,8

DEV
Begins the DEV statement.
DEV G1
Specifies that the device is called G1. The only valid names for ghost tasks are G0 through G9 and GA through GZ.

The first ghost task defined in an IPL file must be named G0 and the second must be named G1.

DEV G1,8
Specifies the device type for G1. Valid values are:
1logical disk directory
4standard dot matrix, character printer, or laser printer
5terminal that uses Thoroughbred Basic Windows
6terminal that uses a video card
7terminal that does not use Thoroughbred Basic Windows
8ghost task
G1
is defined as a ghost task.
Note:
If you plan to use more than one IPL file for one Thoroughbred Basic system, each file must contain identical ghost task specifications.

For example, if the IPLINPUT file contains DEV statements for five ghost tasks named G0 through G4, every other IPL file must contain those DEV statements. No IPL file can define more than five ghost tasks.

From the Customization and Tuning Guide: System Files, version 8.9.1. Open this page in the PDF