/* Environment and associated Z-System structures */ #ifndef ECOC #define package char #define short char #else typedef char package; #endif /* File control block */ struct zfcb { short drive; /* drive number [1..16] */ char fname[8]; /* file name */ char ftype[3]; /* file type */ short extent; /* extent number [0..1f] */ short user; /* s1 - user number in zsdos */ short dmod; /* s2 - data module number */ short rec; /* record number */ int alloc[8]; /* allocation block map for the extent */ short nextrec; /* next sequential record to read/write */ short rrec[3]; /* random record number */ }; /* Multiple command line buffer */ struct mcl { char *first; /* pointer to first char in command */ short bufsiz; /* length of buffer in bytes */ short count; /* length of line read by bdos */ char cline; /* first char in command line */ }; /* Crt entries within ENV */ struct crt { short crt0wid; /* width of crt 0 in chars */ short crt0ht; /* hight of crt 0 in rows */ short crt0tht; /* number of usable text lines on crt 0 */ }; /* Printer entries within ENV */ struct printer { short width; /* printer 0 width in chars */ short height; /* printer 0 page length */ short text; /* printer 0 number of text lines per page */ short feedok; /* form feed flag - 1 = form feed ok */ }; /* ...and finally the ENV itself */ struct env { short jp; int *cbios; /* NZCOM only - others null */ char envstr[5]; /* Z3ENV string */ short envtyp; /* environment type - msb set if extended */ short *path; /* address of path */ short pathsize; /* number of elements in path */ package *rcp; /* RCP address */ short rcpsize; /* size of RCP in records */ package *iop; /* IOP address */ short iopsize; /* size of IOP in records */ package *fcp; /* FCP address */ short fcpsize; /* size of FCP in records */ package *ndr; /* NDR address */ short ndrsize; /* size of NDR in 18 byte entries */ struct mcl *z3mcl; /* multiple command line buffer */ short mclsize; /* command line buffer size */ package *z3env; /* Self reference address */ short envsize; /* Size of ENV in records */ package *shstk; /* address of shell stack */ short shstks; /* number of entries in shell stack */ short shsize; /* size of a shell stack entry */ package *z3msg; /* pointer to message buffer */ struct zfcb *z3fcb; /* zcpr3 external fcb address */ int *extstk; /* command processor external stack */ short quiet; /* quiet flag */ short *wheel; /* wheel byte pointer */ short speed; /* processor speed in mhz */ short maxdisk; /* highest valid disk number */ short maxuser; /* highest allowed user number */ short duok; /* 1=ok to accept du:, else 0 */ short curcrt; /* current crt number */ short curlst; /* current printer number */ struct crt crt0; /* crt size specs */ int okdvct; /* vector of valid drives */ short spare1; /* currently unused */ struct printer lpt0; /* printer 0 control */ struct printer lpt1; /* printer 1 control */ package *ccp; /* base address of ccp */ short ccpsize; /* size of ccp in records */ package *dos; /* base address of bdos - record aligned */ short dossize; /* size of dos in records */ package *bio; /* bios base address */ char shvarn[8]; /* shell variable file name */ char shvart[3]; /* shell variable file type */ char sys1file[11]; /* system file 1 */ char sys2file[11]; /* system file 2 */ char sys3file[11]; /* system file 3 */ char sys4file[11]; /* system file 4 */ short zrpdrv; /* zrdos public drive map */ short zrpuser; /* zrdos public user map */ };