Update Instant mouse controller files to new standardized header comment
This commit is contained in:
parent
1f3bcaf52a
commit
84077e9dc2
5 changed files with 59 additions and 38 deletions
|
|
@ -1,13 +1,16 @@
|
||||||
/*-----------------------------------------*\
|
/*---------------------------------------------------------*\
|
||||||
| InstantMouseController.cpp |
|
| InstantMouseController.cpp |
|
||||||
| |
|
| |
|
||||||
| Driver for Instant mouse lighting |
|
| Driver for Instant mouse |
|
||||||
| controller |
|
| |
|
||||||
| |
|
| Morgan Guimard (morg) 19 Jan 2024 |
|
||||||
| Guimard Morgan (morg) 1/19/2024 |
|
| |
|
||||||
\*-----------------------------------------*/
|
| This file is part of the OpenRGB project |
|
||||||
#include "InstantMouseController.h"
|
| SPDX-License-Identifier: GPL-2.0-only |
|
||||||
|
\*---------------------------------------------------------*/
|
||||||
|
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
#include "InstantMouseController.h"
|
||||||
|
|
||||||
InstantMouseController::InstantMouseController(hid_device* dev_handle, const hid_device_info& info)
|
InstantMouseController::InstantMouseController(hid_device* dev_handle, const hid_device_info& info)
|
||||||
{
|
{
|
||||||
|
|
@ -50,7 +53,7 @@ std::string InstantMouseController::GetFirmwareVersion()
|
||||||
}
|
}
|
||||||
|
|
||||||
void InstantMouseController::SendColor(RGBColor color)
|
void InstantMouseController::SendColor(RGBColor color)
|
||||||
{
|
{
|
||||||
/*---------------------------------------------------------*\
|
/*---------------------------------------------------------*\
|
||||||
| Packet details |
|
| Packet details |
|
||||||
| 07 14 XG RB 00 00 00 00 |
|
| 07 14 XG RB 00 00 00 00 |
|
||||||
|
|
@ -76,7 +79,7 @@ void InstantMouseController::SendColor(RGBColor color)
|
||||||
}
|
}
|
||||||
|
|
||||||
void InstantMouseController::SetMode(uint8_t mode_value, uint8_t speed, uint8_t brightness, uint8_t direction)
|
void InstantMouseController::SetMode(uint8_t mode_value, uint8_t speed, uint8_t brightness, uint8_t direction)
|
||||||
{
|
{
|
||||||
/*---------------------------------------------------------*\
|
/*---------------------------------------------------------*\
|
||||||
| Packet details: |
|
| Packet details: |
|
||||||
| 07 13 FF MS DN -B -- -- |
|
| 07 13 FF MS DN -B -- -- |
|
||||||
|
|
@ -100,7 +103,7 @@ void InstantMouseController::SetMode(uint8_t mode_value, uint8_t speed, uint8_t
|
||||||
pkt[1] = INSTANT_MOUSE_SET_MODE;
|
pkt[1] = INSTANT_MOUSE_SET_MODE;
|
||||||
pkt[2] = 0xFF;
|
pkt[2] = 0xFF;
|
||||||
|
|
||||||
pkt[3] = (mode_value << 4) | (speed & 0xF);
|
pkt[3] = (mode_value << 4) | (speed & 0xF);
|
||||||
pkt[4] = (direction << 4) | led_mask;
|
pkt[4] = (direction << 4) | led_mask;
|
||||||
pkt[5] = 0xF - (brightness & 0xF);
|
pkt[5] = 0xF - (brightness & 0xF);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,16 +1,19 @@
|
||||||
/*-----------------------------------------*\
|
/*---------------------------------------------------------*\
|
||||||
| InstantMouseController.h |
|
| InstantMouseController.h |
|
||||||
| |
|
| |
|
||||||
| Driver for Instant mouse lighting |
|
| Driver for Instant mouse |
|
||||||
| controller - header file |
|
| |
|
||||||
| |
|
| Morgan Guimard (morg) 19 Jan 2024 |
|
||||||
| Guimard Morgan (morg) 1/19/2024 |
|
| |
|
||||||
\*-----------------------------------------*/
|
| This file is part of the OpenRGB project |
|
||||||
|
| SPDX-License-Identifier: GPL-2.0-only |
|
||||||
|
\*---------------------------------------------------------*/
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#include "RGBController.h"
|
|
||||||
#include <string>
|
#include <string>
|
||||||
#include <hidapi/hidapi.h>
|
#include <hidapi/hidapi.h>
|
||||||
|
#include "RGBController.h"
|
||||||
|
|
||||||
#define INSTANT_MOUSE_REPORT_ID 0x07
|
#define INSTANT_MOUSE_REPORT_ID 0x07
|
||||||
#define INSTANT_MOUSE_REPORT_SIZE 8
|
#define INSTANT_MOUSE_REPORT_SIZE 8
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,14 @@
|
||||||
|
/*---------------------------------------------------------*\
|
||||||
|
| InstantMouseControllerDetect.cpp |
|
||||||
|
| |
|
||||||
|
| Detector for Instant mouse |
|
||||||
|
| |
|
||||||
|
| Morgan Guimard (morg) 19 Jan 2024 |
|
||||||
|
| |
|
||||||
|
| This file is part of the OpenRGB project |
|
||||||
|
| SPDX-License-Identifier: GPL-2.0-only |
|
||||||
|
\*---------------------------------------------------------*/
|
||||||
|
|
||||||
#include "Detector.h"
|
#include "Detector.h"
|
||||||
#include "InstantMouseController.h"
|
#include "InstantMouseController.h"
|
||||||
#include "RGBController.h"
|
#include "RGBController.h"
|
||||||
|
|
|
||||||
|
|
@ -1,11 +1,13 @@
|
||||||
/*-----------------------------------------*\
|
/*---------------------------------------------------------*\
|
||||||
| RGBController_InstantMouse.cpp |
|
| RGBController_InstantMouse.cpp |
|
||||||
| |
|
| |
|
||||||
| Generic RGB Interface for OpenRGB |
|
| RGBController for Instant mouse |
|
||||||
| Instant mouse RGB USB Driver |
|
| |
|
||||||
| |
|
| Morgan Guimard (morg) 19 Jan 2024 |
|
||||||
| Guimard Morgan (morg) 1/19/2024 |
|
| |
|
||||||
\*-----------------------------------------*/
|
| This file is part of the OpenRGB project |
|
||||||
|
| SPDX-License-Identifier: GPL-2.0-only |
|
||||||
|
\*---------------------------------------------------------*/
|
||||||
|
|
||||||
#include "RGBController_InstantMouse.h"
|
#include "RGBController_InstantMouse.h"
|
||||||
|
|
||||||
|
|
@ -24,7 +26,7 @@
|
||||||
|
|
||||||
RGBController_InstantMouse::RGBController_InstantMouse(InstantMouseController* controller_ptr)
|
RGBController_InstantMouse::RGBController_InstantMouse(InstantMouseController* controller_ptr)
|
||||||
{
|
{
|
||||||
controller = controller_ptr;
|
controller = controller_ptr;
|
||||||
vendor = "Instant Microelectronics";
|
vendor = "Instant Microelectronics";
|
||||||
type = DEVICE_TYPE_MOUSE;
|
type = DEVICE_TYPE_MOUSE;
|
||||||
description = "Instant USB Gaming Mouse";
|
description = "Instant USB Gaming Mouse";
|
||||||
|
|
|
||||||
|
|
@ -1,11 +1,13 @@
|
||||||
/*-----------------------------------------*\
|
/*---------------------------------------------------------*\
|
||||||
| RGBController_InstantMouse.h |
|
| RGBController_InstantMouse.h |
|
||||||
| |
|
| |
|
||||||
| Generic RGB Interface for OpenRGB |
|
| RGBController for Instant mouse |
|
||||||
| Instant mouse RGB USB Driver |
|
| |
|
||||||
| |
|
| Morgan Guimard (morg) 19 Jan 2024 |
|
||||||
| Guimard Morgan (morg) 1/19/2024 |
|
| |
|
||||||
\*-----------------------------------------*/
|
| This file is part of the OpenRGB project |
|
||||||
|
| SPDX-License-Identifier: GPL-2.0-only |
|
||||||
|
\*---------------------------------------------------------*/
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue