Lady Ada

Ada '83 Language Reference Manual

Copyright 1980, 1982, 1983 owned by the United States Government. Direct reproduction and usage requests to the Ada Information Clearinghouse.

14.6. Low Level Input-Output


A low level input-output operation is an operation acting on a physical device. Such an operation is handled by using one of the (overloaded) predefined procedures SEND_CONTROL and RECEIVE_CONTROL.

A procedure SEND_CONTROL may be used to send control information to a physical device. A procedure RECEIVE_CONTROL may be used to monitor the execution of an input-output operation by requesting information from the physical device.

Such procedures are declared in the standard package LOW_LEVEL_IO and have two parameters identifying the device and the data. However, the kinds and formats of the control information will depend on the physical characteristics of the machine and the device. Hence, the types of the parameters are implementation-defined. Overloaded definitions of these procedures should be provided for the supported devices.

The visible part of the package defining these procedures is outlined as follows:

 package LOW_LEVEL_IO is
    --  declarations of the possible types for DEVICE and DATA;
    --  declarations of overloaded procedures for these types:
    procedure SEND_CONTROL    (DEVICE : device_type; DATA : in out data_type);
    procedure RECEIVE_CONTROL (DEVICE : device_type; DATA : in out data_type);

The bodies of the procedures SEND_CONTROL and RECEIVE_CONTROL for various devices can be supplied in the body of the package LOW_LEVEL_IO. These procedure bodies may be written with code statements.

Rationale references: 16 Input-Output, 16.7 Low Level Input-Output

Style Guide references: 7.7.4 Package Low_Level_IO


[Ada Information Clearinghouse]

Address any questions or comments to