gamepad.h File Reference

Main header. Contains definitions, typedefs and global vars. More...

#include <lar/lar.h>
#include <sys/ioctl.h>
#include <sys/types.h>
#include <fcntl.h>
#include <unistd.h>
#include <linux/joystick.h>
Include dependency graph for gamepad.h:
This graph shows which files directly or indirectly include this file:

Data Structures

struct  TYPE_mapping
 This structure is used to map the buttons on the gamepad to their specific functions. More...
struct  TYPE_gamepad

Defines

#define UNKNOWN   0
#define MSXBOX360   1
#define LOGITECHWINGMAN   2
#define MSXBOX360_2   3
#define GAMEPAD_DEADSPOT   1
#define GAMEPAD_DEADSPOT_SIZE   0.2

Functions

int main (int argc, char **argv)
int initialize_gamepad (TYPE_gamepad *gamepad, char *device)
void set_deadspot_gamepad (TYPE_gamepad *gamepad, int on_off, double size)
int get_gamepad_state (TYPE_gamepad *gamepad)
void close_gamepad (TYPE_gamepad *gamepad)
double normalize (double min, double max, double value)
 Generic normalisation function.
int control_mapping (TYPE_mapping *mapping)
 This functions initializes the button mapping for the connected gamepad.
void robot_state_handler (void)
 Handler activated when a robot_state message is received.
void shutdown_module (int x)
 makes a clean shutdown of the program

Variables

TYPE_executionflags flags
 Include the interface.
TYPE_gamepad gamepad
double maximum_dir

Detailed Description

Main header. Contains definitions, typedefs and global vars.

Generated on Wed Jun 2 12:43:03 2010 for LAR Atlas by  doxygen 1.6.3