Rev 1063 | Details | Compare with Previous | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
538 | mauro | 1 | /* |
2 | * Project: S.Ha.R.K. |
||
3 | * |
||
4 | * Coordinators: |
||
5 | * Giorgio Buttazzo <giorgio@sssup.it> |
||
6 | * Paolo Gai <pj@gandalf.sssup.it> |
||
7 | * |
||
8 | * Authors : |
||
9 | * Mauro Marinoni <mauro.marinoni@unipv.it> |
||
10 | * |
||
11 | * |
||
12 | * ReTiS Lab (Scuola Superiore S.Anna - Pisa - Italy) |
||
13 | * |
||
14 | * http://www.sssup.it |
||
15 | * http://retis.sssup.it |
||
16 | * http://shark.sssup.it |
||
17 | */ |
||
18 | |||
1063 | tullio | 19 | /* |
20 | * This program is free software; you can redistribute it and/or modify |
||
21 | * it under the terms of the GNU General Public License as published by |
||
22 | * the Free Software Foundation; either version 2 of the License, or |
||
23 | * (at your option) any later version. |
||
24 | * |
||
25 | * This program is distributed in the hope that it will be useful, |
||
26 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
||
27 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
||
28 | * GNU General Public License for more details. |
||
29 | * |
||
30 | * You should have received a copy of the GNU General Public License |
||
31 | * along with this program; if not, write to the Free Software |
||
32 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
||
33 | * |
||
34 | */ |
||
35 | |||
538 | mauro | 36 | /* Game Header Linux Input Driver*/ |
37 | |||
38 | #ifndef __SHARK_JOY26_H__ |
||
39 | #define __SHARK_JOY26_H__ |
||
40 | |||
548 | mauro | 41 | /* Flag Codes */ |
42 | #define BTN1_BIT 0x01 |
||
43 | #define BTN2_BIT 0x02 |
||
44 | #define BTN3_BIT 0x04 |
||
45 | #define BTN4_BIT 0x08 |
||
46 | |||
826 | mauro | 47 | #define isButton1Pressed(b) (b & BTN1_BIT) |
48 | #define isButton2Pressed(b) (b & BTN2_BIT) |
||
49 | #define isButton3Pressed(b) (b & BTN3_BIT) |
||
50 | #define isButton4Pressed(b) (b & BTN4_BIT) |
||
51 | #define isButtonPressed(b, n) (b & (1<<n)) |
||
548 | mauro | 52 | |
53 | void joy_getstatus(int *axe0, int *axe1, int *axe2, int *axe3, int *button); |
||
54 | void joy_setstatus(int axe0, int axe1, int axe2, int axe3, int button); |
||
55 | |||
547 | mauro | 56 | void joy_enable(void); |
57 | void joy_disable(void); |
||
58 | |||
549 | mauro | 59 | int JOY26_installed(void); |
538 | mauro | 60 | int JOY26_init(void); |
61 | int JOY26_close(void); |
||
62 | #endif |
||
63 |