Browse
(440) 299-7778
Menu
(440) 299-7778
One-year parts and labor warranty30-day money-back guaranteeEnglishEspañolContact

The text of a manual · part 14 of 23

VRC 4000 Software Driver Manual: Chapter 2 TBDriver Touchscreen Driver for DOS, pages 123 to 132

Pages 123 to 132 of 206, from VRC 4000 Software Driver Manual

The original document is the PDF (1.2 MB). This is its text as extracted, unedited; tables and drawings read best in the PDF, and each page heading opens it at that page.

For the Symbol VRC-4000

Page 123

Chapter 2: TBDriver Touchscreen Driver for DOS

TBmouse Extended Application Program Interface As well as emulating the normal mouse API functions on interrupt 33, TBmouse provides additional functions.

Function: Disable TBmouse Calling Sequence: AX =F4 hex Call interrupt 33 hex

Return Values:

None

Description:

Disconnects TBmouse from TBdriver, so that touches will not be reported as mouse movements. If a real mouse driver is loaded, it will continue to work.

2-81

Page 124

VRC 4000 Software Driver Manual

Function: Enable TBmouse Calling Sequence: AX =F5 hex Call interrupt 33 hex

Return Values:

None

Description:

Re-connects TBmouse to TBdriver, so that touches will be reported as mouse movements.

2-82

Page 125

Chapter 2: TBDriver Touchscreen Driver for DOS

Function: Calling Sequence: Return Values:

Get TBmouse Configuration AX =F1 hex Call interrupt 33 hex AX = BL = BH =

CL = CH = DL =

Description:

'TB', if TBmouse is loaded Button mode, 1, 2, or 3 Control bits: 00000001 /Q 00000010 /C 00000100 /R 00001000 /Z 00010000 /I 00100000 /L 01000000 /N 10000000 /O Major version number Minor version number 1 if currently enabled 0 if currently disabled

Provides a means of finding out if TBmouse is loaded, and if it is, how it is configured.

2-83

Page 126

VRC 4000 Software Driver Manual

Function: Set TBmouse Configuration Calling Sequence: AX = F3 hex BL =

Button mode, 1, 2, or 3

BH =

Control bits as for Get TBmouse Configuration

Call interrupt 33 hex

Return Values:

None

Description:

Allows TBmouse to be reconfigured without unloading and reloading from the command line. This call must only be used with TBmouse disabled, so you must call Disable TBmouse first, then call Enable TBmouse afterwards. You may also wish to perform a Get TBmouse Configuration call to setup the current values of the control flags and mode prior to using this call.

2-84

Page 127

Chapter 2: TBDriver Touchscreen Driver for DOS

Function: Calling Sequence:

Unload TBmouse AX = F2 hex Call interrupt 33 hex

Return Values:

AH = 1 if successful 0 if unsuccessful

Description:

Restores vectors and returns TBmouse's memory to DOS, Unloading is not possible if interrupt 33 has been 'hooked' by another program.

2-85

Page 128

VRC 4000 Software Driver Manual

TBmouse Application Support Touch-Base have experience of using TBmouse with many commercial applications. A few of the more common ones are noted here: • LabWindows, from National Instruments

[Requires version 2.2 or above of LabWindows] TBdriver TBmouse n /M:8,8 • Iconics Genesis real time control system

[Requires Gn_timer.sys (from Iconics) in config.sys] TBdriver /V TBmouse n • Dinosaur Adventure set TBdint=65 TBdriver TBmouse n /L

2-86

Page 129

Chapter 2: TBDriver Touchscreen Driver for DOS

TBPAD - The Keyboard Emulator TBpad is a utility which extends the function of TBdriver to enable emulation of keystrokes by touch. The idea is to convert a keyboard application to touch without re-programming it. Very few keyboard applications lend themselves well to this type of conversion as a permanent solution, but the facility can nevertheless be useful in some cases. TBpad is a small Terminate Stay Resident program which allows you to supply a simple ascii file describing the coordinates of up to 99 pads, and the corresponding keystrokes to be stuffed into the keyboard buffer when each pad is touched. The set of active pad and key definitions can be changed at any time in one of two ways, either by calling TBpad via the command line and supplying a new filename, or via TBpad's Application Programming Interface. TBpad can be unloaded from memory via the command line or via the API.

The TBpad Demonstration The best way to understand what TBpad does is to run the demonstration. First ensure that TBdriver is installed and working. Get to the directory containing the TBpad software (the install program puts it in a subdirectory called TBpad), and then type “paddemo” to start the demonstration. The paddemo.bat file will simply invoke TBpad specifying the pad definition file “tbpad.dem”, and then display the instructions for you to read, and the keypad for you to touch, and then it terminates, returning you to the DOS prompt. TBpad is now resident in memory and will react to touches as defined by the “tbpad.dem” file.

2-87

Page 130

VRC 4000 Software Driver Manual

This batch file shows a simple demonstration of TBpad in action: Touch the keys shown to feed in the keystrokes indicated. Hint:

Start by touching “Date” and “Enter”.

If the screen scrolls, just type PADDEMO again.

7

8

9

Date

4

5

6

Backspace

1

2

3

Unload TBpad

0

/, Enter

C:\TOUCH>

First touch “Date”. The characters “Date” will be stuffed into the keyboard buffer, and so DOS echoes them on the screen. Now touch “Enter”. An Enter key will be stuffed, so DOS will execute the date command. You can now enter a date by touching the various characters on the screen. When you have entered the correct date, touch “Enter” again, and the date will be set. When you have finished, touch “Unload TBpad”, and TBpad will be unloaded from memory (or you can type “TBpad U”). The interesting thing about this demonstration is that it shows a touchscreen being used with no application programming whatsoever. The touch actions are entirely defined in the “tbpad.dem” file, and TBpad simply feeds the specified keystrokes into the keyboard buffer, where DOS or an application program will receive them exactly as if they had come from the real keyboard.

2-88

Page 131

Chapter 2: TBDriver Touchscreen Driver for DOS

Here's the pad definition file which made all that happen: * * TBPAD.DEM: An example pad definition file for TBpad * Scale 1,80,25 Mode F Pad 11,6,18,8,”7” Pad 20,6,27,8,”8” Pad 29,6,36,8,”9” Pad 38,6,45,8,”Date” Pad 11,9,18,11,”4” Pad 20,9,27,11,”5” Pad 29,9,36,11,”6” Pad 38,9,54,11,0E08 Pad 11,12,18,14,”1” Pad 20,12,27,14,”2” Pad 29,12,36,14,”3” Pad 38,12,54,14,”TBpad u” 1c0d Pad 11,15,18,17,”0” Pad 20,15,27,17,”/” Pad 29,15,36,17,”-” Pad 38,15,54,17,1c0d

2-89

Page 132

VRC 4000 Software Driver Manual

Pad Definition File Syntax There are three commands which may be used in pad definition files: Scale, Mode and Pad. Lines with a * in the first column are comment lines and are ignored. Lines beginning with anything else are rejected as errors. • The Scale Command

The Scale command defines the origin and X,Y scales in which the pad definitions for the current file are defined. There may be more than one scale command, but only the last one in the file is used. The syntax is: Scale<Origin>,<Xscale>,<Yscale>

Some examples are: Scale 1,80,25 Scale 0,639,349 Scale 0,639,479 • The Mode Command

The Mode command defines the touch mode by which the pads are activated. It may have a value of “F” for First touch activation, or “L” for Last touch activation. In First touch activation, a pad is activated once as soon as you touch onto it. Sliding onto other pads will not activate them pads will only be activated by touching down onto them. In Last touch activation, a pad is only activated when your finger breaks contact with the screen at the pad. Touching down or sliding has no effect. There may be more than one Mode command, but again, only the last one is used. Examples: Mode F Mode L • The Pad Command

2-90