Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!watmath!clyde!burl!ulysses!allegra!princeton!caip!ut-sally!seismo!mcvax!unido!coma!axel From: axel@coma.UUCP Newsgroups: net.micro.atari16 Subject: GEM-Kermit (Part 1 of 6) Message-ID: <600010@coma.UUCP> Date: Thu, 19-Jun-86 23:02:00 EDT Article-I.D.: coma.600010 Posted: Thu Jun 19 23:02:00 1986 Date-Received: Sat, 28-Jun-86 01:05:37 EDT Sender: notes@unido.UUCP Lines: 1119 Nf-ID: #N:coma:600010:000:45680 Nf-From: coma!axel Jun 20 04:02:00 1986 #! /bin/sh # This is a shell archive, meaning: # 1. Remove everything above the #! /bin/sh line. # 2. Save the resulting text in a file. # 3. Execute the file with /bin/sh (not csh) to create: # README.first # README # kermrsc.uuc # ibmtty.uuc # ibmtty # This archive created: Fri Jun 20 03:39:26 1986 export PATH; PATH=/bin:/usr/bin:$PATH if test -f 'README.first' then echo shar: "will not over-write existing file 'README.first'" else cat << \SHAR_EOF > 'README.first' GEM-Kermit for ATARI ST This is the first distribution of GEM-Kermit, an implementation of the well known kermit file-transfer protocol, with a user-interface, which uses the capabilities of GEM. This Program was developed on and for the Atari ST. GEM-Kermit was implemented by Bernhard Nebel of Technical University Berlin, W-Germany (nebel@db0tui11.bitnet). The main difference to the kermit program supplied with the Atari development kit, is the support of IBM-communication and a *much* nicer user-interface. The GEM Kermit distribution consists of 6 Parts. Five of them are shell-archives, one (Part 2) is the uuencoded kermit-program itself. Gemkermit requires the kermit.rsc (resource) to be present, when invoked. The uuencoded kermit.rsc is contained in Part 1. The filename-extension "uuc" marks uuencoded files. All the resource and .def -files, that come with kermit are uuencoded. The easiest way to put kermit to work is, to bring kermit.uuc, kermrsc.uuc and - if you're going to talk to IBMs - ibmtty.uuc on your Atari and uudecode them there. How to do the download without kermit already running on the ST ? If you don't want to type in the whole stuff by hand, you better find somebody who is already able to download files from a host to the atari. The remaining files are the sources for GemKermit - in case you like to fiddle around with them. To unpack everything, create a directory "kermit", cd to it, and off you go. After "un-shar"-ing, there should be two subdirectories (rsc and ibmtty) - besides a couple of ordinary files, of course. I hope this information will enable you to find your way to GEM-Kermit. ...and now enjoy installing the stuff. ciao, axel@coma SHAR_EOF fi if test -f 'README' then echo shar: "will not over-write existing file 'README'" else cat << \SHAR_EOF > 'README' Known problems with GEM-Kermit: - during transfer, it happens sometimes, that the ST thinks some button is depressed and starts an awful klicking (provided, keyklick is enabled). After depressing any key the noise disappears. - in the RS232 configuration, character size has to be 8. If cs is 7, all opening braces ('{') get lost (nobody knows why - yet). When communicating with IBM mainframes, make sure the following conditions are met: - binary transfer requires both kermits to be in binary mode. - select character size 8 bits/char (see above). - turn XON/XOFF-processing off. This is necessary, because XON is the handshake-character for half-duplex comm.-lines. - run your accoustic-coupler in full-duplex mode if it tends to echo in half-duplex mode. NOTE: some of the distributed files come multiple times ! \SRC\STKOBJ.H = \RSC\STKOBJ.H \RSC\STKOBJ.H = \RSC\STKOBE.H (is neccessary !) \PRG\KERMIT.RSC = \RSC\STKOBE.RSC \PRG\DKERMIT.RSC= \RSC\STKOBJ.RSC (this is the german version of the resource, you can ignore it) Send your bugreports, cheers, complaints, suggestions, hate-mail ..... to: nebel@db0tui11.bitnet Aw rite - enjoy ! SHAR_EOF fi if test -f 'kermrsc.uuc' then echo shar: "will not over-write existing file 'kermrsc.uuc'" else cat << \SHAR_EOF > 'kermrsc.uuc' begin 777 kermit.rsc M 9P!(T$C02-!'< "01VP +@ V 4 $4 !8 "Y0($1E7!E+BXN " @1G)E92!3<&%C92XN+@ @(%-E;F0N M+BX ("!296-E:79E+BXN " @4'5T*%-E2!4'@ 5F5R'AX>'AX M %]?+5]?+5]? #DY.3DY.0!4:&ES('!R;V=R86T@:7,@<'5B;&EC(&1O;6%I M;@ '-O9G1W87)E(&%N9"!I2P@3F5W(%EO7!E/25C+"!L96X])3)D+"!N=6T])3 R> !34$%#2SH@9&%T83U\)7-\ M "HJ*D-H96-K2!T#X@?"5C? !3=&%R="!R96-E:79I;F $ MJ0 !*H P & 1@ __\ "P ! $JP !+, 2[ , !@ !$8 /__ M @ " !,, 38 $V0 # 8 !& #__P 5 $ 3: $X !.8 M P & $1@ __\ !@ & $[ !/@ 3Y , !@ $8 /__ P 0 M!/H 4 %!@ # 8 1& #__P & 8 4, %% !14 P & 1 M@ __\ " ! %%@ !1P 4B , !@ !$8 /__ 8 !@ !2@ 4R M %,P # 8 !& #__P * $ 4T %/ !40 P & $1@ __\ M" ( %3 !6$ 5B , !@ $8 /__ !4 0 !6, 5F %:0 # M 8 !& #__P # , 5L %=P !7@ P & 1@ __\ "P ! % M?P !8< 6/ , !@ !$8 /__ @ " !9< 6L %K0 # 8 !& M #__P 5 $ 6N %N@ !;L P & (1@ __X # ! %O !<@ M 7) , !@ "$8 /_^ P 0 !=@ 7E %Y@ # 8 A& #__@ - M $ 7G %]@ !?< P & (1@ __X #P ! %^ !?D 7Z , M!@ $8 /__ $ 0 !?X 84 &%0 % 8 A& #__P 6 $ 86 M &)0 !B8 !0 & (1@ __\ #P ! &)P !C4 8V , !@ "$' M /__ X 0 !C< 8\ &20 # 8 A& #__P % T 9. &50 M!EX P & (1@ __\ !P ) &90 !H, :$ 4 !@ $8 /__ !X M 0 !H4 :I &J@ % 8 !& #__P D $ :K &S0 !LX !0 & M 1@ __\ (@ ! &SP !O$ ;R 4 !@ $8 /__ "( 0 !O, M <8 '&0 # 8 !& #__P E $ <: '.@ !SL P & 1@ M__\ ( ! '/ !ST <^ , !@ $8 /__ $ 0 !S\ =H ' MD0 # 8 1& #__P I "D U\ -?@ #90 P & 1@ __\ @ 6 M -E@ #9\ VN , !@ !$8 /__ D #P #;H W/ -T # 8 M A& #__@ 5 $ W1 -^@ #B, P & 1@ __\ *0 I .3 M#G$ YR , !@ "$8 /__ "4 ?__ $ !P 9 % M&0 ' ( @ 4 $0 % " 0 ! , !@ 9 @ M !\# 0 $_____P @ "0 8# 0 %_____P @ "L M!@ 8# 0 &_____P @ #( # H# 0 "_____P @ M #T %@ D# 0 @ (0 9 ,! % $P 1 D $ 4 M #_$0 @ !0 " *_____P < $< !0 0 +_____P < M " %4 ! !0 0 ,_____P < &H " !0 0 -____ M_P < '\ # !0 0 ._____P < )0 $ !0 0 / M_____P < *D % !0 0 0_____P < +X & !0 M 0 (_____P < -, ' !0 0 8 !( %P 4 #_$0 " M !( !@ 3_____P < .@ !( 0 4_____P < /0 M ! !( 0 5_____P < 0 % !( 0 6_____P < " M 0< $ !( 0 7_____P < 1H " !( 0 1_____P < M 20 # !( 0 A !D ( 4 #_$0 #@ !, " :_____P < M 30 !, 0 ;_____P < 3X ! !, 0 <____ M_P < 4L # !, 0 =_____P < " 5P " !, 0 > M_____P < 7 $ !, 0 ?_____P < 8$ & !, M 0 @_____P < 9 ' !, 0 8_____P < " :$ % M !, 0 ' "( +0 4 #_$0 & !8 # C_____P < ;4 M !8 0 D_____P < << & !8 0 E_____P < " M =@ ( !8 0 F_____P < >\ ' !8 0 G_____P < M ?X * !8 0 H_____P < " @X % !8 0 I_____P < M B4 ! !8 0 J_____P < CD # !8 0 K____ M_P < D, " !8 0 L_____P < DX ) !8 0 M M_____P < F4 + !8 0 A_____P < " G4 $ !8 M ?__ $ 0 4 $ "$0 !PH% 0 _____P < " G\$ , M H ?__ $ 0 4 $ "$0 @L' 0 _____P < " HH# M 4 H ?__ $ 0 4 $ "$0 ! T' 0 _____P < " M I4% 0 P ?__ $ ' 4 $ "$0 "X $0 "_____P 6 M( $C0 !P ! !\ 0 #_____P 6 $E & # < 0 $_____P 6 M $FP 'P # D 0 ' 4 !@ 6 $H@ !@ $ "( 0 &____ M_P > @ $J0 %P ( 0 $_____P > @ $L ( ( 0 * M @ "0 6 $MP !@ % "( 0 )_____P > @ $O@ %P ( M 0 '_____P > @ $Q0 ( ( 0 , L "P 6 $S !@ & M "( 0 *_____P > @ $TP ( ( 0 / T #@ 6 $V@ M!@ ' "( 0 ._____P > @ $X0 %P ( 0 ,_____P > @ M$Z ( ( 0 1 ! $ 6 $[P !@ ( "( 0 /_____P > @ M $]@ %P ( 0 3 !( $@ 6 $_0 !@ ) "( 0 1_____P > M @ %! %P ( 0 6 !0 %0 6 %"P !@ * "( 0 5____ M_P > @ %$@ %P ( 0 3_____P > @ %&0 ( ( 0 8 M !< %P 6 %( !@ + "( 0 6_____P > @ %)P ( ( M 0 ; !D &@ 6 %+@ !@ , "( 0 :_____P > @ %-0 & M $ 0 8_____P > @ %/ (0 $ 0 <_____P : < _( M!@ . @ 0 _____P : "4 _4 ( . @ ?__ $ ) 4 $ " M$0 "8 $@ "_____P 6 ( ( %0P !P ! !< 0 #_____P 6 ( M( %2@ !P ! !< 0 & 0 !0 4 #_$0 P # " 0 %_____P = M @ %40 "@ !8 0 #_____P 5 %6 4 0 ) < M" 4 #_$0 P $ " 0 (_____P = @ %7P "@ !8 0 & M_____P 5 %9@ H 0 , H "P 4 #_$0 P & " M 0 +_____P = @ %;0 &0 < 0 )_____P 5 %= M !0 0 / T #@ 4 #_$0 P * " 0 ._____P = @ %>P M&P 4 0 ,_____P 5 %@@ L 0 2 ! $0 4 #_ M$0 P + " 0 1_____P = @ %B0 &P 4 0 /_____P 5 M %D < 0 5 !, % 4 #_$0 P , " 0 4_____P = M @ %EP &P 4 0 2_____P 5 %G@ D 0 8 !8 M%P 4 #_$0 P ( " 0 7_____P = @ %I0 &0 < 0 5 M_____P 5 %K !0 0 ; !D &@ 4 #_$0 P - " M 0 :_____P = @ %LP '@ ( 0 8_____P 5 %N@ M H 0 <_____P : $ !7D &@ / D 0 ? !T '@ 4 #_$0 M P ' " 0 >_____P = @ %P0 &0 < 0 <_____P 5 M%R !0 0 @_____P 6 ( ( %SP !P ! !< 0 A_____P 6 ( M( %U@ !P ! !< 0 B_____P : $ ! @ &1@ !0 % "@ 0 _____P : "< ![H % ( M @ ?__ $ 0 4 $ "$0 @D' 0 _____P < " ![T% M 0 @ ?__ $ *P 4 "$0 $X %0 "_____P < M!\8 P 0 #_____P < !], ! L 0 $_____P < M !]\ " "( 0 %_____P < " ( $ !\ 0 &_____P < M ""( # ! 0 '_____P < "#, & "8 0 (____ M_P < "%H % ! 0 )_____P < "&L ' "$ 0 * M_____P < "(T ( ! 0 +_____P < ")X + "8 M 0 ,_____P < ",4 , ! 0 -_____P < "-8 - M !@ 0 ._____P < ".\ . !D 0 /_____P < "0D M / " 0 0_____P < "2H 0 !4 0 1_____P < M"4 1 !T 0 2_____P < "5X 2 !D 0 3_____P < M "7@ 3 !\ 0 4_____P < "9@ 4 "$ 0 5_____P < M ";H ) "$ 0 6_____P < "=P * ! 0 7____ M_P < ">T *0 $ !D 0 8_____P < "@< *0 # !< 0 9 M_____P < "A\ *0 " !@ 0 :_____P < "C@ )0 !\ M 0 ;_____P < "E@ )0 ! "( 0 <_____P < "GL *0 % M "$ 0 =_____P < "IT *0 & !@ 0 >_____P < "K8 M*0 ' ", 0 ?_____P < "MH *0 + !@ 0 @_____P < M"O, *0 * " 0 A_____P < "Q0 *0 , !L 0 B_____P < M "S (P ( "8 0 C_____P < "U< *0 ) !( 0 D_____P < M "VH (P - "< 0 E_____P < "Y( *0 . !L 0 F____ M_P < "ZX (@ / "@ 0 G_____P < "]< *0 0 "( 0 H M_____P < "_H (P 1 "8 0 I_____P < #"$ )0 2 !\ M 0 J_____P < #$$ *0 4 !L 0 K_____P < #%T )@ 3 M ! 0 "P ,0 4 #_$0 $X %0 M_____P < #&X M % 8 0 N_____P < #'4 ! !D 0 O_____P < M#(\ " !D 0 P_____P < #*D "@ 0 Q_____P < M #-( # "8 0 K_____P < " #/D $ !< ?__ $ 0 4 M $ "$0 !P\& 0 _____P < " #1$% , X ?__ $ M 0 4 $ "$0 !P\& 0 _____P < " #2 0, X ?__ M $ 0 4 $ "$0 H& 0 _____P < " #2\" 0, @ M ?__ $ 0 4 $ "$0 ! P& 0 _____P < " #3@& ( M L ?__ $ 0 4 $ "$0 ! D' 0 _____P < " #40" M 0, < ?__ $ 0 4 $ "$0 !0@' 0 _____P < " M#4P& , < ?__ $ 0 4 $ "$0 !Q,( 0 _____P < " M #50' , !( ?__ $ 0 4 $ "$0 !14' 0 _____P < M " #6<' 0 !0 ?__ $ P 4 $ "$0 !L "0 "____ M_P = @ &30 P ! !4 0 #_____P = &5 !@ # X 0 M_____P : "< #;< "0 & @ ?__ $ !0 4 $ "$0 #$ M# "_____P 6 ( &6P #0 ! !8 0 #_____P = @ &8@ ! & M "@ 0 $_____P 5 &:0 !@ $ "0 0 %_____P : < #G, M!P ) @ 0 _____P : "4 #G8 ( ) @ 0 &< !X0 >0 M'G !Z@ A6 )- "8@ FL )N "N0 KP *_ "P@ L 54 +( "RP LX +1 "UP end SHAR_EOF fi if test -f 'ibmtty.uuc' then echo shar: "will not over-write existing file 'ibmtty.uuc'" else cat << \SHAR_EOF > 'ibmtty.uuc' begin 777 ibmtty.acc M8!H !4, #N %\X 8@ "Y\ "B\\ G?"\\ GZB\\ HADZY M 30M_\ ##/ HB#U\ '__F 4,&[__M'(T?P ">>,+P 5)N__X, M;@ *__YMY#/\ ( ">R+KP "?L+SP "B(+SP ">>3KD \84(\NO M*&(O/ *(PO/ *, O/ *+X_/ $0F=.N0 %'#?_ !!.7DYU3E;_ M_$*7/SP! $ZY 3A%2/80 P$I 9@9"0& +(^N0 *&(_.0 *(P_.0 M*, _.0 *+Y"9TZY 3R%"/,\ "B*/KD "AB/SD "B,/SD "C /SD M "B^/SD !X*/SD "=\/SD "C /SD "B^3KD !*>W_P ./KD "AB M/SD "B,/SD "C /SD "B^/SD "B*3KD !0"4(\^N0 *(A.N0 #K0^ MN0 *(A.N0 #50^N0 *(A.N0 #H)P 4Y>3G5.5O_\+KP "?L0F<_.0 M*(A.N0 $"18CS Y G[%) ,\ !SJ,_D "C <[# Y 3G5.5O_\/KD "B(3KD M [F85@^N0 *(I.N0 %#P^N0 *(I.N0 %%8^N0 *&(_.0 *(P_.0 M*, _.0 *+X_.0 '@H_.0 )WP_.0 *, _.0 *+Y.N0 $O#?_ Y. M7DYU3E;__"Z\ E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Q"0& D!*;O_^9@9A /Q@8!(^KO_^,"[__-%780#\WE-N__Y@ M (:(&X "# 0L&[__F8&80#\.& 2/J[__C N__S15V$ _*)2;O_^8 !\B\N M @O/ 'R1A /UP6(\P0-'((GP "B.,#"8 "!?,( ]0/_^+JX ## Y ? M),'\ %#0O 'R8O &$ _0Y8CSZN__P_+O_Z/SD "B(3KD !#T6(\NK@ , M(&X "#\04U="9V$ ^\98CSZN__PP+O_^T5<_+O_Z/SD "B(3KD !#T6(]@ M %F+RX ""\\ ?)&$ _018CS! T<@B? *(XP,)@ (%\P@#U __XNK@ , M,#D !\DP?P 4-"\ ?)B\ 80#\@EB//J[__#\N__H_.0 *(A.N0 $/18 MCRZN P@;@ (/Q!35T)G80#[.EB//J[__# N__[15S\N__H_.0 *(A.N0 M$/18CV -IA /CF+HY9ER\.79<_.0 *(A.N0 #]Y#Z\ '=A /=P80#WJF$ ^$1A /AB8 >BZ.!I?___^P+PX&E____ZYA /M, M6(]*0&=@+HX&E____[ _+O^N80#_;%2/2F[_KF<\,'D "=^T3G5.5O_H8$PNC@:7____[$ZY 20 QN "C_[&8V,"[_]+!Y 3G5.5O_\,_P 90 *&9">0 *&A">0 M*&PS[@ ( H3G5.5O_\,_P !0 *&9">0 *&A">0 *&PS M_ ( H<#/N @ "AR3KD !%,3EY.=4Y6__PS_ % H9D)Y H:$)Y M H;#/\ < "AP,^X " *').N0 $4Q.7DYU3E;__#/\ 4 "AF0GD M "AH0GD "AL,_P !@ *' S[@ ( H3G5.5O_X+7P !T* M__P@;@ *$!!(@")N__PR@%*N I4KO_\2D!FYC/\ 4 "AF0GD "AH("[_ M_)"\ ="H'\ )(P%- ,\ "AL,_P # *' S[@ ( H M3G5.5O_\,_P !0 *&9">0 *&A">0 *&PS_ * H<#/N @ "AR3KD M !%,3EY.=4Y6__PS_ % H9D)Y H:$)Y H;#/\ D "AP,^X " M*').N0 $4Q.7DYU3E;__#/\ 4 "AF0GD "AH0GD "AL,_P P *' S M[@ ( H3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0&! 8$!@0&! 8$!@0.!"0*$ @*$ @*$ @(" @(" @*$ @(" @( M" @*$@H*"@H($ @*$ @*$ @(" @*$ @(" @*$ H0"A ("@H*"@H($ H*" @( -" @!C 0$! 0$! 0$ @* end SHAR_EOF fi if test ! -d 'ibmtty' then mkdir 'ibmtty' fi cd 'ibmtty' if test -f 'ascii.h' then echo shar: "will not over-write existing file 'ascii.h'" else cat << \SHAR_EOF > 'ascii.h' /********************/ /* some ASCII codes */ /********************/ #define NUL 0x00 /* ^@ */ #define SOH 0x01 /* ^A */ #define ETX 0x03 /* ^C */ #define BEL 0x07 /* ^G */ #define BS 0x08 /* ^H */ #define HT 0x08 /* ^I */ #define LF 0x0A /* ^J */ #define VT 0x0B /* ^K */ #define FF 0x0C /* ^L */ #define CR 0x0D /* ^M */ #define DC1 0x11 /* ^S */ #define DC3 0x13 /* ^Q */ #define SUB 0x1A /* ^Z */ #define ESC 0x1B /* ^[ */ #define DEL 0x7F /*******************/ /* Some Scan Codes */ /*******************/ #define CLR_HOME_KEY 0x47 #define UP_KEY 0x48 #define LEFT_KEY 0x4B #define RIGHT_KEY 0x4D #define DOWN_KEY 0x50 #define INSERT_KEY 0x52 #define UNDO_KEY 0x61 #define HELP_KEY 0x62 SHAR_EOF fi if test -f 'ibmtty.c' then echo shar: "will not over-write existing file 'ibmtty.c'" else cat << \SHAR_EOF > 'ibmtty.c' /*********************************/ /* IBM Block Terminal Emulation */ /* written by B. Nebel, March 86 */ /* Version 1.2 of 5/10/86 */ /*********************************/ /* include files */ /*****************/ #include "define.h" /* common C defintions */ #include "osbind.h" /* binding of TOS */ #include "gemdefs.h" /* GEM defintions */ #include "ascii.h" /* ASCII codes and keyboard scan codes */ /* global constant parameters */ /******************************/ #define ACCESSORY YES #define MENU_NAME " IBM Terminal" /* name of menu entry */ #define MAX_LL 80 /* line length */ #define MAX_BUF 20 /* ring buffers */ /* external functions */ /**********************/ /* GEMDOS (osbind.h) */ /* Crawio, Cauxin, Cauxout, Cauxis, Malloc, Mfree */ /* XBIOS (osbind.h) */ /* Rsconf */ /* VDI */ extern int v_opnvwk(); extern int v_clsvwk(); extern int v_enter_cur(); extern int v_exit_cur(); extern int v_curright(); extern int v_curleft(); extern int v_curhome(); extern int v_eeos(); extern int v_eeol(); extern int vs_curaddress(); extern int vq_curaddress(); extern int v_curtext(); extern int vq_chcells(); extern int vro_copyfm(); /* AES */ extern int appl_init(); extern int appl_exit(); extern int graf_handle(); extern int graf_mouse(); extern int graf_growbox(); extern int menu_register(); extern int evnt_mesag(); extern int evnt_timer(); extern int wind_create(); extern int wind_open(); extern int wind_close(); extern int wind_delete(); extern int wind_get(); extern int wind_update(); extern int form_alert(); extern int gl_apid; /* Global Variables */ /********************/ int menu_id, vdi_handle, wi_handle; /* some handles */ int gl_hchar, gl_wchar, gl_wbox, gl_hbox; /* sizes given back by VDI */ int xdesk, ydesk, hdesk, wdesk; /* desktop size and loc. */ int last_entry, next_entry; /* ptr to ring buffer */ char ring_buffer [MAX_BUF] [MAX_LL]; /* the ring buffer */ int ring_filled[MAX_BUF]; /* fill counter for ring buf */ int aux_received; /* if <> 0 someth. rec. by aux */ FDB scrn_mfdb; /* mfdbs for saving menu bar */ FDB save_mfdb; int work_in[11]; /* params for vdi_opnvwk */ int work_out[57]; int pxy[8]; /* param for raster copy */ long int buff_loc = NIL; /* save buffer for menu bar */ long buff_size; /* buffer size */ int menbbuf[1000]; /* buffer for menu bar */ /* static allocation because Malloc allocates too much */ int contrl[12]; /* VDI/AES glob. params */ int intin[128]; int ptsin[128]; int intout[128]; int ptsout[128]; /**********************************/ /* Initializations & Terminations */ /**********************************/ open_vdi() /* open virtual work station */ { int i; vdi_handle = graf_handle(&gl_wchar, &gl_hchar, &gl_wbox, &gl_hbox); for (i = 1; i < 10; i++) { work_in[i] = 1; } work_in[10] = 2; v_opnvwk(work_in, &vdi_handle, work_out); wind_get(0,WF_WORKXYWH,&xdesk,&ydesk,&wdesk,&hdesk); } int init_terminal() /* init virtual workstation as a terminal */ { graf_mouse(M_OFF,NIL); if (!(save_menu_bar())) return FALSE; wi_handle = wind_create(0,xdesk,ydesk,wdesk,hdesk); graf_growbox(xdesk,ydesk,gl_wbox,gl_hbox,xdesk,ydesk,wdesk,hdesk); wind_open(wi_handle,xdesk,ydesk,wdesk,hdesk); v_enter_cur(vdi_handle); v_curhome(vdi_handle); v_eeos(vdi_handle); return TRUE; } int save_menu_bar() /* save menu bar in a area to be allocated */ { vq_extnd(vdi_handle, 0, work_out); save_mfdb.fd_w = work_out[0] + 1; save_mfdb.fd_h = ydesk; save_mfdb.fd_wdwidth = save_mfdb.fd_w >> 4; save_mfdb.fd_stand = 0; vq_extnd(vdi_handle, 1, work_out); save_mfdb.fd_nplanes = work_out[4]; buff_size = (save_mfdb.fd_w >> 3) * save_mfdb.fd_h * save_mfdb.fd_nplanes; buff_loc = save_mfdb.fd_addr = /* ((buff_loc == NIL) ? (Malloc(buff_size)) : buff_loc); * I use static allocation because Malloc stole me 50 K! */ &menbbuf[0]; scrn_mfdb.fd_addr = 0; if (buff_loc == NIL) {form_alert(1,"[1][Nicht genug Speicherplatz vorhanden][Abort]"); return FALSE;}; pxy[0] = pxy[4] = 0; pxy[1] = pxy[5] = 0; pxy[2] = pxy[6] = save_mfdb.fd_w - 1; pxy[3] = pxy[7] = ydesk - 1; vro_cpyfm(vdi_handle,3,pxy,&scrn_mfdb,&save_mfdb); return TRUE; } close_vdi() /* close virtual workstation */ { v_clsvwk(vdi_handle);} exit_terminal() /* exit terminal mode */ { v_exit_cur(vdi_handle); restore_menu_bar(); wind_close(wi_handle); wind_delete(wi_handle); graf_shrinkbox(xdesk,ydesk,gl_wbox,gl_hbox,xdesk,ydesk,wdesk,hdesk); #if !ACCESSORY graf_mouse(M_ON,NIL); #endif } restore_menu_bar() { vro_cpyfm(vdi_handle,3,pxy,&save_mfdb,&scrn_mfdb); /* Mfree(buff_loc); Do not free because it doesn't work right! */ graf_mouse(M_ON,NIL); } /*****************/ /* VDI Functions */ /*****************/ vdi_ch(ch) int ch; {Crawio(ch);} vdi_line(string) char string[]; { v_curtext(vdi_handle,string); vdi_ch(CR); vdi_ch(LF); } /**********************/ /* Terminal Functions */ /**********************/ help() { v_curhome(vdi_handle); v_eeos(vdi_handle); vdi_line("**********************"); vdi_line("* IBM Block Terminal *"); vdi_line("**********************"); vdi_line(""); vdi_line("BACKSPACE - letztes Zeichen lschen"); vdi_line("DELETE - aktuelles Zeichen lschen"); vdi_line("INSERT - lsche Zeile"); vdi_line("RETURN und ENTER - sende Zeile"); vdi_line("CLR HOME - sende BREAK Sequenz"); vdi_line("Pfeile links/rechts - Cursor in der Zeile bewegen"); vdi_line("Pfeile oben/unten - letzte/nchste Zeile editieren"); vdi_line("HELP - Ausgabe dieser Meldung"); vdi_line("UNDO - zurck zum Desktop"); vdi_line(""); } flush_rs232_buffer() {while (Cauxis() != 0) Cauxin();} flush_terminal_buffer() {while (Crawio(0xFF) != 0);} wait_for_char(scan_code,ch) char *scan_code,*ch; { long result; do {*scan_code = NUL; if ((result = Crawio(0xFF)) != 0) { *ch = result & 0xFF; *scan_code = result >> 16 ; } else {if (Cauxis() != 0) {result = Cauxin(); *ch = result & 0x7F; if (*ch <= '~') { vdi_ch(*ch); aux_received = YES; }; }; }; } while (*scan_code == NUL); } send_break() {char tsr; tsr = (Rsconf(-1,-1,-1,-1,-1,-1) >> 16) & 0xFF; Rsconf(-1,-1,-1,-1,(tsr | 0x08),-1); evnt_timer(750,0); Rsconf(-1,-1,-1,-1,tsr,-1); } ring_bell() {vdi_ch(BEL);} redisplay(from,to,line) int from, to; char line[]; { int i,r,c; vq_curaddress(vdi_handle,&r,&c); for (i = from; i <= to; i++) vdi_ch(line[i]); v_eeol(vdi_handle); vs_curaddress(vdi_handle,r,c); } move_right(dummy) int dummy; {v_curright(vdi_handle);} move_left(vcol) int vcol; { int r,c; vq_chcells(vdi_handle,&r,&c); if (c >= vcol) v_curleft(vdi_handle); } shift_right(from, to, line) int from, to; char line[]; { int i; for (i = to ; i >= from ; i--) line[i+1] = line[i]; } shift_left(from, to, line) int from, to; char line[]; { int i; for (i = from; i <= to; i++) line[i] = line[i+1]; } copy_buf_entry(src,dst) char src[]; char dst[]; { int i; for (i = 0; i < MAX_LL; i++) dst[i] = src[i]; } int dec_entry(e) int *e; {return ((--(*e) < 0) ? (*e = MAX_BUF - 1) : (*e));} int inc_entry(e) int *e; {return ((++(*e) >= MAX_BUF) ? (*e = 0) : (*e));} int get_line(filled, line) int *filled; char line[]; { int pos, scol, srow; char ch, scan_code; aux_received = NO; pos = 0; *filled = 0; vq_curaddress(vdi_handle,&srow,&scol); while (TRUE) { wait_for_char(&scan_code,&ch); if (aux_received) {vq_curaddress(vdi_handle,&srow,&scol); redisplay(0,*filled-1,line); vs_curaddress(vdi_handle,srow,scol+pos); aux_received = NO; }; if (ch != NUL) {if ((ch >= ' ') && (ch <= '~')) {if (*filled >= MAX_LL) ring_bell(); else {shift_right(pos, (*filled)-1, line); line[pos] = ch; redisplay(pos,*filled,line); (*filled)++; pos++; move_right(scol+pos); }; } else switch (ch) {case CR: vdi_ch(CR); return TRUE; case BS: if (pos == 0) ring_bell(); else {move_left(scol+pos); shift_left(--pos,--(*filled),line); redisplay(pos,(*filled)-1,line); }; break; case DEL: if (pos == *filled) ring_bell(); else {shift_left(pos,--(*filled),line); redisplay(pos,(*filled)-1,line); }; break; default: ring_bell(); break; }; } else switch (scan_code) {case UNDO_KEY: return FALSE; case LEFT_KEY: if (pos == 0) ring_bell(); else move_left(scol+pos--); break; case RIGHT_KEY: if (pos == *filled) ring_bell(); else move_right(scol+pos++); break; case UP_KEY: pos = *filled = ring_filled[dec_entry(&last_entry)]; copy_buf_entry(ring_buffer[last_entry],line); vs_curaddress(vdi_handle,srow,scol); redisplay(0,(*filled)-1,line); vs_curaddress(vdi_handle,srow,scol+pos); break; case DOWN_KEY: pos = *filled = ring_filled[inc_entry(&last_entry)]; copy_buf_entry(ring_buffer[last_entry],line); vs_curaddress(vdi_handle,srow,scol); redisplay(0,(*filled)-1,line); vs_curaddress(vdi_handle,srow,scol+pos); break; case HELP_KEY: help(); vq_curaddress(vdi_handle,&srow,&scol); redisplay(0,*filled-1,line); vs_curaddress(vdi_handle,srow,scol+pos); break; case CLR_HOME_KEY: vs_curaddress(vdi_handle,srow,scol); v_eeol(vdi_handle); pos = *filled = 0; send_break(); aux_received = TRUE; break; case INSERT_KEY: vs_curaddress(vdi_handle,srow,scol); v_eeol(vdi_handle); pos = *filled = 0; break; default: ring_bell(); break; }; }; } send_line(filled,line) int filled; char line[]; { int i; for (i = 0; i < filled; i++) Cauxout(line[i]); Cauxout(CR); } terminal() { char this_line[MAX_LL]; int this_fill; vdi_ch(ESC); vdi_ch('w'); help(); flush_rs232_buffer(); flush_terminal_buffer(); while (TRUE) {if (!get_line(&this_fill,this_line)) break; send_line(this_fill,this_line); if (this_fill != 0) {ring_filled[next_entry] = this_fill; copy_buf_entry(this_line,ring_buffer[next_entry]); inc_entry(&next_entry); }; last_entry = next_entry; }; } init_accessory() {menu_id = menu_register(gl_apid,MENU_NAME);} handle_events() { int mbuf[10]; while (TRUE) {evnt_mesag(mbuf); {if ((mbuf[0] == AC_OPEN) && (mbuf[4] == menu_id)) {wind_update(BEG_UPDATE); open_vdi(); if (init_terminal()) {terminal (); exit_terminal(); }; close_vdi(); wind_update(END_UPDATE); }; }; }; } main() {appl_init(); #if ACCESSORY init_accessory(); handle_events(); #else open_vdi(); if (init_terminal()) {terminal(); exit_terminal();}; close_vdi(); appl_exit(); #endif } SHAR_EOF fi cd .. exit 0 # End of shell archive