{ These constants define the condition code subranges for the components of
{ the CARTRIDGE_SYSTEM_VE_5744 interface.

  CONST
     tcc$condition = (($integer('T') * 100(16)) + $integer('C')) * 1000000(16),
     tcc$tc_id = 'TC';

  CONST
      tcc$5744_message_base          = tcc$condition + 000;

{-------------------------------------------------------------------------------
{ Error messages that may be generated by the 5744 library interface components.
{-------------------------------------------------------------------------------

  CONST
    tce$acs_full = tcc$5744_message_base + 1,
    {E 5744 library: ACS +P1 is full.}

    tce$acs_not_in_library = tcc$5744_message_base + 2,
    {E 5744 library: ACS +P1 is not configured.}

    tce$acs_offline = tcc$5744_message_base + 3,
    {I 5744 library: ACS +P1 is off-line.}

    tce$audit_in_progress = tcc$5744_message_base + 8,
    {I 5744 library: Request not processed - audit in library.}

    tce$request_cancelled = tcc$5744_message_base + 9,
    {E 5744 library: Request +P1 has been cancelled.}

    tce$count_too_small = tcc$5744_message_base + 20,
    {E 5744 library: Count too small.}

    tce$count_too_large = tcc$5744_message_base + 21,
    {E 5744 library: Count too large.}

    tce$data_base_error = tcc$5744_message_base + 23,
    {F 5744 library: Database error.}

    tce$drive_is_available = tcc$5744_message_base + 28,
    {I 5744 library: Drive available - +P1.}

    tce$drive_in_use = tcc$5744_message_base + 29,
    {I 5744 library: Drive in use - +P1.}

    tce$drive_not_in_library = tcc$5744_message_base + 30,
    {E Drive not in the 5744 library - +P1.}

    tce$drive_offline = tcc$5744_message_base + 31,
    {I 5744 library: Drive off-line - +P1.}

    tce$invalid_acs = tcc$5744_message_base + 39,
    {E 5744 library: Invalid ACS: +P1.}

    tce$invalid_drive = tcc$5744_message_base + 42,
    {E 5744 library: Invalid drive number - +P1.}

    tce$invalid_lsm = tcc$5744_message_base + 43,
    {E 5744 library: Invalid LSM - +P1.}

    tce$invalid_option = tcc$5744_message_base + 45,
    {E 5744 library: Invalid message_option: +P1.}

    tce$invalid_type = tcc$5744_message_base + 51,
    {E 5744 library: Invalid type: +P1.}

    tce$invalid_volume = tcc$5744_message_base + 53,
    {E 5744 library: Invalid EVSN: +P1.}

    tce$library_busy = tcc$5744_message_base + 55,
    {I Request not processed - 5744 library temporarily busy.}

    tce$library_failure = tcc$5744_message_base + 56,
    {F 5744 library failure.}

    tce$library_not_available = tcc$5744_message_base + 57,
    {F 5744 library is not available.}

    tce$lsm_not_in_library = tcc$5744_message_base + 60,
    {E 5744 library: LSM not configured - +P1.}

    tce$lsm_offline = tcc$5744_message_base + 61,
    {I 5744 library: LSM is off-line - +P1.}

    tce$message_too_large = tcc$5744_message_base + 63,
    {E 5744 library: Message too large.}

    tce$message_too_small = tcc$5744_message_base + 64,
    {E 5744 library: Message too small.}

    tce$misplaced_tape = tcc$5744_message_base + 65,
    {I 5744 library: Misplaced EVSN: +P1.}

    tce$not_in_same_acs = tcc$5744_message_base + 69,
    {E 5744 library: EVSN and drive are not in same ACS - +P1.}

    tce$process_failure = tcc$5744_message_base + 74,
    {E 5744 library process has failed.}

    tce$invalid_cyber_request = tcc$5744_message_base + 83,
    {E 5744 library: Invalid request from CYBER.}

    tce$volume_in_drive = tcc$5744_message_base + 91,
    {I 5744 library: EVSN +P1 is already mounted.}

    tce$volume_not_in_drive = tcc$5744_message_base + 93,
    {I 5744 library: EVSN +P1 is not in the drive.}

    tce$volume_not_in_library = tcc$5744_message_base + 94,
    {I 5744 library: EVSN +P1 is not in the library.}

    tce$unreadable_label = tcc$5744_message_base + 95,
    {E 5744 library: Unreadable external label - EVSN: +P1.}

    tce$unsupported_option = tcc$5744_message_base + 96,
    {E 5744 library: Unsupported message_option: +P1.}

    tce$unsupported_type = tcc$5744_message_base + 98,
    {E 5744 library: Unsupported type: +P1.}

    tce$volume_in_use = tcc$5744_message_base + 99,
    {I 5744 library: Requested EVSN is in use: +P1.}

{-----------------------------------------------------------------------
{   Errors resulting from message data returned by STK library
{   and NOT from the STK status codes.
{-----------------------------------------------------------------------

    tce$bad_dismount_status = tcc$5744_message_base + 200,
    {E 5744 library returned unrecognizable dismount status code: +P1.}

    tce$bad_mount_status = tcc$5744_message_base + 201,
    {E 5744 library returned unrecognizable mount status code: +P1.}

    tce$bad_query_status = tcc$5744_message_base + 202,
    {E 5744 library returned unrecognizable query status code: +P1.}

    tce$bad_query_type_code = tcc$5744_message_base + 203,
    {E 5744 library returned unrecognizable query_type code: +P1.}

{   tce$bad_mount_status_id = tcc$5744_message_base + 204,
    {E 5744 library returned unrecognizable mount status ID code: +P1.}

    tce$bad_volume_status = tcc$5744_message_base + 205,
    {E 5744 library returned unrecognizable volume_status code: +P1.}

    tce$bad_location_code = tcc$5744_message_base + 206,
    {E 5744 library query_volume request returned unrecognizable location_type: +P1.}

    tce$bad_command_code = tcc$5744_message_base + 207,
    {E 5744 library returned unrecognizable command code: +P1.}

    tce$bad_external_vsn = tcc$5744_message_base + 208,
    {E 5744 library returned unrecognizable EVSN +P1.}

{-----------------------------------------------------------------------
{   Internal errors.
{-----------------------------------------------------------------------

    tce$heap_allocate_error = tcc$5744_message_base + 300,
    {F System error - ACS table heap ALLOCATE error.}

    tce$workstation_not_defined = tcc$5744_message_base + 301,
    {F Workstation +P1 for 5744 library has not been defined.}

    tce$acs_table_not_allocated = tcc$5744_message_base + 303,
    {F ACS table is NIL in workstation header.}

    tce$acs_not_found = tcc$5744_message_base + 304,
    {E No entry exists in the 5744 library ACS table for ACS +P1.}

    tce$duplicate_drive = tcc$5744_message_base + 305,
    {E Duplicate drive in the configuration +P1.}

    tce$lsm_not_found = tcc$5744_message_base + 306,
    {E Specified LSM address not present in this ACS - +P1.}

    tce$drive_not_found = tcc$5744_message_base + 307,
    {E No entry exists in the 5744 ACS table for drive - +P1.}

    tce$nil_pointer = tcc$5744_message_base + 308,
    {F NIL pointer to +P1.}

    tce$workstation_not_allocated = tcc$5744_message_base + 309,
    {F 5744 library workstation table has not been allocated.}

    tce$no_drive_list = tcc$5744_message_base + 310,
    {F 5744 library configuration has no drives.}

    tce$invalid_media_request = tcc$5744_message_base + 311,
    {F 5744 library job received invalid media request - code +P1.}

    tce$workstation_timeout = tcc$5744_message_base +312,
    {I 5744 library workstation +P1 not responding.}

    tce$no_stk_drives_defined = tcc$5744_message_base +313,
    {E No 5744 equipment is defined in the system configuration.}

    tce$bad_scl_variable = tcc$5744_message_base +314,
    {I Inappropriate value in 5744 library job SCL script for +P1.}

    tce$server_task_timeout = tcc$5744_message_base +315,
    {I 5744 library server task not initiating.}

    tce$configuration_error = tcc$5744_message_base +316,
    {E 5744 library configuration errors detected.}

    tce$logging_validation_error = tcc$5744_message_base +317,
    {E You are not authorized to access HPA logs.}

    tce$undocumented_server_event = tcc$5744_message_base +318,
    {F Unexpected server event code detected in server task - code +P1.}

    tce$communication_breakdown = tcc$5744_message_base +319,
    {E Communication error - server task is inaccessible.}

    tce$wrong_version = tcc$5744_message_base +320,
    {E Wrong version of the 5744 configuration file opened.}

{-----------------------------------------------------------------------
{   Errors returned by C procedures.
{-----------------------------------------------------------------------

    tce$no_socket_available = tcc$5744_message_base +401,
    {F Could not obtain socket for the RPC client.}

    tce$no_sockets = tcc$5744_message_base +402,
    {F Sockets not installed in the system.}

    tce$invalid_socket = tcc$5744_message_base +403,
    {F System error - invalid socket ID.}

    tce$no_network_space = tcc$5744_message_base +404,
    {F System error - no network space.}

    tce$invalid_protocol = tcc$5744_message_base +405,
    {F System error - invalid protocol.}

    tce$invalid_host_entry = tcc$5744_message_base +406,
    {F Invalid entry (CYBER or workstation) in the HOSTS file.}

    tce$attach_hosts_error = tcc$5744_message_base +407,
    {F Attach HOSTS file error.}

    tce$no_local_host = tcc$5744_message_base +408,
    {F No local host in the HOSTS file.}

    tce$invalid_ip = tcc$5744_message_base +409,
    {F Invalid IP address (CYBER or workstation) in HOSTS file.}

    tce$no_host_entry = tcc$5744_message_base +410,
    {F No entry for workstation in HOSTS file.}

    tce$unrecognized_error_code = tcc$5744_message_base +411,
    {F Unrecognized error code from communication function.}

    tce$fd_bad_file = tcc$5744_message_base +420,
    {E RPC server - bad file number on select.}

    tce$fd_interrupt = tcc$5744_message_base +421,
    {E RPC server - interrupted system call.}

    tce$fd_invalid_argument = tcc$5744_message_base +422,
    {E Server - invalid argument in SELECT call.}

    tce$fd_bad_address = tcc$5744_message_base +423,
    {E Server - bad address in SELECT call.}

    tce$no_program_number = tcc$5744_message_base +440,
    {F No transient program number for RPC server.}

    tce$no_client_create = tcc$5744_message_base +441,
    {E Could not create RPC client function.}

    tce$no_client_send = tcc$5744_message_base +442,
    {E Could not execute RPC client call.}

    tce$bad_request_code = tcc$5744_message_base +443,
    {F Internal error: Bad request code in C function +P1.}

    tce$duplicate_message = tcc$5744_message_base +460,
    {I Duplicate message received from the workstation.}

    tce$bad_xdr_translation = tcc$5744_message_base +461,
    {E XDR translation error - message discarded.}

    tce$part_xdr_trans = tcc$5744_message_base +462,
    {E XDR partial translation error - message discarded.}

    tce$interrupt_xdr_trans = tcc$5744_message_base +463,
    {E Interrupted XDR translation error.}

    tce$no_server_create = tcc$5744_message_base +471,
    {E Could not create RPC server.}

    tce$no_server_register = tcc$5744_message_base +472,
    {E Could not register RPC server.}

    tce$bad_c_status_code = tcc$5744_message_base + 473;
    {F C procedure returned invalid error code: +P1.}
