laser printer
Claud Lacy wrote on Oct 18, 2010
I have installed iraf from the scisoft site onto my iMac OS10.5 machine, but need help with interfacing my networked printer, known as PHYS206, an Apple LaserWriter Pro 630. I am trying to print from an irafterm spectral plot window by the :.snap method, but it doesn't print to my default printer (I don't know where it gets sent to). I have tried changing the default printer and stdplot to lw1 in the login.cl file and editing the corresponding graphcap file entry for it to
uapl1|UNIX generic interface to 300dpi Apple Laserwriter (Postscript):\
:xs#0.265:ys#0.202:ar#0.760:\
:DD=apl,tmp$sgk,!{ sgidispatch sgi2uapl $F -l$(XO) -w$(XW) -b$(YO) \
-h$(YW) -p$(PW) | lpr -PPHYS206; rm $F; }&:tc=sgi_apl:
but that doesn't work. Ideally, I would like to just have it be the default printer of my iMac, but I realize that may not be possible. Thanks for your help. - CHSL
uapl1|UNIX generic interface to 300dpi Apple Laserwriter (Postscript):\
:xs#0.265:ys#0.202:ar#0.760:\
:DD=apl,tmp$sgk,!{ sgidispatch sgi2uapl $F -l$(XO) -w$(XW) -b$(YO) \
-h$(YW) -p$(PW) | lpr -PPHYS206; rm $F; }&:tc=sgi_apl:
but that doesn't work. Ideally, I would like to just have it be the default printer of my iMac, but I realize that may not be possible. Thanks for your help. - CHSL
Mike Fitzpatrick wrote on Oct 18, 2010
The default printer for your machine is normally what IRAF would use anyway, i.e. the 'lpr' device in IRAF is just sending postscript to the default printer. SciSoft did have a known problem in an earlier release where printing was broken becuase the 'sgidispatch' command used to spawn the metacode translator wasn't available in the proper bin directory. In this case you would normally see something like "sgidispatch: command not found" after the snap.
Lastly, a 'snap' isn't complete until the graphics buffer is flushed (normally with a ":.gflush" or when you log out) to allow it to be appended. If you do this and see a /tmp/sgkXXXXX.ps file then the conversion worked, and the error may be in talking to the printer. To check this, see whether a simple "lpr /tmp/sgkXXX.ps" is sufficient to print the file or if you need the '-P' command to successfully print. Also note that changes to the graphcap file require a 'gflush' to take effect, otherwise your modified graphcap entry looks like it should work.
Lastly, a 'snap' isn't complete until the graphics buffer is flushed (normally with a ":.gflush" or when you log out) to allow it to be appended. If you do this and see a /tmp/sgkXXXXX.ps file then the conversion worked, and the error may be in talking to the printer. To check this, see whether a simple "lpr /tmp/sgkXXX.ps" is sufficient to print the file or if you need the '-P' command to successfully print. Also note that changes to the graphcap file require a 'gflush' to take effect, otherwise your modified graphcap entry looks like it should work.
Claud Lacy wrote on Oct 18, 2010
What I see when I try to generate a plot from an splot window is:
1. a red line cursor initially goes all the way across the plot in both axes
2. when I say ":.snap" it immediately says " - done" on the same line
3. the cursor changes to a fat + sign
4. no printout appears on PHYS206
5. if I then say ":.gflush" it responds with a " - " and that's all
6. if I look in the /tmp directory, I don't see any files ending .ps
7. PHYS206 is an AppleTalk networked printer. I wonder if that has anything to do with it? It shows up in the Local Zone in the Systems Preferences/Printers list.
8. I can print text files to PHYS206 from within iraf with a command like "!lpr login.cl", but that just means that the unix is using the default PHYS206 printer, I think.
Any ideas?
1. a red line cursor initially goes all the way across the plot in both axes
2. when I say ":.snap" it immediately says " - done" on the same line
3. the cursor changes to a fat + sign
4. no printout appears on PHYS206
5. if I then say ":.gflush" it responds with a " - " and that's all
6. if I look in the /tmp directory, I don't see any files ending .ps
7. PHYS206 is an AppleTalk networked printer. I wonder if that has anything to do with it? It shows up in the Local Zone in the Systems Preferences/Printers list.
8. I can print text files to PHYS206 from within iraf with a command like "!lpr login.cl", but that just means that the unix is using the default PHYS206 printer, I think.
Any ideas?
Mike Fitzpatrick wrote on Oct 18, 2010
See
http://iraf.net/phpBB2/viewtopic.php?t=88950&highlight=scisoft+sgidispatch
and
http://iraf.net/phpBB2/viewtopic.php?t=85546&highlight=scisoft+sgidispatch
http://iraf.net/phpBB2/viewtopic.php?t=88950&highlight=scisoft+sgidispatch
and
http://iraf.net/phpBB2/viewtopic.php?t=85546&highlight=scisoft+sgidispatch
Claud Lacy wrote on Oct 18, 2010
I find the sgidispatch.e file in the directory /Applications/scisoft/all/Packages/iraf/iraf/unix/bin.macintel
From an iraf window, !which cl gives /Applications/scisoft//all/bin/cl
A ls -laF of the directory /Applications/scisoft//all/bin gives:
drwxrwxr-x 10 claudlacy admin 340 Sep 3 14:51 ./
drwxrwxr-x 4 claudlacy admin 136 Jun 24 2008 ../
-rw-rw-r-- 1 claudlacy admin 2946 Sep 15 2009 Setup.bash
-rw-rw-r-- 1 claudlacy admin 2552 Sep 15 2009 Setup.csh
lrwxr-xr-x 1 root 65534 38 Sep 3 14:50 cl@ -> ../Packages/iraf/iraf/unix/hlib/cl.csh
lrwxr-xr-x 1 root 65534 38 Sep 3 14:50 ecl@ -> ../Packages/iraf/iraf/unix/hlib/cl.csh
-rw-rw-r-- 1 claudlacy admin 2440 Nov 1 2007 irafuser.bash
-rw-rw-r-- 1 claudlacy admin 5532 Jun 5 2006 irafuser.csh
-rwxrwxr-x 1 claudlacy admin 209 Jun 21 2007 scisoft-info*
-rwxrwxr-x 1 claudlacy admin 171 Aug 17 2008 set_perms.bash*
I am thinking that this is the directory where I should put a symbolic link to the sgidispatch.e file and call it sgidispatch, but I don't know enough unix to be sure how to set up the link (I assume it is with a link command). Am I on the right track? - CHSL
From an iraf window, !which cl gives /Applications/scisoft//all/bin/cl
A ls -laF of the directory /Applications/scisoft//all/bin gives:
drwxrwxr-x 10 claudlacy admin 340 Sep 3 14:51 ./
drwxrwxr-x 4 claudlacy admin 136 Jun 24 2008 ../
-rw-rw-r-- 1 claudlacy admin 2946 Sep 15 2009 Setup.bash
-rw-rw-r-- 1 claudlacy admin 2552 Sep 15 2009 Setup.csh
lrwxr-xr-x 1 root 65534 38 Sep 3 14:50 cl@ -> ../Packages/iraf/iraf/unix/hlib/cl.csh
lrwxr-xr-x 1 root 65534 38 Sep 3 14:50 ecl@ -> ../Packages/iraf/iraf/unix/hlib/cl.csh
-rw-rw-r-- 1 claudlacy admin 2440 Nov 1 2007 irafuser.bash
-rw-rw-r-- 1 claudlacy admin 5532 Jun 5 2006 irafuser.csh
-rwxrwxr-x 1 claudlacy admin 209 Jun 21 2007 scisoft-info*
-rwxrwxr-x 1 claudlacy admin 171 Aug 17 2008 set_perms.bash*
I am thinking that this is the directory where I should put a symbolic link to the sgidispatch.e file and call it sgidispatch, but I don't know enough unix to be sure how to set up the link (I assume it is with a link command). Am I on the right track? - CHSL
Mike Fitzpatrick wrote on Oct 18, 2010
Try:
Note, a '!which sgidispatch' command should find the command once the link is created.
% ln -s /Applications/scisoft/all/Packages/iraf/iraf/unix/bin.macintel/sgidispatch.e /Applications/scisoft//all/bin/sgidispatchNote, a '!which sgidispatch' command should find the command once the link is created.
Claud Lacy wrote on Oct 18, 2010
Yes! Wonderful! That fixed it. Thanks - CHSL
Last post on Oct 18, 2010