Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros | Functions
touchkit_ps2.c File Reference
#include <linux/kernel.h>
#include <linux/input.h>
#include <linux/serio.h>
#include <linux/libps2.h>
#include "psmouse.h"
#include "touchkit_ps2.h"

Go to the source code of this file.

Macros

#define TOUCHKIT_MAX_XC   0x07ff
 
#define TOUCHKIT_MAX_YC   0x07ff
 
#define TOUCHKIT_CMD   0x0a
 
#define TOUCHKIT_CMD_LENGTH   1
 
#define TOUCHKIT_CMD_ACTIVE   'A'
 
#define TOUCHKIT_CMD_FIRMWARE_VERSION   'D'
 
#define TOUCHKIT_CMD_CONTROLLER_TYPE   'E'
 
#define TOUCHKIT_SEND_PARMS(s, r, c)   ((s) << 12 | (r) << 8 | (c))
 
#define TOUCHKIT_GET_TOUCHED(packet)   (((packet)[0]) & 0x01)
 
#define TOUCHKIT_GET_X(packet)   (((packet)[1] << 7) | (packet)[2])
 
#define TOUCHKIT_GET_Y(packet)   (((packet)[3] << 7) | (packet)[4])
 

Functions

int touchkit_ps2_detect (struct psmouse *psmouse, bool set_properties)
 

Macro Definition Documentation

#define TOUCHKIT_CMD   0x0a

Definition at line 40 of file touchkit_ps2.c.

#define TOUCHKIT_CMD_ACTIVE   'A'

Definition at line 43 of file touchkit_ps2.c.

#define TOUCHKIT_CMD_CONTROLLER_TYPE   'E'

Definition at line 45 of file touchkit_ps2.c.

#define TOUCHKIT_CMD_FIRMWARE_VERSION   'D'

Definition at line 44 of file touchkit_ps2.c.

#define TOUCHKIT_CMD_LENGTH   1

Definition at line 41 of file touchkit_ps2.c.

#define TOUCHKIT_GET_TOUCHED (   packet)    (((packet)[0]) & 0x01)

Definition at line 49 of file touchkit_ps2.c.

#define TOUCHKIT_GET_X (   packet)    (((packet)[1] << 7) | (packet)[2])

Definition at line 50 of file touchkit_ps2.c.

#define TOUCHKIT_GET_Y (   packet)    (((packet)[3] << 7) | (packet)[4])

Definition at line 51 of file touchkit_ps2.c.

#define TOUCHKIT_MAX_XC   0x07ff

Definition at line 37 of file touchkit_ps2.c.

#define TOUCHKIT_MAX_YC   0x07ff

Definition at line 38 of file touchkit_ps2.c.

#define TOUCHKIT_SEND_PARMS (   s,
  r,
  c 
)    ((s) << 12 | (r) << 8 | (c))

Definition at line 47 of file touchkit_ps2.c.

Function Documentation

int touchkit_ps2_detect ( struct psmouse psmouse,
bool  set_properties 
)

Definition at line 69 of file touchkit_ps2.c.