[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]Author Index][Subject Index]

Re: midas-install/1193: printer devices



First concering the printer problem $PRINT.
The MIDAS system keyword SYSCOMS (file: /midas/95NOV/monit/syskeys.unix;
keyword number 30) is created to avoid printer conflicts. However, 
in your case our solution may not work. However, To redefine 
a standard system commands is not the best a system manager can do. 
May be you should suggest him to create the command "print" as an
alias for lpr -P$PRINTER. 
For MIDAS I suggest you "unset" the PRINTER variable (simple set 
it to a empty string ""). You can do that in the file 
/midas/95NOV/monit/devices.sh. After exiting MIDAS the PRINTER 
will be reset to its original value automatically.

To find out what exactly happens you can enable the full echo of 
what the MIDAS monitor executes. Before running the print command 
run the command "echo/full 1,2". Then you will get all output and 
substitutions on your screen and in the log file. In the way you 
can also monitor the variables LPRINT and LASER.
In that case you should get something like:

Midas 007> copy/gra LASER  
 1 > DEFINE/PARAMETER P1 DEFAULT C
 1 > DEFINE/PARAMETER P2 {PLCMETA} C
     DEFINE/PARAMETER P2 graph_wnd000.plt C
 1 > DEFINE/LOCAL NK/I/1/1 0
 1 > DEFINE/LOCAL IND/I/1/1 0
 1 > DEFINE/LOCAL LEN/I/1/1 0
 1 > DEFINE/LOCAL OPT/C/1/1 " "
 1 > DEFINE/LOCAL DEV/C/1/1 " "
 1 > SET/FORMAT I1
 1 > *IF P1(1:3) .NE. "DEF" 00644
 1 > *IF P1(1:1) .NE. "G" 00761
 1 > *IF P1(1:1) .NE. "T" 01088
 1 > *IF P1(1:1) .NE. "I" 01414
 1 > *IF P1(1:1) .NE. "D" 01750
 1 > 01071:
 1 > *IF DEV .NE. "D" 02083
 1 > @ checkdev {P1}
     @ checkdev LASER
 2 > DEFINE/PARAMETER P1 LASER C
 2 > DEFINE/LOCAL PSC/C/1/20 " " all
 2 > DEFINE/LOCAL IND/I/1/1 0
 2 > DEFINE/LOCAL LEN/I/1/1 0
 2 > DEFINE/LOCAL OPT/C/1/1 " "
 2 > SET/FORMAT I1
 2 > *IF P1(1:3) .NE. "LAS" 00614
 2 > *GO 00615
 2 > IND = M$INDEX(P1,".")
 2 > *IF IND .LE. 0 00695
 2 > *IF p1(1:3) .NE. "LAS" 00894
 2 > WRITE/KEYW psc LASER
 2 > *GO 00944
 2 > P1 = M$SYMBOL("{PSC}")
     P1 = M$SYMBOL("LASER")
 2 > 00877:
 2 > *GO 01088
 2 > DEFINE/LOCAL AGLDEV/C/1/40 " " ALL
 2 > DEFINE/LOCAL DEVICE/C/1/20 " " ALL
 2 > DEFINE/LOCAL DRIVER/C/1/20 " " ALL
 2 > DEFINE/LOCAL KK1/I/1/1/ 0
 2 > DEFINE/LOCAL KK2/I/1/1/ 0
 2 > AGLDEV = M$AGL(P1)
 2 > *IF AGLDEV(1:1) .NE. " " 01535
 2 > KK1 = M$INDEX(AGLDEV,":") -1
 2 > WRITE/KEYW DEVICE/C/1/20 {AGLDEV(1:{KK1})}
     WRITE/KEYW DEVICE/C/1/20 ps2usr0
 2 > IND = M$INDEX(DEVICE,".")
 2 > *IF IND .EQ. 0 01790
 2 > KK2 = M$INDEX(AGLDEV,":") + 1
 2 > WRITE/KEYW DRIVER/C/1/20 {AGLDEV({KK2}:>)}
     WRITE/KEYW DRIVER/C/1/20 pscript
 2 > *RE {DEVICE} {DRIVER}
     *RE ps2usr0 pscript
 1 > IND = M$INDEX(Q2,".")
 1 > P1 = "{Q1}"
     P1 = "ps2usr0"
 1 > *IF IND .EQ. 0 02216
 1 > DEFINE/LOCAL DEVICE/C/1/20 {Q1}
     DEFINE/LOCAL DEVICE/C/1/20 ps2usr0
 1 > DEFINE/LOCAL TYPE/C/1/20 {Q2}
     DEFINE/LOCAL TYPE/C/1/20 pscript
 1 > *IF TYPE(1:2) .NE. "ps" 02395
 1 > *IF AUX_MODE(1) .GE. 2 02425
 1 > -DELETE pscrplot*
 1 > 02474:
 1 > *IF DEVICE .NE. "POSTSCRIPT" 02516
 1 > *IF TYPE(8:9) .NE. ".c" 02620
 1 > *IF AUX_MODE(1) .GE. 2 02939
 1 > RUN MID_EXE:COPYGRAP
 1 > -RENAME pscrplot.0 {DEVICE}.ps
     -RENAME pscrplot.0 ps2usr0.ps
 1 > $ {syscoms(1:20)} {DEVICE} {DEVICE}.ps
 1 > $ lpr -h -P            ps2usr0 ps2usr0.ps
 1 > 03054:
 1 > 02922:
 1 > 02603:
 1 > *GO 03183
Midas 008> 

If you have real trouble, please send me the complete screen or
logfile output, including these substitutions.

Hope that this help you.

Ciao,
Rein Warmels, ESO-DMD/USG

PS.
1. Please, send Tom Oosterloo the greetings from me
2. Also, I understood you had problems with entering 
   a PR via the WWW. I know that your WWW services 
   have some problems currently. I would like to ask
   you to try some test PRs from ATNF to see if the 
   connection can be made. Please make sure you fill 
   out all required fields.

Rein