1*23318Smckusick /* 2*23318Smckusick * Copyright (c) 1982 Regents of the University of California. 3*23318Smckusick * All rights reserved. The Berkeley software License Agreement 4*23318Smckusick * specifies the terms and conditions for redistribution. 5*23318Smckusick * 6*23318Smckusick * @(#)adreg.h 6.2 (Berkeley) 06/08/85 7*23318Smckusick */ 87290Ssam 97290Ssam struct addevice { 107290Ssam short int ad_csr; /* Control status register */ 117290Ssam short int ad_data; /* Data buffer */ 127290Ssam }; 137290Ssam 147623Ssam #define AD_CHAN ADIOSCHAN 157623Ssam #define AD_READ ADIOGETW 167623Ssam #define ADIOSCHAN _IOW(a, 0, int) /* set channel */ 177623Ssam #define ADIOGETW _IOR(a, 1, int) /* read one word */ 187290Ssam 197290Ssam /* 207290Ssam * Unibus CSR register bits 217290Ssam */ 227290Ssam 237290Ssam #define AD_START 01 247290Ssam #define AD_SCHMITT 020 257290Ssam #define AD_CLOCK 040 267290Ssam #define AD_IENABLE 0100 277290Ssam #define AD_DONE 0200 287290Ssam #define AD_INCENABLE 040000 297290Ssam #define AD_ERROR 0100000 30