Open vague666 opened 4 years ago
gpm 1.20.7
Available mouse types are:
r name synonym description
mman The "MouseMan" and similar devices (3/4 bytes per packet).
Synonyms: Mouseman
ms The original ms protocol, with a middle-button extension.
Synonyms:
acecad Acecad tablet absolute mode(Sumagrapics MM-Series mode)
Synonyms:
bare Unadorned ms protocol. Needed with some 2-buttons mice.
Synonyms: Microsoft
bm Micro$oft busmice and compatible devices.
Synonyms: BusMouse
brw Fellowes Browser - 4 buttons (and a wheel) (dual protocol?)
Synonyms:
cal Calcomp UltraSlate
Synonyms:
calr Calcomp UltraSlate - relative mode
Synonyms:
etouch EloTouch touch-screens (only button-1 events, by now)
Synonyms:
evdev Linux Event Device
Synonyms:
exps2 IntelliMouse Explorer (ps2) - 3 buttons, wheel unused
Synonyms: ExplorerPS/2
js Joystick mouse emulation
Synonyms: Joystick
genitizer "Genitizer" tablet, in relative mode.
Synonyms:
gunze Gunze touch-screens (only button-1 events, by now)
Synonyms:
* imps2 Microsoft Intellimouse (ps2)-autodetect 2/3 buttons,wheel unused
Synonyms:
logi Used in some Logitech devices (only serial).
Synonyms: Logitech
logim Turn logitech into Mouse-Systems-Compatible.
Synonyms:
mm MM series. Probably an old protocol...
Synonyms: MMSeries
* ms3 Microsoft Intellimouse (serial) - 3 buttons, wheel unused
Synonyms:
ms+ Like 'ms', but allows dragging with the middle button.
Synonyms:
ms+lr 'ms+', but you can reset m by pressing lr (see man page).
Synonyms:
* msc Mouse-Systems-Compatible (5bytes). Most 3-button mice.
Synonyms: MouseSystems
mtouch MicroTouch touch-screens (only button-1 events, by now)
Synonyms:
ncr Ncr3125pen, found on some laptops
Synonyms:
netmouse Genius NetMouse (ps2) - 2 buttons and 2 buttons 'up'/'down'.
Synonyms:
pnp Plug and pray. New mice may not run with '-t ms'.
Synonyms:
* ps2 Busmice of the ps/2 series. Most busmice, actually.
Synonyms: PS/2
* sun 'msc' protocol, but only 3 bytes per packet.
Synonyms:
* summa Summagraphics or Genius tablet absolute mode(MM-Series)
Synonyms:
syn The "Synaptics" serial TouchPad.
Synonyms: synaptics
synps2 The "Synaptics" PS/2 TouchPad
Synonyms: synaptics_ps2
twid Twidddler keyboard
Synonyms:
vsxxxaa The DEC VSXXX-AA/GA serial mouse on DEC workstations.
Synonyms:
wacom Wacom Protocol IV Tablets: Pen+Mouse, relative+absolute mode
Synonyms:
wp Genius WizardPad tablet
Synonyms: wizardpad
@vague666
What is the question?
i read. the fifo speaks a mouse protocol and the fifo is for reading.
fifo /dev/gpmdata in protocol name
^^^^^
where can i put the string?
The gpm daemon must be started with -R
bash-4.3# echo test > /dev/gpmdata; cat /dev/gpmdata
C>C<C<C;C<C;C<C<C<C<C<C<C=C=C>C?C?L>L>L=L;L:L9L:L9L:L;L;L;L;L<L<L>L>L?L?L?@L?L?@@L?@L?@L?L?L?L?test
C?C>C=C>C>C?C>C?C?C?C?@@@@@@@@L?L?L=L<L<L<L<L<L<L;L<L<L=L=L=L>L>L>L>L?L?L?L?C?L?C?O??C?O??C?O??O>?O>?C>C>C=C=C=C>C=C=C>C=C=C>C?C?@@@@@@@@@@@@@@@@@L?L?L>L>L=L=L<L<L<L=L=L=L>L>L?L?L?^C
Try some other mouse types is all I can say. I tested in a centos vm, change both -t and -R to the gpm daemon
[src ]$ print **/(*.c|*.h) |xargs grep fifofd
daemon/getmousedata.c: if (kd_mode!=KD_TEXT && fifofd != -1 && opt_rawrep)
daemon/getmousedata.c: write(fifofd, data, howmany);
daemon/getmousedata.c: if (kd_mode!=KD_TEXT && fifofd != -1 && opt_rawrep && j > 0)
daemon/getmousedata.c: write(fifofd, edata-i, j);
daemon/gpm.c:int fifofd=-1;
daemon/processmouse.c: if (fifofd != -1 && ! opt_rawrep) {
daemon/processmouse.c: repeated_type->repeat_fun(event, fifofd); /* itz Jan 11 1999 */
daemon/startup.c: if((fifofd=open(GPM_NODE_FIFO, O_RDWR|O_NONBLOCK)) < 0)
headers/daemon.h:extern int fifofd;
TIOCLINUX, subcode=2
Set selection. argp points to a
struct {
char subcode;
short xs, ys, xe, ye;
short sel_mode;
};
xs and ys are the starting column and row. xe and ye are the ending column and row. (Upper left corner is row=column=1.) sel_mode is 0 for character-by-character selection, 1 for word-by-word selection, or 2 for line-by-line selection. The indicated screen characters are highlighted and saved in the static array sel_buffer in devices/char/console.c.
TIOCLINUX, subcode=3
Paste selection. The characters in the selection buffer are written to fd.
Did the upload somehow fuck up the filename? Not really sure what I should do with the fifoexample
Did the upload somehow fuck up the filename?
fifoexample.tar.gz
Not really sure what I should do with the fifoexample
$> ./run.sh
gcc -o openfifo openfifo.c
ein test
$>cat run.sh
#!/bin/sh
make
mkfifo fifo
./openfifo&
echo 'ein test' > fifo
cat fifo
I still don't know what that is supposed to mean. Why the c program?
/dev/gpmdata is created when the gpm daemon is run with -R
:face_with_head_bandage:
:hourglass_flowing_sand:
I run all my centos without X. If you have possibility to try on a system without X please do but I don't think the fifo means X is/has to be installed, just that any mouse data in graphic mode, could mean both vesafb and X I guess, will be repeated in /dev/gpmdata
, nothing stops you from using the device to move data around, ie echo test > /dev/gpmdata; cat /dev/gpmdata
, but the fifo will only be created if you start gpm with -R[type/protocol]
-R[name] Causes gpm to act as a repeater: any mouse data received while in graphic mode will be produced on the fifo /dev/gpmdata in protocol name, given as an optional argument (no space in between !). In principle, you can use the same names as for the -t option, although repeating into some protocols may not be implemented for a while. In addition, you can specify raw as the name, to repeat the mouse data byte by byte, without any protocol translation. If name is omitted, it defaults to msc. Using gpm in repeater mode, you can configure the X server to use its fifo as a mouse device. This option is useful for bus-mouse owners to override the single-open limitation. It is also an easy way to manage those stupid dual-mode mice which force you to keep the middle button down while changing video mode. The option is forced on by the -M option.
/etc/rc.d/rc.gpm
# There is another way to run GPM, where it acts as a repeater outputting a
# virtual MouseSystems mouse on /dev/gpmdata. This is useful for feeding
# gpm's data to X, especially if you've got a busmouse (in that situation X
# and gpm may not coexist without using a repeater). To try running a GPM
# repeater for X, change the gpm command line to look like this:
# /usr/sbin/gpm -R msc -m /dev/mouse -t ps2
# Then, make sure that the mouse configuration in your XF86Config file refers
# to the repeater device (/dev/gpmdata) and a MouseSystems mouse type. If you
# edit the file directly, you'll want the lines to look like this (minus the
# comment marks '#' shown here, of course):
#Section "Pointer"
# Protocol "MouseSystems"
# Device "/dev/gpmdata"
I don't know what you mean by that. X is not required from what I can see. Just add a possibility to print data to /dev/gpmdata
to the script and document the need to run gpm with -R
/dev/gpmdata is a output of gpm.
/dev/gpmdata
is created when gpm
is run with -R. It's a normal fifo, you can write to it and read from it. X has no bearing on it in this case
f447306
Just add a possibility to print data to
/dev/gpmdata
to the script
This is completely wrong. /dev/gpmdata
is not for passing text around.
@bw1 It might be possible to use
gpm
to copy text if in non-X env There should be a fifo called /dev/gpmdataDon't know without testing myself if it's possible to write data to gpmdata and paste with mouse middle-button, also, no idea if gpm has to be started with -R for gpmdata to be created Something to test :)