HP3000-L Archives

October 1999, Week 3

HP3000-L@RAVEN.UTC.EDU

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
John Korb <[log in to unmask]>
Reply To:
John Korb <[log in to unmask]>
Date:
Fri, 15 Oct 1999 09:37:03 -0400
Content-Type:
text/plain
Parts/Attachments:
text/plain (320 lines)
From the "HP 150//MS-DOS User's Guide" part number 45624-90001 printed 6/84:

The section pertaining to Touch programming is "Section IV Programming
Considerations" and is 14 pages long.  Below are highlights from that section.




Touch Screen Escape Sequences

Introduction
The following escape sequences allow control of the HP 150 Touch Screen
from a program executing from a remote host.  All sequences correspond
exactly to operations supported by the A/GIOS touch screen interface,
described in the "Programmer's Tool Kit".

The default condition for the touch screen reports is OFF; that is, it is
possible to define fields and not have them respond to touch.  The Set
Report Modes sequence must be used to enable Touch Screen reporting.

When defining touch fields, touch field addressing is absolute.  Thus, row
and column specifications will be defined relative to row 0, column 0 in
the upper left corner of display memory.


Handling of Invalid Values
The way in which invalid values are treated depends on the nature of the
value.  If you enter an invalid value, it will be handled in one of the
following ways:

*  it will be replaced by the default value for the parameter.

*  the previous definition for the parameter will be used.

*  it will be rounded or truncated to the nearest valid value for the
parameter.

*  the value will be ignored.

*  the entire escape sequence will be aborted if one or more values cannot
be parsed by the escape sequence processor.


Touch Screen Reset
The following escape sequence resets all touch fields to the OFF state.

   Esc -zJ


Set Report Mode
The default mode for touch screen reporting is OFF.  Using the folowig
escape sequence, you can enable and disable all touch screen reports, and
specify the form in which touches are reported.

   Esc -z <screen mode> n <touch mode> m

TERM                Value Meaning
<screen mode> n           Set screen mode
                      0   Disable all reports.  Softkeys are still active
                          unless explicitly disabled using the Enable Softkey
                          Touch Sensitivity sequence described later in this
                          section.  This is the start-up default alue.

                      1   Enable <row> <col> reporting only.

                      2   Enable touch field reporting only.

                      3   Enable both ,row> <col> and touch field reporting.

                      4   Toggle the touch screen on/off.  When set to OFF,
                          ALL touch screen operations are deactivated,
                          including soft key responses.  The start-up
                          default value is ON. (This can be performed
                          manually by pressing the "CONTROL" "SHIFT"
                          "MENU" keys simultaneously.)  The message
                          "TouchOff" will appear in the bottom right corner
                          of the screen when touch is off.

<touch mode> m            Set touch mode for <row> <col> reporting.
                      1   Report on touch only.  This is the start-up default
                          value.

                      2   Report on release only.

                      3   Report on both touch and release.

If <screen mode> n values of 1 or 3 are set, the value for <touch mode> m
MUST be set also.  If one of the two parameters is omitted, it will default
to the last value executed or to the start-up default value.  For this
reason we generally recommend that you specify both parameters even if you
intend to specify the start-up default values.

You should note, however, that if <screen mode> n is set to 0, 2, or 4,
which enables touch field reporting ony, any value for <touch mode> m will
be ignored, because it applies to <row> <col> reporting for a given
character cell if a field has been defined;  if a field has not been
defined, <row> <col> reporting will take place.


Define Touch Field
The sequence to define a touch field allows you to define rectangular or
square areas of the screen to respond or report the ways you specify.  To
define a touch field, use the following escape sequence:

   Esc -zg <rows>r <columns>c <cursor positioning mode>p
           <beep-on-touch mode>b <enhancement1>e <enhancement2>f
           <attributes>a <touch mode>m <string length>L <report string>

TERM                Value Meaning
<rows> r            0-47  Two integers, separated by a comma, that define
                          the upper and lower row bounds of the touch field
                          in display memory.  The bounds are included
within the field.

<columns> c         0-79  Two integers, separated by a comma, that define the
                          left and right column bounds of the touch field.
                          The bounds are included in the field.

                          Note:  If you do not specify rows and columns, no
                          field is defined.  There is no default.

<cursor> p                Cursor positioning mode specifies that the cursor
                          will be moved to the upper left corner of the
                          specified field when it is touched.  The default
                          is no cursor positioning.

                      0   Disable cursor positioning mode

                      1   Enable cursorpositioning mode

<beep-on-touch mode> b
                      0   Specifies the terminal should not beep when the
                          field is touched.

                      1   Specifies the terminal should beep when the field is
                          touched.

<enhancement1> e          Defines the enhancement for the field when it is in
                          the OFF state.

<enhancement2> f          Defines the enhancement for the field when it is in
                          the ON state.

The available enhancements for touch fields are shown in the table that
follows.  Security as an enhancement allows you to define a label that is
not displayed.  The label is separate from the field, so the field
enhancement is visible, but the label withing the field is not.  we
recommend that you use enhancements 0 - 15 only.

The start-up default enhancement is 0 (no enhancements) for fields that are
in the OFF state, and for fields that are in the ON state.

Table 18-1.  Touch Field Display Enhancements

Sec OFF   0   1   2   3   4   5   6   7   8   9  10  11  12  13  14  15
Sec ON   16  17  18  19  20  21  22  23  24  25  26  27  28  29  30  31

Hf brt                                    x   x   x   x   x   x   x   x
Undrln                    x   x   x   x                   x   x   x   x
inv-vid           x   x           x   x           x   x           x   x
blink'g       x       x       x       x       x       x       x       x

TERM                Value Meaning
<attribute> a             Defines the touch field type or attribute
                      1   ASCII field;  an ASCII field returns the field
                          string just as if characters had been typed on
                          the keyboard.  ASCII field is the start-up
                          default value.

                      3   Toggle field;  when the field is first touched it
                          is toggled ON.  When the field is touched AGAIN,
                          it is toggled OFF.

                      4   Normal Field, for any other report.

<touch mode> m            Defines the touch mode for the touch field.
                      1   Report on touch only

                      2   Report on release only

                      3   Report on both touch and release

<string length> L         Defines the length, in characters, of the report
                          string.
                     0-80 Use only if an ASCII field is being specified.

                      2   Specify for Toggle and Normal fields.

<string>                  Specifies the report string
                0-80 char For ASCII fields only

             2 lower-case For Toggle and Normal fields.
               characters

The following escape sequence illustrates the use of the Define Touch Field
Escape Sequence:

   Esc-zg10,12r35,45c1b10e2f5LEXIT<cr>

will result in a touch field with the following characteristics:

1. The touch-sensitive field is columns 35 through 45 on rows 10 through 12.

2. The terminal will beep once each time the field is touched.

3. The field will be displayed in inverse video and half-bright when it is
not being touched.

4. The field will be displayed inverse video when it is being touched, and
will remain in inverse video until it is released.

5. When the defined field is touched, it will transmit the ASCII phrase
"EXIT" and a carriage return to your application.


Enable Softkey Touch Sensitivity
To enable or disable softkey touch sensitivity, use the following escape
sequence:

   Esc -z <softkey number> s <response> k

TERM                Value Meaning
<softkey number>     1-8  Specifies the softkey for which touch sensitivity is
                          to be modified.  All softkeys are enabled for touch
                          sensitivity at start-up.

<response>            0   Disables the touch sensitivity of the softkey field.

                      1   Enables the touch sensitivity to the softkey field.


Delete Touch Field
To delete a touch field OTHER THAN A SOFTKEY FIELD, use the following
escape sequence:

   Esc -zd <row>r <col>c

TERM                Value Meaning
<row> r             0-47  An integer that specifies the row coordinate of any
                          position within the filed to be deleted.

<column>c           0-79  An integer that specifies the column coordinate of
                          any position within the field to be deleted.

Note:  The coordinates need not be exact; any coordinates WITHIN a defined
touch field will delete the entire field.  If both the <row> and <column>
parameters are omitted, ALL touch fields will be deleted.


Touch Field Report Sequences
The following information is returned to your remote application as an
escape sequence as a result of the user touching and/or releasing a touch
field on the screen:

1. For ASCII fields, the response string that was specified when the field
was defined is returned to the application as though it were typed on the
keyboard.

2. For Normal and Toggle fields, the following sequence is returned:

   Esc -z <string> <type> Q

   <string>   The two lower-case ASCII characters that were defined as the
              response string when the field was defined.

   <type>Q    Specifies the report type:
              1 = Toggle field ON report
              2 = Toggle field OFF report
              5 = Normal field touch report
              6 = Normal field release report

3. For <row> <col> reporting, the following sequence is returned:

   Esc -z <row> x <col> y <type> Q

   <row> x    A two-digit integer specifying the screen relative row position

   <col> y    A two-digit integer specifying the screen relative column
              position

   <type> Q   The report type, where <Q> equals:
              3 = <row> <col> touch report
              4 = <row> <col> release report



Enjoy!

John


At 10/15/99 12:24 PM , you wrote:
>Hello all,
>
>I have just bought a second hand HP 150 II Touch screen computer. It is an
>XT with a monochrome diplay and built in monitor. It can be used either as a
>computer or a terminal. When Used as a terminal, It is possible to make
>Touch screen Buttons appear by sending escape sequences to it's COM port.
>Does anybody have a list of these escape sequences? I intend to run this
>machine as a terminal running from my PC's COM port Via a COM cable and
>writing a menu program for it.
>
>The Product Number for this machine is: 45849A
>The Serial Number is: 2718A52404
>
>Any  help would be greatly appreciated.
>
>Please send responses to: [log in to unmask]
>
>Thanks.
> - Russell Anderson


--------------------------------------------------------------
John Korb                            email: [log in to unmask]
Innovative Software Solutions, Inc.

The thoughts, comments, and opinions expressed herein are mine
and do not reflect those of my employer(s), or anyone else.

ATOM RSS1 RSS2