Tachyon (current)  Current Main Branch
Macros | Typedefs | Functions
eventio.h File Reference

Go to the source code of this file.

Macros

#define EVENTIO_SUCCESS   0
 
#define EVENTIO_ERROR   -1
 
#define EVENTIO_BACK   0x0001
 
#define EVENTIO_TASK   0x0002
 
#define EVENTIO_START   0x0004
 
#define EVENTIO_UNUSED08   0x0008
 
#define EVENTIO_UNUSED10   0x0010
 
#define EVENTIO_UNUSED20   0x0020
 
#define EVENTIO_UNUSED40   0x0040
 
#define EVENTIO_UNUSED80   0x0080
 
#define EVENTIO_GAMEPAD_A   0x0100
 
#define EVENTIO_GAMEPAD_B   0x0200
 
#define EVENTIO_GAMEPAD_X   0x0400
 
#define EVENTIO_GAMEPAD_Y   0x0800
 
#define EVENTIO_TL   0x1000
 
#define EVENTIO_TR   0x2000
 
#define EVENTIO_THUMBL   0x4000
 
#define EVENTIO_THUMBR   0x8000
 
#define EVENTIO_JOYSTICK_STD   0x01
 
#define EVENTIO_JOYSTICK_LOGIF310   0x02
 
#define EVENTIO_JOYSTICK_NYKO   0x04
 
#define EVENTIO_SPACEBALL_STD   0x01
 

Typedefs

typedef void * evio_handle
 

Functions

evio_handle evio_open (const char *devpath)
 
int evio_close (evio_handle)
 
int evio_is_joystick (evio_handle)
 
int evio_print_devinfo (evio_handle)
 
int evio_get_joystick_status (evio_handle, float *abs_x1, float *abs_y1, float *abs_x2, float *abs_y2, int *buttons)
 

Macro Definition Documentation

◆ EVENTIO_BACK

#define EVENTIO_BACK   0x0001

Definition at line 23 of file eventio.h.

Referenced by evio_get_joystick_status().

◆ EVENTIO_ERROR

#define EVENTIO_ERROR   -1

Definition at line 21 of file eventio.h.

Referenced by evio_print_devinfo().

◆ EVENTIO_GAMEPAD_A

#define EVENTIO_GAMEPAD_A   0x0100

Definition at line 33 of file eventio.h.

Referenced by evio_get_joystick_status().

◆ EVENTIO_GAMEPAD_B

#define EVENTIO_GAMEPAD_B   0x0200

Definition at line 34 of file eventio.h.

Referenced by evio_get_joystick_status().

◆ EVENTIO_GAMEPAD_X

#define EVENTIO_GAMEPAD_X   0x0400

Definition at line 35 of file eventio.h.

Referenced by evio_get_joystick_status().

◆ EVENTIO_GAMEPAD_Y

#define EVENTIO_GAMEPAD_Y   0x0800

Definition at line 36 of file eventio.h.

Referenced by evio_get_joystick_status().

◆ EVENTIO_JOYSTICK_LOGIF310

#define EVENTIO_JOYSTICK_LOGIF310   0x02

Definition at line 44 of file eventio.h.

Referenced by evio_get_joystick_status(), and evio_open().

◆ EVENTIO_JOYSTICK_NYKO

#define EVENTIO_JOYSTICK_NYKO   0x04

Definition at line 45 of file eventio.h.

Referenced by evio_get_joystick_status(), and evio_open().

◆ EVENTIO_JOYSTICK_STD

#define EVENTIO_JOYSTICK_STD   0x01

Definition at line 43 of file eventio.h.

Referenced by evio_get_joystick_status(), and evio_open().

◆ EVENTIO_SPACEBALL_STD

#define EVENTIO_SPACEBALL_STD   0x01

Definition at line 47 of file eventio.h.

Referenced by evio_open().

◆ EVENTIO_START

#define EVENTIO_START   0x0004

Definition at line 25 of file eventio.h.

Referenced by evio_get_joystick_status().

◆ EVENTIO_SUCCESS

#define EVENTIO_SUCCESS   0

Definition at line 20 of file eventio.h.

Referenced by evio_print_devinfo().

◆ EVENTIO_TASK

#define EVENTIO_TASK   0x0002

Definition at line 24 of file eventio.h.

Referenced by evio_get_joystick_status().

◆ EVENTIO_THUMBL

#define EVENTIO_THUMBL   0x4000

Definition at line 40 of file eventio.h.

Referenced by evio_get_joystick_status().

◆ EVENTIO_THUMBR

#define EVENTIO_THUMBR   0x8000

Definition at line 41 of file eventio.h.

Referenced by evio_get_joystick_status().

◆ EVENTIO_TL

#define EVENTIO_TL   0x1000

Definition at line 38 of file eventio.h.

Referenced by evio_get_joystick_status().

◆ EVENTIO_TR

#define EVENTIO_TR   0x2000

Definition at line 39 of file eventio.h.

Referenced by evio_get_joystick_status().

◆ EVENTIO_UNUSED08

#define EVENTIO_UNUSED08   0x0008

Definition at line 26 of file eventio.h.

◆ EVENTIO_UNUSED10

#define EVENTIO_UNUSED10   0x0010

Definition at line 28 of file eventio.h.

◆ EVENTIO_UNUSED20

#define EVENTIO_UNUSED20   0x0020

Definition at line 29 of file eventio.h.

◆ EVENTIO_UNUSED40

#define EVENTIO_UNUSED40   0x0040

Definition at line 30 of file eventio.h.

◆ EVENTIO_UNUSED80

#define EVENTIO_UNUSED80   0x0080

Definition at line 31 of file eventio.h.

Typedef Documentation

◆ evio_handle

typedef void* evio_handle

Definition at line 49 of file eventio.h.

Function Documentation

◆ evio_close()

int evio_close ( evio_handle  )

Definition at line 172 of file eventio.c.

References evio::fd.

◆ evio_get_joystick_status()

int evio_get_joystick_status ( evio_handle  ,
float *  abs_x1,
float *  abs_y1,
float *  abs_x2,
float *  abs_y2,
int *  buttons 
)

◆ evio_is_joystick()

int evio_is_joystick ( evio_handle  )

◆ evio_open()

evio_handle evio_open ( const char *  devpath)

◆ evio_print_devinfo()

int evio_print_devinfo ( evio_handle  )