SAM Coupé to Linux Keyboard Relay

I have written several programs that allow a SAM Coupé with the Comms interface to be used as the keyboard (and mouse) for any machine running Linux with an RS232 port. These programs are:

Warning: the userevent module has possible security implications. If a user is given permissions for the /dev/userevent device, this is equivalent to handing the machine’s keyboard and mouse to that user. The user may be able to perform reboots, kill processes, etc. without the need to log in.

Licence

The drivers (and DOS) on the event.dsk are not my own work. They were Copyright © M.G.T. and SAMCo respectively. The Coupé programs (event.asm and event.bas) are in the public domain. The GNU/Linux programs (userevent, usertype and samevent) are distributed under the terms of the GNU General Public License (GPL).

Usage

To create the relay, perform the following (as root):

Pitfalls

Changes

samevent

2005-08-07 22:09:14 BST: 1.2
   Renamed to "samevent" (was "samkbd").
   Added mouse support.
   Now using "/dev/userevent".
   Updated to the userevent-1.2 protocol.
   Added "userevent.h".

2005-08-05 19:49:28 BST: 1.1
   Made the EDIT key send KEY_RIGHTALT (instead of KEY_META).
   Made the CNTRL key send KEY_LEFTALT (instead of KEY_LEFTCTRL).
   Made the SYMBOL keys send KEY_LEFTCTRL (instead of KEY_LEFTALT).

2005-08-02 00:47:13 BST: 1.0
   Initial release.

userevent

2005-08-07 22:09:14 BST: 1.2
   Renamed to "userevent" (was "usrkbd").
   Added key repeat support.
   Added mouse support.
   Now using "/dev/userevent" (was "/dev/usrkbd").
   Added "userevent.h".

2005-08-05 19:49:28 BST: 1.1
   The build script now determines the build directory using "uname -r".

2005-08-02 00:47:13 BST: 1.0
   Initial release.

usertype

2005-08-02 22:09:14: 1.1
   Renamed to "usertype" (was "kbdtype").
   Now using "/dev/userevent".
   Updated to the userevent-1.2 protocol.
   Added "userevent.h".

2005-08-02 00:47:13: 1.0
   Initial release.  Appears to miss keys ocassionally.

event.asm

2005-08-07 22:09:14 BST: 1.2
   Renamed to "event" (was "keyb").
   Added mouse support.

2005-08-05 19:49:28 BST: 1.1
   Minor cleanups.

2005-08-03 23:37:14 BST: 1.0
   Initial Release.

Stuart Brady

Valid XHTML 1.1