{	Constant declarations for stubs in DD/OC RPC scheme	RPCCONST
	---------------------------------------------------

History:
	14 Dec 86	Integer message numbers defined (for 6809 etc)
	   Dec 86	Byte constants added for M6809 compatability 	TJA
	 7 Jan 87	Correlation between _s_ and _m_ fixed,
			Severity := 2 for all errors.	(bug fix)	TBL
	19 Jan 87	3 errors added for multiple decnet handling	RJJ
	 9 Mar 87	rpc_default_timeout added			TBL
	10 Mar 87	V24 protocol characters added			TJA
	11 mar 87	rpc_*_timeout addded				TBL
	16 Mar 87	Bit 15 added to _s_ values: "facility local"	TBL
	17 Mar 87	RPC_facility: X'08520000'--->X'0852'		TJA
	26 Jan 88	Large version with 8kB buffer			TBL
	13 Apr 88	TurboPascal Version 4 TP4 added			PL
	27 Apr 88	TP4 (confusing) renamed PCTURBO			TBL
}

rpc_default_timeout	=	-1;

*IF -DEF M6809 1
RPC_s_normal=		1;			{ happens to = SS$_NORMAL }
*IF DEF M6809 1
RPC_s_normal=		1L;			{ long integer notation }

*IF -DEF M6809 1
RPC_sev_error =		2;			{ Build up VAX- style }
*IF DEF M6809 1
RPC_sev_error =		2L;

RPC_facility =		2130;			{ X'0852' }

{
NOTE:	If you change this table, you must also change the following table
	so that the two are kept consistent!

				139591680	Facility
					8	Message number
				    32768	b15 = "Facility-wide message"
					2	Severity = error
				---------
				139624458
	
				Code:		Blame:
}
RPC_s_unsupported_version=	139624458;	{Compatability}
RPC_s_bad_procedure_number=	139624466;	{ Client Stub }
RPC_s_IVPARAM=			139624474;	{ Caller }
RPC_s_bad_msg_type=		139624482;	{ Other machne }
RPC_s_bad_program_number=	139624490;	{ Routing }
RPC_s_bad_reject_code=		139624498;	{ Server }
RPC_s_bad_ethernet_address=	139624506;	{ Routing }
RPC_s_Syntax_1=			139624514;	{ Name server }
RPC_s_Syntax_2=			139624522;	{ Name server }
RPC_s_Syntax_3=			139624530;	{ Name server }
RPC_s_Syntax_4=			139624538;	{ Name server }
RPC_s_bad_message_header=	139624546;	{ Other end }
RPC_s_too_manyclients=		139624554;	{ MAX_UNIT }
RPC_s_too_manyservers=		139624562;	{ MAX_PROGRAM }
RPC_s_no_results_returned=	139624570;	{ Stub code }
RPC_s_no_such_package=		139624578;	{ Config prog }
RPC_s_too_manysockets=		139624586;	{ MAX_socket }
RPC_s_Syntax_5= 		139624594;	{ Name too long }
RPC_S_framing=			139624602;	{ V24 framing error (STX) }
RPC_S_bad_handle=		139624610;	{ caller of RTS }
RPC_s_not_implemented=		139624618;	{ Not implemented - Tim }
RPC_s_conversion_error=		139624626;	{ Number/string too large }
RPC_s_nosuchsocket=		139624634;	{ caller of TS }
RPC_s_TS_internal_error=	139624642;	{ Internal TS error }
RPC_s_already_reading=		139624650;	{ Caller of TS }
RPC_s_timeout=			139624658;	{ peer node not responding }

{ Message numbers, without severity or facility:

				Code:		Blame:
}
RPC_m_normal=			0;	{ No-one }
RPC_m_unsupported_version=	1;	{ Compatability }
RPC_m_bad_procedure_number=	2;	{ Client Stub }
RPC_m_IVPARAM=			3;	{ Caller }
RPC_m_bad_msg_type=		4;	{ Other machne }
RPC_m_bad_program_number=	5;	{ Routing }
RPC_m_bad_reject_code=		6;	{ Server }
RPC_m_bad_ethernet_address=	7;	{ Routing }
RPC_m_Syntax_1=			8;	{ Name server }
RPC_m_Syntax_2=			9;	{ Name server }
RPC_m_Syntax_3=			10;	{ Name server }
RPC_m_Syntax_4=			11;	{ Name server }
RPC_m_bad_message_header=	12;	{ Other end }
RPC_m_too_manyclients=		13;	{ MAX_UNIT }
RPC_m_too_manyservers=		14;	{ MAX_PROGRAM }
RPC_m_no_results_returned=	15;	{ Stub code }
RPC_m_no_such_package=		16;	{ no local package found }
RPC_m_too_manysockets=		17;	{ MAX_socket }
RPC_m_Syntax_5= 		18;	{ Name too long }
RPC_m_framing=			19;	{ V24 framing error (bad protocol) }
RPC_m_bad_handle=		20;	{ caller of RTS }
RPC_m_not_implemented=		21;	{ Not implemented - Tim }
RPC_m_conversion_error=		22;	{ Number/string too large }
RPC_m_nosuchsocket=		23;	{ caller of TS }
RPC_m_TS_internal_error=	24;	{ Internal TS error }
RPC_m_already_reading=		25;	{ Caller of TS }
RPC_m_timeout=			26;	{ peer node not respoinding }

	call_header_length=	12;	{ Length of message headers in bytes }
	return_header_length=	4;
	reject_header_length=	6;

	rpc_name_length=	40;	{ length of service name }

	call_message   =   0;	{ These are	 }
*IF -DEF PCTURBO
*IF -DEF VAXVMS
	reject_message =   1;	{  courier	 }
	return_message =   2;	{  definitions   }
	abort_message  =   3;
*ENDIF
*ENDIF
*IF DEF VAXVMS
	reject_message = 256;	{  reversed for  }
	return_message = 512;	{  simplicity    }
	abort_message  = 768;
*ENDIF
*IF DEF PCTURBO
	reject_message = 256;	{  reversed for  }
	return_message = 512;	{  simplicity    }
	abort_message  = 768;
*ENDIF

*IF -DEF LARGE
	maxlength =	 1500;	{ Max packet size currently (ethernet limit) }
	twomaxlength =	 3000;	{ For v24 Monica version }
*ENDIF
*IF DEF LARGE
	maxlength =	 8000;	{ Max packet size (UDP limit) }
	twomaxlength =	16000;	{ For v24 Monica version }
*ENDIF

*IF DEF M6809
	byte_0		=	#0;	{ Omegasoft needs funny byte constants }
	byte_1		=	#1;
	rpc_v24_rts	=	#124;	{ "|", V24 Request To Send }
	rpc_v24_cts	=	#94;	{ "^", V24 Clear To Send }
	rpc_v24_stx	=	#95;	{ "_", V24 header byte - Start of TeXt }
*ENDIF
*IF -DEF M6809
	byte_0		=	0;
	byte_1		=	1;
	rpc_v24_rts	=	124;
	rpc_v24_cts	=	94;
	rpc_v24_stx	=	95;
*ENDIF
*IF DEF PCTURBO
*IF DEF NOHEAP 1
	max_sockets	=	20;
*ENDIF

