Skip to content

Commit

Permalink
Merge pull request #19 from alexschwantes/color-not-sent-on-state-iss…
Browse files Browse the repository at this point in the history
…ue-18

Fixing issue #18 where color was not being sent on MQTT state when in…
  • Loading branch information
smrtnt committed Apr 23, 2017
2 parents bac0878 + 3bf017e commit cd8d8f7
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions Arilux_AL-LC0X.ino
Original file line number Diff line number Diff line change
Expand Up @@ -815,9 +815,10 @@ void handleCMD(void) {
root["brightness"] = arilux.getBrightness();
// root["transition"] =
root["white_value"] = arilux.getWhite1Value();
root["color"]["r"] = arilux.getRedValue();
root["color"]["g"] = arilux.getGreenValue();
root["color"]["b"] = arilux.getBlueValue();
JsonObject& color = root.createNestedObject("color");
color["r"] = arilux.getRedValue();
color["g"] = arilux.getGreenValue();
color["b"] = arilux.getBlueValue();
root.printTo(outgoingJsonBuffer);
publishToMQTT(ARILUX_MQTT_JSON_STATE_TOPIC, outgoingJsonBuffer);
};
Expand Down

0 comments on commit cd8d8f7

Please sign in to comment.