Skip to content

Commit

Permalink
Merge SteelSeries Arctis 1 drivers
Browse files Browse the repository at this point in the history
Now SteelSeries Arctis 1 and SteelSeries Arctis 1 for XBox
differ only in function naming and device IDs, there is no
reason to keep two separate drivers for these two devices.
  • Loading branch information
iv-m committed May 25, 2021
1 parent 226898f commit a966b92
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 137 deletions.
10 changes: 4 additions & 6 deletions src/device_registry.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,12 @@
#include "devices/logitech_zone_wired.h"
#include "devices/roccat_elo_7_1_air.h"
#include "devices/steelseries_arctis_1.h"
#include "devices/steelseries_arctis_1_xbox.h"
#include "devices/steelseries_arctis_7.h"
#include "devices/steelseries_arctis_9.h"

#include <string.h>

#define NUMDEVICES 13
#define NUMDEVICES 12

// array of pointers to device
static struct device*(devicelist[NUMDEVICES]);
Expand All @@ -32,10 +31,9 @@ void init_devices()
arctis_7_init(&devicelist[6]);
arctis_9_init(&devicelist[7]);
gpro_init(&devicelist[8]);
arctis_1_xbox_init(&devicelist[9]);
zone_wired_init(&devicelist[10]);
elo71Air_init(&devicelist[11]);
g432_init(&devicelist[12]);
zone_wired_init(&devicelist[9]);
elo71Air_init(&devicelist[10]);
g432_init(&devicelist[11]);
}

int get_device(struct device* device_found, uint16_t idVendor, uint16_t idProduct)
Expand Down
2 changes: 0 additions & 2 deletions src/devices/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,6 @@ set(SOURCE_FILES ${SOURCE_FILES}
${CMAKE_CURRENT_SOURCE_DIR}/logitech_g533.h
${CMAKE_CURRENT_SOURCE_DIR}/steelseries_arctis_1.c
${CMAKE_CURRENT_SOURCE_DIR}/steelseries_arctis_1.h
${CMAKE_CURRENT_SOURCE_DIR}/steelseries_arctis_1_xbox.c
${CMAKE_CURRENT_SOURCE_DIR}/steelseries_arctis_1_xbox.h
${CMAKE_CURRENT_SOURCE_DIR}/steelseries_arctis_7.c
${CMAKE_CURRENT_SOURCE_DIR}/steelseries_arctis_7.h
${CMAKE_CURRENT_SOURCE_DIR}/steelseries_arctis_9.c
Expand Down
3 changes: 2 additions & 1 deletion src/devices/steelseries_arctis_1.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,9 @@
static struct device device_arctis;

#define ID_ARCTIS_1 0x12b3
#define ID_ARCTIS_1_XBOX 0x12b6

static const uint16_t PRODUCT_IDS[] = { ID_ARCTIS_1 };
static const uint16_t PRODUCT_IDS[] = { ID_ARCTIS_1, ID_ARCTIS_1_XBOX };

static int arctis_1_send_sidetone(hid_device* device_handle, uint8_t num);
static int arctis_1_request_battery(hid_device* device_handle);
Expand Down
125 changes: 0 additions & 125 deletions src/devices/steelseries_arctis_1_xbox.c

This file was deleted.

3 changes: 0 additions & 3 deletions src/devices/steelseries_arctis_1_xbox.h

This file was deleted.

0 comments on commit a966b92

Please sign in to comment.