← Documents Documentation/sound/cards/joystick.rst GitHub 원문 ↗

Linux 6.18.37 · Sound

ALSA 드라이버의 아날로그 조이스틱 지원

ALSA의 PCI·ISA 아날로그 조이스틱 지원에서 GAMEPORT 커널 설정과 드라이버별 모듈 옵션·추가 모듈을 정리합니다.

Source pathDocumentation/sound/cards/joystick.rst
Source versionLinux v6.18.37
TranslationDUJINLABS 전문 번역 + 해설

요약·해설과 원문, 전문 번역을 서로 분리했습니다. API 이름, symbol, source path는 원문 표기를 사용합니다.

1. 요약·해설

원문의 핵심 논리와 kernel programming 관점의 보충 설명입니다. 아래의 전문 번역과는 별도로 작성했습니다.

요약·해설

joystick.rst:1-91

ALSA의 PCI·ISA 아날로그 조이스틱 지원에서 GAMEPORT 커널 설정과 드라이버별 모듈 옵션·추가 모듈을 정리합니다.

2. 영어 원문 전체

번역 기준이 된 Linux v6.18.37 원문입니다. 줄 번호는 이 버전의 파일 좌표입니다.

원문 전체 펼치기
1 =======================================
2 Analog Joystick Support on ALSA Drivers
3 =======================================
4
5 Oct. 14, 2003
6
7 Takashi Iwai <tiwai@suse.de>
8
9 General
10 -------
11
12 First of all, you need to enable GAMEPORT support on Linux kernel for
13 using a joystick with the ALSA driver. For the details of gameport
14 support, refer to Documentation/input/joydev/joystick.rst.
15
16 The joystick support of ALSA drivers is different between ISA and PCI
17 cards. In the case of ISA (PnP) cards, it's usually handled by the
18 independent module (ns558). Meanwhile, the ALSA PCI drivers have the
19 built-in gameport support. Hence, when the ALSA PCI driver is built
20 in the kernel, CONFIG_GAMEPORT must be 'y', too. Otherwise, the
21 gameport support on that card will be (silently) disabled.
22
23 Some adapter modules probe the physical connection of the device at
24 the load time. It'd be safer to plug in the joystick device before
25 loading the module.
26
27
28 PCI Cards
29 ---------
30
31 For PCI cards, the joystick is enabled when the appropriate module
32 option is specified. Some drivers don't need options, and the
33 joystick support is always enabled. In the former ALSA version, there
34 was a dynamic control API for the joystick activation. It was
35 changed, however, to the static module options because of the system
36 stability and the resource management.
37
38 The following PCI drivers support the joystick natively.
39
40 ============== ============= ============================================
41 Driver Module Option Available Values
42 ============== ============= ============================================
43 als4000 joystick_port 0 = disable (default), 1 = auto-detect,
44 manual: any address (e.g. 0x200)
45 au88x0 N/A N/A
46 azf3328 joystick 0 = disable, 1 = enable, -1 = auto (default)
47 ens1370 joystick 0 = disable (default), 1 = enable
48 ens1371 joystick_port 0 = disable (default), 1 = auto-detect,
49 manual: 0x200, 0x208, 0x210, 0x218
50 cmipci joystick_port 0 = disable (default), 1 = auto-detect,
51 manual: any address (e.g. 0x200)
52 cs4281 N/A N/A
53 cs46xx N/A N/A
54 es1938 N/A N/A
55 es1968 joystick 0 = disable (default), 1 = enable
56 sonicvibes N/A N/A
57 trident N/A N/A
58 via82xx [#f1]_ joystick 0 = disable (default), 1 = enable
59 ymfpci joystick_port 0 = disable (default), 1 = auto-detect,
60 manual: 0x201, 0x202, 0x204, 0x205 [#f2]_
61 ============== ============= ============================================
62
63 .. [#f1] VIA686A/B only
64 .. [#f2] With YMF744/754 chips, the port address can be chosen arbitrarily
65
66 The following drivers don't support gameport natively, but there are
67 additional modules. Load the corresponding module to add the gameport
68 support.
69
70 ======= =================
71 Driver Additional Module
72 ======= =================
73 emu10k1 emu10k1-gp
74 fm801 fm801-gp
75 ======= =================
76
77 Note: the "pcigame" and "cs461x" modules are for the OSS drivers only.
78 These ALSA drivers (cs46xx, trident and au88x0) have the
79 built-in gameport support.
80
81 As mentioned above, ALSA PCI drivers have the built-in gameport
82 support, so you don't have to load ns558 module. Just load "joydev"
83 and the appropriate adapter module (e.g. "analog").
84
85
86 ISA Cards
87 ---------
88
89 ALSA ISA drivers don't have the built-in gameport support.
90 Instead, you need to load "ns558" module in addition to "joydev" and
91 the adapter module (e.g. "analog").
92

3. 한국어 전문 번역

영어 원문의 문단 순서와 의미를 유지한 전체 번역입니다. 코드, 함수명, symbol과 URL은 원문 표기를 유지합니다.

GAMEPORT와 ISA·PCI 차이

1-27

Takashi Iwai가 2003-10-14에 작성한 문서다. ALSA 드라이버에서 조이스틱을 쓰려면 먼저 Linux 커널의 GAMEPORT 지원을 켜야 하며 자세한 내용은 `Documentation/input/joydev/joystick.rst`를 참조한다.

ALSA 조이스틱 지원은 ISA와 PCI 카드가 다르다. ISA(PnP) 카드는 보통 독립 모듈 `ns558`이 게임포트를 처리한다. ALSA PCI 드라이버는 게임포트 지원을 내장하므로 드라이버를 커널에 빌트인하면 `CONFIG_GAMEPORT`도 `y`여야 한다. 그렇지 않으면 해당 카드의 게임포트가 아무 경고 없이 비활성화된다.

일부 어댑터 모듈은 적재할 때 장치의 물리 연결을 탐지하므로, 모듈을 적재하기 전에 조이스틱을 연결하는 편이 안전하다.

ALSA 게임포트 준비
PCI 드라이버 빌트인CONFIG_GAMEPORT=y내장 gameport 사용
ISA(PnP)ns558joydevanalog 등 어댑터 모듈
어댑터 적재 전조이스틱 물리 연결탐지 안정성 향상

카드 버스 유형에 따라 필요한 커널·모듈 구성이 달라진다.

=======================================
Analog Joystick Support on ALSA Drivers
=======================================

Oct. 14, 2003

Takashi Iwai <tiwai@suse.de>

General
-------

First of all, you need to enable GAMEPORT support on Linux kernel for
using a joystick with the ALSA driver.  For the details of gameport
support, refer to Documentation/input/joydev/joystick.rst.

The joystick support of ALSA drivers is different between ISA and PCI
cards.  In the case of ISA (PnP) cards, it's usually handled by the
independent module (ns558).  Meanwhile, the ALSA PCI drivers have the
built-in gameport support.  Hence, when the ALSA PCI driver is built
in the kernel, CONFIG_GAMEPORT must be 'y', too.  Otherwise, the
gameport support on that card will be (silently) disabled.

Some adapter modules probe the physical connection of the device at
the load time.  It'd be safer to plug in the joystick device before
loading the module.

PCI 드라이버별 모듈 옵션

28-85

PCI 카드에서는 해당 모듈 옵션으로 조이스틱을 켠다. 옵션 없이 항상 활성화되는 드라이버도 있다. 과거 ALSA에는 동적 활성화 제어 API가 있었지만 시스템 안정성과 자원 관리를 위해 정적 모듈 옵션으로 바뀌었다.

PCI 조이스틱 기본 지원
드라이버모듈 옵션허용값
als4000joystick_port0 비활성(기본), 1 자동, 임의 주소 예: 0x200
au88x0N/AN/A
azf3328joystick0 비활성, 1 활성, -1 자동(기본)
ens1370joystick0 비활성(기본), 1 활성
ens1371joystick_port0 비활성(기본), 1 자동, 0x200/0x208/0x210/0x218
cmipcijoystick_port0 비활성(기본), 1 자동, 임의 주소 예: 0x200
cs4281N/AN/A
cs46xxN/AN/A
es1938N/AN/A
es1968joystick0 비활성(기본), 1 활성
sonicvibesN/AN/A
tridentN/AN/A
via82xxjoystick0 비활성(기본), 1 활성; VIA686A/B만
ymfpcijoystick_port0 비활성(기본), 1 자동, 0x201/0x202/0x204/0x205

원문 표의 드라이버·옵션·허용값을 모두 보존한다.

YMF744/754 칩은 포트 주소를 임의로 선택할 수 있다. `emu10k1`과 `fm801`은 게임포트를 드라이버 안에 직접 지원하지 않지만 각각 `emu10k1-gp`, `fm801-gp` 추가 모듈을 적재하면 된다.

추가 게임포트 모듈
드라이버추가 모듈
emu10k1emu10k1-gp
fm801fm801-gp

게임포트를 별도 모듈로 제공하는 PCI 드라이버다.

`pcigame`과 `cs461x`는 OSS 드라이버 전용이다. ALSA의 `cs46xx`, `trident`, `au88x0`에는 게임포트가 내장되어 있다. ALSA PCI 드라이버에는 `ns558`이 필요 없고 `joydev`와 `analog` 같은 적절한 어댑터 모듈만 적재하면 된다.

PCI Cards
---------

For PCI cards, the joystick is enabled when the appropriate module
option is specified.  Some drivers don't need options, and the
joystick support is always enabled.  In the former ALSA version, there
was a dynamic control API for the joystick activation.  It was
changed, however, to the static module options because of the system
stability and the resource management.

The following PCI drivers support the joystick natively.

==============        =============        ============================================
Driver                Module Option        Available Values
==============        =============        ============================================
als4000                joystick_port        0 = disable (default), 1 = auto-detect,
                                manual: any address (e.g. 0x200)
au88x0                N/A                N/A
azf3328                joystick        0 = disable, 1 = enable, -1 = auto (default)
ens1370                joystick        0 = disable (default), 1 = enable
ens1371                joystick_port        0 = disable (default), 1 = auto-detect,
                                manual: 0x200, 0x208, 0x210, 0x218
cmipci                joystick_port        0 = disable (default), 1 = auto-detect,
                                manual: any address (e.g. 0x200)
cs4281                N/A                N/A
cs46xx                N/A                N/A
es1938                N/A                N/A
es1968                joystick        0 = disable (default), 1 = enable
sonicvibes        N/A                N/A
trident                N/A                N/A
via82xx [#f1]_        joystick        0 = disable (default), 1 = enable
ymfpci                joystick_port        0 = disable (default), 1 = auto-detect,
                                manual: 0x201, 0x202, 0x204, 0x205 [#f2]_
==============        =============        ============================================

.. [#f1] VIA686A/B only
.. [#f2] With YMF744/754 chips, the port address can be chosen arbitrarily

The following drivers don't support gameport natively, but there are
additional modules.  Load the corresponding module to add the gameport
support.

=======        =================
Driver        Additional Module
=======        =================
emu10k1        emu10k1-gp
fm801        fm801-gp
=======        =================

Note: the "pcigame" and "cs461x" modules are for the OSS drivers only.
These ALSA drivers (cs46xx, trident and au88x0) have the
built-in gameport support.

As mentioned above, ALSA PCI drivers have the built-in gameport
support, so you don't have to load ns558 module.  Just load "joydev"
and the appropriate adapter module (e.g. "analog").

ISA 카드

86-91

ALSA ISA 드라이버는 게임포트 지원을 내장하지 않는다. 따라서 `joydev`와 `analog` 같은 어댑터 모듈에 더해 `ns558`도 적재해야 한다.

ISA 조이스틱 모듈
계층모듈 예
게임포트ns558
입력 장치joydev
조이스틱 어댑터analog 등

ISA 카드에서 필요한 세 계층이다.

ISA Cards
---------

ALSA ISA drivers don't have the built-in gameport support.
Instead, you need to load "ns558" module in addition to "joydev" and
the adapter module (e.g. "analog").