Re: [DNG] mouse driver question

2022-05-13 Thread Fred

Hi Karl,

On 5/13/22 03:22, k...@aspodata.se wrote:

Fred:

On 5/12/22 15:23, Florian Zieboll via Dng wrote:

On May 12, 2022 9:44:39 PM GMT+02:00, Fred  wrote:

I don't use a DE, just openbox and xterm.  The regular scroll wheel
mouse works correctly in both xev and the application.  Button 2 is
identified as 2 so I contend it has to have something to do with
program(s) run to use the serial mouse.

xmodmap -pp shows the buttons mapped correctly with both mice.

The Xorg.log file has entries for USB Optical Mouse, Mouse Systems
mouse and Sun mouse (when I gave that protocol to inputattach and
gpm) but nothing about mouse buttons.


Then I'm more or less at loss what to do, save make an adapter for my
sun mouse try it at home.

If you are willing to work on it I can send you my adapter.  I can 
easily make another one.  I assume you are in Sweden.  You could send a 
mailing address off-list.


Best regards,
Fred


...

There's just one question itching me for a
little while now: Is it possible, that this
old mouse simply has some physical
issue, triggered by using button 2?

And if so, what would be the best way to
prove it?


He has already proven it.


No, the mouse is fine.  I have an application that I have used for 20
years running on Solaris 2.6.  The Sun is retired but I still need the
application.  I was able to get it to compile and run happily on Devuan
Beowulf and it works fine with the standard pc scroll wheel mouse.  The
program makes extensive use of the middle button which is a pain with
the pc mouse.  I would like to continue using the Sun three button mouse
which works except the middle button.  I have studied the output of the
mouse with an oscilloscope and software and it is working exactly as a
Mouse Systems mouse.  There is some defugalty in getting the middle
button information into user programs.  Maybe a bug somewhere?


There have been some changes over the years, e.g. xlib replaced by xcb.

This might not be related, but this little test program didn't work (segfault)
with devuan/debian libXt but it workes fine in gentoo:
  http://aspodata.se/computing/librnd_motif/Shell_Size_Constraint/
it also workes fine in debian woody and when rebuilding libXt in previous
devuan version, so it might be something shady in current devuan/debian libxt.

If this is really important to you, you could try to
. rebuild libxt
. install another distro, eg. gentoo
. try an older version of debian, e.g. potato, woody or sarge

Regards,
/Karl Hammar


___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-05-13 Thread karl
Fred:
> On 5/12/22 15:23, Florian Zieboll via Dng wrote:
> > On May 12, 2022 9:44:39 PM GMT+02:00, Fred  wrote:
> >> I don't use a DE, just openbox and xterm.  The regular scroll wheel
> >> mouse works correctly in both xev and the application.  Button 2 is
> >> identified as 2 so I contend it has to have something to do with
> >> program(s) run to use the serial mouse.
> >>
> >> xmodmap -pp shows the buttons mapped correctly with both mice.
> >>
> >> The Xorg.log file has entries for USB Optical Mouse, Mouse Systems
> >> mouse and Sun mouse (when I gave that protocol to inputattach and
> >> gpm) but nothing about mouse buttons.

Then I'm more or less at loss what to do, save make an adapter for my
sun mouse try it at home.

...
> > There's just one question itching me for a
> > little while now: Is it possible, that this
> > old mouse simply has some physical
> > issue, triggered by using button 2?
> > 
> > And if so, what would be the best way to
> > prove it?

He has already proven it.

> No, the mouse is fine.  I have an application that I have used for 20 
> years running on Solaris 2.6.  The Sun is retired but I still need the 
> application.  I was able to get it to compile and run happily on Devuan 
> Beowulf and it works fine with the standard pc scroll wheel mouse.  The 
> program makes extensive use of the middle button which is a pain with 
> the pc mouse.  I would like to continue using the Sun three button mouse 
> which works except the middle button.  I have studied the output of the 
> mouse with an oscilloscope and software and it is working exactly as a 
> Mouse Systems mouse.  There is some defugalty in getting the middle 
> button information into user programs.  Maybe a bug somewhere?

There have been some changes over the years, e.g. xlib replaced by xcb.

This might not be related, but this little test program didn't work (segfault)
with devuan/debian libXt but it workes fine in gentoo:
 http://aspodata.se/computing/librnd_motif/Shell_Size_Constraint/
it also workes fine in debian woody and when rebuilding libXt in previous
devuan version, so it might be something shady in current devuan/debian libxt.

If this is really important to you, you could try to
. rebuild libxt
. install another distro, eg. gentoo
. try an older version of debian, e.g. potato, woody or sarge

Regards,
/Karl Hammar


___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-05-12 Thread Fred

On 5/12/22 15:23, Florian Zieboll via Dng wrote:



On May 12, 2022 9:44:39 PM GMT+02:00, Fred  wrote:


Hi Karl,
I don't use a DE, just openbox and xterm.  The regular scroll wheel mouse works 
correctly in both xev and the application.  Button 2 is identified as 2 so I 
contend it has to have something to do with program(s) run to use the serial 
mouse.

xmodmap -pp shows the buttons mapped correctly with both mice.

The Xorg.log file has entries for USB Optical Mouse, Mouse Systems mouse and 
Sun mouse (when I gave that protocol to inputattach and gpm) but nothing about 
mouse buttons.
Best regards,
Fred



A very interesting thread, never have I
been so close to hardware!

There's just one question itching me for a
little while now: Is it possible, that this
old mouse simply has some physical
issue, triggered by using button 2?

And if so, what would be the best way to
prove it?

libre Grüße,
Florian



Hi Florian,
No, the mouse is fine.  I have an application that I have used for 20 
years running on Solaris 2.6.  The Sun is retired but I still need the 
application.  I was able to get it to compile and run happily on Devuan 
Beowulf and it works fine with the standard pc scroll wheel mouse.  The 
program makes extensive use of the middle button which is a pain with 
the pc mouse.  I would like to continue using the Sun three button mouse 
which works except the middle button.  I have studied the output of the 
mouse with an oscilloscope and software and it is working exactly as a 
Mouse Systems mouse.  There is some defugalty in getting the middle 
button information into user programs.  Maybe a bug somewhere?


Best regards,
Fred

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-05-12 Thread Florian Zieboll via Dng


On May 12, 2022 9:44:39 PM GMT+02:00, Fred  wrote:

> Hi Karl,
> I don't use a DE, just openbox and xterm.  The regular scroll wheel mouse 
> works correctly in both xev and the application.  Button 2 is identified as 2 
> so I contend it has to have something to do with program(s) run to use the 
> serial mouse.
> 
> xmodmap -pp shows the buttons mapped correctly with both mice.
> 
> The Xorg.log file has entries for USB Optical Mouse, Mouse Systems mouse and 
> Sun mouse (when I gave that protocol to inputattach and gpm) but nothing 
> about mouse buttons.
> Best regards,
> Fred


A very interesting thread, never have I
been so close to hardware! 

There's just one question itching me for a 
little while now: Is it possible, that this 
old mouse simply has some physical 
issue, triggered by using button 2? 

And if so, what would be the best way to 
prove it?

libre Grüße,
Florian


-- 

[message sent otg]



___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-05-12 Thread Fred

On 5/12/22 03:15, k...@aspodata.se wrote:

Fred:
...

With xev, buttons 1 and 3 are correctly identified but the middle button
is randomly assigned 4,5,6 or 7.  Possibly this is the problem as I know
the application is expecting button 2.


Maybe it is the desktop environment or the window manager that messes
this up.

Try installing and using fvwm1 or something of similar age instead of
what you are using currently and do the same test, or if you know how,
run bare Xorg.

///

It can also be the xserver config if you happens to have a xorg.conf
that is picked up by X. Configs like buttonmapping and things related
to emulateweel can mess this up. Look in man evdev (or man mousedrv).

  Look in your X11 log file for clues:
$ man xorg | grep -A8 ' -logfile'
-logfile filename
Use  the file called filename as the Xorg server log file.  The
default log file when running as  root  is  /var/log/Xorg.n.log
and  for  non root it is $XDG_DATA_HOME/xorg/Xorg.n.log where n
is the display number of the Xorg server.  The default  may  be
in  a  different  directory  on some platforms.  This option is
only available when the server is run as root (i.e, with  real-
uid 0).

Regards,
/Karl Hammar


___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng

Hi Karl,
I don't use a DE, just openbox and xterm.  The regular scroll wheel 
mouse works correctly in both xev and the application.  Button 2 is 
identified as 2 so I contend it has to have something to do with 
program(s) run to use the serial mouse.


xmodmap -pp shows the buttons mapped correctly with both mice.

The Xorg.log file has entries for USB Optical Mouse, Mouse Systems mouse 
and Sun mouse (when I gave that protocol to inputattach and gpm) but 
nothing about mouse buttons.

Best regards,
Fred
___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-05-12 Thread karl
Fred:
...
> With xev, buttons 1 and 3 are correctly identified but the middle button 
> is randomly assigned 4,5,6 or 7.  Possibly this is the problem as I know 
> the application is expecting button 2.

Maybe it is the desktop environment or the window manager that messes
this up.

Try installing and using fvwm1 or something of similar age instead of
what you are using currently and do the same test, or if you know how,
run bare Xorg.

///

It can also be the xserver config if you happens to have a xorg.conf
that is picked up by X. Configs like buttonmapping and things related
to emulateweel can mess this up. Look in man evdev (or man mousedrv).

 Look in your X11 log file for clues:
$ man xorg | grep -A8 ' -logfile'
   -logfile filename
   Use  the file called filename as the Xorg server log file.  The
   default log file when running as  root  is  /var/log/Xorg.n.log
   and  for  non root it is $XDG_DATA_HOME/xorg/Xorg.n.log where n
   is the display number of the Xorg server.  The default  may  be
   in  a  different  directory  on some platforms.  This option is
   only available when the server is run as root (i.e, with  real-
   uid 0).

Regards,
/Karl Hammar


___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-05-12 Thread Daniel Abrecht via Dng
To find out what's behind which /dev/input/event* device, and generally 
what's going on with the input stuff on the kernel side, I usually 
check: "cat /proc/bus/input/devices"




___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-05-11 Thread Fred

Hi Karl,

On 5/11/22 08:23, k...@aspodata.se wrote:

Fred:

On 5/11/22 05:02, k...@aspodata.se wrote:



You should be able to do lsinput from input-utils package to see which
/dev/input/inputX file your mouse's byte stream transformed as events
would appear. And then run input-events X to see the events. E.g.:

# lsinput | tail
open /dev/input/event11: No such device or address

/dev/input/event10
 bustype : BUS_I8042
 vendor  : 0x2
 product : 0xa
 version : 0
 name: "TPPS/2 IBM TrackPoint"
 phys: "isa0060/serio1/input0"
 bits ev : (null) (null) (null)

Why did you pick event10?


Because that where the mouse is as shown by the lsinput output.


I have event0 to 21 also mice and mouse0 in that directory.
The reason I asked is that when I ran your command line I got one 
paragraph with the name"ALSA".  My mouse is tied to event0 whether pc 
mouse or Sun.



Run lsinput and choose.

Here ia another example:

# modprobe  sermouse
# ./inputattach --daemon --mouseman /dev/ttyS0
# tail -2 /var/log/all
May 11 15:01:30 zoisit user.info kernel: [15477.331554] input: Logitech M+ 
Mouse as /devices/pnp0/00:01/tty/ttyS0/serio3/input/input19
May 11 15:01:30 zoisit user.info kernel: [15477.332229] serio: Serial port ttyS0
# lsinput | tail
open /dev/input/event18: No such device or address

/dev/input/event17
bustype : BUS_RS232
vendor  : 0x4
product : 0x1
version : 256
name: "Logitech M+ Mouse"
phys: "ttyS0/serio0/input0"
bits ev : (null) (null) (null)

# input-events 17
/dev/input/event17
bustype : BUS_RS232
vendor  : 0x4
product : 0x1
version : 256
name: "Logitech M+ Mouse"
phys: "ttyS0/serio0/input0"
bits ev : (null) (null) (null)

waiting for events
15:13:30.888773: (null) ??? (0x112) pressed
15:13:30.888773: (null) code=0 value=0
15:13:32.998688: (null) ??? -1
15:13:32.998688: (null) code=0 value=0
15:13:33.061029: (null) ??? -1
15:13:33.061029: (null) code=0 value=0
15:13:33.560736: (null) ??? 1
15:13:33.560736: (null) code=0 value=0
15:13:33.583775: (null) ??? 3
15:13:33.583775: (null) code=0 value=0
15:13:33.591262: (null) ??? 3
15:13:33.591262: (null) code=0 value=0
15:13:33.614295: (null) ??? 1
15:13:33.614295: (null) code=0 value=0
15:13:33.621787: (null) ??? 2
15:13:33.621787: (null) code=0 value=0
15:13:34.191695: (null) ??? 1
15:13:34.191695: (null) code=0 value=0
15:13:34.302401: (null) ??? 1
15:13:34.302401: (null) code=0 value=0
15:13:34.553504: (null) ??? (0x112) released
15:13:34.553504: (null) code=0 value=0
...

Here above we can see the middle button pressed, the mouse moved, and
the button released.
input-events produces essentially the same as you show.  All three 
buttons work similarly.




I think we are barking up the wrong tree here.  The application sees the
button because the pointer freezes when it is pressed.  What is missing
is X and Y movement info. while the button is pressed.


With the above example we can check if that is true.

Another way to test this is to use xev. Start xev, move the mouse xev's
window, press button, move, release, check the result:

ButtonPress event, serial 33, synthetic NO, window 0x321,
 root 0x4d3, subw 0x0, time 243503614, (56,88), root:(360,300),
 state 0x0, button 1, same_screen YES

MotionNotify event, serial 33, synthetic NO, window 0x321,
 root 0x4d3, subw 0x0, time 243504966, (57,88), root:(361,300),
 state 0x100, is_hint 0, same_screen YES

MotionNotify event, serial 33, synthetic NO, window 0x321,
 root 0x4d3, subw 0x0, time 243504989, (59,89), root:(363,301),
 state 0x100, is_hint 0, same_screen YES

MotionNotify event, serial 33, synthetic NO, window 0x321,
 root 0x4d3, subw 0x0, time 243505012, (60,90), root:(364,302),
 state 0x100, is_hint 0, same_screen YES

ButtonRelease event, serial 33, synthetic NO, window 0x321,
 root 0x4d3, subw 0x0, time 243505908, (60,90), root:(364,302),
 state 0x100, button 1, same_screen YES

Regards,
/Karl Hammar


___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng
With xev, buttons 1 and 3 are correctly identified but the middle button 
is randomly assigned 4,5,6 or 7.  Possibly this is the problem as I know 
the application is expecting button 2.


Best regards,
Fred

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-05-11 Thread karl
Fred:
> On 5/11/22 05:02, k...@aspodata.se wrote:

> > You should be able to do lsinput from input-utils package to see which
> > /dev/input/inputX file your mouse's byte stream transformed as events
> > would appear. And then run input-events X to see the events. E.g.:
> > 
> > # lsinput | tail
> > open /dev/input/event11: No such device or address
> > 
> > /dev/input/event10
> > bustype : BUS_I8042
> > vendor  : 0x2
> > product : 0xa
> > version : 0
> > name: "TPPS/2 IBM TrackPoint"
> > phys: "isa0060/serio1/input0"
> > bits ev : (null) (null) (null)
> Why did you pick event10?

Because that where the mouse is as shown by the lsinput output.

> I have event0 to 21 also mice and mouse0 in that directory.

Run lsinput and choose.

Here ia another example:

# modprobe  sermouse
# ./inputattach --daemon --mouseman /dev/ttyS0
# tail -2 /var/log/all
May 11 15:01:30 zoisit user.info kernel: [15477.331554] input: Logitech M+ 
Mouse as /devices/pnp0/00:01/tty/ttyS0/serio3/input/input19
May 11 15:01:30 zoisit user.info kernel: [15477.332229] serio: Serial port ttyS0
# lsinput | tail
open /dev/input/event18: No such device or address

/dev/input/event17
   bustype : BUS_RS232
   vendor  : 0x4
   product : 0x1
   version : 256
   name: "Logitech M+ Mouse"
   phys: "ttyS0/serio0/input0"
   bits ev : (null) (null) (null)

# input-events 17
/dev/input/event17
   bustype : BUS_RS232
   vendor  : 0x4
   product : 0x1
   version : 256
   name: "Logitech M+ Mouse"
   phys: "ttyS0/serio0/input0"
   bits ev : (null) (null) (null)

waiting for events
15:13:30.888773: (null) ??? (0x112) pressed
15:13:30.888773: (null) code=0 value=0
15:13:32.998688: (null) ??? -1
15:13:32.998688: (null) code=0 value=0
15:13:33.061029: (null) ??? -1
15:13:33.061029: (null) code=0 value=0
15:13:33.560736: (null) ??? 1
15:13:33.560736: (null) code=0 value=0
15:13:33.583775: (null) ??? 3
15:13:33.583775: (null) code=0 value=0
15:13:33.591262: (null) ??? 3
15:13:33.591262: (null) code=0 value=0
15:13:33.614295: (null) ??? 1
15:13:33.614295: (null) code=0 value=0
15:13:33.621787: (null) ??? 2
15:13:33.621787: (null) code=0 value=0
15:13:34.191695: (null) ??? 1
15:13:34.191695: (null) code=0 value=0
15:13:34.302401: (null) ??? 1
15:13:34.302401: (null) code=0 value=0
15:13:34.553504: (null) ??? (0x112) released
15:13:34.553504: (null) code=0 value=0
...

Here above we can see the middle button pressed, the mouse moved, and
the button released.

> I think we are barking up the wrong tree here.  The application sees the 
> button because the pointer freezes when it is pressed.  What is missing 
> is X and Y movement info. while the button is pressed.

With the above example we can check if that is true.

Another way to test this is to use xev. Start xev, move the mouse xev's 
window, press button, move, release, check the result:

ButtonPress event, serial 33, synthetic NO, window 0x321,
root 0x4d3, subw 0x0, time 243503614, (56,88), root:(360,300),
state 0x0, button 1, same_screen YES

MotionNotify event, serial 33, synthetic NO, window 0x321,
root 0x4d3, subw 0x0, time 243504966, (57,88), root:(361,300),
state 0x100, is_hint 0, same_screen YES

MotionNotify event, serial 33, synthetic NO, window 0x321,
root 0x4d3, subw 0x0, time 243504989, (59,89), root:(363,301),
state 0x100, is_hint 0, same_screen YES

MotionNotify event, serial 33, synthetic NO, window 0x321,
root 0x4d3, subw 0x0, time 243505012, (60,90), root:(364,302),
state 0x100, is_hint 0, same_screen YES

ButtonRelease event, serial 33, synthetic NO, window 0x321,
root 0x4d3, subw 0x0, time 243505908, (60,90), root:(364,302),
state 0x100, button 1, same_screen YES

Regards,
/Karl Hammar


___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-05-11 Thread Fred

Hi Karl,

On 5/11/22 05:02, k...@aspodata.se wrote:

Fred:
...

The Sun Compact 1 three button mouse is 1200 baud, 8 data bits, no
parity and sends 5 bytes in Mouse Systems protocol.  Byte 0 is button
info. exactly the same as msc.  Byte 1 is 8 bit signed X movement. Byte
2 is 8 bit signed Y movement.  Bytes 3, 4 are zero.


That fits the Mousesystems protocol as described in man mouse.

...

The problem seems to be that movement info. is not being sent or is
incorrect when the middle button is down.  The inputattach program
appears to be decoding the mouse protocol so I think that is where the
problem is.  I am not a C programmer so I can't determine what is wrong.

...

If I look at utils/inputattach.c from
  https://sourceforge.net/projects/linuxconsole/files/latest/download

inputattach does
. option handling
. sets the line discipline:
   ldisc = N_MOUSE;
   if (ioctl(fd, TIOCSETD, ) < 0) {
. sets the device type (e.g. it's a MSC mouse)
   ioctl(fd, SPIOCSTYPE, )
. goes into the background (daemon())
. stays there just emptying the input buffer of the serial port

So, inputattach does not decode the byte stream from the mouse.
Instead it seems that the kernels drivers/input/mouse/sermouse.c
does that. Look in the
  static void sermouse_process_msc(struct sermouse *sermouse, signed char data)
function.

So... the "input" way is too buggy. Why not consider the deprecated X11
mouse driver.

///

You should be able to do lsinput from input-utils package to see which
/dev/input/inputX file your mouse's byte stream transformed as events
would appear. And then run input-events X to see the events. E.g.:

# lsinput | tail
open /dev/input/event11: No such device or address

/dev/input/event10
bustype : BUS_I8042
vendor  : 0x2
product : 0xa
version : 0
name: "TPPS/2 IBM TrackPoint"
phys: "isa0060/serio1/input0"
bits ev : (null) (null) (null)

Why did you pick event10?
I have event0 to 21 also mice and mouse0 in that directory.



# input-events -t 100 10
/dev/input/event10
bustype : BUS_I8042
vendor  : 0x2
product : 0xa
version : 0
name: "TPPS/2 IBM TrackPoint"
phys: "isa0060/serio1/input0"
bits ev : (null) (null) (null)

waiting for events
11:58:57.217543: (null) ??? (0x110) pressed
11:58:57.217543: (null) code=0 value=0
11:58:57.356137: (null) ??? (0x110) released
11:58:57.356137: (null) code=0 value=0
11:58:59.084678: (null) ??? (0x112) pressed
11:58:59.084678: (null) code=0 value=0
11:58:59.225056: (null) ??? (0x112) released
11:58:59.225056: (null) code=0 value=0
11:58:59.613730: (null) ??? (0x111) pressed
11:58:59.613730: (null) code=0 value=0
11:58:59.689984: (null) ??? (0x111) released
11:58:59.689984: (null) code=0 value=0
^C
#

Where I pressed the left, middle and lastly right button on my laptop.

Regards,
/Karl Hammar

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng
I think we are barking up the wrong tree here.  The application sees the 
button because the pointer freezes when it is pressed.  What is missing 
is X and Y movement info. while the button is pressed.


Best regards,
Fred
___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-05-11 Thread karl
Fred:
...
> The Sun Compact 1 three button mouse is 1200 baud, 8 data bits, no 
> parity and sends 5 bytes in Mouse Systems protocol.  Byte 0 is button 
> info. exactly the same as msc.  Byte 1 is 8 bit signed X movement. Byte 
> 2 is 8 bit signed Y movement.  Bytes 3, 4 are zero.

That fits the Mousesystems protocol as described in man mouse.

...
> The problem seems to be that movement info. is not being sent or is 
> incorrect when the middle button is down.  The inputattach program 
> appears to be decoding the mouse protocol so I think that is where the 
> problem is.  I am not a C programmer so I can't determine what is wrong.
...

If I look at utils/inputattach.c from
 https://sourceforge.net/projects/linuxconsole/files/latest/download

inputattach does
. option handling
. sets the line discipline:
  ldisc = N_MOUSE;
  if (ioctl(fd, TIOCSETD, ) < 0) {
. sets the device type (e.g. it's a MSC mouse)
  ioctl(fd, SPIOCSTYPE, )
. goes into the background (daemon())
. stays there just emptying the input buffer of the serial port

So, inputattach does not decode the byte stream from the mouse.
Instead it seems that the kernels drivers/input/mouse/sermouse.c
does that. Look in the 
 static void sermouse_process_msc(struct sermouse *sermouse, signed char data)
function.

So... the "input" way is too buggy. Why not consider the deprecated X11 
mouse driver.

///

You should be able to do lsinput from input-utils package to see which
/dev/input/inputX file your mouse's byte stream transformed as events
would appear. And then run input-events X to see the events. E.g.:

# lsinput | tail
open /dev/input/event11: No such device or address

/dev/input/event10
   bustype : BUS_I8042
   vendor  : 0x2
   product : 0xa
   version : 0
   name: "TPPS/2 IBM TrackPoint"
   phys: "isa0060/serio1/input0"
   bits ev : (null) (null) (null)

# input-events -t 100 10
/dev/input/event10
   bustype : BUS_I8042
   vendor  : 0x2
   product : 0xa
   version : 0
   name: "TPPS/2 IBM TrackPoint"
   phys: "isa0060/serio1/input0"
   bits ev : (null) (null) (null)

waiting for events
11:58:57.217543: (null) ??? (0x110) pressed
11:58:57.217543: (null) code=0 value=0
11:58:57.356137: (null) ??? (0x110) released
11:58:57.356137: (null) code=0 value=0
11:58:59.084678: (null) ??? (0x112) pressed
11:58:59.084678: (null) code=0 value=0
11:58:59.225056: (null) ??? (0x112) released
11:58:59.225056: (null) code=0 value=0
11:58:59.613730: (null) ??? (0x111) pressed
11:58:59.613730: (null) code=0 value=0
11:58:59.689984: (null) ??? (0x111) released
11:58:59.689984: (null) code=0 value=0
^C
#

Where I pressed the left, middle and lastly right button on my laptop.

Regards,
/Karl Hammar

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-05-10 Thread Fred

On 4/27/22 15:40, k...@aspodata.se wrote:

Fred:
...

In spare time I am building a board to convert mouse output to RS232.  I
did research on this in 2011.  I found a program I wrote (for embedded
controller) to watch serial port and show mouse bytes on lcd.  I don't
know yet if it was finished or works.  Viewing the mouse output with an
oscilloscope shows it is definitely 1200 baud and appears to be 8 data
bits odd parity and one stop bit.  The mouse is sending 5 bytes.


I made a program that "spied" on a serial port, reporting all bytes
coming in and out from a serial port. It worked by using pty's.
It has seen some bitrot, but perhaps I can shape it up during the
summer.

In the meantime, you could watch the input bytes by doing

# stty -F /dev/ttyS4 1200 cs8 raw
# cat /dev/ttyS4 | od -t x1  # and then move the mouse
000 40 01 00 4c 3d 4c 05 3f 4c 04 3f 02 3f 40 00 01
020 40 01 01 40 02 03 40 02 40 03 40 00 04 43 3d 06
040 43 3c 06 43 3b 06 43 3b 04 43 3d 01 40 00 01 43
060 3f 00 4f 3f 3f 4f 3f 3f 4f 3e 3f 4f 3f 3c 3d 4f
100 3b 4f 3d 4f 3f 4c 00 3f 4c 00 3f 4c 01 3f 4c 01
^C

# cat /dev/ttyS4 | od -t x1 # pressing the right button
000 40 00 50 00 00 40 00 00 50 00 40 00 50 00 40 00
020 50 00 00 40 00 00 50 00 40 00 00 50 00 40 00 50
^C

# cat /dev/ttyS4 | od -t x1 # pressing the left button
000 60 00 40 00 00 60 00 40 00 00 60 00 00 40 00 60
020 00 40 00 00 60 00 40 00 00 60 00 40 00 60 00 40
^C

od waits to fill one line before it writes out anything.

  Descriptions of mouse protocols are available here:
https://courses.cs.washington.edu/courses/cse477/00sp/projectwebs/groupb/PS2-mouse/mouse.html
https://www.kryslix.com/nsfaq/Q.12.html
man mouse


I tried gpm again in a VT.  The left button highlights a single
character or lines.  The right button highlights lines from the last
left button click.  The middle button prints the character that was
under the cursor at last left button click.


$ man gpm
  ...
OPERATION
To select text press the left mouse button and drag the mouse.
To paste text in the same or another console, press the middle button.
The right button is used to extend the selection, like in `xterm'.

Soo, it works as adverticed above ?
Then the problem is that the input subsystem is doing the wrong things
(i.e. in the kernel git repo, drivers/input/mouse/sermouse.c needs some
fix) or it is been set up wrongly.


I think inputattach is actually doing what it is supposed to do but is
telling the application something different from what the standard
scroll wheel pc mouse does.


inputattach is just setting up the kernel to read and translate the
mouse packets. The packets then appear somewhere at /dev/input/
which X11 reads.

Regards,
/Karl Hammar

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng

Hi,
The Sun Compact 1 three button mouse is 1200 baud, 8 data bits, no 
parity and sends 5 bytes in Mouse Systems protocol.  Byte 0 is button 
info. exactly the same as msc.  Byte 1 is 8 bit signed X movement. Byte 
2 is 8 bit signed Y movement.  Bytes 3, 4 are zero.


In the application I need to use the Sun mouse, the PC mouse works 
correctly in that with the middle button down objects can be moved 
around.  With the Sun mouse the pointer freezes with the middle button down.


In nedit, with the PC mouse pointer on the scroll thingy on the side the 
text smooth scrolls.  With the Sun mouse the text jump scrolls one line 
at a time.


The problem seems to be that movement info. is not being sent or is 
incorrect when the middle button is down.  The inputattach program 
appears to be decoding the mouse protocol so I think that is where the 
problem is.  I am not a C programmer so I can't determine what is wrong.


Best regards,
Fred

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-27 Thread karl
Fred:
...
> In spare time I am building a board to convert mouse output to RS232.  I 
> did research on this in 2011.  I found a program I wrote (for embedded 
> controller) to watch serial port and show mouse bytes on lcd.  I don't 
> know yet if it was finished or works.  Viewing the mouse output with an 
> oscilloscope shows it is definitely 1200 baud and appears to be 8 data 
> bits odd parity and one stop bit.  The mouse is sending 5 bytes.

I made a program that "spied" on a serial port, reporting all bytes
coming in and out from a serial port. It worked by using pty's.
It has seen some bitrot, but perhaps I can shape it up during the
summer.

In the meantime, you could watch the input bytes by doing

# stty -F /dev/ttyS4 1200 cs8 raw
# cat /dev/ttyS4 | od -t x1  # and then move the mouse
000 40 01 00 4c 3d 4c 05 3f 4c 04 3f 02 3f 40 00 01
020 40 01 01 40 02 03 40 02 40 03 40 00 04 43 3d 06
040 43 3c 06 43 3b 06 43 3b 04 43 3d 01 40 00 01 43
060 3f 00 4f 3f 3f 4f 3f 3f 4f 3e 3f 4f 3f 3c 3d 4f
100 3b 4f 3d 4f 3f 4c 00 3f 4c 00 3f 4c 01 3f 4c 01
^C

# cat /dev/ttyS4 | od -t x1 # pressing the right button
000 40 00 50 00 00 40 00 00 50 00 40 00 50 00 40 00
020 50 00 00 40 00 00 50 00 40 00 00 50 00 40 00 50
^C

# cat /dev/ttyS4 | od -t x1 # pressing the left button
000 60 00 40 00 00 60 00 40 00 00 60 00 00 40 00 60
020 00 40 00 00 60 00 40 00 00 60 00 40 00 60 00 40
^C

od waits to fill one line before it writes out anything.

 Descriptions of mouse protocols are available here:
https://courses.cs.washington.edu/courses/cse477/00sp/projectwebs/groupb/PS2-mouse/mouse.html
https://www.kryslix.com/nsfaq/Q.12.html
man mouse

> I tried gpm again in a VT.  The left button highlights a single 
> character or lines.  The right button highlights lines from the last 
> left button click.  The middle button prints the character that was 
> under the cursor at last left button click.

$ man gpm
 ...
OPERATION
   To select text press the left mouse button and drag the mouse.
   To paste text in the same or another console, press the middle button.
   The right button is used to extend the selection, like in `xterm'.

Soo, it works as adverticed above ?
Then the problem is that the input subsystem is doing the wrong things
(i.e. in the kernel git repo, drivers/input/mouse/sermouse.c needs some
fix) or it is been set up wrongly.

> I think inputattach is actually doing what it is supposed to do but is 
> telling the application something different from what the standard 
> scroll wheel pc mouse does.

inputattach is just setting up the kernel to read and translate the
mouse packets. The packets then appear somewhere at /dev/input/
which X11 reads.

Regards,
/Karl Hammar

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-27 Thread Fred

Hi Karl,

On 4/25/22 15:09, k...@aspodata.se wrote:

Fred:

On 4/25/22 10:17, k...@aspodata.se wrote:

...

I am using the DLP-TXRX-G usb/serial adapter with a transistor to invert
the mouse output.  The mouse has an active high output and the dlp rx
input is active low.


  This one:
http://www.dlpdesign.com/usb/txrx.php
seems to be ttl, not rs232 levels/signals.


I forgot to say in the previous message that x and y movement and
buttons 1 and 3 all work normally.  Only the middle button doesn't work.


Well, half a victory!


I have some hardware that would be fairly easy to have read in the mouse
signals and display the bytes.  I will do this over the next few days
and it should be possible to determine the exact protocol.


Nice.

Regards,
/Karl Hammar

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


I tried inputattach with the sun protocol and the results were the same, 
pointer freeze with button2 down.


In spare time I am building a board to convert mouse output to RS232.  I 
did research on this in 2011.  I found a program I wrote (for embedded 
controller) to watch serial port and show mouse bytes on lcd.  I don't 
know yet if it was finished or works.  Viewing the mouse output with an 
oscilloscope shows it is definitely 1200 baud and appears to be 8 data 
bits odd parity and one stop bit.  The mouse is sending 5 bytes.


I tried gpm again in a VT.  The left button highlights a single 
character or lines.  The right button highlights lines from the last 
left button click.  The middle button prints the character that was 
under the cursor at last left button click.


I think inputattach is actually doing what it is supposed to do but is 
telling the application something different from what the standard 
scroll wheel pc mouse does.

Best regards,
Fred
___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-25 Thread karl
Fred:
> On 4/25/22 10:17, k...@aspodata.se wrote:
...
> I am using the DLP-TXRX-G usb/serial adapter with a transistor to invert 
> the mouse output.  The mouse has an active high output and the dlp rx 
> input is active low.

 This one:
http://www.dlpdesign.com/usb/txrx.php
seems to be ttl, not rs232 levels/signals.

> I forgot to say in the previous message that x and y movement and 
> buttons 1 and 3 all work normally.  Only the middle button doesn't work.

Well, half a victory!

> I have some hardware that would be fairly easy to have read in the mouse 
> signals and display the bytes.  I will do this over the next few days 
> and it should be possible to determine the exact protocol.

Nice.

Regards,
/Karl Hammar

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-25 Thread Fred

On 4/25/22 10:17, k...@aspodata.se wrote:

Fred:
...

  I ran gpm-mouse-test again.  That program seems to have major
problems.  It can't even detect the baud rate which I know to be 1200.

...

I tested it here and it succesfully detected my MouseMan at 1200baud.

It can be that your serial to usb converter confuses the program because
usb delivers bytes in a different way, in packets, not one byte at a time.

I might make a din-8 (aka sun mouse if.) to rs232 converter within the
month. If so I'll report back to you.

Regards,
/Karl Hammar

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng

Hi Karl,

I am using the DLP-TXRX-G usb/serial adapter with a transistor to invert 
the mouse output.  The mouse has an active high output and the dlp rx 
input is active low.


I forgot to say in the previous message that x and y movement and 
buttons 1 and 3 all work normally.  Only the middle button doesn't work.


I have some hardware that would be fairly easy to have read in the mouse 
signals and display the bytes.  I will do this over the next few days 
and it should be possible to determine the exact protocol.


Best regards,
Fred

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-25 Thread Fred

On 4/25/22 10:17, k...@aspodata.se wrote:

Nick:

On 25-04-2022 16:20, Fred wrote:

...

The compile went ok.  I used command line:
inputattach --daemon --baud 1200 -msc /dev/ttyUSB0
It accepted the baud rate option this time however the middle button
still does not work.  The pointer freezes when the middle button is
down.


So, everything works, except the middle button ?

Just checking, is this one in the kernel:

# grep MOUSE_SERIAL /boot/config-`uname -r`
CONFIG_MOUSE_SERIAL=y


The response is:  CONFIG_MOUSE_SERIAL=m


If done as a module, you need to
modprobe sermouse


This produced no response.


I ran gpm-mouse-test again.  That program seems to have major
problems.  It can't even detect the baud rate which I know to be 1200.

...

Forget about that program then, it doesn't help you.


Looking at inputattach man page could you give the option

*-ms*,*--mshack*
 3-button mouse in Microsoft mode.

a try?


Cannot say much about that, but there is a -sun variant also.
You have to try around.
I will try the sun protocol later today and maybe a few others.  I am 
not good a guessing games.




///

If you cannot make inputattach to work, you can
. go for the old mouse driver and edit xorg.conf
. reverse engineer the protocol used and make code to handle that

Regards,
/Karl Hammar



___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Best regards,
Fred
___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-25 Thread karl
Fred:
...
>  I ran gpm-mouse-test again.  That program seems to have major 
> problems.  It can't even detect the baud rate which I know to be 1200.
...

I tested it here and it succesfully detected my MouseMan at 1200baud.

It can be that your serial to usb converter confuses the program because
usb delivers bytes in a different way, in packets, not one byte at a time.

I might make a din-8 (aka sun mouse if.) to rs232 converter within the 
month. If so I'll report back to you.

Regards,
/Karl Hammar

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-25 Thread karl
Nick:
> On 25-04-2022 16:20, Fred wrote:
...
> > The compile went ok.  I used command line:
> > inputattach --daemon --baud 1200 -msc /dev/ttyUSB0
> > It accepted the baud rate option this time however the middle button 
> > still does not work.  The pointer freezes when the middle button is 
> > down.

So, everything works, except the middle button ?

Just checking, is this one in the kernel:

# grep MOUSE_SERIAL /boot/config-`uname -r`
CONFIG_MOUSE_SERIAL=y

If done as a module, you need to
modprobe sermouse

> > I ran gpm-mouse-test again.  That program seems to have major 
> > problems.  It can't even detect the baud rate which I know to be 1200.
...

Forget about that program then, it doesn't help you.

> Looking at inputattach man page could you give the option
> 
> *-ms*,*--mshack*
> 3-button mouse in Microsoft mode.
> 
> a try?

Cannot say much about that, but there is a -sun variant also.
You have to try around.

///

If you cannot make inputattach to work, you can
. go for the old mouse driver and edit xorg.conf
. reverse engineer the protocol used and make code to handle that

Regards,
/Karl Hammar


___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-25 Thread d...@d404.nl

On 25-04-2022 16:20, Fred wrote:

On 4/25/22 02:39, k...@aspodata.se wrote:

Fred:
...

The compile fails because SDL.h can't be found.
Package sd12 was not found in the pkg-config search path.  It also
mentions adding directory containing sd12.pc to the PKG-CONFIG_PATH
environment variable.


To find which package a missing file belongs to, do:

# apt-get install apt-file

$ apt-file search SDL.h
$ apt-file search sdl2.h

///

   I get:
$ apt-file -x search /SDL.h$
libsdl1.2-dev: /usr/include/SDL/SDL.h
libsdl2-dev: /usr/include/SDL2/SDL.h
$ apt-file search /sdl2.pc
libsdl2-dev: /usr/lib/x86_64-linux-gnu/pkgconfig/sdl2.pc

So, the above problem is solved by installing libsdl2-dev.

Regards,
/Karl Hammar

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng

Hi Karl,
The compile went ok.  I used command line:
inputattach --daemon --baud 1200 -msc /dev/ttyUSB0
It accepted the baud rate option this time however the middle button 
still does not work.  The pointer freezes when the middle button is 
down.  I ran gpm-mouse-test again.  That program seems to have major 
problems.  It can't even detect the baud rate which I know to be 1200.

Best regards,
Fred

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Hi Fred,

Looking at inputattach man page could you give the option

*-ms*,*--mshack*
   3-button mouse in Microsoft mode.

a try?

Grtz.

Nick
___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-25 Thread Fred

On 4/25/22 02:39, k...@aspodata.se wrote:

Fred:
...

The compile fails because SDL.h can't be found.
Package sd12 was not found in the pkg-config search path.  It also
mentions adding directory containing sd12.pc to the PKG-CONFIG_PATH
environment variable.


To find which package a missing file belongs to, do:

# apt-get install apt-file

$ apt-file search SDL.h
$ apt-file search sdl2.h

///

   I get:
$ apt-file -x search /SDL.h$
libsdl1.2-dev: /usr/include/SDL/SDL.h
libsdl2-dev: /usr/include/SDL2/SDL.h
$ apt-file search /sdl2.pc
libsdl2-dev: /usr/lib/x86_64-linux-gnu/pkgconfig/sdl2.pc

So, the above problem is solved by installing libsdl2-dev.

Regards,
/Karl Hammar

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng

Hi Karl,
The compile went ok.  I used command line:
inputattach --daemon --baud 1200 -msc /dev/ttyUSB0
It accepted the baud rate option this time however the middle button 
still does not work.  The pointer freezes when the middle button is 
down.  I ran gpm-mouse-test again.  That program seems to have major 
problems.  It can't even detect the baud rate which I know to be 1200.

Best regards,
Fred

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-25 Thread karl
Fred:
...
> The compile fails because SDL.h can't be found.
> Package sd12 was not found in the pkg-config search path.  It also 
> mentions adding directory containing sd12.pc to the PKG-CONFIG_PATH 
> environment variable.

To find which package a missing file belongs to, do:

# apt-get install apt-file

$ apt-file search SDL.h
$ apt-file search sdl2.h

///

  I get:
$ apt-file -x search /SDL.h$
libsdl1.2-dev: /usr/include/SDL/SDL.h 
libsdl2-dev: /usr/include/SDL2/SDL.h
$ apt-file search /sdl2.pc
libsdl2-dev: /usr/lib/x86_64-linux-gnu/pkgconfig/sdl2.pc

So, the above problem is solved by installing libsdl2-dev.

Regards,
/Karl Hammar

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-24 Thread Fred

On 4/24/22 13:56, k...@aspodata.se wrote:

Fred:

On 4/23/22 12:53, k...@aspodata.se wrote:

...

If so, press Ctl-Alt-F2 buttons simultaineusly to get to a console.
There log in as root
and then try one of
gpm -b 1200 -m /dev/ttyUSB0 -t msc
gpm -b 1200 -m /dev/ttyUSB0 -t sun
gpm -b 1200 -m /dev/ttyUSB0 -t mman
and move the mouse to test.


This works.  The msc protocol works best, the mman protocol doesn't work
at all.  All three buttons show some effect.


Very good.

...

B, try inputattach to make the mouse appear as a /dev/input/* device
 and be automatically included by X11, I haven't tested this. See

 https://wiki.archlinux.org/title/Serial_input_device_to_kernel_input
 https://sourceforge.net/projects/linuxconsole/files/
 https://help.ubuntu.com/community/SerialMouseHowto
 https://wiki.alpinelinux.org/wiki/Serial_Mouse

...

There is some progress. The inputattach package in Devuan apparently
doesn't have a config file.  Specifying the baud on the command line
results in an invalid baud message. inputattach does work with the Sun
mouse but the middle button doesn't work.  I tried msc and sun protocol
and both work the same.  I may try some other protocols but I suspect a
bug in inputattach.  Maybe I should contact the maintainer?


I have no experience with inputattach, but looking at
utils/inputattach.c from
  https://sourceforge.net/projects/linuxconsole/files/latest/download
around line 1163:

switch(baud[i]) {
case -1: break;
case 2400: type[i]->speed = B2400; break;
case 4800: type[i]->speed = B4800; break;
case 9600: type[i]->speed = B9600; break;
case 19200: type[i]->speed = B19200; break;
case 38400: type[i]->speed = B38400; break;
case 115200: type[i]->speed = B115200; break;
default:
fprintf(stderr, "inputattach: invalid baud rate '%d'\n",
baud[i]);
return EXIT_FAILURE;
}

and

$ grep -A2 msc inputattach.c
{ "--mousesystems", "-msc", "3-button Mouse Systems mouse",
 B1200, CS8,
 SERIO_MSC,  0x00,   0x01,   1,  NULL },

So, yes, you found a bug.

Add this before the "case 2400" line:

case 1200: type[i]->speed = B1200; break;

compile and test.

Regards,
/Karl Hammar


Hi Karl,

The compile fails because SDL.h can't be found.
Package sd12 was not found in the pkg-config search path.  It also 
mentions adding directory containing sd12.pc to the PKG-CONFIG_PATH 
environment variable.


Best regards,
Fred
___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-24 Thread karl
Fred:
...
> The middle button is being seen as the pointer won't move when it is 
> held down.  It would appear the application is being told something 
> different than when the standard pc mouse is used.

It is probably because you were forced to set the wron baudrate.

Regards,
/Karl Hammar

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-24 Thread karl
Fred:
> On 4/23/22 12:53, k...@aspodata.se wrote:
...
> > If so, press Ctl-Alt-F2 buttons simultaineusly to get to a console.
> > There log in as root
> > and then try one of
> >gpm -b 1200 -m /dev/ttyUSB0 -t msc
> >gpm -b 1200 -m /dev/ttyUSB0 -t sun
> >gpm -b 1200 -m /dev/ttyUSB0 -t mman
> > and move the mouse to test.
> > 
> This works.  The msc protocol works best, the mman protocol doesn't work 
> at all.  All three buttons show some effect.

Very good.

...
> > B, try inputattach to make the mouse appear as a /dev/input/* device
> > and be automatically included by X11, I haven't tested this. See
> > 
> > https://wiki.archlinux.org/title/Serial_input_device_to_kernel_input
> > https://sourceforge.net/projects/linuxconsole/files/
> > https://help.ubuntu.com/community/SerialMouseHowto
> > https://wiki.alpinelinux.org/wiki/Serial_Mouse
...
> There is some progress. The inputattach package in Devuan apparently 
> doesn't have a config file.  Specifying the baud on the command line 
> results in an invalid baud message. inputattach does work with the Sun 
> mouse but the middle button doesn't work.  I tried msc and sun protocol 
> and both work the same.  I may try some other protocols but I suspect a 
> bug in inputattach.  Maybe I should contact the maintainer?

I have no experience with inputattach, but looking at
utils/inputattach.c from
 https://sourceforge.net/projects/linuxconsole/files/latest/download
around line 1163:

switch(baud[i]) {
case -1: break;
case 2400: type[i]->speed = B2400; break;
case 4800: type[i]->speed = B4800; break;
case 9600: type[i]->speed = B9600; break;
case 19200: type[i]->speed = B19200; break;
case 38400: type[i]->speed = B38400; break;
case 115200: type[i]->speed = B115200; break;
default:
fprintf(stderr, "inputattach: invalid baud rate '%d'\n",
baud[i]);
return EXIT_FAILURE;
}

and

$ grep -A2 msc inputattach.c 
{ "--mousesystems", "-msc", "3-button Mouse Systems mouse",
B1200, CS8,
SERIO_MSC,  0x00,   0x01,   1,  NULL },

So, yes, you found a bug.

Add this before the "case 2400" line:

case 1200: type[i]->speed = B1200; break;

compile and test.

Regards,
/Karl Hammar


___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-24 Thread Fred

On 4/24/22 10:49, Fred wrote:

Hi,

On 4/23/22 12:53, k...@aspodata.se wrote:

Fred:

On 4/23/22 02:34, k...@aspodata.se wrote:

...

So, make sure you are running in a virtual console and logged in as
root, then run the gpm -b etc. thing and move the mouse around.

To make the mouse to work in X11, please test the mouse with gpm in
a console first to assert basic functionality, and then come back.


Did you do the test above ?

As long the serial port isn't opened by anything,
you can let X11 and openbox be running.

If so, press Ctl-Alt-F2 buttons simultaineusly to get to a console.
There log in as root
and then try one of
   gpm -b 1200 -m /dev/ttyUSB0 -t msc
   gpm -b 1200 -m /dev/ttyUSB0 -t sun
   gpm -b 1200 -m /dev/ttyUSB0 -t mman
and move the mouse to test.

This works.  The msc protocol works best, the mman protocol doesn't work 
at all.  All three buttons show some effect.



A previous post mentioned xorg.conf which doesn't appear to exist in
Devuan Beowulf (AMD64).
So, where do I go from here?


You can either
A, do a xorg configuration with the mouse driver
    man xorg.conf is your friend.

B, try inputattach to make the mouse appear as a /dev/input/* device
    and be automatically included by X11, I haven't tested this. See

    https://wiki.archlinux.org/title/Serial_input_device_to_kernel_input
    https://sourceforge.net/projects/linuxconsole/files/
    https://help.ubuntu.com/community/SerialMouseHowto
    https://wiki.alpinelinux.org/wiki/Serial_Mouse

Regards,
/Karl Hammar

There is some progress. The inputattach package in Devuan apparently 
doesn't have a config file.  Specifying the baud on the command line 
results in an invalid baud message. inputattach does work with the Sun 
mouse but the middle button doesn't work.  I tried msc and sun protocol 
and both work the same.  I may try some other protocols but I suspect a 
bug in inputattach.  Maybe I should contact the maintainer?


Best regards,
Fred

The middle button is being seen as the pointer won't move when it is 
held down.  It would appear the application is being told something 
different than when the standard pc mouse is used.


Best regards,
Fred
___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-24 Thread Fred

Hi,

On 4/23/22 12:53, k...@aspodata.se wrote:

Fred:

On 4/23/22 02:34, k...@aspodata.se wrote:

...

So, make sure you are running in a virtual console and logged in as
root, then run the gpm -b etc. thing and move the mouse around.

To make the mouse to work in X11, please test the mouse with gpm in
a console first to assert basic functionality, and then come back.


Did you do the test above ?

As long the serial port isn't opened by anything,
you can let X11 and openbox be running.

If so, press Ctl-Alt-F2 buttons simultaineusly to get to a console.
There log in as root
and then try one of
   gpm -b 1200 -m /dev/ttyUSB0 -t msc
   gpm -b 1200 -m /dev/ttyUSB0 -t sun
   gpm -b 1200 -m /dev/ttyUSB0 -t mman
and move the mouse to test.

This works.  The msc protocol works best, the mman protocol doesn't work 
at all.  All three buttons show some effect.



A previous post mentioned xorg.conf which doesn't appear to exist in
Devuan Beowulf (AMD64).
So, where do I go from here?


You can either
A, do a xorg configuration with the mouse driver
man xorg.conf is your friend.

B, try inputattach to make the mouse appear as a /dev/input/* device
and be automatically included by X11, I haven't tested this. See

https://wiki.archlinux.org/title/Serial_input_device_to_kernel_input
https://sourceforge.net/projects/linuxconsole/files/
https://help.ubuntu.com/community/SerialMouseHowto
https://wiki.alpinelinux.org/wiki/Serial_Mouse

Regards,
/Karl Hammar

There is some progress. The inputattach package in Devuan apparently 
doesn't have a config file.  Specifying the baud on the command line 
results in an invalid baud message. inputattach does work with the Sun 
mouse but the middle button doesn't work.  I tried msc and sun protocol 
and both work the same.  I may try some other protocols but I suspect a 
bug in inputattach.  Maybe I should contact the maintainer?


Best regards,
Fred

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-24 Thread Arnt Karlsen
On Sat, 23 Apr 2022 21:11:18 +0200, Florian wrote in message 
<2022042328.14e36a59.f.zieb...@web.de>:

> Some time ago, in a similar situation, I had been successful with
> 
> $ find / | grep xorg.conf
> 
> Also worth a try:
> 
> $ man 5 xorg.conf


..also worth trying:~$ man -k xorg.conf

...and the educational: $ man -h  # ;o)


-- 
..med vennlig hilsen = with Kind Regards from Arnt Karlsen
...with a number of polar bear hunters in his ancestry...
  Scenarios always come in sets of three: 
  best case, worst case, and just in case.
___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-24 Thread aitor

On 24/4/22 13:52, aitor wrote:

but enable it when using vdev.


*disable*


___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-24 Thread aitor

Hi Ralph,

On 23/4/22 23:32, Ralph Ronnquist wrote:

Then, I think the X11 system relies on udev for setting up its inputs
and load the appropriate modules. You may take over that and do things
"by hand" by a) making the following file /etc/X11/xorg.conf.d/a.conf

Section "ServerFlags"
 Option "AutoAddDevices" "false"
EndSection



X11-common contains a file config/udev.c and -if i'm not mistaken- as 
long as the sources are built enabling CONFIG_UDEV, the above option 
"AutoAddDevices" is set up to true by default. On the contrary, vdev 
requires the following setup to get both the keyboard and mouse working:


Section "ServerFlags"     Option "AutoAddDevices" "off"     Option 
"AllowEmptyInput" "on" (either "off") EndSection


I don't think this configuration would work with eudev, because I guess 
that "AutoAddDevices" is required to carry out udev monitor's event 
processing (libudev-enumerate.c). On the contrary, vdev removes the 
netlink connection to udev, in favor of creating the underlying 
`udev_monitor`specific directory:


* /dev/events/libudev-$PID

watched by vdev's helpers for new packet events. This is the way vdev 
works. So, libudev-compat (vdev) connects to a netlink socket only if 
the name is "kernel" and removes this netlink connection if the name is 
"udev", because vdevd's helper scripts will send serialized device 
events by writing them as files (here, Jude Nelson recommends the 
installation of eventfs).


It's because libeudev and libudev-compat work with opposing approaches, 
my recommendation is to not disable "AutoAddDevices" when using eudev, 
but enable it when using vdev.


Cheers,

Aitor.


___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-24 Thread karl
Fred:
...
> I also don't like the beetle wings for buttons one and three because
> I am often accidentally clicking button three.
...

Yes, it is wery annoying when you accidentally press button three.

Regards,
/Karl Hammar

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-24 Thread karl
Ralph Ronnquist:
...
> I think all mice are supposed to be handled by the kernel and will
> then get presented at /dev/input/mice
...

At some level every hardware is handled by the kernel. What you are
talking about is the input subsystem. To make a serial mouse work
or use the input subsystem you have to do an inputattach so the mouse
attached at /dev/ttySx is available as /dev/input/mouseY.

As you kan see in the kernel source/drivers/input/mouse/sermouse.c,
in function
 static void sermouse_process_msc(struct sermouse *sermouse, signed char data)
it takes the protocol and converts it to another protocol.

For that function to work you need it be configured in the kernel, 
build in or as a module. This command should return y or m.

# grep MOUSE_SERIAL /boot/config-`uname -r`
CONFIG_MOUSE_SERIAL=y

If done as a module, you need to
 modprobe sermouse

After that you do the inputattach of the serial port.
At this stage you need to know the protocol used, there is no
autodetection.

It is in a sense similar to the gpm repeater mode.

> Section "ServerFlags"
> Option "AutoAddDevices" "false"
> EndSection

I.e. either you do it all by yourself, or you use hw that can be auto 
detected, there is no midpoint, like auto detect gpu and monitor, but 
use this mouse...

Yea, thanks x devs. for ditching us with unusual hw.

> and b) installing xserver-xorg-input-kbd and xserver-xorg-input-mouse
...

Thoose two drivers are abandoned upstream from what I heard.

Regards,
/Karl Hammar


___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-24 Thread karl
Fred:
...
> If gpm only works in a virtual terminal why do I need to continue 
> working with it?  I don't use a virtual terminal.
...

Since it is such a simple test to do, e.g. you don't have to restart
the X server to try another protocol.

Regards,
/Karl Hammar

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-23 Thread wirelessduck--- via Dng


> On 24 Apr 2022, at 12:23, Olaf Meeuwissen via Dng  wrote:
> 
> Hi,
> 
> Antony Stone  writes:
> 
>>> On Saturday 23 April 2022 at 22:57:12, Florian Zieboll via Dng wrote:
>>> 
>>> On Sat, 23 Apr 2022 21:15:34 +0200 Antony Stone wrote:
 On Saturday 23 April 2022 at 21:11:18, Florian Zieboll via Dng wrote:
 
> Some time ago, in a similar situation, I had been successful with
> 
> $ find / | grep xorg.conf
 
 Personally I'd have gone for:
find / -name xorg.conf
>>> 
>>> I may be wrong (and nitpicking;) - but I think that your approach is
>>> less fast, as 'find' does the file name matching /before/ it continues
>>> searching - in opposite to just piping its output to grep and going on
>>> with running down the file system hierarchy without any interruption.
>> 
>> Interesting - and you're right.
>> 
>> I just tried several successive searches for a few unique filenames in a
>> directory tree (all files in the same directory, just in case the position 
>> made
>> a difference).
>> 
>> The first search took 6 minutes and clearly set up some cache of results,
>> because subsequent searches were consistently:
>> 
>>find . | grep filename : 20 seconds
>> 
>>find . -name filename : 25 seconds
>> 
>> That was consistent no matter whether the two filenames were the same, or
>> different but still in the same directory, and no matter which command was 
>> run
>> first.
>> 
>> Nice observation.
> 
> Indeed but you must have an awful lot of files, slow disks and/or a slow
> network connection.  After setting up the cache on my machine, I get 0.7
> seconds for the -name approach and 0.5 seconds for grep.
> That's with close to half a million filesystem entries and about 7000 of
> those on an NFS backed filesystem on the NAS downstairs.  The rest is on
> an SSD (NVMe).
> 
> Another point, the grep approach also lists everything below a directory
> that matches, whereas the -name approach does not.  That may be a lot of
> extra junk to scan through depending on what you're looking for.
> That's also why I suggested redirecting errors to /dev/null when looking
> for stuff below / as a normal user ;-)
> 
> Hope this helps,
> --
> Olaf Meeuwissen

How does this speed compare to mlocate or whatever is the preferred version of 
locate database these days?

-- 
Tom
___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-23 Thread Olaf Meeuwissen via Dng
Hi,

Antony Stone  writes:

> On Saturday 23 April 2022 at 22:57:12, Florian Zieboll via Dng wrote:
>
>> On Sat, 23 Apr 2022 21:15:34 +0200 Antony Stone wrote:
>> > On Saturday 23 April 2022 at 21:11:18, Florian Zieboll via Dng wrote:
>> >
>> > > Some time ago, in a similar situation, I had been successful with
>> > >
>> > > $ find / | grep xorg.conf
>> >
>> > Personally I'd have gone for:
>> >find / -name xorg.conf
>>
>> I may be wrong (and nitpicking;) - but I think that your approach is
>> less fast, as 'find' does the file name matching /before/ it continues
>> searching - in opposite to just piping its output to grep and going on
>> with running down the file system hierarchy without any interruption.
>
> Interesting - and you're right.
>
> I just tried several successive searches for a few unique filenames in a
> directory tree (all files in the same directory, just in case the position 
> made
> a difference).
>
> The first search took 6 minutes and clearly set up some cache of results,
> because subsequent searches were consistently:
>
>   find . | grep filename : 20 seconds
>
>   find . -name filename : 25 seconds
>
> That was consistent no matter whether the two filenames were the same, or
> different but still in the same directory, and no matter which command was run
> first.
>
> Nice observation.

Indeed but you must have an awful lot of files, slow disks and/or a slow
network connection.  After setting up the cache on my machine, I get 0.7
seconds for the -name approach and 0.5 seconds for grep.
That's with close to half a million filesystem entries and about 7000 of
those on an NFS backed filesystem on the NAS downstairs.  The rest is on
an SSD (NVMe).

Another point, the grep approach also lists everything below a directory
that matches, whereas the -name approach does not.  That may be a lot of
extra junk to scan through depending on what you're looking for.
That's also why I suggested redirecting errors to /dev/null when looking
for stuff below / as a normal user ;-)

Hope this helps,
--
Olaf MeeuwissenFSF Associate Member since 2004-01-27
 GnuPG key: F84A2DD9/B3C0 2F47 EA19 64F4 9F13  F43E B8A4 A88A F84A 2DD9
 Support Free Softwarehttps://my.fsf.org/donate
 Join the Free Software Foundation  https://my.fsf.org/join
___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-23 Thread Fred

On 4/23/22 12:53, k...@aspodata.se wrote:

Fred:

On 4/23/22 02:34, k...@aspodata.se wrote:

...

So, make sure you are running in a virtual console and logged in as
root, then run the gpm -b etc. thing and move the mouse around.

To make the mouse to work in X11, please test the mouse with gpm in
a console first to assert basic functionality, and then come back.


Did you do the test above ?

As long the serial port isn't opened by anything,
you can let X11 and openbox be running.

If so, press Ctl-Alt-F2 buttons simultaineusly to get to a console.
There log in as root
and then try one of
   gpm -b 1200 -m /dev/ttyUSB0 -t msc
   gpm -b 1200 -m /dev/ttyUSB0 -t sun
   gpm -b 1200 -m /dev/ttyUSB0 -t mman
and move the mouse to test.


A previous post mentioned xorg.conf which doesn't appear to exist in
Devuan Beowulf (AMD64).
So, where do I go from here?


You can either
A, do a xorg configuration with the mouse driver
man xorg.conf is your friend.

B, try inputattach to make the mouse appear as a /dev/input/* device
and be automatically included by X11, I haven't tested this. See

https://wiki.archlinux.org/title/Serial_input_device_to_kernel_input
https://sourceforge.net/projects/linuxconsole/files/
https://help.ubuntu.com/community/SerialMouseHowto
https://wiki.alpinelinux.org/wiki/Serial_Mouse

Regards,
/Karl Hammar





___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng
It is going to take me a few days to get back to try your suggestions. 
I am drowning in things to do.


If gpm only works in a virtual terminal why do I need to continue 
working with it?  I don't use a virtual terminal.


I had previously looked for xorg.conf in /etc/X11 where one would expect 
a config. file to be.  I did find one at 
/usr/share/doc/xserver-xorg-video-intel/xorg.conf.  It had a single 
entry and didn't appear likely to be read for mouse configuration.


Best regards,
Fred
___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-23 Thread Fred

On 4/23/22 15:26, Hendrik Boom wrote:

On Fri, Apr 22, 2022 at 12:19:45PM -0700, Fred wrote:


The mouse is a Sun three button mouse without the scroll wheel.  I
frequently use a program that makes extensive use of the middle button and
the pc mouse scroll wheel is hateful.


I would like a mouse with a middle button *and* a scroll wheel.
So there's no ambiguity as to which I am using.
I've never seen one.

-- hendrik
___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng
I would be very happy with that.  The scroll wheel should never have 
been included with the middle button but it is cheaper to build that way 
and that is more important than ergonomics.  I also don't like the 
beetle wings for buttons one and three because I am often accidentally 
clicking button three.  The Sun mouse has three buttons with spacing 
between to rest your fingers.


Best regards,
Fred

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-23 Thread Florian Zieboll via Dng
On Sat, 23 Apr 2022 18:26:59 -0400
Hendrik Boom  wrote:

> I would like a mouse with a middle button *and* a scroll wheel.
> So there's no ambiguity as to which I am using.
> I've never seen one.


Out of curiosity, I just did a quick websearch for four+button+mouse -
there are dozens of options out there. It should be easy to disable the
"wheel click" with libinput's 'ButtonMapping' option. 

At home, I use a trackball with four buttons, which has the additional
advantage of living in peace with the tea cup on my narrow desk -_-

libre Grüße,
Florian
___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-23 Thread Hendrik Boom
On Fri, Apr 22, 2022 at 12:19:45PM -0700, Fred wrote:

> The mouse is a Sun three button mouse without the scroll wheel.  I
> frequently use a program that makes extensive use of the middle button and
> the pc mouse scroll wheel is hateful.

I would like a mouse with a middle button *and* a scroll wheel.
So there's no ambiguity as to which I am using.
I've never seen one.

-- hendrik
___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-23 Thread Antony Stone
On Saturday 23 April 2022 at 22:57:12, Florian Zieboll via Dng wrote:

> On Sat, 23 Apr 2022 21:15:34 +0200 Antony Stone wrote:
> > On Saturday 23 April 2022 at 21:11:18, Florian Zieboll via Dng wrote:
> >  
> > > Some time ago, in a similar situation, I had been successful with
> > > 
> > > $ find / | grep xorg.conf
> > 
> > Personally I'd have gone for:
> > find / -name xorg.conf
> 
> I may be wrong (and nitpicking;) - but I think that your approach is
> less fast, as 'find' does the file name matching /before/ it continues
> searching - in opposite to just piping its output to grep and going on
> with running down the file system hierarchy without any interruption.

Interesting - and you're right.

I just tried several successive searches for a few unique filenames in a 
directory tree (all files in the same directory, just in case the position made 
a difference).

The first search took 6 minutes and clearly set up some cache of results, 
because subsequent searches were consistently:

find . | grep filename : 20 seconds

find . -name filename : 25 seconds

That was consistent no matter whether the two filenames were the same, or 
different but still in the same directory, and no matter which command was run 
first.

Nice observation.


Antony.

-- 
The more 'success' you get, the easier it is to be disappointed by not getting 
things.
The only difference is that now no-one feels sorry for you.

 - Matt Haig

   Please reply to the list;
 please *don't* CC me.
___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-23 Thread Ralph Ronnquist
On Sat, Apr 23, 2022 at 09:07:57AM -0700, Fred wrote:
> On 4/23/22 02:34, k...@aspodata.se wrote:
> > Fred:
> > > On 4/22/22 15:31, k...@aspodata.se wrote:
> > ...
> > > >gpm -b 1200 -m /dev/ttyS1 -t msc
> > ...
> > > It shows up at /dev/ttyUSB0.  I have tried that command line several
> > > times.  Nothing happens.  ps -e shows gpm is running.  The pointer will
> > > not move and the mouse buttons have no effect.
> > ...
> > 
> > You have to be aware that gpm is for virtual consoles:
> > 
> > $ man gpm | grep 'gpm - '
> > gpm - a cut and paste utility and mouse server for virtual consoles
> > 
> > So in X11, openbox etc. graphical environment, it has no effect unless
> > you take special action. With graphical environment I mean bitmapped as
> > opposed to character (i.e. letters) based graphics.
> > 
> > Testing with gpm is best done without X11, so stop your window manager
> > (obenbox) and exit from X11. If you then is presented with a greeter
> > (also called display manager, see
> >   https://en.wikipedia.org/wiki/X_display_manager_(program_type)
> > ), see if you can stop the greeter.
> > 
> > Also testing has to be done as root.
> > 
> > So, make sure you are running in a virtual console and logged in as
> > root, then run the gpm -b etc. thing and move the mouse around.
> > 
> > To make the mouse to work in X11, please test the mouse with gpm in
> > a console first to assert basic functionality, and then come back.
> > 
> > Regards,
> > /Karl Hammar
> > 
> > ___
> > Dng mailing list
> > Dng@lists.dyne.org
> > https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng
> Hi,
> I understand now.  I was stuck on gpm because it worked some time ago on
> Debian Jessie.  I was not ready to continue with it then because I still had
> use of my Sun workstation.  The Sun is gone now, I was able to move the
> application program to Linux and now I need a three button mouse without the
> scroll wheel that works with X11.  Maybe the Sun mouse.
> 
> A previous post mentioned xorg.conf which doesn't appear to exist in Devuan
> Beowulf (AMD64).
> 
> So, where do I go from here?

I think all mice are supposed to be handled by the kernel and will
then get presented at /dev/input/mice

You should be able to check that with a simple
$ cat -v /dev/input/mice
which should then show "noise" when you move the mouse.

Then, I think the X11 system relies on udev for setting up its inputs
and load the appropriate modules. You may take over that and do things
"by hand" by a) making the following file /etc/X11/xorg.conf.d/a.conf

Section "ServerFlags"
Option "AutoAddDevices" "false"
EndSection


and b) installing xserver-xorg-input-kbd and xserver-xorg-input-mouse

With that you avoid the automagic processes around X11 inputs and
might have a slightly more stable system for tracking down the issue,
if it remains. (Needs an X11 restart of course)

Ralph.
___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-23 Thread Florian Zieboll via Dng
On Sat, 23 Apr 2022 21:15:34 +0200
Antony Stone  wrote:

> On Saturday 23 April 2022 at 21:11:18, Florian Zieboll via Dng wrote:
> 
> > On Sat, 23 Apr 2022 09:07:57 -0700 Fred wrote:  
>  [...]  
> > 
> > Some time ago, in a similar situation, I had been successful with
> > 
> > $ find / | grep xorg.conf  
> 
> Personally I'd have gone for:
> 
>   find / -name xorg.conf


I may be wrong (and nitpicking;) - but I think that your approach is
less fast, as 'find' does the file name matching /before/ it continues
searching - in opposite to just piping its output to grep and going on
with running down the file system hierarchy without any interruption.

libre Grüße,
Florian
___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-23 Thread karl
Fred:
> On 4/23/22 02:34, k...@aspodata.se wrote:
...
> > So, make sure you are running in a virtual console and logged in as
> > root, then run the gpm -b etc. thing and move the mouse around.
> > 
> > To make the mouse to work in X11, please test the mouse with gpm in
> > a console first to assert basic functionality, and then come back.

Did you do the test above ?

As long the serial port isn't opened by anything,
you can let X11 and openbox be running.

If so, press Ctl-Alt-F2 buttons simultaineusly to get to a console.
There log in as root
and then try one of
  gpm -b 1200 -m /dev/ttyUSB0 -t msc
  gpm -b 1200 -m /dev/ttyUSB0 -t sun
  gpm -b 1200 -m /dev/ttyUSB0 -t mman
and move the mouse to test.

> A previous post mentioned xorg.conf which doesn't appear to exist in 
> Devuan Beowulf (AMD64).
> So, where do I go from here?

You can either
A, do a xorg configuration with the mouse driver
   man xorg.conf is your friend.

B, try inputattach to make the mouse appear as a /dev/input/* device
   and be automatically included by X11, I haven't tested this. See

   https://wiki.archlinux.org/title/Serial_input_device_to_kernel_input
   https://sourceforge.net/projects/linuxconsole/files/
   https://help.ubuntu.com/community/SerialMouseHowto
   https://wiki.alpinelinux.org/wiki/Serial_Mouse

Regards,
/Karl Hammar





___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-23 Thread Antony Stone
On Saturday 23 April 2022 at 21:11:18, Florian Zieboll via Dng wrote:

> On Sat, 23 Apr 2022 09:07:57 -0700 Fred wrote:
> > A previous post mentioned xorg.conf which doesn't appear to exist in
> > Devuan Beowulf (AMD64).
> > 
> > So, where do I go from here?
> 
> Some time ago, in a similar situation, I had been successful with
> 
> $ find / | grep xorg.conf

Personally I'd have gone for:

find / -name xorg.conf

:)

> Also worth a try:
> 
> $ man 5 xorg.conf

> libre Grüße,
> Florian

I still really like that greeting (if that's the right word for it in 
English).


Antony.

-- 
A good conversation is like a miniskirt;
short enought to retain interest,
but long enough to cover the subject.

 - Celeste Headlee


   Please reply to the list;
 please *don't* CC me.
___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-23 Thread Florian Zieboll via Dng
On Sat, 23 Apr 2022 09:07:57 -0700
Fred  wrote:

> A previous post mentioned xorg.conf which doesn't appear to exist in 
> Devuan Beowulf (AMD64).
> 
> So, where do I go from here?


Some time ago, in a similar situation, I had been successful with

$ find / | grep xorg.conf

Also worth a try:

$ man 5 xorg.conf


libre Grüße,
Florian
___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-23 Thread Fred

On 4/23/22 02:34, k...@aspodata.se wrote:

Fred:

On 4/22/22 15:31, k...@aspodata.se wrote:

...

   gpm -b 1200 -m /dev/ttyS1 -t msc

...

It shows up at /dev/ttyUSB0.  I have tried that command line several
times.  Nothing happens.  ps -e shows gpm is running.  The pointer will
not move and the mouse buttons have no effect.

...

You have to be aware that gpm is for virtual consoles:

$ man gpm | grep 'gpm - '
gpm - a cut and paste utility and mouse server for virtual consoles

So in X11, openbox etc. graphical environment, it has no effect unless
you take special action. With graphical environment I mean bitmapped as
opposed to character (i.e. letters) based graphics.

Testing with gpm is best done without X11, so stop your window manager
(obenbox) and exit from X11. If you then is presented with a greeter
(also called display manager, see
  https://en.wikipedia.org/wiki/X_display_manager_(program_type)
), see if you can stop the greeter.

Also testing has to be done as root.

So, make sure you are running in a virtual console and logged in as
root, then run the gpm -b etc. thing and move the mouse around.

To make the mouse to work in X11, please test the mouse with gpm in
a console first to assert basic functionality, and then come back.

Regards,
/Karl Hammar

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng

Hi,
I understand now.  I was stuck on gpm because it worked some time ago on 
Debian Jessie.  I was not ready to continue with it then because I still 
had use of my Sun workstation.  The Sun is gone now, I was able to move 
the application program to Linux and now I need a three button mouse 
without the scroll wheel that works with X11.  Maybe the Sun mouse.


A previous post mentioned xorg.conf which doesn't appear to exist in 
Devuan Beowulf (AMD64).


So, where do I go from here?

Best regards,
Fred
___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-23 Thread karl
Fred:
> On 4/22/22 15:31, k...@aspodata.se wrote:
...
> >   gpm -b 1200 -m /dev/ttyS1 -t msc
...
> It shows up at /dev/ttyUSB0.  I have tried that command line several 
> times.  Nothing happens.  ps -e shows gpm is running.  The pointer will 
> not move and the mouse buttons have no effect.
...

You have to be aware that gpm is for virtual consoles:

$ man gpm | grep 'gpm - '
   gpm - a cut and paste utility and mouse server for virtual consoles

So in X11, openbox etc. graphical environment, it has no effect unless
you take special action. With graphical environment I mean bitmapped as
opposed to character (i.e. letters) based graphics.

Testing with gpm is best done without X11, so stop your window manager 
(obenbox) and exit from X11. If you then is presented with a greeter
(also called display manager, see
 https://en.wikipedia.org/wiki/X_display_manager_(program_type)
), see if you can stop the greeter.

Also testing has to be done as root.

So, make sure you are running in a virtual console and logged in as 
root, then run the gpm -b etc. thing and move the mouse around.

To make the mouse to work in X11, please test the mouse with gpm in
a console first to assert basic functionality, and then come back.

Regards,
/Karl Hammar

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-22 Thread Fred

On 4/22/22 15:31, k...@aspodata.se wrote:

Fred:

On 4/22/22 14:21, Fred wrote:

On 4/22/22 13:46, k...@aspodata.se wrote:

Fred:
...

As I said in an earlier post there is an article on using a (different)
Sun mouse on Linux.  The protocol used was msc.  From looking at the
output with an oscilloscope that protocol does appear close if not
correct.

...


From the scope trace you can infer the baud rate.

The baud rate is 1 / smallest_pulse_width.


Have you tried:

   mouse-test [ device ]

...

That program is actually gpm-mouse-test.

...

Should be the same program, differnt packaging. Does most development on
gentoo, run devuan on production boxes.


The Sun mouse I would like to use is also a compact-1.  Does the
mouse-test program you mention work with your compact-1 mouse and
therefore is actually a different program than the one in the gpm package?


I haven't made any adapter for it, it is on a sparcstation.

...

As I said in an earlier post I used the mouse
(long ago) on Debian Jessie with gpm and it worked with msc protocol.


Soo, what happens when you try with:

  gpm -b 1200 -m /dev/ttyS1 -t msc

where ttyS1 should be changed to the serial port used.

Regards,
/Karl Hammar


___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng

Hi,
It shows up at /dev/ttyUSB0.  I have tried that command line several 
times.  Nothing happens.  ps -e shows gpm is running.  The pointer will 
not move and the mouse buttons have no effect.


I have tried using minicom to connect to the mouse and that works in 
that the minicom cursor moves toward the right with mouse movement.

So the hardware is functional.  I know the baud rate is 1200.
Best regards,
Fred

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-22 Thread karl
Fred:
> On 4/22/22 14:21, Fred wrote:
> > On 4/22/22 13:46, k...@aspodata.se wrote:
> >> Fred:
> >> ...
> >>> As I said in an earlier post there is an article on using a (different)
> >>> Sun mouse on Linux.  The protocol used was msc.  From looking at the
> >>> output with an oscilloscope that protocol does appear close if not 
> >>> correct.
...

>From the scope trace you can infer the baud rate.
The baud rate is 1 / smallest_pulse_width.

> >> Have you tried:
> >>
> >>   mouse-test [ device ]
...
> > That program is actually gpm-mouse-test.
...

Should be the same program, differnt packaging. Does most development on
gentoo, run devuan on production boxes.

> > The Sun mouse I would like to use is also a compact-1.  Does the 
> > mouse-test program you mention work with your compact-1 mouse and 
> > therefore is actually a different program than the one in the gpm package?

I haven't made any adapter for it, it is on a sparcstation.

...
> As I said in an earlier post I used the mouse 
> (long ago) on Debian Jessie with gpm and it worked with msc protocol.

Soo, what happens when you try with:

 gpm -b 1200 -m /dev/ttyS1 -t msc

where ttyS1 should be changed to the serial port used.

Regards,
/Karl Hammar

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-22 Thread Fred

On 4/22/22 14:21, Fred wrote:

On 4/22/22 13:46, k...@aspodata.se wrote:

Fred:
...

As I said in an earlier post there is an article on using a (different)
Sun mouse on Linux.  The protocol used was msc.  From looking at the
output with an oscilloscope that protocol does appear close if not 
correct.


  Type-4 and -5 mice seems to been made by mouse systems:
https://www.oldmouse.com/mouse/mousesystems/sun.shtml
http://www.telltronics.org/hardware/SunMouse.html

My own sun moues is a type compact-1 and is done by Logitech.

So your primary choises would be msc and mman (in gpm parlance).



As I said in an earlier post I haven't been able to get gpm to do
anything with the pointer.


Have you tried:

  mouse-test [ device ]

Regards,
/Karl Hammar

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng

Hi,
That program is actually gpm-mouse-test.  According to the man page it 
is incomplete but otherwise would be helpful.  The mouse I would like to 
use appears as a serial port but gpm-mouse-test doesn't provide any 
option for baud rate.  The author is listed in the man page and I will 
email him to stir the pot.


The Sun mouse I would like to use is also a compact-1.  Does the 
mouse-test program you mention work with your compact-1 mouse and 
therefore is actually a different program than the one in the gpm package?


Best regards,
Fred

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng
I tried the gpm-mouse-test program and it is more complete than the man 
page indicates.  It does try several baud rates.  It appeared to be able 
to see the mouse present but was not able to detect the protocol.  I 
don't know whether that was because of a bug in the program or the mouse 
uses a custom protocol.  As I said in an earlier post I used the mouse 
(long ago) on Debian Jessie with gpm and it worked with msc protocol.


The gpm-mouse-test program also did not detect the regular USB mouse so 
it may have some problems.

Best regards,
Fred

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-22 Thread Fred

On 4/22/22 13:46, k...@aspodata.se wrote:

Fred:
...

As I said in an earlier post there is an article on using a (different)
Sun mouse on Linux.  The protocol used was msc.  From looking at the
output with an oscilloscope that protocol does appear close if not correct.


  Type-4 and -5 mice seems to been made by mouse systems:
https://www.oldmouse.com/mouse/mousesystems/sun.shtml
http://www.telltronics.org/hardware/SunMouse.html

My own sun moues is a type compact-1 and is done by Logitech.

So your primary choises would be msc and mman (in gpm parlance).



As I said in an earlier post I haven't been able to get gpm to do
anything with the pointer.


Have you tried:

  mouse-test [ device ]

Regards,
/Karl Hammar

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng

Hi,
That program is actually gpm-mouse-test.  According to the man page it 
is incomplete but otherwise would be helpful.  The mouse I would like to 
use appears as a serial port but gpm-mouse-test doesn't provide any 
option for baud rate.  The author is listed in the man page and I will 
email him to stir the pot.


The Sun mouse I would like to use is also a compact-1.  Does the 
mouse-test program you mention work with your compact-1 mouse and 
therefore is actually a different program than the one in the gpm package?


Best regards,
Fred

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-22 Thread karl
Fred:
...
> As I said in an earlier post there is an article on using a (different) 
> Sun mouse on Linux.  The protocol used was msc.  From looking at the 
> output with an oscilloscope that protocol does appear close if not correct.

 Type-4 and -5 mice seems to been made by mouse systems:
https://www.oldmouse.com/mouse/mousesystems/sun.shtml
http://www.telltronics.org/hardware/SunMouse.html

My own sun moues is a type compact-1 and is done by Logitech.

So your primary choises would be msc and mman (in gpm parlance).


> As I said in an earlier post I haven't been able to get gpm to do 
> anything with the pointer.

Have you tried:

 mouse-test [ device ]

Regards,
/Karl Hammar

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-22 Thread Fred

On 4/22/22 09:32, k...@aspodata.se wrote:

Fred:
...

I need to work with a nonstandard serial three button mouse without
scroll wheel. It needs a baud rate specification and gpm has an
option for this.

...

  I know that gpm works with this mouse.


Since gpm works with the mouse I wouldn't say it is a "non-standard"
one. What mouse protocol does the mouse speak ?

The mouse is a Sun three button mouse without the scroll wheel.  I 
frequently use a program that makes extensive use of the middle button 
and the pc mouse scroll wheel is hateful.


As I said in an earlier post there is an article on using a (different) 
Sun mouse on Linux.  The protocol used was msc.  From looking at the 
output with an oscilloscope that protocol does appear close if not correct.



Common protocols are mouseman and msmouse.
You can see what protocols are supported by gpm by doing:

  gpm -m /dev/null -t help

Unfortunately you have to do that as root, it doesn't matter what
you write as the device, it can be any string.

You can also find out about mouse protocols with

  man mouse

Examples of mouse protocols:

  
https://web.stanford.edu/class/ee281/projects/aut2002/yingzong-mouse/media/Serial%20Mouse%20Detection.pdf
  https://www.kryslix.com/nsfaq/Q.12.html

Example mouse code (if you want to build a mouse yourself):

  https://aspodata.se/git/openhw/boards_arm_aspo/mouse/mouse.c



What program is used as mouse driver on Beowulf and Chimaera?


In a text mode terminal you can use gpm or something similar.

In wayland, I don't know, it seems libinput is used by wayland.

In X11 you could use the mouse driver:

  https://www.x.org/releases/current/doc/man/man4/mousedrv.4.xhtml
  https://packages.debian.org/bullseye/xserver-xorg-input-mouse

You have to configure the mouse driver yourself, udev is of no help
for a serial mouse. You can have multiple serial mice connected and
used. Example xorg.conf extracts:

Section "InputDevice"
 Identifier  "Configured Mouse"
 Driver  "mouse"
 Option  "CorePointer"
 Option  "Device""/dev/ttyS4"
 Option  "Protocol"  "MouseMan"
EndSection

Section "InputDevice"
 Identifier  "Configured MSMouse"
 Driver  "mouse"
 Option  "SendCoreEvents"
 Option  "Device""/dev/ttyS5"
 Option  "Protocol"  "Microsoft"
EndSection

  Todays usb mice can use:

Section "InputDevice"
 Identifier  "Generic Mouse"
 Driver  "mouse"
 Option  "SendCoreEvents""true"
 Option  "Device""/dev/input/mice"
 Option  "Protocol"  "auto"
 Option  "ZAxisMapping"  "4 5"
EndSection

It has apperantly been removed in favour of libinput upstream:

  
https://www.gentoo.org/support/news-items/2020-04-03-deprecation-of-legacy-x11-input-drivers.html

Regards,
/Karl Hammar

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


As I said in an earlier post I haven't been able to get gpm to do 
anything with the pointer.  I haven't been able to find xorg.conf yet. 
I will try an entry there.


Best regards,
Fred
___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-22 Thread Florian Zieboll via Dng
On April 22, 2022 12:21:02 AM GMT+02:00, aitor  wrote:
> Hi Fred,
> 
> On 21/4/22 23:39, Fred wrote:
> 
> > I don't understand what you mean by virtual terminal.
> 
> For sure the login prompts of tty2, tty3... brung up by holding down the 
> Ctrl+Alt keys, and pressing one of the function keys F2, F3...


Sorry for the confusion: I meant to write 'terminal emulator' (xterm and 
alike), not 'virtual terminal'! 

If I don't get it wrong, in the graphical environment, gpm is not available and 
pointer actions are handeled by X11 resp. the terminal emulator.

gpm is only needed for the text console (tty1, tty2, ...).




-- 

[message sent otg]

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-22 Thread karl
Fred:
...
> I don't understand what you mean by virtual terminal.

There are not many "true" terminals left:

 https://en.wikipedia.org/wiki/Computer_terminal

so basically all terminals today are virtual, in the sense that
they behave as if they were an actual terminal, but they are not.

There are basically two types of virtual terminals:

. virtual consoles (also called virtual terminals)
  https://en.wikipedia.org/wiki/Virtual_console

. terminal emulators (like xterm)
  https://en.wikipedia.org/wiki/Terminal_emulator

It seems the primary differance between them is that the virtual
consoles/terminals works in the text mode which linux comes up in.
I.e. with no X11, wayland, openbox or whatever graphical support.

And the terminal emulators works in the graphical mode.

Some people relate this to the difference between DOS and MS-Windows.

Regards,
/Karl Hammar


___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-22 Thread karl
Fred:
...
> I need to work with a nonstandard serial three button mouse without
> scroll wheel. It needs a baud rate specification and gpm has an
> option for this.
...
>  I know that gpm works with this mouse.

Since gpm works with the mouse I wouldn't say it is a "non-standard"
one. What mouse protocol does the mouse speak ?

Common protocols are mouseman and msmouse.
You can see what protocols are supported by gpm by doing:

 gpm -m /dev/null -t help

Unfortunately you have to do that as root, it doesn't matter what
you write as the device, it can be any string.

You can also find out about mouse protocols with

 man mouse

Examples of mouse protocols:

 
https://web.stanford.edu/class/ee281/projects/aut2002/yingzong-mouse/media/Serial%20Mouse%20Detection.pdf
 https://www.kryslix.com/nsfaq/Q.12.html

Example mouse code (if you want to build a mouse yourself):

 https://aspodata.se/git/openhw/boards_arm_aspo/mouse/mouse.c


> What program is used as mouse driver on Beowulf and Chimaera?

In a text mode terminal you can use gpm or something similar.

In wayland, I don't know, it seems libinput is used by wayland.

In X11 you could use the mouse driver:

 https://www.x.org/releases/current/doc/man/man4/mousedrv.4.xhtml
 https://packages.debian.org/bullseye/xserver-xorg-input-mouse

You have to configure the mouse driver yourself, udev is of no help
for a serial mouse. You can have multiple serial mice connected and
used. Example xorg.conf extracts:

Section "InputDevice"
Identifier  "Configured Mouse"
Driver  "mouse"
Option  "CorePointer"
Option  "Device""/dev/ttyS4"
Option  "Protocol"  "MouseMan"
EndSection

Section "InputDevice"
Identifier  "Configured MSMouse"
Driver  "mouse"
Option  "SendCoreEvents"
Option  "Device""/dev/ttyS5"
Option  "Protocol"  "Microsoft"
EndSection

 Todays usb mice can use:

Section "InputDevice"
Identifier  "Generic Mouse"
Driver  "mouse"
Option  "SendCoreEvents""true"
Option  "Device""/dev/input/mice"
Option  "Protocol"  "auto"
Option  "ZAxisMapping"  "4 5"
EndSection

It has apperantly been removed in favour of libinput upstream:

 
https://www.gentoo.org/support/news-items/2020-04-03-deprecation-of-legacy-x11-input-drivers.html

Regards,
/Karl Hammar

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-22 Thread Fred

On 4/21/22 23:00, marc wrote:

Hello


gpm (and I suppose also consolation) is active only on the console, not in 
virtual terminals - so there's no conflict.

Libre Gre,
Florian



I don't understand what you mean by virtual terminal.  I don't use a DE,
just openbox.  I may have two xterms open, nedit, tuxcmd plus some other
program.  The mouse will work in any of these and its input would come from
one place, presumably the mouse driver.  If I install gpm (or consolation)
what decides where the mouse input is coming from?  It appears to me that
the default driver needs to be stopped but I don't know what it is called.


Are you using gpm in repeater mode (-R with /dev/gpmdata)
to somehow translate mouse buttons ?

There are a number of programs to translate input devices (via /dev/uinput),
including one written by yours truly...  though given that gpm appears
to be present in the upgraded distribution, just making sure that
it runs with the correct options might be the easiest ?

regards

marc


Hi Marc,
I installed gpm but it was not able to capture the pointer.  Likely I 
don't know enough about how it works to choose the right options.


The original (USB) mouse appears to show up at /dev/input/mouse0.  The 
mouse I want to use has a TTL interface which is connected to one of the 
FTDI serial to USB converters.  When plugged in it appears at 
/dev/ttyUSB0.  I used minicom to verify it works.  There was an article 
somewhere on the Internet about using a Sun mouse on Linux and long ago 
I tested their command line on Debian Jessie and it worked.


gpm -b 1200 -m /dev/ttyUSB0 -t msc

However, on Beowulf it does not do anything.  ps -e shows that gpm is 
running.
What should the command line be for repeater mode?  /dev/gpmdata does 
not exist.


Best regards,
Fred
___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-22 Thread marc
Hello

> >gpm (and I suppose also consolation) is active only on the console, not in 
> >virtual terminals - so there's no conflict.
> >
> >Libre Gre,
> >Florian
> >
> 
> I don't understand what you mean by virtual terminal.  I don't use a DE,
> just openbox.  I may have two xterms open, nedit, tuxcmd plus some other
> program.  The mouse will work in any of these and its input would come from
> one place, presumably the mouse driver.  If I install gpm (or consolation)
> what decides where the mouse input is coming from?  It appears to me that
> the default driver needs to be stopped but I don't know what it is called.

Are you using gpm in repeater mode (-R with /dev/gpmdata)
to somehow translate mouse buttons ?

There are a number of programs to translate input devices (via /dev/uinput), 
including one written by yours truly...  though given that gpm appears
to be present in the upgraded distribution, just making sure that 
it runs with the correct options might be the easiest ?

regards

marc

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-21 Thread aitor

Hi again,

On 22/4/22 0:21, aitor wrote:


For sure the login prompts of tty2, tty3... brung up by holding down the 
Ctrl+Alt keys, and pressing one of the function keys F2, F3...


In debian the first six virtual TTYs (tty1, tty2,... tty6) are non-graphical,
according to the configuration in /etc/inittab. Quoted verbatim:

# Note that on most Debian systems tty7 is used by the X Window System,
# so if you want to add more getty's go ahead but skip tty7 if you run X.
#
1:2345:respawn:/sbin/getty --noclear 38400 tty1
2:23:respawn:/sbin/getty 38400 tty2
3:23:respawn:/sbin/getty 38400 tty3
4:23:respawn:/sbin/getty 38400 tty4
5:23:respawn:/sbin/getty 38400 tty5
6:23:respawn:/sbin/getty 38400 tty6

Aitor.


___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-21 Thread aitor

Hi Fred,

On 21/4/22 23:39, Fred wrote:


I don't understand what you mean by virtual terminal.


For sure the login prompts of tty2, tty3... brung up by holding down the 
Ctrl+Alt keys, and pressing one of the function keys F2, F3...

Cheers,

Aitor.


___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-21 Thread Fred

On 4/21/22 13:09, Florian Zieboll wrote:

On April 21, 2022 9:28:16 PM GMT+02:00,   wrote:

Hi,

If I install gpm or consolation won't that conflict with whatever driver
is already installed?



gpm (and I suppose also consolation) is active only on the console, not in 
virtual terminals - so there's no conflict.

Libre Grüße,
Florian



I don't understand what you mean by virtual terminal.  I don't use a DE, 
just openbox.  I may have two xterms open, nedit, tuxcmd plus some other 
program.  The mouse will work in any of these and its input would come 
from one place, presumably the mouse driver.  If I install gpm (or 
consolation) what decides where the mouse input is coming from?  It 
appears to me that the default driver needs to be stopped but I don't 
know what it is called.


Best regards,
Fred


___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-21 Thread Florian Zieboll via Dng
On April 21, 2022 9:28:16 PM GMT+02:00,   wrote:
> Hi,
> 
> If I install gpm or consolation won't that conflict with whatever driver 
> is already installed?


gpm (and I suppose also consolation) is active only on the console, not in 
virtual terminals - so there's no conflict. 

Libre Grüße,
Florian




-- 

[message sent otg]

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-21 Thread Fred

Hi,

If I install gpm or consolation won't that conflict with whatever driver 
is already installed?  The gpm man page says it is not allowed to have 
two instances of gpm running at the same time and there is an option to 
kill the previous instance.


Best regards,
Fred


On 4/21/22 11:50, Daniel Abrecht via Dng wrote:
An alternative to "gpm" would be "consolation". It's based on 
"libinput". I've never tried serial mice, but you can probably install & 
start "inputattach", and then "consolation" should probably pick it up 
if it's installed. inputattach should also work with other things such 
as X11 and Wayland.


Regards,
Daniel Abrecht
___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-21 Thread Daniel Abrecht via Dng
An alternative to "gpm" would be "consolation". It's based on 
"libinput". I've never tried serial mice, but you can probably install & 
start "inputattach", and then "consolation" should probably pick it up 
if it's installed. inputattach should also work with other things such 
as X11 and Wayland.


Regards,
Daniel Abrecht
___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-21 Thread Gastón via Dng
On Thu, Apr 21, 2022 at 09:07:20AM -0700, Fred wrote:
> Hello,
> 
> What program is used as mouse driver on Beowulf and Chimaera?  Gpm was
> previously used but it is not installed now.  I need to work with a
> nonstandard serial three button mouse without scroll wheel.  It needs a baud
> rate specification and gpm has an option for this.  I know that gpm works
> with this mouse.
> 
Hi, gpm package is available in beowulf and chimaera repos.

$ apt-cache madison gpm
gpm | 1.20.7-8 | http://deb.devuan.org/merged chimaera/main amd64 Packages 
gpm | 1.20.7-5 | http://deb.devuan.org/merged beowulf/main amd64 Packages

--
gast0n

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng


Re: [DNG] mouse driver question

2022-04-21 Thread Florian Zieboll via Dng
On April 21, 2022 6:07:20 PM GMT+02:00, Fred  wrote:
> Hello,
> 
> What program is used as mouse driver on Beowulf and Chimaera?  Gpm was 
> previously used but it is not installed now.  I need to work with a 
> nonstandard serial three button mouse without scroll wheel.  It needs a 
> baud rate specification and gpm has an option for this.  I know that gpm 
> works with this mouse.


I have gpm running on chimaera, so it should be in the repository. Besides 
that, 'consolation' had been mentioned on this list as a successor of gpm, but 
I have not tried it yet. 

Libre Grüße,
Florian


-- 

[message sent otg]

___
Dng mailing list
Dng@lists.dyne.org
https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng