Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!swrinde!mips!public!valentin From: valentin@public.BTR.COM (Valentin Pepelea) Newsgroups: comp.sys.amiga.programmer Subject: Re: Printer online checking - how ? Keywords: printer Message-ID: <3242@public.BTR.COM> Date: 28 Jun 91 06:52:51 GMT References: <1290@sys.uea.ac.uk> Distribution: comp Organization: BTR Communications, Mtn. View, CA Lines: 32 In article <1290@sys.uea.ac.uk> cmp8163@sys.uea.ac.uk (P.N.J. Vlietstra) writes: > >I know this may sound like a pathetic question, but I never had to do this >before: There is no such thing as a pathetic or stupid question. We all need to ask questions some times, whether it is to learn new things, reassure us of uncertainties, or to merely find out where to find the information. >how do you check whether a printer (on the parallel port) is actually >switched on (or on-line) ? >The libs&devs manual is a bit unclear on this point. You may check the hardware directly if you wish, by reading the ciab.ciapra register located at address $bfd000. Bit 0 will tell you whether the printer is busy, bit 1 will tell you whether the printer is out of paper and bit 2 will tell you whether the printer is on-line. This register is documented on page 318 of the Hardware Manual, in appendix F. But I suggest you use the PDCMD_QUERY command of the parallel device instead. Should the hardware change in the future, or should your computer have a mutli- parallel board installed, this command will remain upwardly compatible. It is documented on page B-45 of the ROM Kernel Manual, Includes & Autodocs. Valentin -- "An operating system without virtual memory Name: Valentin Pepelea is an operating system without virtue." Phone: (408) 985-1700 Usenet: mips!btr!valentin - Ancient Inca Proverb Internet: valentin@btr.com