Set default output device for WS2812SPI (#724)

With this change the WS2812SPI device works with Hypercon out of the box.
This commit is contained in:
Rick van Hattem 2016-09-06 22:58:55 +02:00 committed by brindosch
parent dd7dba2233
commit 355a324523
1 changed files with 1 additions and 1 deletions

View File

@ -146,7 +146,7 @@ LedDevice * LedDeviceFactory::construct(const Json::Value & deviceConfig)
}
else if (type == "ws2812spi")
{
const std::string output = deviceConfig["output"].asString();
const std::string output = deviceConfig.get("output", "/dev/spidev0.0").asString();
const unsigned rate = deviceConfig.get("rate",2857143).asInt();
LedDeviceWs2812SPI* deviceWs2812SPI = new LedDeviceWs2812SPI(output, rate);