Skip to content
This repository was archived by the owner on May 6, 2021. It is now read-only.

Commit 022ed45

Browse files
committed
Fixed bug in x86 compile
1 parent 447458a commit 022ed45

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

libsrc/leddevice/LedDeviceFactory.cpp

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,16 @@ LedDevice * LedDeviceFactory::construct(const Json::Value & deviceConfig)
6363

6464
device = deviceLpd8806;
6565
}
66+
else if (type == "p9813")
67+
{
68+
const std::string output = deviceConfig["output"].asString();
69+
const unsigned rate = deviceConfig["rate"].asInt();
70+
71+
LedDeviceP9813* deviceP9813 = new LedDeviceP9813(output, rate);
72+
deviceP9813->open();
73+
74+
device = deviceP9813;
75+
}
6676
else if (type == "ws2801" || type == "lightberry")
6777
{
6878
const std::string output = deviceConfig["output"].asString();
@@ -146,16 +156,6 @@ LedDevice * LedDeviceFactory::construct(const Json::Value & deviceConfig)
146156

147157
device = deviceWs2812b;
148158
}
149-
else if (type == "p9813")
150-
{
151-
const std::string output = deviceConfig["output"].asString();
152-
const unsigned rate = deviceConfig["rate"].asInt();
153-
154-
LedDeviceP9813* deviceP9813 = new LedDeviceP9813(output, rate);
155-
deviceP9813->open();
156-
157-
device = deviceP9813;
158-
}
159159
else
160160
{
161161
std::cout << "Unable to create device " << type << std::endl;

0 commit comments

Comments
 (0)