Preh Electronic Inc.
Lake Zurich, IL 60047 USA
847-438-4000
847-438-5522 (Fax)

PP4100e-11/19/96-mk    Information may be subject to change without notice


             PREH-MWX.EXE (PrehProgrammer) Version 4.1.00
             --------------------------------------------
                Copyright (c) Preh, Bad Neustadt 1996





   Contents

   1.     General
   2.     PrehProgrammer Menu
   2.1.   Info-Submenu 
   2.2.   File Submenu
   2.3.   Edit Submenu
   2.4.   Default Submenu
   2.5.   Configuration Submenu
   2.6.   List Submenu
   2.7.   Utilities Submenu
   2.8.   Help Submenu
   3.     Setup for Processing
   3.1.   Input from key assignments
   3.1.1. Assignment
   3.1.2. Key position
   3.1.3. Number of Levels
   3.1.4. Key Attributes
   3.1.5. Level Selection
   3.2.   Module Settings
   3.2.1. Autoinput
   3.2.2. Barcode
   3.2.3. Ext. Keyboard
   3.2.4. KVK Reader 
   3.2.5. Magnetic Card Reader
   4.     Online Programming
   5.     Examples
   6.     Glossary
   7.     NEW FEATURES


1. General

Key assignements for programmable Preh keyboards can be constructed by 
means of the Prehprogrammer. The key assignements can be loaded to and 
from the keyboard and stored as MWX data files. In this way it is 
possible to easily prepare and duplicate keyboard assignments. In like 
manner, the MWX data file can be loaded into the keyboard via 
COPY2WX.EXE. The LST file generated by the PrehProgrammer (see also 
2.6), which enables a simple checkout, can also be transfered to a MWX 
file by MWXC.EXE. The PrehProgrammer can be run on an MS-DOS processor 
(80286 or higher) with 640k RAM and a color monitor (CGA, EGA or VGA).
A mouse is recommended.



             Input                          Input
               |                              |
        [ ASCII-Editor ]               [ PREH-MWX.EXE ]
               |                         |    |    |
         *.mwf |   +---------------------+    |    |
               |   |           *.lst          |    |
            [ MWXC.EXE ]                      |    |
                 |                      *.mwx |    |
           *.mwx |                            |    |
                 +---------------+------------+    | Read/Write
                 ^               |                 |  Keytable
                 |        [ COPY2MWX.EXE ]         |
                 |               |                 |
        [ READMWX.EXE ]          +-----------------+
                 |               |                 ^
                 |       ! PREH KEYBOARD !         |
          Upload |       !  MWX / PCPOS  !         |
                 |               |                 |
                 +---------------+-----------------+

         Overview of Available Tools and Data File Formats

The program is started with: 
PREH-MWX [/H|?] [/nn] [/E] [/A] [/P] [/COMx:  9600,0,8,1] [Filename]

/? or /H reveals the callup syntax of the command line.

The preset keyboard language can be selected by means of the parameter
<nn>. Via the indicated language code (US, GR, FR, UK, SG, SF, IT or 
SP) the PrehProgrammer can translate the inputted key assignment into 
scancode appropriate for the keyboard driver (KEYB xx).

/E starts the PrehProgrammer in the Expert Mode. In this mode, all the 
functions of the PrehProgrammer are available; however the programming 
does require that the user have a basic knowledge of the function modes 
of a keyboard system.

The parameter /A switches to the ASCII Mode. In this mode the 
key assignment is optimized with respect to storage area, although output 
takes a little longer.

/P switches on Edit-Layout for the PCPOS family.

By means of the parameter /COMx, the corresponding COM port of the PC 
is used for communication with the Preh- keyboard. The keyboard must 
also be simultaneously set to RS232. The default levels for the keyboard 
are 9600 baud, odd parity, 8 data bits and 1 stop bit.
This setting can be selected by pressing the key-combination A01+D01 
during startup.

Via <Filename>, the MWX data file to be loaded into the PrehProgrammer 
on startup can be specified.

Keyboard and mouse operations follow the guidelines of IBM's SAA 
(=Systems Application Architecture) standards, which simplifies usage.


2. PrehProgrammer Menus

** causes the indicated menu items to appear only in the Expert Mode.

After startup, the Main Menu with the following selections appears:

Info(-)   -- Info
File,     -- Load *.MWX, Save *.MWX, Read (KB), Write (KB), and Exit.
Edit      -- Modification of assignment, hotkeys and interface.
Default   -- Default Settings (levels and attributes) for new keys.
Config.   -- Operational Settings of the PrehProgrammer.
List      -- Output of the keyboard assignments as files.
Utilities -- Auxilliary Functions
Help      -- Calls up the Help System.

These menu items are selected from the keyboard by pressing the ALT-key 
together with the designated letter key. With the mouse you simply click 
on the corresponding word. A Pulldown Menu then appears. There you can 
select more menu items.


2.1 Info-Submenu

Info   -- Displays the version of the PrehProgrammer, the PP number and 
          the Checksum(ID) of the connected Preh keyboard. The Checksum
          (ID) denotes the firmware of the keyboard being used.
Exit   -- Closes the program and returns to DOS.
Help   -- Online Help
Cancel -- Breaks off the PrehProgrammer.


2.2  File Submenu

In this Submenu you will find the following functions:

Open           -- Loads an MWX Data File
New            -- Deletes the keytable currently in RAM.
Save           -- Saves the keytable as an MWX Data File.
Save as        -- Saves a keytable with new name.
Read Keytable  -- Reads the keytable database of the Preh keyboard.
Write Keytable -- Prints the keytable database in the Preh keyboard.
Use Interface  -- Selects the Read/Write interface.
Exit           -- Quits the program and returns to DOS.

The port to which the Preh keyboard, to be programmed, is connected is 
selected by means of USE INTERFACE (theoretically, three keyboards can 
be programmed "simultaneously" without changing connections (AT, COM1 
and COM2)). If a COM port is selected, the RS232 parameter can be 
specified after confirming the port via "Return". The basic setting is 
9600 baud, odd parity, 8 data bits, 1 stop bit.


2.3 Edit Submenu

This submenu provides functions for the setup of the assignment memory 
of a Preh keyboard. Here you will find the following menu selections:

Keys              -- Input from key assignments (Section 3.1).
Modules           -- Input from Module Parameters/Overlays 
                     (Section 3.2).
Hotkey 0          -- Definition of hotkeys for online string 
                     programming.
Hotkey 1          -- Definition of hotkeys for online single key 
                     programming.
Interface         -- Settings for the active ports. With this, the key-
                     board interface of the new assignment is specified. 
                     It is only active AFTER download.
Sound             -- Settings for sound parameters. Volume and duration 
                     for keyclick and error beeps (fat finger alarm) can 
                     be specified over the ranges of 0%...100% and 
                     20ms...5100ms.
Repeat/Delay      -- Settings for repeat and delay rates. If the Auto-
                     repeat attribute is activated for a key, then after 
                     depressing that key for the delay time, MakeCodes 
                     repeats this key at <Rate> characters per second.
Slow Output Speed -- Sets the output rate. Upon activation of the Slow 
                     Output attribute, the output rate (i.e. buffer 
                     delay in the processor) is selected by means of the 
                     Speed parameter. The default setting is the normal 
                     output rate. To speed up the output rate, MakeCodes 
                     can only be activated to the extent that the system 
                     will accept this output mode (i.e. MS-DOS).


2.4  Default Submenu

The default of the key levels and the attributes of new assignment 
strings can be set here (to lessen the amount of work in the Input 
screen).

Here you will find the following menu items for level selection:

Normal Level  -- Defines the normal level of a key.
Shift Level   -- Defines the shift level of a key.
Ctrl Level    -- Defines the control level of a key.
Alt Level     -- Defines the Alt level of a key.
Special Level -- Selected level is not changed.
Standard Key  -- Adjusts standard keys.

You can set the following attributes:

Keyclick  -- Turns Key Click on or off.
Repeat    -- Switches Autorepeat on or off.
Protect   -- Enables or disables online programming.
Slow Outp -- Slows character output (necessary due to buffer delays!)
MakeBreak -- Key works like a standard key.
Restore   -- Keyboard status can always be restored or not.


2.5 Configuration Submenu

In this submenu you can change the configuration of the PrehProgrammer 
and the programmable Preh keyboard.

Input Mode -- Select the input mode for the key assignment.
You may choose between:
   String   - Input as text string and automatic conversion of 
              Scancodes.
   Scancode - Input of Scancodes in the HEX format.
   ASCII    - Input of ASCII strings without conversion into Scancodes. 
              In the future, ASCII will no longer be supported.

In order to simplify the construction of the key assignments, you can 
choose between an EASY Mode and an EXPERT Mode. In the EASY Mode, 
simplifications and adjustments are carried out by the progam itself. 
In the EXPERT Mode, these system limitations do not apply and you 
maintain control over all possible settings. However, you yourself 
must then provide all the significant combinations of the conditions 
and attribute flags with which the keyboard generates the desired 
characters.
   Expert  - Activates Expert Mode, otherwise Easy Mode remains active.

Matrix Size   -- Defines kind of keyboard. The type of keyboard can also 
                 be stored in the key assignment and the PrehProgrammer  
                 set up for keyboard programming of the corresponding 
                 layout.
KEYB Language -- Defines keyboard language. A correct translation of 
                 text input in the String Mode is only possible with the 
                 proper setting for keyboard language. The following 
                 languages are supported via KEYB xx:  US, GR, FR, UK, 
                 SG, SF, IT and SP. In addition, you can opt for the 
                 utilized keyboard drivers having a CAPS Lock or a 
                 SHIFTLOCK function.
                 CAPSLOCK  - Keyboard has a CAPSLOCK function.
                 SHIFTLOCK - Keyboard has a SHIFTLOCK function.
Save Config   -- Saves configuration in Configuration Data File format 
                 (*.CFG). If such a data file resides in the memory of 
                 the PrehProgrammer, then it can be installed on startup.


2.6 List Submenu

With this submenu you can output the key assignment list to the monitor, 
the printer or a data file.

Display -- After selecting a command line by means of the cursor keys 
           and RETURN (or the mouse) you can edit the assignment text 
           and/or key characteristics so they are equivalent to the MWX 
           Compiler Syntax. The listing can be terminated by means of ESC.
Printer -- The output goes to the printer connected to LPT1.
File    -- The output goes to a data file with the extension '.LST'. 
           This data file can then also be further processed by means of 
           the MWX Compiler.


2.7 Utilities Submenu

Various auxilliary functions for configurating the key assignment are 
available here.

Add...    -- The basic assignments for PCPOS and PCPOS JUNIOR are loaded 
             in addition to the current keyboard assignment.
Protect   -- Sets the Protect Attribute for all keys.
Unprotect -- Removes the Protect Attribute for all keys.
Copy Key  -- Copies all levels of a single key assignment to a new key 
             position.
Swap Keys -- Interchanges two key assignments (all levels).


2.8  Help Submenu

Index    -- Help arranged according to topics.
Overview -- A brief introduction.

Subject-related help can be found within each submenu by pressing 
the F1 key.


3. Setup for Processing

After you have started the PrehProgrammer without parameters, you can 
load a stored MWX file with FILE\OPEN, read out with FILE\READ KEYTABLE 
a keytable stored in the connected Preh keyboard, or prepare a 
completely new overlay. If you want to construct a new overlay, you 
must first specify the country code with CONFIGURATION\KEYB LANGUAGE 
and the keyboard type with CONFIGURATION\MATRIX SIZE. Even if a Preh 
keyboard with an Alpha key-field has been newly programmed, you must 
still load the standard assignment with UTILITIES\ADD DEFAULT KEY 
ASSIGNMENT.



3.1  Inputing Key assignments

The selection screen is reached via EDIT\KEYS. All previously loaded key 
positions appear bright. The key positions which depend upon the 
keyboard type defined in CONFIGURATION\MATRIX SIZE are displayed in the 
lower area. In the upper region, the assignment for the Header and 
Terminator of the module can be selected in the same way as for the 
normal key assignments. Header and Terminator are used immediately before 
and after a data string of the corresponding hardware and can be 
utilized, for example, to identify the pertinent data stream. By selecting 
a keyposition you reach the EDIT KEY screen. Each new key assignment must 
be authenticated with <Return>. If you want to quit the EDIT KEY screen 
without making any changes, press <ESC>.

3.1.1  Assignment

In the Assignment command line of the EDIT KEY screen you can input the 
key assignment as a string or as Scancodes (set in CONFIGURATION\INPUT 
MODE). After confirmation that the input is error-free, it is marked 
"complete". In case of a mistake, an alarm sounds and the cursor is 
positioned at the incorrect location. When inputting as a string, all 
keys which cannot be represented by an ASCII code must be replaced by 
their key-names (in {}), i.e. {F1} for the F1 key, {Ctrl + Up} for the 
Ctrl function of the Up Arrow key. Please select the key-designations 
Scancode Macros) from the following table:
 F1 .. F12      Function keys F1 .. F12
 FS1 .. FS12    SHIFT + Function keys F1 .. F12
 FC1 .. FC12    CTRL+ Function keys F1 .. F12
 FA1 .. FA12    ALT + Function keys F1 .. F12
 N0 .. N9, N.   Numerical block positions
 #0 .. #9, #.   Numerical block codes
 SPACE          Spacing (only used at the end of a line)
 BACKSPACE      Backspace key (BS abbreviation allowed)
 PAUSE          Pause key
 BREAK          Break key ( = CTRL + Pause)
 EMPTY          Empty string
 NO_DATA        Suppressed data string (only for equipment IDs)
 INS            INS key
 DEL            DEL key
 PGUP           PgUp key
 PGDN           PgDn key
 HOME           Home key
 END            End key
 SYS            Switches on SysRq function
 SYSBREAK       Switches off SysRq function
 NUMLOCK        NumLock key
 SCROLL-LOCK    Scroll-Lock key
 PRTSC          PrtSc key
 ESC            ESC key
 TAB            Tab key
 LEFT           Moves cursor to the left
 RIGHT          Moves cursor to the right
 UP             Moves cursor up
 DOWN           Moves cursor down
 RETURN         RETURN key
 ENTER          ENTER key
 PLUS           Plus key in numeric keypad
 MINUS          Minus key in numeric keypad
 STAR           *-key in numeric keypad
 DIV            /-key in numeric keypad
 DELAY          0.5 sec output delay
 LED_ON         Key LED on (only M W/X bel)
 LED_OFF        Key LED off (only M W/X bel)
 RESET          RESET function
 NUL            Null byte
 SHIFT          Shift key
 CTRL           Ctrl key
 ALT            Alt key
 ALTxxx         Alt sequence with the code xxx (e.g. ALT27=ESC)
 ALTGR          AltGr key
 SHIFT+..       Shift function of ..
 CTRL+..        Ctrl function of ..
 ALT+..         Alt function of ..
 ALTGR+         AltGr function of ..
 LWIN+..        Left WIN95 function of ..
 RWIN+..        LRight WIN95 function of ..
 APP            WIN95 application key

Examples:  {F1}, {Ctrl+F5}, {up}, {Ctrl+A}, {Delay}, {Alt+X}, ...


3.1.2  Key Position

The key position field represents the current key position as a 3-place 
code. The first place indicates the row by a letter, as shown below. The 
digits of the remaining two places specify the column, from left to right.

   __ H01 H02 H03 H04 H05 H06 H07 H08 H09 H10 H11 H12 H13 H14 H15 H16
      G01 G02 G03 G04 G05 G06 G07 G08 G09 G10 G11 G12 G13 G14 G15 G16
      F01 F02 F03 F04 F05 F06 F07 F08 F09 F10 F11 F12 F13 F14 F15 F16
      E01 E02 E03 E04 E05 E06 E07 E08 E09 E10 E11 E12 E13 E14 E15 E16
      D01 D02 D03 D04 D05 D06 D07 D08 D09 D10 D11 D12 D13 D14 D15 D16
      C01 C02 C03 C04 C05 C06 C07 C08 C09 C10 C11 C12 C13 C14 C15 C16
      B01 B02 B03 B04 B05 B06 B07 B08 B09 B10 B11 B12 B13 B14 B15 B16
      A01 A02 A03 A04 A05 A06 A07 A08 A09 A10 A11 A12 A13 A14 A15 A16
                                                     |
                 Assignment of key IDs for M 84/128 W/X


   G01 G02 G03 G04 G05 G06 G07 G08 G09 G10 G11 G12 G13 G14 G15 G16 G17
   F01 F02 F03 F04 F05 F06 F07 F08 F09 F10 F11 F12 F13 F14 F15 F16 F17
   E01 E02 E03 E04 E05 E06 E07 E08 E09 E10 E11 E12 E13 E14 E15 E16 E17
   D01 D02 D03 D04 D05 D06 D07 D08 D09 D10 D11 D12 D13 D14 D15 D16 D17
   C01 C02 C03 C04 C05 C06 C07 C08 C09 C10 C11 C12 C13 C14 C15 C16 C17
   B01 B02 B03 B04 B05 B06 B07 B08 B09 B10 B11 B12 B13 B14 B15 B16 B17
   A01 A02 A03 A04 A05 A06 A07 A08 A09 A10 A11 A12 A13 A14 A15 A16 A17

                  Assignment of key IDs for M 119 W/X


F: 01 02 03 04 05 06 07 08 09 10 11 12 13 14 15  16 17 18.19 20 21.22 23

E: 01 02 03 04 05 06 07 08 09 10 11 12 13[14 15] 16 17 18.19 20 21.22 23
D:[01] 02 03 04 05 06 07 08 09 10 11 12 13 [ 14] 15 16 17.18 19 20.21 22
C:[01 ] 02 03 04 05 06 07 08 09 10 11 12 13 [14] 15 16 17.18 19 20.21 22
B:[01] 02 03 04 05 06 07 08 09 10 11 12 [13  14] 15 16 17.18 19 20.21 22
A:[01 ]  [02 ]  [      03       ]  [ 04 ] [ 05 ] 06 07 08.09 10 11.12 13

                    Assignment of key IDs for PC POS


       G:  01 02 03 04 05 06 07 08 09 10 11 12 13 14 15  16
       F:  01 02 03 04 05 06 07 08 09 10 11 12 13 14 15  16
       E:  01 02 03 04 05 06 07 08 09 10 11 12 13[14 15] 16
       D: [01] 02 03 04 05 06 07 08 09 10 11 12 13 [ 14] 15
       C: [01 ] 02 03 04 05 06 07 08 09 10 11 12 13 [14] 15
       B: [01] 02 03 04 05 06 07 08 09 10 11 12 [13  14] 15
       A: [01 ]  [02 ]  [      03       ]  [ 04 ] [ 05 ] 06

                 Assignment of key IDs for PC POS JUNIOR


      H01 H02 H03 H04 H05 H06 H07 H08 H09 H10 H11 H12 H13 H14 H15 H16
      G01 G02 G03 G04 G05 G06 G07 G08 G09 G10 G11 G12 G13 G14 G15 G16
   __ F01 F02 F03 F04 F05 F06 F07 F08 F09 F10 F11 F12 F13 F14 F15 F16
      E01 E02 E03 E04 E05 E06 E07 E08 E09 E10 E11 E12 E13 E14 E15 E16
      D01 D02 D03 D04 D05 D06 D07 D08 D09 D10 D11 D12 D13 D14 D15 D16
      C01 C02 C03 C04 C05 C06 C07 C08 C09 C10 C11 C12 C13 C14 C15 C16
      B01 B02 B03 B04 B05 B06 B07 B08 B09 B10 B11 B12 B13 B14 B15 B16
      A01 A02 A03 A04 A05 A06 A07 A08 A09 A10 A11 A12 A13 A14 A15 A16

                   Assignment of key IDs for MC 80/128



In order to select the key position to be edited, you can either change 
this field accordingly or exit the input screen via <ESC> and choose a 
new position from the selection screen. Headers and Terminators for 
particular hardware modules can be defined via the following Codes, just 
as with all the other keys.

   M1H    Header string for MSR Track 1
   M1T    Terminator string for MSR Track 1
   M2H    Header string for MSR Track 2
   M2T    Terminator string for MSR Track 2
   M3H    Header string for MSR Track 3
   M3T    Terminator string for MSR Track 3
   BCH    Header string for barcode reader
   BCT    Terminator string for barcode reader
   FIH    Header string for inserting functioncard and -lock
   FIT    Terminator string for inserting functioncard and -lock
   FRH    Header string for removing functioncard and -lock
   FRT    Terminator string for removing functioncard and -lock
   KLH    Header string for keylock 
   KLT    Terminator string for keylock


3.1.3  Number of  Levels

No key has been defined yet for the key position "new level". "level N
of M" will appear if M levels for this key-position are already 
defined. With <PgDn> and <PgUp>, a level to be edited can be chosen, 
and a new level can be defined with <Ctrl+PgDn>.


3.1.4  Key Attributes

Various functions of the keyboard assignment can be assigned by means 
of these attributes.
Keyclick    -- String output with acoustic key click. A beep, whose 
               volume and duration can be regulated, is produced when 
               the key is pressed.
Autorepeat  -- String output with Autorepeat Function. If the key is 
               held down, the keyboard repeats its MakeCode with the 
               parameters selected in EDIT\REPEAT/DELAY.
Protected   -- String cannot be changed by means of ONLINE programming.
Slow Output -- Slows character output. The character output of strings 
               and hardware data (Slow Output defined in the Header) 
               are delayed according to the setting stipulated in 
               EDIT\SLOWOUTPUTSPEED.
MakeBreak   -- Key sends MakeCodes when depressed and BreakCodes when 
               released. This attribute must be specified if a <Shift> 
               key, <Ctrl> key, etc. are to be defined.
Restore     -- Levels are restored after sending. Attribute for Lock 
               functions (i.e. Ctrl Lock). If the level must be changed 
               during a string output, then the keyboard restores the 
               levels as they were before the String output.


3.1.5  Level Selection

Every change in the "level selection" sector opens up a new assignment 
level as long as it has not yet been defined.

In the Easy Mode, the levels for Normal, Shift, Ctrl and Alt can be 
defined. If, for example, a string is defined in the Ctrl level, this 
overlay is only transmitted if a Ctrl key is pressed together with the 
corresponding programmed key. The Level Standard generates a key-
assignment which behaves identically to a Standard key on a MF2 
keyboard.

The individual levels can be combined in the Expert Mode. Here, the 
subordinate conditions of active, inactive and ignore can be chosen for 
each level.

The Keyled level is only supported by the M84WX-bel. The key level is 
specified if the overlay is to be transmitted upon depressing and 
releasing. Together with the MakeBreak and Auto Repeat attributes and 
without the restore attribute, a Standard key can be defined in this way.


3.2  Module Settings

By means of EDIT\MODULES, you reach the EDIT MODULES screen, in which 
you can make all module-specific settings. Besides the assignments for 
Header and Terminator, the parameters for specific equipment can also 
be defined here. If the attribute SlowOutput is defined in the Header 
of a Module, then this also applies to the data of the module. In this 
way a possible overflow of the system buffer due to large quantities 
of data can be avoided.


3.2.1  Autoinput

The data for the optional equipment of the keyboard -- magnetic stripe 
reader (MSR), barcode reader (BCR), keylock (KL), funktionkey reader 
(FSR) and functioncard (FCR) reader is standard, with a particular 
action or change sent to the corresponding module (Autoinput). These 
functions can be turned off by means of the switch.


3.2.2  Barcode

RS232 equipment (especially the Barcode Reader) can be connected to the 
keyboard by means of the BCR/RS232 module. In this way, it is possible 
to transfer their data to the host via the keyboard interface. The EDIT 
key in the Barcode domain opens the BARCODE INTERFACE SETUP window in 
which this interface is initialized and defines the 'Initstring', which 
is sent to this interface after each Power On Reset. The following 
partial strings have special significance in the initialization string:
^^ -- The character '^'
^c -- Control Code (Bsp: ^a=\x01='.')
This function is not available with the standard BCR module.


3.2.3  Ext. Keyboard

The initialization of the keyboard connected to the optional connector 
can be disabled by means of this switch. This initialization normally 
takes place in the same way in which the host does it during the Power 
On Reset.


3.2.4  KVK Reader (German Health Card)

The desired output format can be selected in the KVK Reader area:

PC-CHIP-KVK0/keyboard version (90313-004/0000)
BA0 -- ASCII output via connection of the KVK
BA1 -- ASN.1 output after sending the command sequence EFh 26h (default)
BA2 -- ASCII output via connection of the KVK (functions faster than 
       BA0, although not with all systems)

PC-CHIP KVK2/RS232 version (90313-004/0002)
Festformat -- ASCII output after KBV-spec.
ASN.1      -- ASN.1 output after KBV-spec. (default)


3.2.5  Magnetic Card Reader

The magnetic card reader can read up to three tracks per the following 
standards:

Standard                   ISO 7811   ISO 7811   ISO 7811   JISX6302
Track                          1          2          3       JISII
Max. No. of characters        79         40        107         72
Track density/bpi            210         75        210        210
Word length without parity     6          4          4          7
Start sentinel (ASCII)       05h('%')   0Bh(';')   0Bh(';')    7Fh
End sentinel (ASCII)         1Fh('?')   0Fh('?')   0Fh('?')    7Fh

The output takes place across the keyboard interface with Scancodes, 
i.e. the data is output encoded in the same way as the keyboard input. 
A prerequisite of this is that the country setting of the keyboard 
driver (i.e. KEYB GR) agrees with the language setting of the keyboard 
(i.e. GR). The magnetic card reader channels are output in the order 
of their channel number. If a JISII channel is available, then this 
is output instead of the lowest erroneous ISO channel.

A string which outputs the channel data ahead of the Header and after 
the Terminator can be defined for each channel. The speed formatting 
of the Header is transferred with the channel data, so an overflow of 
the system buffer at high data rates can be avoided. The formatting of 
the Header and Terminator is the same as that of the key definitions. 
The basic settings for the Header and Terminator are empty strings 
(only channel strings are output).

The immediate output of the channel data after the magnetic card has 
been read can be prevented by disabling the Auto input Option. The data 
then remain stored until they are recalled by either of the command 
sequences EFh 1Ah or Efh 18h. Three command sequences which can be 
sent to the keyboard are associated with this function.

EFh 18h -- MSR Auto input on
EFh 19h -- MSR Auto input off
EFh 1Ah -- Read MSR data

The basic setting stored in the keyboard assignment is Auto input on.

The corresponding channels of the magnetic card reader can be locked 
or released by means of the Track1/2/3 keys. The Header and Terminator 
of unavailable MSR channels are also suppressed in this way.

Each magnetic card channel has a start character (Start sentinel) and 
an end indicator (End sentinel) with which the data are bracketed. 
These characters are output in the basic setting. In order to enable 
the simple handling of numerical MSR data, the Sentinels can be 
suppressed via the Sentinels key.

The checksum (XOR) encoded on the magnetic card is normally not 
transferred. The LRC (Longitudinal Redundancy Check) is also 
transferred with the established checksum, and attached to the 
end with the same ASCII convertibility as all other characters. 
Because of ASCII convertibility, with the checksum only those 
locations are valid which have been defined in terms of word-length. 
The checksum is always the same as the one coded on the card. 
If Start sentinel and End sentinel are disabled, these must be linked 
with the transferred checksum according to the standard being used, 
in order for the checksum to support the current data string.

With BadReadString a string can be defined, which is sent as a 
datastring upon a faulty reading (corrupted card, data file not 
according to standard, etc.). In the string, the token "/#" is 
replaced by the error number:
  0 -- No Start sentinel recognized
  1 -- Parity error
  2 -- Checksum error

The error code is sent with the Start- and End sentinels due to the 
preset Sentinel option.

Because of the many different kinds of modules, the parameters 
Checksum and BadReadString may not be supported by all keyboard 
types for certain magnetic card reader modules!

The output format is structured as follows:

Header1 Startsentinel1 Data1 Endsentinel1 Checksum1 Terminator1
Header2 Startsentinel2 Data2 Endsentinel2 Checksum2 Terminator2
Header3 Startsentinel3 Data3 Endsentinel3 Checksum3 Terminator3

Example:

Keyboard assignment:

M1H: "msr1"     M1T: "ende1{Return}"
M3H: "msr3"     M3T: "ende3{Return}

In the MSR sector only Track2 is disabled.

Output:

msr1%DATA1Qende1
msr3;123?4ende3

4. Online Programming

Besides programming a Preh keyboard with the PrehProgrammer or 
COPY2WX.EXE, you can also program a keyboard by means of an MF2 
attached to the daisy chain. The programming can in two Modis.
The hotkeys on the MF2 keyboard can be defined in the menus 
EDIT\HOTKEY0 or EDIT\HOTKEY1. The basic setting for HOTKEY0 is 
the SYS key (Alt+PrtSc) and for HOTKEY 1 the Ctrl+SYS 
key-combination (Ctrl+Alt+PrtSc).

String Online Programming:

In this mode, complete strings can be programmed at normal 
levels with the Keyclick attribute.

1) Press HOTKEY0 (MF2 keyboard)
2) Press the key to be programmed (Preh keyboard)
3) Input the string (MF2 keyboard)
4) Press HOTKEY0 to quit (MF2 keyboard)

Single Key Online Programming:

In this mode, a standard key is programmed by means of the 
attributes Keyclick, Autorepeat and MakeBreak.

1) Press HOTKEY0 (MF2 keyboard)
2) Press the key to be programmed (Preh keyboard)
3) Press standard key (MF2] keyboard

Online Programming works like a recorder function, i.e. all 
inputs are sent to the processor as well as being stored in 
the key assignment.


5. Examples

The following examples demonstrate the procedure for making 
simple modifications. Play around with the examples in order to 
familiarize yourself with the PrehProgrammer.

Programming key position F19 of a PCPOS as a Sys key. (PCPOS is 
connected to the processor.)

1) Start the PrehProgrammer with the command PREH-MWX.
2) Select keyboard type PCPOS with CONFIGURATION\MATRIX Size.
3) Select the language with CONFIGURATION\LANGUAGE.
4) Save the configuration with CONFIGURATION\SAVE. (2 to 4 are only 
   necessary for a new configuration)
5) Load current keytable with FILE\READ Keytable.
6) Use EDIT\EDIT KEYS to select key F19.
7) Input "{SYS}" key assignment.
8) Select Standardkey levels.
9) Turn off all attributes.
10) Confirm input with <Return>.
11) Save new keytable as an MWX data file with FILE\SAVE.
12) Load the new keytable into PCPOS with FILE\WRITE KEYTABLE.
13) Quit PrehProgrammer with FILE\EXIT.

New key assignment and programming of the key position A01 with the 
string "echo Hallo {Return}" for normal levels and "echo HALLO 
{Return}" for shift levels. (M84WX is connected to the processor.)

1) Start the PrehProgrammer with the command PREH-MWX.
2) Select keyboard type M84WX with CONFIGURATION\Matrix Size.
3) Select language with CONFIGURATION\LANGUAGE.
4) Save the configuration with CONFIGURATION\SAVE. (2 to 4 only 
   necessary for a new configuration)
5) Select key A01 with EDIT\EDIT KEYS.
6) Input assignment "echo Hallo{Return}".
7) Select normal levels.
8) Turn off all attributes.
9) Confirm input with <Return>.
6) Input assignment "echo HALLO{Return}".
7) Select shift levels.
8) Select Keyclick attribute.
9) Confirm input with <Return>.
10) Save new keytable as an MWX data file with FILE\SAVE.
11) Load new keytable into PCPOS with FILE\WRITE Keytable.
12) Quit PrehProgrammer with FILE\EXIT.


6. Glossary

Breakcode        -- Scancode of a key which is sent upon its release. 
                    The MSB of Makecodes is set here in Scanset1 or in 
                    Scanset2 an F0h is sent ahead of the Makecode.
Fat Finger Alarm -- Error Beep. Triggered if the keyboard cannot 
                    distinguish the correct sequence of two keystrokes 
                    (two keys pressed simultaneously).
Error Beep       -- Beep if a key-combination cannot be correctly 
                    transmitted (fat finger alarm, phantom key alarm).  
                    Volume and duration are globally regulatable.
Header           -- String output preceeding the data string from an  
                    equipment module. The string is defined in the same 
                    way as a key-assignment. If the attribute Slow Output 
                    has been activated, this function is also operative 
                    for the data string.
Keyclick         -- (attribute) A beep which sounds when a key is pressed. 
                    Volume and duration are globally regulatable.
KVK              -- Health insurance card.
Makecode         -- Scancode of a key which is sent when it is pressed.
MSR              -- Magnetic Strip Reader
Phantom          -- Error beep. Is triggered if in an unfavorable 
                    combination Key Alarm three keys are being pressed 
                    simultaneously.
Scanset1         -- Keycode table which can be used for Preh keyboards 
                    as well as in PC systems. The individual Scancodes 
                    of the key positions represented thereby are inde- 
                    pendent of the keyboard language. Scanset1 is used  
                    during transfers to the Host System with the XT  
                    keyboard interface.
Scanset2         -- Keycode table which is used during transfers to the 
                    host system with the AT keyboard interface. The 
                    keyboard codes are used in the AT system as Scanset1  
                    codes sent on to PC systems. The individual Scancodes  
                    represented thereby are independent of the keyboard 
                    language of the key position.
Sentinels        -- Start and end indicators on the magnetic stripe  
                    (';', '%' and '?') whose output can be suppressed.
String           -- A chain of characters. In special cases, only one 
                    character.
Terminator       -- A string which is output following a data string 
                    from an equipment module. The string is defined in 
                    the same was as a key assignmente.


7. NEW FEATURES

Starting with version 4.1.00 all functions are usable under windows 
(DOS-Box). This only works with keyboard with the Manufacture Date 
Code 5480 or higher.

This version of the PrehProgrammer supports also the MC family.

The key assignment Syntax are expanded:

- Left WIN key {LWIN}, right WIN key {RWIN} and application key {APP}
  are usable like the SHIFT, Ctrl or Alt key. E. g. {Lwin+E} will
  start the Explorer.

- Chained key combinations will be supported (e.g.{Ctrl+Alt+F12}).

- hex coded scancodes can be used in brackets with the syntax \xNN 
  (e.g. {\x1D}). The change to the scan code mode is not necessary.

- COPY2MWX.EXE is also usable under windows.

- The Menu EDIT-->Modules supports now additional modules and functions
  e.g. RS232 barcode interface, LRC and BadReadString in the new MSR.

- The matrix size will be saved in the keytable. When the PrehProgrammer 
  starts up the matrix size of the keyboard will be detected.

Attention!
----------
Some features are only supported of new manufactured keyboards.
Older keyboards will ignore the setting of this features and work 
conventionally.


