[comp.sys.apollo] printer driver

YEOAK@NUSDISCS.BITNET (09/29/89)

1) We've a Seikosha dot-matrix printer connected to a SR10.1 node running
   BSD4.3. We used 'genicom' device driver in our prsvr configuration file.
   After having setup prsvr & prmgr, our text files can be printed on the
   Seikosha printer using prf, but almost every printed line is prefixed
   with 120e0m. (I presume it's genicom printer control code.) Right now
   we use 'prf -trans' to print our text files, that means we lost all the
   good features of prf such as -head, -banner & etc.
   Q: Is there a way to substitute the genicom control codes by other
      dot-matrix printer control codes? How?
   Q: Is there a generic device driver available for printing text file
      on a dot-matrix or line printer which has a serial/RS232 port?

2) I've tried to build a simple device driver by following the example
   shown in 5.1.2 of "Printing in the Aegis Environment". I encountered
   the following problem during bind:

   Unresolved globals:
      add_db_range_c     First referenced in driver_ex.bin
      add_db_value_c     ""
      get_db_value_c     ""
      inq_entry_c        ""
   Q: Where is the lib for there routines?

3) What is TML as mentioned in "Printing in the Aegis Environment"?

4) We've managed to set up lpd in a separate testing. We're able to get lpr
   to work w/o prsvr & prmgr. The problem is that the output is in double
   spacing. Any body knows to fix it?

 Thanks for your help in advance.

--AnnKian Yeo
  Bitnet: yeoak@nusdiscs

yamanoue@seri.isct.kyutech.ac.jp (yamanoue) (03/21/91)

In article <24297@hydra.gatech.EDU>
>We have the 9.7 binary for an Okidata 2410 print driver and are looking
>for a 10.3 version of the same.  ...
>...
>Susan Liebeskind
>sl11@prism.gatech.edu

 Yes, we have almost same problem. We're using NEC PC-PR201
(Japanese Kanji serial dot printer for personal computer). Driver
 for 9.7 is, but for 10.x none(Where is??) So, I first made up 
"my_driver", that is in /domain_examples/hardcopy/driver and 
used them(no headers,... nothing). I dont Know the name
 "Okidata 2410", but maybe useful to print ONLY unstruct(uasc)
 files. 
 Here is an advice to make "my_driver".(our old configs)

= crty_my_driver.sh =======================
# /com/sh crty_my_driver.sh
xon
crty my_driver -l
crtyobj my_driver
dlty my_driver
xoff
= makefile ===============================
#  my DOMAIN PRINTER
#
my_driver : driver_ex.bin driver_init_ex.bin makefile
	/com/bind -allmark driver_ex.bin driver_init_ex.bin my_driver_uid.bin \
     -entry my_driver_\$$initialize -b my_driver

driver_ex.bin : driver_ex.c
	/com/cc driver_ex.c -pic -natural -dbs -opt 4
driver_init_ex.bin : driver_init_ex.c
	/com/cc driver_init_ex.c -pic -natural -dbs -opt 4
=====================================================
@How to make driver & install
  1. crty_my_driver_driver.sh
          =>  my_driver_uid.bin created
  2. /bin/make
          =>  my_driver  created
            (ignore errors & warnings)
  3. copy my_driver into /sys/hardcopy/drivers

@Modify rc.user

 if [ -f /sys/hardcopy/prsvr]; then
	(echo " prsvr\c" >/dev/console)
	/sys/hardcopy/prsvr /sys/hardcopy/config/config.my_driver &
 fi

   ** Caution *****
         [-f /sys/hardcopy/prsvr   -a $LLBD...  ]
                                  === remove === 
@Modify printer config file
** sample (config/config.my_driver)****
#print server CONFIGURATION FILE

# who we are and what print manager we use
prmgr_site              I_am_sr10_print_manager  <- default prmgr name
printer_name            p                        <- only 1 name in net
device_driver           my_driver
    
# what i/o connection we use 
speed                   9600
io_device_name          /dev/sio1
    
file_banners            off
logo                    none

@Misc
  Check if OK
    Invoke By   "root"
	$ /sys/hardcopy/prsvr /sys/hardcopy/config/config.my_driver
       if no errors then ok

  Acl for /sys/mgrs
    In OS 10.2, there is no right for prsvr(user.server.none)
    if closed install.
    so  PLEASE ADD extended acl by  
      $ edacl -a %.server -user -dir /sys/mgrs
      $ edacl -a %.server -user -id  /sys/mgrs
      $ edacl -a %.server -user -if  /sys/mgrs

  If you have manuals for the printer, add some CONTROL CODE 
is useful, like control code for H-tab,...
...../* htab for 201  esc,"(004,...,016."  */
    strcpy(buffer,"(004,008,012,016.");
    c = 0x1b;
    ios_$put(out_id,(short)0,c,(long)1,status);
    ios_$put(out_id,(short)0,buffer,(long)strlen(buffer),status);
....
==========================================================
 Now,after adding some code, version for pr201 driver is 0.3 
     file type          UASC,(unstruct),gmf
     kanji code         EUC
     header, footer     filename,last modified date,current date o
                        page number                              x
     tab                at 4,8,12,...
     (OS                 OS 10.2     )
     (Lang               /com/cc 6.7m)
  Anyone here interested in? But, march is end of scool year in JA,
and I must leave here K.I.T. I'm sorry leave it ver 0.3 ...
 Also, if there's a good example or text for driver, please 
up this news group.

  Kyusyu Institute of Technology | $@>.>>(J  $@Lw(J(Yasushi Komatsu)
    Tobata Kitakyusyu  804 JAPAN | (b51015@comp.kyutech.ac.jp)