The Preh PS2 Linux Keyboard Driver Package installs a driver to access the
Preh Keyboards via PS2 keyboard interface of an i386 computer. This driver
is used by the Preh JavaPOS Driver for Linux and other Preh PS2 keyboard utilities.
The package contains all necessary sources files and installation
instructions needed to compile and install the Linux driver for the
Preh PS2 keyboards. In fact the driver is realized as a loadable module.
The software has been released under the term of the GPL license,
which has been included in this package.
Notes:
If your Preh keyboard is connected via USB to your computer, it is not necessary to
install this driver. In this case no special driver is needed, nor the kernel must be modified.
To install and use this loadable PS/2 keyboard driver module a modification
in the Linux kernel source and a recompile of the Linux kernel is necessary.
For details and further informations on compiling the Linux kernel we would ask
you to consult your Linux distribution's documentation and also the HOWTO
instructions on the internet. Especially as you could use several different distributions with small but important differences, we cannot give all the
informations in this installation instructions.
The Linux driver has been developed to provide simple access to the Preh PS2 keyboards and their internal modules (like MSR, keylock, PosKeys...) and can perform the following functions:
Notes:
This PS2 keyboard driver V0.1.6 is only to be used for Linux kernel 2.2 up to 2.4.x.
Beginning with kernel version 2.5 a new architecture will be built into Linux. So this driver can NOT be used for kernel 2.5.x and above.
prehdrv-0.1.6.tar.gz - Archive containing the following files:
To install the Preh PS2 Keyboard driver for Linux (i386) please follow this procedure precisely. Those basic steps have to be done:
Important Notes:
This kernel preparation only has to be done once for each kernel you
are using.
If you already have done this for the kernel used, you can go to step B
to make and install the Preh PS2 keyboard driver for Linux.
Extraversion=-preh
* kbdhook function added by Rudolf Limpert <tech-support@preh.de> 2001-11-28. * send_data() exported by Rudolf Limpert <tech-support@preh.de> 2001-11-28.
#include <linux/module.h>
/* add kbdhook function (PREH LR) 2001-11-28 */ int (*kbdhook)(unsigned char cScancode) = NULL;
if (do_acknowledge(scancode)) if((kbdhook == NULL) || !(kbdhook(scancode))) // PREH LR 2001-11-28 handle_scancode(scancode, !(scancode & 0x80));
/* added by Rudolf Limpert <tech-support@preh.de> 2001-11-28 */ EXPORT_SYMBOL(send_data); EXPORT_SYMBOL(kbdhook);
pc_keyb.o
For details and further informations on compiling the Linux kernel
we would ask you to consult your Linux distribution's documentation
and also the HOWTO instructions on the internet. Especially as you
could use several different distributions with small but important
differences, we cannot give all the informations in this installation
instructions. In the Annex you can find
some example for kernel compile steps in RedHat 8.0.
For details and further informations on compiling the Linux kernel
we would ask you to consult your Linux distribution's documentation
and also the HOWTO instructions on the internet. Especially as you
could use several different distributions with small but important
differences, we cannot give all the informations in this installation
instructions. In the Annex you can find
some example for kernel compile steps in RedHat 8.0.
Note:
If you're using the Preh PS/2 keyboard driver from within the
Preh JavaPOS package for Linux, the following steps 1..5 are
done automatically during the global JavaPOS "setup" script.
In addition you have to configure your system to load the
Preh PS/2 loadable driver module at startup. Please see the annotations below.
cd /home/user1 tar -xzvf prehdrv-0.1.6.tar.gz
cd prehdrv
make
make install
make clean
Automatically loading the driver at boot time:
In order to load the Preh PS2 keyboard driver at boot time,
you have to do some additional configuration - one of the following
lines has to be added to the list of Linux system modules to be loaded
at startup:
This is usually done in a startup configuration file:
Unload the Preh PS2 keyboard driver:
The driver can be unloaded by the following command:
make uninstall
Some useful Linux commands:
uname -a returns all information about the kernel version
/sbin/lsmod show loaded modules
After proper installation of the Preh PS2 keyboard driver you will find a module loaded named 'preh_dev'. You can check this by via /sbin/lsmod.
The Preh PS2 keyboard driver is used by Preh software for Linux, for example the Preh JavaPOS driver for Linux.
If the Preh PS2 PS2 keyboard driver is loaded, it will provide some
additonal character devices. Usually there is no need for direct access
to the devices provided by the Preh PS2 keyboard driver.
Nevertheless you can directly access the keyboard's modules by the
following device names with your own software:
Example:
To read MSR data, open the device '/dev/preh_msr', then read this device. If 0 is returned then no data is available, else a data string is available containing the MSR track data string. Close the opened device before exiting your tool.
The following text is based on the RedHat 8.0 documentation. For details and further informations on compiling the Linux kernel we would ask you to consult your Linux distribution's documentation and also the HOWTO instructions on the internet. Especially as you could use several different distributions with small but important differences, we cannot give all the informations in this installation instructions.
System Requirements: -------------------- - You must have the kernel-source package installed. - You have to be logged in as "root" How to compile the kernel: -------------------------- 1. Open a shell prompt and change to the directory /usr/src/linux-2.4. terminal: cd /usr/src/linux-2.4 All commands from this point forward must be executed from this directory. 2. It is important that you begin a kernel build with the source tree in a known condition. terminal: make mrproper 3. Create a configuration file that will determine which components to include in your new kernel) terminal: make xconfig (If you are running the X Window System) terminal: make config (An interactive text program which deos not require X Window System) terminal: make menuconfig (A text mode, menu driven program, which deos not require X Window System) terminal: make oldconfig (This is a non-interactive script that will set up your configuration file to contain the default settings) 4. Set up all the dependencies correctly. terminal: make dep 5. Prepare the source tree for the build. terminal: make clean 6. Build the kernel. terminal: make bzImage 7. Build any modules you configured. terminal: make modules 8. Install the kernel modules (even if you did not build any). terminal: make modules_install 9. Copy your new kernel and its associated files to the proper directories. terminal: make install 10. Make shure that you add the new kernel-image into your bootmanager (grub or lilo)
If you should have any problems on installing and using these drivers we of course will like to help you. Also if you have any comments or suggestions to improve our drivers and installation scripts please email to: tech-support@preh.de. Further informations and latest drivers you can find in the internet at www.preh.com