#ifndef CAPIBASE_H
#define CAPIBASE_H
/*
**
**	$Id: capibase.h,v 1.876 1996/08/13 03:16:35 chris Exp $
**	$Revision: 1.876 $
**
**	$Filename: ARCH/AMIGADOS/CAPIBase.h $
**	$Author: chris $
**	$Portability: Amiga $
**
**	Include-File for communication with the capi20.device
**
**	COPYRIGHT (C) 1992-1996 BY RELOG AG, ZUERICH. ALL RIGHTS RESERVED.
**	NO PART OF THIS SOFTWARE MAY BE COPIED, REPRODUCED, OR TRANSMITTED
**	IN ANY FORM OR BY ANY MEANS,  WITHOUT THE PRIOR WRITTEN PERMISSION
**	OF RELOG AG.
**
*/

#include <exec/types.h>
#include <exec/io.h>

#include "capi-usr.h"


/*
**	CAPI Device Name for OpenDevice()
*/
#define CAPINAME "capi20.device"


/*
**	CAPI device commands for DoIO()
*/
/* #define CAPIIOCMD_REGISTER			(('C' << 8) | 0x01) */
/* #define CAPIIOCMD_RELEASE			(('C' << 8) | 0x02) */
#define CAPIIOCMD_PUT_MESSAGE			(('C' << 8) | 0x03)
#define CAPIIOCMD_GET_MESSAGE			(('C' << 8) | 0x04)
#define CAPIIOCMD_SET_SIGNAL			(('C' << 8) | 0x05)
#define CAPIIOCMD_GET_MANUFACTURER		(('C' << 8) | 0xF0)
#define CAPIIOCMD_GET_VERSION			(('C' << 8) | 0xF1)
#define CAPIIOCMD_GET_SERIAL_NUMBER		(('C' << 8) | 0xF2)
#define CAPIIOCMD_GET_PROFILE			(('C' << 8) | 0xF3)
#define CAPIIOCMD_MANUFACTURER			(('C' << 8) | 0xFF)


/*
**	CAPI IO-Request
*/
struct IOExtCAPI
{
	struct IOStdReq IOCAPI;			/* Standard extended IO-Request */

	/*
	**	The following three values must be initialized before the device
	**	is opened:
	*/
	UWORD	Level3Cnt;				/* Number of simultaneous conections */
	UWORD	DataBlkCnt;				/* Number of unacknowledged data blocks (2..7) */
	UWORD	DataBlkLen;				/* Maximum length of a data block (2048?) */

	/*
	**	The following value will be set after every call to the CAPI device.
	**	It contains the CAPI result code according to the CAPI 2.0 specification.
	*/
	UWORD	CAPIResult;

	ULONG	reserved[8];				/* Future expansion */
};


#endif

