mirror of
https://github.com/hyperion-project/hyperion.ng.git
synced 2025-03-01 10:33:28 +00:00
Lightpack device added based on hidapi
Former-commit-id: 4d3d9c01b169991757587a67479094186d52e6e8
This commit is contained in:
@@ -20,6 +20,7 @@
|
||||
#include "device/LedDeviceWs2801.h"
|
||||
#include "device/LedDeviceAdalight.h"
|
||||
#include "device/LedDeviceLightpack.h"
|
||||
#include "device/LedDeviceLightpack-hidapi.h"
|
||||
#include "device/LedDeviceMultiLightpack.h"
|
||||
|
||||
#include "LinearColorSmoothing.h"
|
||||
@@ -94,6 +95,15 @@ LedDevice* Hyperion::createDevice(const Json::Value& deviceConfig)
|
||||
|
||||
device = deviceLightpack;
|
||||
}
|
||||
else if (type == "lightpack-hidapi")
|
||||
{
|
||||
const std::string output = deviceConfig.get("output", "").asString();
|
||||
|
||||
LedDeviceLightpackHidapi* deviceLightpack = new LedDeviceLightpackHidapi();
|
||||
deviceLightpack->open(output);
|
||||
|
||||
device = deviceLightpack;
|
||||
}
|
||||
else if (type == "multi-lightpack")
|
||||
{
|
||||
LedDeviceMultiLightpack* deviceLightpack = new LedDeviceMultiLightpack();
|
||||
|
Reference in New Issue
Block a user