TuxScreen on SourceForge TuxScreen CVS search the Wiki
Browsing -> Wiki -> Main -> [Xfree86_and_serial_mouse]
Google
Topic:
edit, info, topics, orphans, hubs and nodes, or recent changes in the Wiki create a new user or login

TomW - June 17, 2002

Just a few notes on getting a serial mouse working on the Tux. I don't use tinyx but have opted for a full implementation of debian-ARM on the IDE drive of my Tux. Getting the serial mouse working is not difficult, first you need an XF86Config file:



# **********************************************************************
# Refer to the XF86Config(4/5) man page for details about the format of
# this file.
# **********************************************************************

Section "Files"
    RgbPath	"/usr/X11R6/lib/X11/rgb"
    FontPath   "unix/:7100"
EndSection


# **********************************************************************
# Server flags section.
# **********************************************************************

Section "ServerFlags"
#    NoTrapSignals
#    DontZap
#    DontZoom
    AllowMouseOpenFail
EndSection

# **********************************************************************
# Keyboard section
# **********************************************************************

Section "Keyboard"
    Protocol    "Standard"
#    Protocol   "Xqueue"
    AutoRepeat  250 30
    #ServerNumLock
    LeftAlt        Meta
    RightAlt       Meta
    ScrollLock     Compose
    RightCtl       Control
#    XkbDisable
# These are the default XKB settings for XFree86
#    XkbRules    "xfree86"
#    XkbModel    "pc101"
#    XkbLayout   "us"
#    XkbVariant  ""
#    XkbOptions  ""
    XkbKeycodes     "xfree86"
    XkbTypes        "default"
    XkbCompat       "default"
    XkbSymbols      "us(pc105)"
    XkbGeometry     "pc"
    XkbRules        "xfree86"
    XkbModel        "pc105"
    XkbLayout       "us"
EndSection

# **********************************************************************
# Pointer section
# **********************************************************************

Section "Pointer"
    Protocol    "Microsoft"
    Device      "/dev/ttySA0"
#    ZAxisMapping 4 5
    Emulate3Buttons
    Emulate3Timeout    50
# ChordMiddle is an option for some 3-button Logitech mice
#    ChordMiddle
EndSection


# **********************************************************************
# Monitor section
# **********************************************************************

# Any number of monitor sections may be present

Section "Monitor"
 Identifier	"Primary-Monitor"
EndSection


# **********************************************************************
# Graphics device section
# **********************************************************************

Section "Device"
 Identifier     "fbdev"
 VendorName     "fbdev"
 BoardName      "fbdev"
EndSection


# **********************************************************************
# Screen sections
# **********************************************************************


# The Colour SVGA server

Section "Screen"
 Driver        "fbdev"
 Device        "fbdev"
 Monitor       "Primary-Monitor"
 SubSection "Display"
 Depth       8
 Modes       "default"
 EndSubSection
EndSection


Next, you need to patch the kernel to allow the RTS pin of the Aux port to output a positive voltage (idle state of RTS), this is a bug in serial_sa1100.c that it doesn't initialize the modem control lines (RTS):



--- linux/drivers/serial/serial_sa1100.c.old	Mon Jun 17 02:50:45 2002
+++ linux/drivers/serial/serial_sa1100.c	Mon Jun 17 02:51:21 2002
@@ -562,6 +562,8 @@
 	 */
 	PPDR |= PPC_TXD1 | PPC_TXD3;
 	PPSR |= PPC_TXD1 | PPC_TXD3;
+		/* make GPIO_19 output a positive voltage on RTS. */
+	GPDR |= GPIO_SSP_CLK; GPCR |= GPIO_SSP_CLK;
 }
 
 void __init sa1100_register_uart_fns(struct sa1100_port_fns *fns)


That is it! You may have some trouble determining which mouse to use. I determined my mouse by hooking it up to my workstation, got it to work there, then copied the Pointer section over to the Tux XF86Config.

The mouse pointer on the screen does not move smoothly, it sort of "flutters" when you move it. I suspect that this is due to how the mouse pointer is drawn / managed by the frame buffer (XF68_FBDev).

I am not sure that tinyx will support a mouse, tinyx is a heavily hacked bit of source that was geared towards a specific use: the iPAQ. Since tinyx does not have an XF86Config file, I doubt that you can get a mouse working on it without adding more code to tinyx.



SourceForge Content of these pages are owned and copyrighted by the poster. SourceForge