Usenet comp.sys.dec (1990-2013)
 help / color / mirror / Atom feed
From: wald@alfalfa.sps.mot.com (Steve Wald)
Subject: Re: VT220 User definable keys.
Date: Wed, 21 Oct 1992 21:05:50 GMT	[thread overview]
Message-ID: <1992Oct21.210550.9210@newsgate.sps.mot.com> (raw)
In-Reply-To: 1c3juvINNdr5@grapevine.EBay.Sun.COM

In article <1c3juvINNdr5@grapevine.EBay.Sun.COM> smckinty@sunicnc.France.Sun.COM (Steve McKinty - Sun ICNC) writes:
>In article <1992Oct21.135832.15116@tpl68k0.tplrd.tpl.oz.au>, keithh@tplrd.tpl.oz.au (Keith Harwood) writes:
>> Could someone tell me how to set the user-definable-keys
>> on a VT220? All I have in the way of documentation is
>> the user's summary, which isn't very forth-coming. I've
>> tried doing what it says there, but nothing happens.
>> Could you give me an example command string which works,
>> say to set the F8 key to transmit the string FRED?
>
>You can't set F8 alone to send a string, the user-defined string will
>be sent when you press Shift-F8.

I wrote this file for the dxterm, but I'm pretty sure the escape
sequences are the same for your VT220.  If not, someone will correct me.

Put an actual ESC character between the quotes where it says 'set esc=""'
below... Edit the keys to do what you want... I called the file
setdxtermfeys and put it in my bin directory, to be called by .login
-------------------------------------------------
#!/bin/csh

# Escape key for sending DECUDK control strings
set esc=""

# Hex translations for within the key definitions
set A="41";set a="61"
set B="42";set b="62"
set C="43";set c="63"
set D="44";set d="64"
set E="45";set e="65"
set F="46";set f="66"
set G="47";set g="67"
set H="48";set h="68"
set I="49";set i="69"
set J="4a";set j="6a"
set K="4b";set k="6b"
set L="4c";set l="6c"
set M="4d";set m="6d"
set N="4e";set n="6e"
set O="4f";set o="6f"
set P="50";set p="70"
set Q="51";set q="71"
set R="52";set r="72"
set S="53";set s="73"
set T="54";set t="74"
set U="55";set u="75"
set V="56";set v="76"
set W="57";set w="77"
set X="58";set x="78"
set Y="59";set y="79"
set Z="5a";set z="7a"
set null="00"
set bell="07"
set bs="08"
set tab="09"
set vtab="0b"
set nl="0a"
set cr="0d"
set shiftout="0e"
set shiftin="0f"
set escape="1b"
set space="20"
set exclam="21"
set dquote="22"
set pound="23"
set dollar="24"
set percent="25"
set ampersand="26"
set squote="27"
set lparen="28"
set rparen="29"
set star="2a"
set plus="2b"
set comma="2c"
set minus="2d"
set period="2e"
set slash="2f"
set colon="3a"
set semicolon="3b"
set less="3c"
set equal="3d"
set greater="3e"
set question="3f"
set at="40"
set backslash="5c"
set lbracket="5b"
set rbracket="5d"
set carat="5e"
set underscore="5f"
set tick="60"
set pipe="7c"
set lbrace="7b"
set rbrace="7d"
set tilde="7e"
set delete="7f"
set n1="31";set n2="32";set n3="33";set n4="34";set n5="35"
set n6="36";set n7="37";set n8="38";set n9="39";set n0="30"

# Function key selector values
set F6="17"
set F7="18"
set F8="19"
set F9="20"
set F10="21"
set F11="23"
set F12="24"
set F13="25"
set F14="26"
set F17="31"
set F18="32"
set F19="33"
set F20="34"
set Help="28"
set Do="29"

# The following sequence redefines the UDKs on the LK201 keyboard for a dxterm:
#   NOTE: This defines only the SHIFTED Fkeys.

# First clear the old definitions:
echo -n $esc:x"P0;1|"$esc:x"\"

# Introduction sequence: no clear; no lock
echo -n $esc:x"P1;1|"

# Define F6-F10
echo -n $F6"/"$l$s$space$minus$a$l$F$g$cr
echo -n ";"$F10"/"$pipe$slash$u$s$r$slash$l$i$b$slash$s$e$n$d$m$a$i$l$space$minus$t$space$y$o$u$r$n$a$m$e$h$e$r$e$cr

# Define Special Keys
echo -n ";"$Help"/"$x$m$a$n$space$ampersand$cr
echo -n ";"$Do"/"$d$x$t$e$r$m$space$ampersand$cr

# Terminate the sequence
echo $esc:x"\"

-- 
Steve Wald, Motorola Inc.
wald@borg.sps.mot.com


  parent reply	other threads:[~1992-10-21 21:05 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1992-10-21  3:49 VT220 User definable keys Keith Harwood
1992-10-21 12:54 ` Steve McKinty - Sun ICNC
1992-10-21 19:00   ` Michael A. Thomas
1992-10-21 21:05   ` Steve Wald [this message]
1992-11-04 11:49 ` Yosef Branse
1992-11-05 18:48   ` Lee Havemann
read-only archive

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox