Update ENE SMBus controller files to new standardized header comment

This commit is contained in:
Adam Honse 2024-05-16 22:06:29 -05:00
parent 9b1ea375b8
commit 50ec1095c1
17 changed files with 200 additions and 142 deletions

View file

@ -1,18 +1,17 @@
/*-----------------------------------------*\
| ENESMBusController.cpp |
| |
| Driver for ENE SMBus RGB lighting |
| controller |
| |
| Formerly known as ASUS Aura SMBus. ASUS |
| AURA chips are rebranded ENE controllers |
| |
| Adam Honse (CalcProgrammer1) 8/19/2018 |
\*-----------------------------------------*/
/*---------------------------------------------------------*\
| ENESMBusController.cpp |
| |
| Driver for ENE SMBus devices |
| |
| Adam Honse (CalcProgrammer1) 19 Aug 2018 |
| |
| This file is part of the OpenRGB project |
| SPDX-License-Identifier: GPL-2.0-only |
\*---------------------------------------------------------*/
#include <cstring>
#include "ENESMBusController.h"
#include "LogManager.h"
#include <cstring>
static const char* ene_channels[] = /* ENE channel strings */
{

View file

@ -1,24 +1,24 @@
/*-----------------------------------------*\
| ENESMBusController.h |
| |
| Definitions and types for ENE SMBus RGB |
| lighting controller |
| |
| Formerly known as ASUS Aura SMBus. ASUS |
| AURA chips are rebranded ENE controllers |
| |
| Adam Honse (CalcProgrammer1) 8/19/2018 |
\*-----------------------------------------*/
/*---------------------------------------------------------*\
| ENESMBusController.h |
| |
| Driver for ENE SMBus devices |
| |
| Adam Honse (CalcProgrammer1) 19 Aug 2018 |
| |
| This file is part of the OpenRGB project |
| SPDX-License-Identifier: GPL-2.0-only |
\*---------------------------------------------------------*/
#pragma once
#include <string>
#include "ENESMBusInterface.h"
#include "RGBController.h"
#pragma once
#define ENE_APPLY_VAL 0x01 /* Value for Apply Changes Register */
#define ENE_SAVE_VAL 0xAA /* Value for Save Changes */
#define ENE_NUM_ZONES 8 /* Number of ENE config table zones */
enum
{
ENE_REG_DEVICE_NAME = 0x1000, /* Device String 16 bytes */

View file

@ -1,3 +1,15 @@
/*---------------------------------------------------------*\
| ENESMBusControllerDetect.cpp |
| |
| Detector for ENE SMBus devices |
| |
| This file is part of the OpenRGB project |
| SPDX-License-Identifier: GPL-2.0-only |
\*---------------------------------------------------------*/
#include <stdio.h>
#include <stdlib.h>
#include <vector>
#include "Detector.h"
#include "ENESMBusController.h"
#include "ENESMBusInterface_i2c_smbus.h"
@ -6,9 +18,6 @@
#include "RGBController_ENESMBus.h"
#include "i2c_smbus.h"
#include "pci_ids.h"
#include <vector>
#include <stdio.h>
#include <stdlib.h>
#include "dmiinfo.h"
#define DETECTOR_NAME "ENE (ASUS Aura) SMBus Controller"

View file

@ -1,15 +1,18 @@
/*-----------------------------------------*\
| ENESMBusInterface.h |
| |
| Definitions and types for ENE interface |
| |
| Adam Honse (CalcProgrammer1) 11/21/2021 |
\*-----------------------------------------*/
#include <string>
/*---------------------------------------------------------*\
| ENESMBusInterface.h |
| |
| ENE SMBus interface |
| |
| Adam Honse (CalcProgrammer1) 21 Nov 2021 |
| |
| This file is part of the OpenRGB project |
| SPDX-License-Identifier: GPL-2.0-only |
\*---------------------------------------------------------*/
#pragma once
#include <string>
typedef unsigned short ene_register;
typedef unsigned char ene_dev_id;
typedef unsigned int ene_interface_type;

View file

@ -1,10 +1,13 @@
/*-----------------------------------------*\
| ENESMBusInterface_ROGArion.cpp |
| |
| Code for ENE ASUS ROG Arion interface |
| |
| Adam Honse (CalcProgrammer1) 9/17/2023 |
\*-----------------------------------------*/
/*---------------------------------------------------------*\
| ENESMBusInterface_ROGArion.cpp |
| |
| ENE SMBus interface for ASUS ROG Arion |
| |
| Adam Honse (CalcProgrammer1) 17 Sep 2023 |
| |
| This file is part of the OpenRGB project |
| SPDX-License-Identifier: GPL-2.0-only |
\*---------------------------------------------------------*/
#include "ENESMBusInterface_ROGArion.h"

View file

@ -1,11 +1,13 @@
/*-----------------------------------------*\
| ENESMBusInterface_ROGArion.h |
| |
| Definitions and types for ENE ASUS ROG |
| Arion interface |
| |
| Adam Honse (CalcProgrammer1) 9/17/2023 |
\*-----------------------------------------*/
/*---------------------------------------------------------*\
| ENESMBusInterface_ROGArion.h |
| |
| ENE SMBus interface for ASUS ROG Arion |
| |
| Adam Honse (CalcProgrammer1) 17 Sep 2023 |
| |
| This file is part of the OpenRGB project |
| SPDX-License-Identifier: GPL-2.0-only |
\*---------------------------------------------------------*/
#pragma once

View file

@ -1,16 +1,18 @@
/*-----------------------------------------*\
| ENESMBusInterface_SpectrixS40G.cpp |
| |
| Code for ENE XPG Spectrix S40G NVMe |
| interface |
| |
| Adam Honse (CalcProgrammer1) 11/21/2021 |
\*-----------------------------------------*/
/*---------------------------------------------------------*\
| ENESMBusInterface_SpectrixS40G_Linux.cpp |
| |
| ENE SMBus interface for XPG Spectrix S40G (Linux) |
| |
| Adam Honse (CalcProgrammer1) 21 Nov 2021 |
| |
| This file is part of the OpenRGB project |
| SPDX-License-Identifier: GPL-2.0-only |
\*---------------------------------------------------------*/
#include "ENESMBusInterface_SpectrixS40G_Linux.h"
#include <sys/ioctl.h>
#include <cstring>
#include <cstdint>
#include <cstring>
#include <sys/ioctl.h>
#include "ENESMBusInterface_SpectrixS40G_Linux.h"
/*---------------------------------------------------------------------*\
| Functions for submitting NVME admin passthrough command taken from |

View file

@ -1,16 +1,18 @@
/*-----------------------------------------*\
| ENESMBusInterface_SpectrixS40G.h |
| |
| Definitions and types for ENE XPG |
| Spectrix S40G NVMe interface |
| |
| Adam Honse (CalcProgrammer1) 11/21/2021 |
\*-----------------------------------------*/
#include "ENESMBusInterface.h"
/*---------------------------------------------------------*\
| ENESMBusInterface_SpectrixS40G_Linux.h |
| |
| ENE SMBus interface for XPG Spectrix S40G (Linux) |
| |
| Adam Honse (CalcProgrammer1) 21 Nov 2021 |
| |
| This file is part of the OpenRGB project |
| SPDX-License-Identifier: GPL-2.0-only |
\*---------------------------------------------------------*/
#pragma once
#include "ENESMBusInterface.h"
class ENESMBusInterface_SpectrixS40G : public ENESMBusInterface
{
public:

View file

@ -1,18 +1,19 @@
/*-----------------------------------------*\
| ENESMBusInterface_SpectrixS40G_Windows |
| |
| Code for ENE XPG Spectrix S40G NVMe |
| interface |
| Windows implementation |
| |
| Adam Honse (CalcProgrammer1) 11/21/2021 |
\*-----------------------------------------*/
#include "ENESMBusInterface_SpectrixS40G_Windows.h"
/*---------------------------------------------------------*\
| ENESMBusInterface_SpectrixS40G_Windows.cpp |
| |
| ENE SMBus interface for XPG Spectrix S40G (Windows) |
| |
| Adam Honse (CalcProgrammer1) 21 Nov 2021 |
| |
| This file is part of the OpenRGB project |
| SPDX-License-Identifier: GPL-2.0-only |
\*---------------------------------------------------------*/
#include <fileapi.h>
#include <winioctl.h>
#include <nvme.h>
#include <winioctl.h>
#include "ENESMBusInterface_SpectrixS40G_Windows.h"
ENESMBusInterface_SpectrixS40G::ENESMBusInterface_SpectrixS40G(HANDLE fd, wchar_t* path)
{

View file

@ -1,18 +1,19 @@
/*-----------------------------------------*\
| ENESMBusInterface_SpectrixS40G_Windows.h |
| |
| Definitions and types for ENE XPG |
| Spectrix S40G NVMe interface |
| Windows implementation |
| |
| Adam Honse (CalcProgrammer1) 11/21/2021 |
\*-----------------------------------------*/
#include "ENESMBusInterface.h"
#include <windows.h>
/*---------------------------------------------------------*\
| ENESMBusInterface_SpectrixS40G_Windows.h |
| |
| ENE SMBus interface for XPG Spectrix S40G (Windows) |
| |
| Adam Honse (CalcProgrammer1) 21 Nov 2021 |
| |
| This file is part of the OpenRGB project |
| SPDX-License-Identifier: GPL-2.0-only |
\*---------------------------------------------------------*/
#pragma once
#include <windows.h>
#include "ENESMBusInterface.h"
class ENESMBusInterface_SpectrixS40G : public ENESMBusInterface
{
public:

View file

@ -1,10 +1,13 @@
/*-----------------------------------------*\
| ENESMBusInterface_i2c_smbus.cpp |
| |
| Code for ENE I2C/SMBus interface |
| |
| Adam Honse (CalcProgrammer1) 11/21/2021 |
\*-----------------------------------------*/
/*---------------------------------------------------------*\
| ENESMBusInterface_i2c_smbus.cpp |
| |
| ENE SMBus interface for I2C/SMBus |
| |
| Adam Honse (CalcProgrammer1) 21 Nov 2021 |
| |
| This file is part of the OpenRGB project |
| SPDX-License-Identifier: GPL-2.0-only |
\*---------------------------------------------------------*/
#include "ENESMBusInterface_i2c_smbus.h"

View file

@ -1,17 +1,19 @@
/*-----------------------------------------*\
| ENESMBusInterface_i2c_smbus.h |
| |
| Definitions and types for ENE I2C/SMBus |
| interface |
| |
| Adam Honse (CalcProgrammer1) 11/21/2021 |
\*-----------------------------------------*/
/*---------------------------------------------------------*\
| ENESMBusInterface_i2c_smbus.h |
| |
| ENE SMBus interface for I2C/SMBus |
| |
| Adam Honse (CalcProgrammer1) 21 Nov 2021 |
| |
| This file is part of the OpenRGB project |
| SPDX-License-Identifier: GPL-2.0-only |
\*---------------------------------------------------------*/
#pragma once
#include "ENESMBusInterface.h"
#include "i2c_smbus.h"
#pragma once
class ENESMBusInterface_i2c_smbus : public ENESMBusInterface
{
public:

View file

@ -1,10 +1,13 @@
/*-----------------------------------------*\
| RGBController_ENESMBus.cpp |
| |
| Generic RGB Interface for ENE SMBus |
| |
| Adam Honse (CalcProgrammer1) 6/13/2019 |
\*-----------------------------------------*/
/*---------------------------------------------------------*\
| RGBController_ENESMBus.cpp |
| |
| RGBController for ENE SMBus devices |
| |
| Adam Honse (CalcProgrammer1) 13 Jun 2019 |
| |
| This file is part of the OpenRGB project |
| SPDX-License-Identifier: GPL-2.0-only |
\*---------------------------------------------------------*/
#include "RGBController_ENESMBus.h"
#include "LogManager.h"

View file

@ -1,10 +1,13 @@
/*-----------------------------------------*\
| RGBController_ENESMBus.h |
| |
| Generic RGB Interface for ENE SMBus |
| |
| Adam Honse (CalcProgrammer1) 6/13/2019 |
\*-----------------------------------------*/
/*---------------------------------------------------------*\
| RGBController_ENESMBus.h |
| |
| RGBController for ENE SMBus devices |
| |
| Adam Honse (CalcProgrammer1) 13 Jun 2019 |
| |
| This file is part of the OpenRGB project |
| SPDX-License-Identifier: GPL-2.0-only |
\*---------------------------------------------------------*/
#pragma once

View file

@ -1,11 +1,19 @@
/*---------------------------------------------------------*\
| ROGArionDetect.cpp |
| |
| Detector for ASUS ROG Arion |
| |
| This file is part of the OpenRGB project |
| SPDX-License-Identifier: GPL-2.0-only |
\*---------------------------------------------------------*/
#include <vector>
#include "Detector.h"
#include "ENESMBusController.h"
#include "ENESMBusInterface_ROGArion.h"
#include "LogManager.h"
#include "RGBController.h"
#include "RGBController_ENESMBus.h"
#include <vector>
#include "scsiapi.h"
/******************************************************************************************\

View file

@ -1,16 +1,24 @@
/*---------------------------------------------------------*\
| XPGSpectrixS40GDetect_Linux.cpp |
| |
| Detector for XPG Spectrix S40G (Linux) |
| |
| This file is part of the OpenRGB project |
| SPDX-License-Identifier: GPL-2.0-only |
\*---------------------------------------------------------*/
#include <dirent.h>
#include <fcntl.h>
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <vector>
#include "Detector.h"
#include "ENESMBusController.h"
#include "ENESMBusInterface_SpectrixS40G_Linux.h"
#include "LogManager.h"
#include "RGBController.h"
#include "RGBController_ENESMBus.h"
#include <vector>
#include <stdio.h>
#include <stdlib.h>
#include <fcntl.h>
#include <unistd.h>
#include <dirent.h>
/******************************************************************************************\
* *

View file

@ -1,16 +1,25 @@
/*---------------------------------------------------------*\
| XPGSpectrixS40GDetect_Windows.cpp |
| |
| Detector for XPG Spectrix S40G (Windows) |
| |
| This file is part of the OpenRGB project |
| SPDX-License-Identifier: GPL-2.0-only |
\*---------------------------------------------------------*/
#include <fileapi.h>
#include <stdio.h>
#include <stdlib.h>
#include <vector>
#include <windows.h>
#include "Detector.h"
#include "ENESMBusController.h"
#include "ENESMBusInterface_SpectrixS40G_Windows.h"
#include "LogManager.h"
#include "RGBController.h"
#include "RGBController_ENESMBus.h"
#include <vector>
#include <stdio.h>
#include <stdlib.h>
#define DEVBUFSIZE (128 * 1024)
#include <windows.h>
#include <fileapi.h>
/*----------------------------------------------------------------------*\
| Windows defines "interface" for some reason. Work around this |