GDDM V3R2 Base Application Programming Reference
Previous topic | Next topic | Contents | Index | Contact z/OS | Library | PDF | BOOK


DSOPEN

GDDM V3R2 Base Application Programming Reference
SC33-0868-02



Function


To open a device.


   DSOPEN      (device-id, family, device-token, procopt-count, procopt-list,
               name-count, name-list)

APL code 901 GDDM RCP code X'0C000200' (201327104)


Parameters


device-id (specified by user) (fullword integer)
The device identifier. It must not be negative.


The values 0 and 1 should also be avoided, unless it is certain that they are not required for default devices.

Note that GDDM can automatically open devices, as follows:

  • It opens the default primary device (device-id = 0), when no primary device has been specified (by a DSUSE), or
    
    
  • It opens the default alternate device (device-id = 1), if an FSOPEN statement is issued.
    
    

family (specified by user) (fullword integer)
The device-family code, which can take these values:

1 3270-family devices
These include:

  • 3270 displays and printers
  • Plotters
  • Scanners
  • 5550-family displays and printers
  • 5081 high function graphics display
  • Personal computer systems using GDDM-PCLK or GDDM-OS/2 Link, together with attached printers and plotters
  • ASCII displays.
    
    
For a full list of these devices, see the GDDM General Information manual for the latest release.

2 Queued printer files
Queued printer output for any of the family-1 devices.

3 System printer files
For a full list of system printers, see the GDDM General Information manual for the latest release.

4 Page printer files
For a full list of page printers, see the GDDM General Information manual for the latest release.

Note: A device-family code of zero, which can be returned by DSQDEV, FSQDEV, or FSQURY (see the descriptions of these functions), cannot be specified for the family parameter on DSOPEN.

device-token (specified by user) (8-byte character string)
Tells GDDM where to find the properties of the device. GDDM left-justifies the supplied parameter, and converts it to uppercase, if necessary. It can have these values:

  • '* '--GDDM is to determine device properties from subsystem tables, the device itself, or GDDM's own defaults, or both as appropriate to the device and subsystem.
    
    
  • The name of a device token that is part of the ADMLSYS1, ADMLSYS3, ADMLSYS4, or ADMLSYSA table. A version of each of these tables is supplied with GDDM, and contains several device tokens. A table containing different definitions can be regenerated if required. For contents of the GDDM-supplied tables and other information, see "Device characteristics tokens" in topic 21.0.
    
    

Notes:

1. The device token determines the size of the default page. (See the maxpage parameter of the ADMM3270 macro in the GDDM System Customization and Administration book).

2. On a queued printer (family-2 device), the device token does not affect the device properties subsequently used by the GDDM print utility when it processes the print request; the device token is used only to determine the size of the default page. The device characteristics are established when the real output device is opened. If a heading page is specified, it is created at output time using the default page size of the real output device.

procopt-count (specified by user) (fullword integer)
The number of fullwords in procopt-list. Zero can be specified to indicate that procopt-list is empty and is not to be inspected.

procopt-list (specified by user) (an array of fullword integers)
This list is used to pass miscellaneous processing options to GDDM. Some of these options are dependent on the device family, and some on a particular subsystem.

Each option is passed as an option group, consisting of a fullword option code, followed by one or more fullwords of option data. Option groups can be specified in any order. Only those option groups for which it is specifically required to override GDDM's default action need be specified. If an option group is not relevant in the execution circumstances (for example, CMS attention handling, while operating under TSO), that option group is ignored.

The parameter list takes the form:


    __________________________ 
   | First Option Group Code  |
   |__________________________|
   |   Option 1               |
   |__________________________|
   |   Option 2               |
   |__________________________|
   |   ( .... )               |
   |__________________________|
   | Second Option Group Code |
   |__________________________|
   |   Option 1               |
   |__________________________|
   |   ( .... )               |
   |__________________________|


The option groups are described in detail in "Processing options" in topic 19.0.

name-count (specified by user) (fullword integer)
The number of 8-byte name-parts in name-list. Zero can be specified to indicate that name-list is empty and is not to be inspected. Even if name-list is empty, it must be specified in the parameter list of the call.

name-list (specified by user) (array of 8-byte character tokens)
This list gives the name-parts that constitute the name by which the device is known to the underlying subsystem. The number of name-parts that can be supplied and their meanings are subsystem- and family-dependent. GDDM left-justifies each supplied name-part and converts it to uppercase, if necessary. Even if name-list is empty, it must be specified in the parameter list of the call.

The values for the name-count and name-list parameters for the various subsystems are shown in "Name-lists" in topic 20.0.

Description


Opens (initializes) a device that GDDM is to access.

There is usually no need to issue a DSOPEN call when the output is to appear on the invoking terminal - known as the user console. By default, GDDM automatically opens the user console with device ID of 0 if it is required.

If a device other than the user console is to be made known to GDDM, it must have an explicit DSOPEN call unless a nickname is used (see below) that acts on GDDM's automatic opening of the user console.

After an explicit DSOPEN and before creating any output for a device, the device must be made current using a DSUSE call. According to the usage specified in the DSUSE call, statements apply to that device until a new device is made current. The scheme is the same as that for pages; that is, several devices are available but only one of them is current at any one time.

In a windowing environment, the DSOPEN call applies to a virtual device that is displayed in an operator window of a real device. However, unless the application needs to use the windowing calls, it does not have to distinguish between real and virtual devices. For more information, see the GDDM Base Application Programming Guide.

DSOPEN calls are required for auxiliary devices, such as plotters, which can be attached through 3179-G, 3192-G, or 3472-G display stations, 3270-PC/G or 3270-PC/GX workstations, 5550-family Multistations, or devices using GDDM-PCLK. To GDDM, a plotter is a family-1 device. It is identified by using DSOPEN's name-count and name-list parameters. For full information, see "Name-lists" in topic 20.0.

Image scanners (3117 and 3118) are always attached to an image display (3193), and therefore DSOPEN calls cannot be made directly to them; DSOPEN calls must be made to the image display.

All loadable-character-set stores on the device are assumed to be available for use by GDDM, unless they are subsequently reserved by a call to PSRSV.

In CICS transaction-dependent pseudoconversational mode, on the initial invocation of a transaction and after processing the initial input, the PSCNVCTL processing option must be set to "start pseudoconversational mode." On subsequent invocations, it must be set to "continue pseudoconversational mode." For further information, see the GDDM Base Application Programming Guide.

   Notes:

1. There are restrictions on the use of DSOPEN for some subsystems. For further information, see the GDDM Base Application Programming Guide.

2. To enable the invocation of the Interactive Chart Utility in circumstances that require special DSOPEN parameters, the PGF feature of GDDM provides the sample module ADMUCDSO. This module is supported under TSO and VM/CMS only. Information about how to use ADMUCDSO is given in the GDDM-PGF Programming Reference book.

3. Throughout the description of this call, references to TSO also apply to the MVS Batch environment.

Example of a DSOPEN call

Here is an example of a DSOPEN call. The example assumes that the necessary declare statements for the programming language in use have been written (for a PL/I model, see the GDDM Base Application Programming Guide).

This example assigns a device identifier of 11 to a local 3279 Model 3 display (screen size 32 by 80), with processing option groups 1000 and 1001 (for CMS PA1/PA2 protocol and attention handling), and with a virtual address known to VM/CMS as '061'.

The DSOPEN call to define the device in this way is:


     CALL DSOPEN(11,1,'L79A3',6,P_LIST,1,N_LIST)

The following diagram illustrates the values in each of the DSOPEN parameters:


   Device Identifier   Device Family    Device Token
    ________            _____            ________ 
   |   11   |          |  1  |          | 'L79A3'|
   |________|          |_____|          |________|
                                        (Character)

Procopt-count Procopt-list ______ ________ | 6 | | 1000 | |______| |________| (Number of elements in the procopt- | 2 | list array called P_LIST) |________| | 1001 | |________| | 1 | |________| | 8 | |________| |'12AB80'| |________|

Name-count Name-list ________ _______ | 1 | | '061' | |________| |_______| (Number of elements in the name-list array called N_LIST) (hexadecimal)


The procopt-list called P_LIST is constructed as follows:


    __________ 
   |          | First procopt group code
   |   1000   | (CMS PA1/PA2 protocol)
   |__________|
   |          | Procopt value for this group
   |      2   | (PA1 to CP, PA2 to user)
   |__________|
   |          | Second procopt group code
   |   1001   | (CMS attention handling)
   |__________|
   |          | First procopt value (extended
   |      1   | attention handling) for group
   |__________|
   |          | Second procopt value (length of
   |      8   | feedback block) for group
   |__________|
   |          | Third procopt value (address of
   |X'12AB80' | feedback block) for group
   |__________|


Principal errors


ADM0074 E
INVALID DEVICE IDENTIFIER
ADM0075 E
INVALID DEVICE FAMILY n
ADM0077 E
DEVICE ALREADY EXISTS
ADM0078 E
INVALID NAME COUNT n
ADM0079 E
INVALID PROCESSING OPTIONS COUNT n
ADM0080 E
DEVICE IS NOT HARDCOPY. DEVICE TOKEN WAS 'a'
ADM0085 E
UNSUPPORTED PROCESSING OPTION CODE n
ADM0086 E
INVALID PROCESSING OPTION VALUE n1 FOR CODE n2
ADM0087 E
QUERY ERROR: TOKEN 'a',HDR X'llllttqq' OFF X'xx' REASON n
ADM0088 E
QUERY VALUE ERROR: TOKEN 'a', HDR X'llllttqq' , OFF X'xx'
ADM0090 E
NO USABLE AREA IN QUERY REPLY
ADM0091 E
DEVICE NOT SUPPORTED ON THIS SUBSYSTEM. DEVICE TOKEN WAS 'a'
ADM0092 E
CONFLICT BETWEEN PROCESSING OPTION CODE n AND DEVICE TOKEN 'a'
ADM0093 W
PAGE SIZE REDUCED TO n1,n2 TO FIT MEDIUM
ADM0094 W
PROCESSING OPTION CODE n NOT SUPPORTED BY PLOTTER
ADM0096 E
AUXILIARY DEVICE TYPE a IS UNKNOWN TO GDDM
ADM0097 E
AUXILIARY DEVICE 'a' NOT FOUND
ADM0100 S
DEVICE NOT SUPPORTED FOR FAMILY n. DEVICE TOKEN WAS 'a'
ADM0101 E
USABLE AREA WIDTH OR DEPTH NOT LESS THAN 16384 PIXELS
ADM0102 E
INVALID PROCOPT GROUP. CODE = a1{, NUMBER = n}, REASON = a2
ADM0103 E
PLOTTER CANNOT SUPPORT THE REQUESTED PAPER SIZE
ADM0104 E
PLOT AREA IS TOO BIG FOR THE CURRENT PLOTTER SETUP
ADM0106 E
DEVICE TOKEN 'a' IS FOR AUXILIARY DEVICES ONLY
ADM0107 E
PLOTTER CANNOT BE SUPPORTED ON AN OUTPUT-ONLY TERMINAL
ADM0108 E
CANDIDATE OPERATOR WINDOW ALREADY IN USE OR NOT ACCESSIBLE
ADM0109 E
ONLY ONE DEVICE AT A TIME MAY BE WINDOWED
ADM0400 E
DEFAULT 'MAXIMUM TRANSMISSION SIZE' n IS INVALID
ADM0401 E
INVALID TERMINAL TYPE. THIS IS NOT A DISPLAY TERMINAL
ADM0402 E
TERMINAL ERROR. RETURN CODE n (DECIMAL) FROM a
ADM0403 E
TERMINAL a DISCONNECTED OR DOES NOT EXIST
ADM0404 E
DATA STREAM ERROR
ADM0407 E
DEFAULT 'MAXIMUM FSSAVE/FSSHOW BUFFER SIZE', n, IS INVALID
ADM0409 E
INVALID COLOR MASTER SET NUMBER n
ADM0441 S
TERMINAL ERROR{ ON a}. DEVICE DISCONNECTED OR NOT DEFINED
ADM0444 E
INVALID CMS ATTN OPTION FOR DEVICE 'a'
ADM0445 E
INVALID CMS PA1/PA2 OPTION FOR DEVICE 'a'
ADM0461 E
I/O PCB ALREADY IN USE OR NOT AVAILABLE
ADM0462 E
NO TP PCB WITH DESTINATION a AVAILABLE FOR USE BY THIS DEVICE
ADM0481 E
NAME COUNT OF n1 FOR 'a' IS INVALID FOR FAMILY n2
ADM0482 E
DEVICE NAME LIST 'a' IS INVALID FOR FAMILY n
ADM0483 E
COLOR MASTER a NOT FOUND
ADM0484 E
NO DEVICE TOKEN PROVIDED FOR DUMMY DEVICE
ADM0485 E
SUBSYSTEM DEVICE 'a' ALREADY OPEN
ADM0872 W
SCREEN SIZE TOO SMALL FOR USER CONTROL

Go to the previous page Go to the next page



Copyright IBM Corporation 1990, 2012