summaryrefslogtreecommitdiff
path: root/sensei-raw-ctl.c
diff options
context:
space:
mode:
authorPřemysl Janouch <p.janouch@gmail.com>2013-06-02 23:50:33 +0200
committerPřemysl Janouch <p.janouch@gmail.com>2013-06-08 21:03:58 +0200
commitc05d522a1d840b801c6bdaf635b61a9cd6a991b3 (patch)
tree312c94d8b9d941fe47b878596a444d70d97d3405 /sensei-raw-ctl.c
parent2c250916392c36ec107d6b5d19d9485bf115bd9d (diff)
downloadsensei-raw-ctl-c05d522a1d840b801c6bdaf635b61a9cd6a991b3.tar.gz
sensei-raw-ctl-c05d522a1d840b801c6bdaf635b61a9cd6a991b3.tar.xz
sensei-raw-ctl-c05d522a1d840b801c6bdaf635b61a9cd6a991b3.zip
Add a GTK+ GUI
Diffstat (limited to 'sensei-raw-ctl.c')
-rw-r--r--sensei-raw-ctl.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/sensei-raw-ctl.c b/sensei-raw-ctl.c
index 8e0c18b..970c31b 100644
--- a/sensei-raw-ctl.c
+++ b/sensei-raw-ctl.c
@@ -86,8 +86,8 @@ out:
#define USB_VENDOR_STEELSERIES 0x1038
#define USB_PRODUCT_STEELSERIES_SENSEI 0x1369
-#define GET_REPORT 0x01
-#define SET_REPORT 0x09
+#define USB_GET_REPORT 0x01
+#define USB_SET_REPORT 0x09
#define SENSEI_CTL_IFACE 0
@@ -108,7 +108,7 @@ enum sensei_pulsation
/* Just guessing the names, could be anything */
enum sensei_mode
{
- MODE_COMPATIBILITY = 1,
+ MODE_LEGACY = 1,
MODE_NORMAL
};
@@ -148,7 +148,7 @@ sensei_send_command (libusb_device_handle *device,
{
int result = libusb_control_transfer (device, LIBUSB_ENDPOINT_OUT
| LIBUSB_REQUEST_TYPE_CLASS | LIBUSB_RECIPIENT_INTERFACE,
- SET_REPORT, 0x0200, 0x0000, data, length, 0);
+ USB_SET_REPORT, 0x0200, 0x0000, data, length, 0);
return result < 0 ? result : 0;
}
@@ -215,7 +215,7 @@ sensei_load_config (libusb_device_handle *device,
int result = libusb_control_transfer (device, LIBUSB_ENDPOINT_IN
| LIBUSB_REQUEST_TYPE_CLASS | LIBUSB_RECIPIENT_INTERFACE,
- GET_REPORT, 0x0300, 0x0000, data, sizeof data, 0);
+ USB_GET_REPORT, 0x0300, 0x0000, data, sizeof data, 0);
if (result < 0)
return result;
@@ -287,7 +287,7 @@ show_usage (const char *program_name)
printf (" --version Show program version and exit\n");
printf (" --show Show current mouse settings and exit\n");
printf (" --mode X Set the mode of the mouse"
- " (can be either 'compat' or 'normal')\n");
+ " (can be either 'legacy' or 'normal')\n");
printf (" --polling X Set polling to X Hz (1000, 500, 250, 125)\n");
printf (" --cpi-on X Set CPI with the LED on to X\n");
printf (" --cpi-off X Set CPI with the LED off to X\n");
@@ -369,8 +369,8 @@ parse_options (int argc, char *argv[],
options->save_to_rom = true;
break;
case 'm':
- if (!strcasecmp (optarg, "compat"))
- new_config->mode = MODE_COMPATIBILITY;
+ if (!strcasecmp (optarg, "legacy"))
+ new_config->mode = MODE_LEGACY;
else if (!strcasecmp (optarg, "normal"))
new_config->mode = MODE_NORMAL;
else