File: mouse.4

package info (click to toggle)
manpages-ja 0.5.0.0.20120606-1
  • links: PTS
  • area: main
  • in suites: wheezy
  • size: 25,964 kB
  • sloc: perl: 161; makefile: 116
file content (130 lines) | stat: -rw-r--r-- 7,045 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
.\" t
.\"roff.\" Copyright
.\" This manpage is Copyright (C) 1996 Michael Haardt.
.\" Updates Nov 1998, Andries Brouwer
.\"
.\" Permission is granted to make and distribute verbatim copies of this
.\" manual provided the copyright notice and this permission notice are
.\" preserved on all copies.
.\"
.\" Permission is granted to copy and distribute modified versions of this
.\" manual under the conditions for verbatim copying, provided that the
.\" entire resulting derived work is distributed under the terms of a
.\" permission notice identical to this one.
.\"
.\" Since the Linux kernel and libraries are constantly changing, this
.\" manual page may be incorrect or out-of-date.  The author(s) assume no
.\" responsibility for errors or omissions, or for damages resulting from
.\" the use of the information contained herein.  The author(s) may not
.\" have taken the same level of care in the production of this manual,
.\" which is licensed free of charge, as they might when working
.\" professionally.
.\"
.\" Formatted or processed versions of this manual, if unaccompanied by
.\" the source, must acknowledge the copyright and authors of this work.
.\"*******************************************************************
.\"
.\" This file was generated with po4a. Translate the source file.
.\"
.\"*******************************************************************
.TH MOUSE 4 1996\-02\-10 Linux "Linux Programmer's Manual"
.SH 名前
mouse \- シリアルマウスインターフェース
.SH 設定
シリアルマウスは RS232/V24 ダイアルアウトラインに接続される。 RS232/V24 ダイアルアウトライン については \fBttyS\fP(4)
を参照のこと。
.SH 説明
.SS 概説
シリアルマウスで使われる普通の 9 ピンプラグのピン配列は以下である:
.TS
center;
r c l.
pin	name	used for
2	RX	Data
3	TX	\-12 V, Imax = 10 mA
4	DTR	+12 V, Imax = 10 mA
7	RTS	+12 V, Imax = 10 mA
5	GND	Ground
.TE

これは仕様書であり、実際はほとんどのマウスでは 9 V で十分である。
.PP
マウスドライバは RTS をロー(low)に落し、再び上げることによって、マウスを認識でき る。およそ 14 ms 後、マウスはデータライン上に
0x4D (\(aqM\(aq) を送るだろう。さら に 63ms あと、マイクロソフト互換 3ボタンマウスは 0x33 (\(aq3\(aq)
を送る。
.PP
マウスの相対的な移動は、\fIdx\fP(正が右)と\fIdy\fP(正が下)として伝えられる。
各種のマウスは異なったスピードで操作できる。スピードを選択するには、 下の表の2文字を送ってから 0.1 秒待つことで、9600, 4800,
2400, 1200 bit/s を順に選べる。 以下の表では選択可能なスピードとそれを選択するための文字列を示している。
.TS
center;
l l.
bit/s	string
9600	*q
4800	*p
2400	*o
1200	*n
.TE

データパケットの第 1 バイトは同期をとるのに利用できる。
.SS "マイクロソフト プロトコル(Microsoft Protocol)"
\fBマイクロソフト\fPプロトコルは、1200 bits/sec のスピードで、1 ス タートビット(1 start bit)、7 データビット(7
data bits)、パリティな し、1 ストップビット(1 stop bit)である。 データは RxD に 3
バイトのパケットとして送られる。\fIdx\fP と \fIdy\fP の動きは 2 の補数表示で送られ、左(右)のボタンが押された時には \fIlb\fP
(\fIrb\fP)がセットされる。
.TS
center;
r c c c c c c c.
byte	d6	d5	d4	d3	d2	d1	d0
1	1	lb	rb	dy7	dy6	dx7	dx6
2	0	dx5	dx4	dx3	dx2	dx1	dx0
3	0	dy5	dy4	dy3	dy2	dy1	dy0
.TE
.SS "3つボタン マイクロソフト プロトコル(3\-button Microsoft protocol)"
本来のマイクロソフトマウスは 2 つのボタンしか持たない。しかし、3 つボタン のマウスでマイクロソフトプロトコルの物も存在する。真中のボタンを押す、
または放すということは、動きゼロでボタンが押されていないというパケット を送ることで伝えられる。(従って他の二つのボタンと違い、真中のボタ
ンのステータスは、それぞれのパケットからは伝わって来ない。)
.SS "ロジテック プロトコル(Logitech protocol)"
ロジテック シリアル 3つボタンマウスは、マイクロソフト プロトコルとは 異なった拡張をしている。:真中のボタンが押されてないと、上記 3バイトの
パケットが送られる。真中のボタンが押されていると、4バイトのパケットが 送られる。第4バイトは 0x20 の値を持っている(あるいは、少なくとも
0x20 ビットがセットされている)。 但し、他のボタンが押されていない状態で、 真中のボタンが押されると、0,0,0,0x20 と伝えられる。
.SS "マウスシステムズ プロトコル(Mousesystems protocol)"
\fBマウスシステムズ\fPプロトコルは、1200 bits/secで、1 スタートビット、 8 データビット、パリティなし、2 ストップビットである。
データは、RxD に 5 バイトのパケットとして送られる。\fIdx\fP は 2 つの 2 の補数の和として送られ、\fIdy\fP は 2 つの 2
の補数の和の否定 として送られる。左(中、右)のボタンが押された時には\fIlb\fP (\fImb\fP, \fIrb\fP) がクリアされる。
.TS
center;
r c c c c c c c c.
byte	d7	d6	d5	d4	d3	d2	d1	d0
1	1	0	0	0	0	lb	mb	rb
2	0	dxa6	dxa5	dxa4	dxa3	dxa2	dxa1	dxa0
3	0	dya6	dya5	dya4	dya3	dya2	dya1	dya0
4	0	dxb6	dxb5	dxb4	dxb3	dxb2	dxb1	dxb0
5	0	dyb6	dyb5	dyb4	dyb3	dyb2	dyb1	dyb0
.TE

第 4,5 バイトには、第 2,3 バイトが送られたあと生じた変更が記述される。
.SS "サン プロトコル(Sun protocol)"
\fBサン\fP プロトコルは、上記の 5 バイト マウスシステムプロトコルの 3 バイト版です。後の 2 バイトは送られません。
.SS "MM プロトコル(MM protocol)"
\fBMM\fP プロトコルは 1200 bits/sec で 1 スタートビット、8 データビッ ト、奇数パリティ、 1 ストップビットを使う。データは
RxD に 3 バイトのパ ケットとして送られる。\fIdx\fP と \fIdy\fP は一つの符号つきの値として
送られ、サインビットは負の値を表す。左(中、右)のボタンが押された時には \fIlb\fP (\fImb\fP, \fIrb\fP)がセットされる。
.TS
center;
r c c c c c c c c.
byte	d7	d6	d5	d4	d3	d2	d1	d0
1	1	0	0	dxs	dys	lb	mb	rb
2	0	dx6	dx5	dx4	dx3	dx2	dx1	dx0
3	0	dy6	dy5	dy4	dy3	dy2	dy1	dy0
.TE
.SH ファイル
.TP 
\fI/dev/mouse\fP
一般的にマウスデバイスをさすのに使われるシンボリックリンク
.SH 関連項目
\fBttyS\fP(4), \fBgpm\fP(8)
.SH この文書について
この man ページは Linux \fIman\-pages\fP プロジェクトのリリース 3.41 の一部
である。プロジェクトの説明とバグ報告に関する情報は
http://www.kernel.org/doc/man\-pages/ に書かれている。