C** ACCOUNTING PROGRAM RECORD DEFINITION FILE
C
C.. HEADER FIELD
	INTEGER	BLNK		! utility link word
	BYTE	BTYP		! block type
	 PARAMETER BTSAB=1	!..system account block
	 PARAMETER BTUAB=2	!..user account block
	 PARAMETER BTSS ="11	!..accounting startup
	 PARAMETER BTINV="12	!..invalid login attempt
	 PARAMETER BTTIM="13	!..system time change
	 PARAMETER BTALL="14	!..allocate device
	 PARAMETER BTDEA="15	!..deallocate device
	 PARAMETER BTMOU="16	!..mount device
	 PARAMETER BTDMO="17	!..demount device
	 PARAMETER BTPRT="20	!..print despooler transaction
	 PARAMETER BTDIR="21	!..disk accounting by directory
	 PARAMETER BTVOL="22	!..disk accountin by volume
	 PARAMETER BTLOG="23	!..login transaction
	 PARAMETER BTCRH="24	!..crash recovery
	BYTE	BLEN		! length of this block
	BYTE	BTIM(6)		! transaction time
	INTEGER	BUID(2)		! session id (1 rad50, 1 binary)
	INTEGER	BACN		! account number
	BYTE	BTID(2)		! terminal type, unit number
C
	EQUIVALENCE (BBUFFR(0),BLNK)
	EQUIVALENCE (BBUFFR(2),BTYP)
	EQUIVALENCE (BBUFFR(3),BLEN)
	EQUIVALENCE (BBUFFR(4),BTIM)
	EQUIVALENCE (BBUFFR(10),BUID)
	EQUIVALENCE (BBUFFR(14),BACN)
	EQUIVALENCE (BBUFFR(16),BTID)
C
C.. ACCUMULATION FIELDS FOR TYPE 1 & 2
	INTEGER*4	BCPU	! total cpu time used
	INTEGER*4	BDIR	! total directive count
	INTEGER*4	BQIO	! total qio count
	INTEGER*4	BTAS	! total task count
	BYTE		BBEG(6)	! login time
	INTEGER*4	BCPUL	! reserved
	INTEGER		BPNT	! unused
	BYTE		BSTM	! status mask word
	 PARAMETER BSACT = "200	!..control block active
	 PARAMETER BSCRH = "100	!..crash recovery record
	 PARAMETER BSLGO = "40	!.. logged off with outstanding act.
	 PARAMETER BSZER = "10	!..zero intervals
	 PARAMETER BSSCN = "4	!..ready for scan file
C
	EQUIVALENCE (BBUFFR(18),BCPU)
	EQUIVALENCE (BBUFFR(22),BDIR)
	EQUIVALENCE (BBUFFR(26),BQIO)
	EQUIVALENCE (BBUFFR(30),BTAS)
	EQUIVALENCE (BBUFFR(34),BBEG)
	EQUIVALENCE (BBUFFR(40),BCPUL)
	EQUIVALENCE (BBUFFR(44),BPNT)
	EQUIVALENCE (BBUFFR(46),BSTM)
C
C.. SYSTEM ACCOUNT BLOCK - TYPE 1
	BYTE		BSHDN	! SHUTDOWN CODE
	INTEGER		BUHD	! USER ACCOUNT BLOCK LISTHEAD
	INTEGER		BULO	! NUMBER USERS CURRENTLY LOGGED ON
	INTEGER*4	BULT	! TOTAL NUMBER OF LOGONS
	INTEGER*4	BCKP	! TOTAL NUMBER OF CHECKPOINTS
	INTEGER*4	BSHF	! TOTAL NUMBER OF SHUFFLER RUNS
	INTEGER*4	BRND	! TOTAL NUMBER OF ZERO TIC INTERVALS
	INTEGER		BFID(3)	! FILE I/D OF TRANSACTION FILE
	BYTE		BDVNM(2)! DEVICE NAME FOR TRANSACTION FILE
	INTEGER		BUNIT	! DEVICE UNIT FOR TRANSACTION FILE
	INTEGER		BEXTS	! EXTEND SIZE FOR TRANSACTION FILE
	BYTE		BLSCN(6)! TIME OF LAST SCAN
	INTEGER		BSCNR	! SCAN RATE IN SECONDS
C
	EQUIVALENCE (BBUFFR(47),BSHDN)
	EQUIVALENCE (BBUFFR(48),BUHD)
	EQUIVALENCE (BBUFFR(50),BULO)
	EQUIVALENCE (BBUFFR(52),BULT)
	EQUIVALENCE (BBUFFR(56),BCKP)
	EQUIVALENCE (BBUFFR(60),BSHF)
	EQUIVALENCE (BBUFFR(64),BRND)
	EQUIVALENCE (BBUFFR(68),BFID)
	EQUIVALENCE (BBUFFR(74),BDVNM)
	EQUIVALENCE (BBUFFR(76),BUNIT)
	EQUIVALENCE (BBUFFR(78),BEXTS)
	EQUIVALENCE (BBUFFR(80),BLSCN)
	EQUIVALENCE (BBUFFR(86),BSCNR)
C
C.. USER ACCOUNT FIELDS - TYPE 2
	BYTE		BUSE	! use count
	INTEGER		BACT	! number of active tasks
	INTEGER		BUUIC	! login uic
	INTEGER		BUCB	! terminal ucb pointer
	BYTE		BLGO(6)	! logoff time
	INTEGER		BULNK	! forward link
	INTEGER		BRNA(3)	! account file location
	BYTE		BNAM(16)! last name - first initial @15
	BYTE		BNAMF	! first initial
C
	EQUIVALENCE (BBUFFR(47),BUSE)
	EQUIVALENCE (BBUFFR(48),BACT)
	EQUIVALENCE (BBUFFR(50),BUUIC)
	EQUIVALENCE (BBUFFR(52),BUCB)
	EQUIVALENCE (BBUFFR(54),BLGO)
	EQUIVALENCE (BBUFFR(60),BULNK)
	EQUIVALENCE (BBUFFR(62),BRNA)
	EQUIVALENCE (BBUFFR(68),BNAM)
C
C.. SYSLOG STARTUP BLOCK - TYPE 11
C NO DEFINITIONS FOR SYSLOG
C
C.. INVALID LOGIN TRANSACTION
	BYTE		BINAM(14) ! NAME FROM INPUT LINE
	BYTE		BIUIC(6) ! UIC FROM INPUT LINE
	BYTE		BIPSW(6) ! PASSWORD FROM INPUT LINE
C
	EQUIVALENCE(BBUFFR(18),BINAM)
	EQUIVALENCE(BBUFFR(32),BIUIC)
	EQUIVALENCE(BBUFFR(38),BIPSW)
C
C.. SYSTEM TIME CHANGE
	BYTE		BTOLD(6) ! OLD TIME
	BYTE		BTNEW(6) ! NEW TIME
C
	EQUIVALENCE(BBUFFR(18),BTOLD)
	EQUIVALENCE(BBUFFR(24),BTNEW)
C
C.. ALLOCATE,DEALLOCATE,MOUNT,DISMOUNT - TYPES 14,15,16 & 17
	INTEGER		BDNAM	! device name (ascii)
	BYTE		BDUNT	! device unit number and unused byte
	BYTE		BDLBL(6)! volume label
C
	EQUIVALENCE (BBUFFR(18),BDNAM)
	EQUIVALENCE (BBUFFR(20),BDUNT)
	EQUIVALENCE (BBUFFR(22),BDLBL)
C
C.. PRINT DESPOOLER TRANSACTION - TYPE 20
	REAL		BPNAM	! print job name
	INTEGER		BPPGS	! page count
	INTEGER		BPNFI	! number of files
	BYTE		BPFRM	! form number
	BYTE		BPPRI	! print priority
	INTEGER		BPDEV	! print device name(ascii)
	BYTE		BPPUN	! unit number for print device
C
	EQUIVALENCE (BBUFFR(18),BPNAM)
	EQUIVALENCE (BBUFFR(22),BPPGS)
	EQUIVALENCE (BBUFFR(24),BPNFI)
	EQUIVALENCE (BBUFFR(26),BPFRM)
	EQUIVALENCE (BBUFFR(27),BPPRI)
	EQUIVALENCE (BBUFFR(28),BPDEV)
	EQUIVALENCE (BBUFFR(30),BPPUN)
C
C.. DISK ACCOUNTING BY DIRECTORY - TYPE 21
CCC
C
C.. DISK ACCOUNTING BY VOLUME - TYPE 22
CCC
C
C.. LOGIN TRANSACTION - TYPE 23
	INTEGER		BLUIC		! login uic
	BYTE		BLNAM(16)	! user name
C
	EQUIVALENCE (BBUFFR(18),BLUIC)
	EQUIVALENCE (BBUFFR(20),BLNAM)
C
C.. CRASH RECOVERY TRANSACTION - TYPE 24
	BYTE		BCTLS(6)	! time of last scan before crash
	INTEGER		BCSRT		! scan rate prior to crash
	BYTE		BCRSN(60)	! crash reason
C
	EQUIVALENCE (BBUFFR(18),BCTLS)
	EQUIVALENCE (BBUFFR(24),BCSRT)
	EQUIVALENCE (BBUFFR(26),BCRSN)
C
C.. COMMON DECLARATOR
	BYTE BBUFFR(0:511)		! accounting buffer
	COMMON /ACNDF/ BBUFFR		! load into named common
	EQUIVALENCE	(BNAMF,BNAM(15))! first initial
C
C.. END OF ACCOUNTING BLOCK DEFINITIONS