You are not logged in.

#1 2010-01-12 07:32:27

karljs
Member
Registered: 2009-07-22
Posts: 10

Touchpad and HAL Policy File

I just did a fresh install of Arch on my laptop and am trying to get edge scrolling and the like working with my touchpad.  I'm using XFCE so I don't think there is software which will handle the mouse configuration for me.

I found the wiki page which describes copying the fdi file into /etc/hal/fdi/policy/ which I've done -- the problem is that this file is definitely NOT an xml file, rather a C file.  What gives?

Here's what it looks like:

/*
 * linux/include/linux/nfsd/stats.h
 *
 * Statistics for NFS server.
 *
 * Copyright (C) 1995, 1996 Olaf Kirch <okir@monad.swb.de>
 */

#ifndef LINUX_NFSD_STATS_H
#define LINUX_NFSD_STATS_H

#include <linux/nfs4.h>

/* thread usage wraps very million seconds (approx one fortnight) */
#define    NFSD_USAGE_WRAP    (HZ*1000000)

#ifdef __KERNEL__

struct nfsd_stats {
    unsigned int    rchits;        /* repcache hits */
    unsigned int    rcmisses;    /* repcache hits */
    unsigned int    rcnocache;    /* uncached reqs */
    unsigned int    fh_stale;    /* FH stale error */
    unsigned int    fh_lookup;    /* dentry cached */
    unsigned int    fh_anon;    /* anon file dentry returned */
    unsigned int    fh_nocache_dir;    /* filehandle not found in dcache */
    unsigned int    fh_nocache_nondir;    /* filehandle not found in dcache */
    unsigned int    io_read;    /* bytes returned to read requests */
    unsigned int    io_write;    /* bytes passed in write requests */
    unsigned int    th_cnt;        /* number of available threads */
    unsigned int    th_usage[10];    /* number of ticks during which n perdeciles
                     * of available threads were in use */
    unsigned int    th_fullcnt;    /* number of times last free thread was used */
    unsigned int    ra_size;    /* size of ra cache */
    unsigned int    ra_depth[11];    /* number of times ra entry was found that deep
                     * in the cache (10percentiles). [10] = not found */
#ifdef CONFIG_NFSD_V4
    unsigned int    nfs4_opcount[LAST_NFS4_OP + 1];    /* count of individual nfsv4 operations */
#endif

};


extern struct nfsd_stats    nfsdstats;
extern struct svc_stat        nfsd_svcstats;

void    nfsd_stat_init(void);
void    nfsd_stat_shutdown(void);

#endif /* __KERNEL__ */
#endif /* LINUX_NFSD_STATS_H */

update: I tried just copying and pasting some XML samples over all that stuff and it caused some very serious input problems where the mouse became nonfunctional and the keyboard button presses only worked about half the time.  Maybe the wiki is out of date?

Last edited by karljs (2010-01-12 07:41:19)

Offline

#2 2010-01-12 09:44:19

sand_man
Member
From: Australia
Registered: 2008-06-10
Posts: 2,164

Re: Touchpad and HAL Policy File

err I don't know where you got that from but here's my  /etc/hal/fdi/policy/11-x11-synaptics.fdi

<?xml version="1.0" encoding="ISO-8859-1"?>
<deviceinfo version="0.2">
  <device>
    <match key="info.product" contains="ETPS/2 Elantech Touchpad">
        <append key="info.capabilities" type="strlist">input.touchpad</append>
    </match> 
    <match key="info.capabilities" contains="input.touchpad">
        <merge key="input.x11_driver" type="string">synaptics</merge>
    <merge key="input.x11_options.TapButton1" type="string">1</merge>
    <merge key="input.x11_options.TapButton2" type="string">2</merge>
    <merge key="input.x11_options.TapButton3" type="string">3</merge>
        <!-- Arbitrary options can be passed to the driver using
             the input.x11_options property since xorg-server-1.5. -->
        <!-- EXAMPLES:
        Switch on shared memory, enables the driver to be configured at runtime
    <merge key="input.x11_options.SHMConfig" type="string">true</merge>

    Maximum movement of the finger for detecting a tap
    <merge key="input.x11_options.MaxTapMove" type="string">2000</merge>

    Enable vertical scrolling when dragging along the right edge
    <merge key="input.x11_options.VertEdgeScroll" type="string">true</merge>

    Enable vertical scrolling when dragging with two fingers anywhere on the touchpad
    <merge key="input.x11_options.VertTwoFingerScroll" type="string">true</merge>

    Enable horizontal scrolling when dragging with two fingers anywhere on the touchpad
    <merge key="input.x11_options.HorizTwoFingerScroll" type="string">true</merge>

    If on, circular scrolling is used
    <merge key="input.x11_options.CircularScrolling" type="string">true</merge>

    For other possible options, check CONFIGURATION DETAILS in synaptics man page
        -->
    </match>
  </device>
</deviceinfo>

neutral

Offline

#3 2010-01-12 14:13:24

voyciz
Member
Registered: 2010-01-07
Posts: 9

Re: Touchpad and HAL Policy File

That's a header file from the kernel source code.

...oh, and just thought I'd mention that I had trouble getting my touchpad to work correctly with HAL so I opted to just put my options in the xorg.conf file.
"man synaptics" lists all the options, assuming it's a synaptics touchpad.

Last edited by voyciz (2010-01-12 14:16:35)

Offline

#4 2010-01-14 12:30:21

rvickers
Member
Registered: 2008-11-08
Posts: 32

Re: Touchpad and HAL Policy File

voyciz, can you do me a favor and post your synaptics entry from the xorg.conf. I'm fighting a touch pad issue as well.
Thanks

Offline

#5 2010-01-14 14:28:06

voyciz
Member
Registered: 2010-01-07
Posts: 9

Re: Touchpad and HAL Policy File

Sure. Mine is very simple, I just needed to turn off the vertical edge scrolling because when I'm typing my palm passes over the touchpad and it wants to scroll all over the place.  The synaptics man page shows all the options.

Section "InputDevice"
        Identifier "Mouse0"
        Driver "synaptics"
        Option "Protocol" "auto-dev"
        Option "Device" "/dev/input/mice"
        Option "VertEdgeScroll" "False"
EndSection

Last edited by voyciz (2010-01-14 14:28:38)

Offline

#6 2010-01-14 17:11:31

perbh
Member
From: Republic of Texas
Registered: 2005-03-04
Posts: 765

Re: Touchpad and HAL Policy File

On a laptop/notebook/netbook - that friggin' touchpad drives me crazy whenever I type. I always use a cordless usb-mouse anyway.
Solution:
In /etc/rc.local just do a

 lsmod | grep -q '^pcmouse' && rmmod pcmouse

... solved all my woes

Offline

#7 2010-01-14 18:12:17

anti-destin
Member
Registered: 2009-02-14
Posts: 234

Re: Touchpad and HAL Policy File

sand_man wrote:

err I don't know where you got that from but here's my  /etc/hal/fdi/policy/11-x11-synaptics.fdi

<?xml version="1.0" encoding="ISO-8859-1"?>
<deviceinfo version="0.2">
  <device>
    <match key="info.product" contains="ETPS/2 Elantech Touchpad">
        <append key="info.capabilities" type="strlist">input.touchpad</append>
    </match> 
    <match key="info.capabilities" contains="input.touchpad">
        <merge key="input.x11_driver" type="string">synaptics</merge>
    <merge key="input.x11_options.TapButton1" type="string">1</merge>
    <merge key="input.x11_options.TapButton2" type="string">2</merge>
    <merge key="input.x11_options.TapButton3" type="string">3</merge>
        <!-- Arbitrary options can be passed to the driver using
             the input.x11_options property since xorg-server-1.5. -->
        <!-- EXAMPLES:
        Switch on shared memory, enables the driver to be configured at runtime
    <merge key="input.x11_options.SHMConfig" type="string">true</merge>

    Maximum movement of the finger for detecting a tap
    <merge key="input.x11_options.MaxTapMove" type="string">2000</merge>

    Enable vertical scrolling when dragging along the right edge
    <merge key="input.x11_options.VertEdgeScroll" type="string">true</merge>

    Enable vertical scrolling when dragging with two fingers anywhere on the touchpad
    <merge key="input.x11_options.VertTwoFingerScroll" type="string">true</merge>

    Enable horizontal scrolling when dragging with two fingers anywhere on the touchpad
    <merge key="input.x11_options.HorizTwoFingerScroll" type="string">true</merge>

    If on, circular scrolling is used
    <merge key="input.x11_options.CircularScrolling" type="string">true</merge>

    For other possible options, check CONFIGURATION DETAILS in synaptics man page
        -->
    </match>
  </device>
</deviceinfo>

does vertical scrolling work for you? i copied the fdi file, but vertical scrolling doesn't work for me.

Offline

#8 2010-01-15 00:23:48

n1xx
Member
From: Melbroune
Registered: 2010-01-14
Posts: 2
Website

Re: Touchpad and HAL Policy File

anti-destin,
Did you try to remove comment below?

 <merge key="input.x11_options.VertEdgeScroll" type="string">true</merge>

You should read http://wiki.archlinux.org/index.php/Tou … _scrolling wink


Never stop programming smile
blog - http://blog.n1xx.net
micro - http://identi.ca/n1xx

Offline

#9 2010-01-15 14:51:50

anti-destin
Member
Registered: 2009-02-14
Posts: 234

Re: Touchpad and HAL Policy File

doesn't that line need to be present, though? i read the wiki, and it looks like you need to have that line in the fdi file.

in any case, i've found that two-finger scrolling works out of the box and is just as good.

Last edited by anti-destin (2010-01-15 14:52:08)

Offline

#10 2010-01-16 08:57:21

NeoXP
Member
From: MS Matrix
Registered: 2009-01-09
Posts: 206
Website

Re: Touchpad and HAL Policy File

Atm I have things configured in xorg, but I'm working on switching to hal (still working on the keyboard). Anyways, last time I checked this was working for me:

<?xml version="1.0" encoding="ISO-8859-1"?>
<deviceinfo version="0.2">
  <device>
    <match key="info.capabilities" contains="input.touchpad">
      <match key="info.product" contains="Synaptics TouchPad">
        <merge key="input.x11_driver" type="string">synaptics</merge>
      </match>
      <match key="info.product" contains="AlpsPS/2 ALPS">
        <merge key="input.x11_driver" type="string">synaptics</merge>
      </match>
      <match key="info.product" contains="appletouch">
        <merge key="input.x11_driver" type="string">synaptics</merge>
      </match>
      <match key="info.product" contains="bcm5974">
        <merge key="input.x11_driver" type="string">synaptics</merge>
      </match>

      <merge key="input.x11_options.MinSpeed" type="double">0.1</merge>
      <merge key="input.x11_options.MaxSpeed" type="double">0.4</merge>
      <merge key="input.x11_options.AccelFactor" type="double">0.0010</merge>

      <merge key="input.x11_options.SHMConfig" type="string">on</merge>

      <merge key="input.x11_options.TapButton1" type="string">1</merge>
      <merge key="input.x11_options.TapButton2" type="string">2</merge>
      <merge key="input.x11_options.TapButton3" type="string">3</merge>
      <merge key="input.x11_options.FastTaps" type="string">1</merge>

      <merge key="input.x11_options.VertEdgeScroll" type="string">true</merge>
      <merge key="input.x11_options.VerteScrollDelta" type="string">2</merge>
      <merge key="input.x11_options.VertTwoFingerScroll" type="string">true</merge>

      <merge key="input.x11_options.HorizEdgeScroll" type="string">true</merge>
      <merge key="input.x11_options.HorizScrollDelta" type="string">2</merge>
      <merge key="input.x11_options.HorizTwoFingerScroll" type="string">true</merge>

      <merge key="input.x11_options.LeftEdge" type="string">2000</merge>
      <merge key="input.x11_options.TopEdge" type="string">2000</merge>

    </match>
  </device>
</deviceinfo>

Note 1: I also use two-finger scrolling.
Note 2: I haven't tested it yet since upgrading from kernel 2.6.31 to 2.6.32.


Arch x86_64 on HP 6820s and on HP nx9420. Registered Linux User 350155, since 24-03-2004
"Everyone said that it could not be done, until someone came along who didn't know that."

Offline

Board footer

Powered by FluxBB