1993.1.26



SUBJECT: labtom X-terminal ÀÇ serial port test

MEANING OF THIS MEMO:
Çö´ë»ó¼±ÀÇ labtom X-terminalÀÇ serial port¸¦ ÀÌ¿ëÇÏ¿© PostScript file printing.

CONTENTS:
0. Setting ¹æ¹ý.
1. ¿Ø ¹®Á¦Á¡ ?

DESCRIPTION:
0. Setting ¹æ¹ý 

   . X-TERMINALÀÇ default setting»óÅ´ ´ÙÀ½°ú °°´Ù
       port0  :  mouse
       port1  :  TCP port number 35
       port2  :  unused
       port3  :  unused

   . TCP port number´Â /etc/services file¿¡¼­ »ç¿ëµÇÁö ¾Ê´Â ÀÓÀÇÀÇ number¸¦
       ÀÌ¿ë serial interfaceÀÇ protocolÀ» ¸ÂÃã
 
   . port2¿Í port3¸¦ »ç¿ëÇÒ °æ¿ì X-TERMINALÀÇ setting mode¿¡¼­
        unused·Î settingµÇ¾î ÀÖ´Â port2¿Í port3¸¦ TCP¸¦ »ç¿ëÇÒ¼ö ÀÖµµ·Ï setting
         (¿¹, port2 TCP 36 , ¿©±â¼­ 36Àº TCP port number )

   . X-terminal»ó¿¡¼­
    
        Interface menu¿¡¼­ port1  :  baud rate 9600
                                     data bits    8
                                     stop bits    1
                                     parity    none
                                     flow control  Xoff  no CTS  no XANY  no DSK
                                     purpose : remote serial port
                                     TCP port number 35
                                     action on close  none

   . Installing¹× »ç¿ë¹æ¹ý

     i)Sun SE ÀÇ printer-labtom(/SUNSE/SHARE) À̶ó´Â S/W package °¡ ÀÖ¾î¾ßÇÔ.
       Àû´çÇÑ ÆÄƼ¼Ç¿¡ ±ò°í¼­ ÄÄÆÄÀÏ( make )
       
       ÄÄÆÄÀÏ ÈÄ »ý±ä ½ÇÇàÈ­ÀÏ µéÀ» /usr/local/bin À¸·Î copy Çϼ¼¿ë..
      
   xeprint : xengine serial port¿¡ data¸¦ º¸³»´Â file.
   xeprintd :xengine»óÀÇ serial port¸¦ ÀÌ¿ëÇÏ¿© printingÀ» ÇÏ°ÔÇÏ´Â print daemon
   xettyd : xengine serial port¿¡ ¿¬°áµÈ pseudo tty device¸¦ ¸¸µë

     cp xettyd /usr/local/bin
     cp xeprintd /usr/local/bin
     cp xeprint /usr/local/bin


     ii)/etc/ttytab file¿¡ pseudo device µî·Ï (terminal »ç¿ë½Ã ÇØ´ç)
       xepr1  "/usr/etc/getty std.9600"   unknown    on  local   secure
       (printer ÀÌ¿ë½Ã´Â status ¸¦ off ·Î ÇϽðí kill -1 1 Çϼ¼¿ä !!!)
       
 
     iii)Pseudo deviceÀÇ »ý¼º
         #xettyd /dev/xepr1 lapc 35
           
         (  /dev/xepr1  : port1ÀÇ pseudo device name
           lapc        : X-terminalÀÇ host name
           35          : port1ÀÌ »ç¿ëÇÏ´Â TCP port number )

     iv)  Print »ç¿ë¹æ¹ý
          . /etc/printcap file¿¡ print µî·Ï
   
             # vi /etc/printcap
                xepr1|lab top X-terminal port:\
                lp=/dev/xepr1:\
                sd=/usr/spool/xepr1:\
    
          . lpr -h -Pxepr1 file_name
    

     v) pin assign

        9 pin                    25pin

          2    ----------   2
          3    ----------   3
          5    ----------   7

1.À¢ ¹®Á¦Á¡.

       i) port È®ÀÎ ÇÊ¿ä.
          
         - port 3 °³Áß¿¡¼­ 1 ¹ø°  Æ÷Æ®°¡ ºÒ·®À̾ ÇÑÂüÇì¸É.
           port 2 ¹ø°°Í »ç¿ëÈÄ Å×½ºÆ®´Â °¡´É
       
       ii) Hyper ÀÇ KS mode ·Î½á ÅؽºÆ® ´Â Ãâ·Â°¡´É.
            *cat /tmp/test > /dev/xepr2
            *lpr -h -Pxepr2 /tmp/test µÑ´Ù OK !!

       iii)Hyper ÀÇ HS/2 mode(Postscript) ¶§´Â ¹®Á¦Á¡ ¹ß»ý.

          - Postscript data °¡ Ưº°È÷ ÀÛÀ»¶§´Â
            *cat /tmp/test.ps > /dev/xepr2
            *lpr -h -Pxepr2 /tmp/test.ps  µÑ´Ù OK !!
  
          -  Postscript data °¡ Àû´çÈ÷ Ŭ¶§´Â 
            *cat /tmp/test.ps > /dev/xepr2
            *lpr -h -Pxepr2 /tmp/test.ps
            µÑ´Ù  ´Ù ¸ø±×¸®°í hang-up.
       iv)Dot printer µµ buffer size ¹®Á¦°¡ ¹ß»ý.  

  1 Â÷ test °á°ú.

        *****Áï, labtom ÀÇ port °¡ »ç¿ëÇÏ°íÀÖ´Â ÀÔÃâ·Â ¹öÆÛÀÇ Å©±â°¡
           ¹®Á¦°¡ µÇ¾î¼­ ¹öÆÛÅ©±âº¸´Ù ÀÛÀº µ¥ÀÌŸ´Â ó¸®ÇÏ°í
          ¹öÆÛÅ©±âº¸´Ùµµ Å« µ¥ÀÌŸ´Â overflow ·Î½á ó¸®ÇÏÁö¸øÇÏ´Â°Í °°´Ù.

  2 Â÷ test °á°ú.

       ****** data ¸¦ ³»º¸³»´Â µ¿¾È °ü·Ã daemon(xettyd) ÀÌ Á×¾î¹ö·Á
       printer ¿¡ º¸³»Áø data ¸¸ printing µÈ´Ù.
       µû¶ó¼­, °ü·Ã source level ÀÇ ¼öÁ¤ÀÌ ÇÊ¿äÇÏ´Ù.

   3 Â÷ test Çغ¼°Íµé
   
      xettyd /dev/xepr1 lapc 35 666 &
      xeprintd 35 &

      xdpr or lp ·Î test ÇÒ°Í.

Revision History
Created on Jan  26 ,1993